7ZIP - Command Line Compression | Can Never Keep it Simple
- by OneTwoYou
I've been Googleing for a few hours on how to just compress a file inside a directory and I can't find anything. I found how to just compress a folder in general. Now I wish to know how I can compress a folder in a folder with a file. Current code:
7zG.exe a -tzip "test.zip" dontcompressme/compressme/new.txt
pause
As you can see above, I don't want to compress the first folder, but only the second and what ever is within that folder. I have the 7zG.exe sitting in the main folder and I have some files that are three folders in, but I don't know how to only compress those. Here is my directory list:
Folder One (don't compress)
Folder Two (don't compress)
Folder Three (okay to compress)
Document One.txt (okay to compress)
Document Two.txt (okay to compress)
Index.html (okay to compress)
Does anyone know how I can do this in the most simplest way ever invented by man? Cause whenever I go to a website using Google it goes throw all these methods on how to compress a folder, but not do it the way I wish it to do. It makes me kinda upset cause I can't get a simple and straight forward answer. Thank you if you answer my question.