Computational Magnetism York
Showing posts with label
formatting
.
Show all posts
Showing posts with label
formatting
.
Show all posts
Tuesday, 24 March 2009
Bash number formatting
Use printf as in c. For zero padding add a 0 infront of the field length, eg: %06i
So to delete more files than rm can handle
for i in `seq 0 100`; do file=`printf "%06i" "$i"`; echo $file; done
Home
Subscribe to:
Posts (Atom)