[Nottingham] Batch file renaming
Andrew Etches
seadog at mehmoo.com
Sun Jul 20 13:47:20 BST 2008
> >> Could someone suggest a way to rename all these files so as to strip the
> >> trailing ".128kbps" and leave the rest of the filename and folder names
> >> intact?
> >
> > OK, first:
> >
> > MAKE A FULL BACKUP OF EVERYTHING FIRST!
> >
> >
> > For take one, try:
> >
> > cd to the top directory, and:
> >
> > find . -name '*.128k' -print | while read n ; do mv -v "${n}"
> > "${n%.128k}" ; done
Wouldn't a basic 'cd musicdir; rename ".128kbps" "" */*' do?
More information about the Nottingham
mailing list