Quote:
Originally Posted by jolecanard
...Unfortunately I had already though using a loop but I still needed as many lines to do the job...(If I had to make 1000 copies that would be definitely better, but for 5 or 6...).
In fact I wanted to make sure there was not a built-in function capable to do that! 
|
Code:
while read file
do
i=12
while [ $i -lt 17 ]
do
cp -p "$file" /other/dir/"${file%.*}.$i"
i=$(($i + 1))
done
done < files_list
Code:
$ cat files_list
xsec.1.11
xsec.2.11
xsec.3.11
...
Set the counter
i (i=12) and the limit
(17) to whatever value you desire.