Two Plus Two Older Archives

Two Plus Two Older Archives (http://archives2.twoplustwo.com/index.php)
-   Computer Technical Help (http://archives2.twoplustwo.com/forumdisplay.php?f=46)
-   -   I want to save 1 image to X image files with different names. (http://archives2.twoplustwo.com/showthread.php?t=401435)

Jeff W 12-19-2005 03:36 PM

I want to save 1 image to X image files with different names.
 
I know this is kind of a strange question, but I'm hoping someone can help me out:

I want to save 1 image to X image files with different names and I have the list of names in a comma separated form: A.bmp, B.bmp, C.bmp, etc

I can change the list to a different form through liberal of grep if necessary. i.e. I can get it into the form "A.bmp" "B.bmp"...etc

I need to do this twice. Once for a bitmap and once for a jpeg.

Thanks.

jba 12-19-2005 04:16 PM

Re: I want to save 1 image to X image files with different names.
 
try this

awk '{split($0,names,","); for (i in names){printf "cp image.bmp %s;\n", names[ i ]}}' < names.txt

edit: the ubb code is screwing it up -- the "names[ i ]" part you need to take out the spaces


All times are GMT -4. The time now is 01:43 AM.

Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2024, vBulletin Solutions Inc.