Search This Blog


Batch Rename Files With Sed

To rename files we get a list of files, match a patern, and copy to a destination with that new regex filename

Validate Functionality

for i in `ls /path/to/files/`; do echo $i | sed "s/winxp/windows/"; done

Commit Changes

for i in `ls /path/to/files/ | grep winxp`; do cp /path/to/files/$i `echo /path/to/files/$i | sed "s/winxp/windows/"`; done


No comments:

Post a Comment