Shell

Shell One Liners

May 21, 2010 // 0 Comments

Renaming file name.old to name.new – To test things first, insert ‘echo’ between ‘do mv’ (below).

$ for i in *.input; do mv $i ${i/name.old/name.new}; done

Running application in loops on many input files

$ for i in *.input; do ./application $i; done