in reply to Easy Things

Other responses have latched on to perl -e and that's probably one good avenue to explore. Here's a real-world example for you. I recently downloaded a bunch of files from a Windows system and uploaded them to a FreeBSD system, only to find that the spaces in the file names had been encoded so they were now '%20'. I had to rename three directories, each containing six files.

After wimping out on the first two directories (this was time critical stuff and it was after midnight, a great time for making dumb mistakes, especially after a jam-packed 11 hour work day) I wrote

perl -e 'while(<*.mp3>){$orig=$_;s/%20/ /;print"$orig -> $_\n";}'
That seemed OK, but then I realized I'd have to escape the space in the middle of the name, so finally I wrote
perl -e 'while(<*.mp3>){$orig=$_;s/%20/\\ /;print`mv -v $orig $_`;}'
I ran it, and the verbose option confirmed that I'd done it correctly.

So what did that require that I wouldn't have had a clue how to do as a beginner?

Well, that's not exactly an earth-shatteringly important list, but that's what I can squeeze out of that lemon.

Alex / talexb / Toronto

Life is short: get busy!