Skip to content

Instantly share code, notes, and snippets.

@hrickards
Created July 22, 2011 12:32
Show Gist options
  • Save hrickards/1099362 to your computer and use it in GitHub Desktop.
Save hrickards/1099362 to your computer and use it in GitHub Desktop.
Finds, moves, renames and lowercases downloaded How I Met Your Mother videos
cd /home/harry/Downloads/complete
mv \[180*\]-\[FULL\]-\[*.teevee\@EFNet\]-\[\ How.I.Met.Your.Mother*/*.avi /home/harry/Videos/How_I_Met_Your_Mother/
cd /home/harry/Videos/How_I_Met_Your_Mother
for file in *ow.*.*et.*our.*other* ; do mv $file `echo $file | cut -d. -f6`'.avi' ; done
for f in `find`; do mv -v $f `echo $f | tr '[A-Z]' '[a-z]'`; done
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment