Nav: Home
Welcome, Guest. Please login or register.
Did you miss your activation email?
May 26, 2012, 19:59

Login with username, password and session length

MicrostockGroup

Microstockgroup Sponsors


« previous next »
Pages: [1] Print

Topic: Script or similar to zip files based on file names  

(Read 533 times)
Microbius
« on: August 30, 2011, 05:27 »

I am looking for a way of automating the following:
I have folders of illustrations each one as a jpeg file and also as an eps file. The two files for each illustration share the same name apart from the extension.
Is there an automated way of getting Windows to zip the pairs together in one zip file each.
It's proving to be very time consuming going through the folders and doing this by hand.


Ignore | Logged


DepositPhotos.com
microstockphoto.co.uk


Dreamstime GaugeiStock Gauge
« Reply #1 on: August 30, 2011, 06:35 »

I had the same problem... not a completely automated solution but the best I found:

from the dos command line:

c:\>dir /s /b *.eps >c:\filename.bat

(/s lists subdirectories; /b outputs file name only without headers; >filename.bat sends output to file)

open c:\filename.bat with a text editor and replace text in each line
in order to replace <filename>.eps with pkzip <filename>.* <filename>.zip
you may have to do this part manually through copy and past but it's still faster

put pkzip.exe in the same folder (you need an old command line version of PkZip)

launch filename.bat

seems a bit crooked but saves time in the end
« Last Edit: August 30, 2011, 06:40 by microstockphoto.co.uk »

Ignore | Logged


Microbius
« Reply #2 on: August 30, 2011, 09:20 »

Thanks Claudio but I fear the dos prompt! Your post is going to get a heart anyhow for taking the time to post.


Ignore | Logged


microstockphoto.co.uk


Dreamstime GaugeiStock Gauge
« Reply #3 on: August 30, 2011, 09:30 »

yes, the dos prompt can be scary but it's so cool!


Ignore | Logged


Envateo Photo ToolsMicrostock Insider
Pages: [1] Print 
« previous next »
Jump to:  


TinyPortal v1.0.5 beta 1© Bloc