I'm finding myself having to do this every once in a while, and was wondering if there's a way to simplify this command?
In essence, all I'm doing is copying a file and re-naming it. The functionality to create A1, A2.. B1, B2..
is non-negotiable :) Thus, the nested for loop.
Note, I'm not interested in creating an actual script file. I need something quick and dirty.
bash> for x in {A..B}; do for i in {1..4};do cp orig.xml prefix_$x$i.xml; done;done
System Info
Platform: SunOS
Bash Version: GNU bash, version 3.00.16(1)-release (i386-pc-solaris2.10)