Chima Nwosu said:
Windows Media Player has reorganized my music folder so that each of my over
3000 mp3s is now in at least one folder ( some are buried three folders
deep). I didn't want this to happen and have now turned off the option
allowing the player to do this, but I still have the problem of how to get
back to how my music folder was organized before the intervention of WMP.
Does anyone know of a freeware program that will allow me to simultaneously
extract the contents of over 3000 folders so that they can be saved in just
one folder, with no subfolders.
I'd use XXCopy, with a switch from the /SG family. Not only will XXCopy
be much cleaner and stronger to do the job over GUI drag actions, but
it also has some useful options. Particularly: the automatic rename in
case of filename collision. (And misc other options available, such as
logging the process, faithful to the SFNs, deleting from source after
successful move, exclusions if wanted, etc.)
http://www.xxcopy.com/xxcopy16.htm
"Gathering files into one directory using XXCOPY"
..............................................................................
[BATCH SAMPLES]
The file below is sample only. Might help as a starter point.
-----------Sample1.bat---------------------
@echo off
set src="C:\Example\Windows Media Player\*.mp3"
set dst="D:\Example\Data\My MP3s\"
:: Don't use a destination directory within the path of the source directory.
:: XXCopy has the ability, via custom command, to avoid an infinite recursion
:: loop, but it'd be simpler to just use an independent destination directory.
xxcopy %src% %dst% /SG /h/r/ks
:: /SG gathers the files into a single directory
:: /h/r/ks include hidden & read-only files, keep attribs
-----------/Sample1.bat---------------------
The following is a variation of the above, but containg data-destructive
commands. And my sample, I might be blind, for all I know, to some bad error.
So proceed thoughtfully. But the reason I went to the second one
here is that your operation could benefit from some cleanup of the source
directory during that copy process.
-----------Sample2.bat---------------------
@echo off
echo *data destructive* !!
set src="C:\Example\Windows Media Player\*.mp3"
set dst="D:\Example\Data\My MP3s\"
:: Don't use a destination directory within the path of the source directory.
:: XXCopy has the ability, via custom command, to avoid an ini finite
recursion
:: loop, but it'd be simpler to just use an independent destination directory.
xxcopy %src% %dst% /SG /RCY /PD0 /h/r/ks/i0
:: /SG gathers the files into a single directory
:: /RCY will delete those files from the source after copy
:: /PD0 will suppress the prompt that has you confirm permission to delete
:: /h/r/ks include hidden & read-only files, keep attribs
pause
:: Now kill leftover empty directories.
:: REM xxcopy %dst% /RSY /H /R /S /X*
:: Or, use RMempty to kill the empty directories.
RMempty.exe %dst%
GOTO :EOF
:EOF
-----------/Sample2.bat---------------------
..............................................................................
[URLs]
RMempty
http://www.jsiinc.com/SUBL/tip5500/rh5538.htm
http://www.otbsw.com/Files/rmemp12.zip
XXCopy
http://www.xxcopy.com/index.htm
http://www.xxcopy.com/xxcopy16.htm
http://www.xxcopy.com/download/xxcopy.zip
http://www.xxcopy.com/download/xxcopy.chm
..............................................................................
[MORE HELP]
The author of the program, Kan Yamamoto, has written some very helpful
messages to users, over time, including illustrative explanations on
using the directory flattening/gathering feature of XXCopy.
I'd thought of trying to include some references links to pertinent
messages, or even pasting some excerpts from my archives, but in the
end I decided not worth the hassle. If you want to do the lookup yourself,
though, keywords might be something like: xxcopy Kan gather OR flatten.
Kan used to post fairly regularly on netnews. More recent few years I
suppose that most of the gold over at the Yahoo Groups site. Fortunately
he mirrors a copy of the archives on his own site, so one can avoid Yahoo
if only seeking to read.
..............................................................................
[EN BREF?]
Of course you might not be inclined into delving into a lot of XXCopy
learning at the moment. I believe that you'll be fine if not, and
assuming you've used the command prompt before. Basically all you
have to do is run XXCopy with the /SG switch to accomplish your task.
Only item is be attentive about specifying your source and destination
directories. For this project, don't use one that is within the other.
And follow syntax rules: surround directory names in quotes, and end
them with a trailing backslash.