Mass Zipping


DemonStar55

chai chai chai chai chai chai chai chai chai chai
Joined
Nov 24, 2003
Messages
1,889
Age
35
Location
Wrentham, MA
Website
demonstar55.phpnet.us
well I need a program (GUI or command line), for linux, that will take about 1000 files totaling liek 7 GB and just zipping and deleteing the source file because I need some hdd space. I know there was an app for windows that did this just I forget the name, might be possible to run through WINE.
 
Code:
for file in *; do zip -m $file.zip $file; done
so I CD to the directory and type zip -m $file.zip $file and it will just take every file in that directory and zip them?

edit: nvm if I just select the files and compress them with ark it does it apparently
edit2: nvm it doesn't seem to want to work on that PC...
 
Last edited by a moderator:
No, you just CD in the directory and type "for file in *; do zip -m $file.zip $file; done".
Since you are using Linux, you can also use bzip2 wich is better than zip.
Code:
for file in *; do bzip2 -f $file; done
(the -f flag will delete the uncompressed file)
 
No, you just CD in the directory and type "for file in *; do zip -m $file.zip $file; done".
Since you are using Linux, you can also use bzip2 wich is better than zip.
Code:
for file in *; do bzip2 -f $file; done
(the -f flag will delete the uncompressed file)
arg, famn it doesn't work with spaces in the filenames :(

and Im not sure if the program Im using supports bzip2, know it supports zip tho

EDIT: alright I added some quotes, works now :)

thank you people for your troubles
 
Last edited by a moderator:
Last edited by a moderator:
Back
Top