I wish to store a few folders in a zip file and then convert that zip file into a jar.
I have the following folders :
I tried the following command:
zip META-INF/ org/ wordcount.zip
But wordcount.zip was not created.
Ask Ubuntu is a question and answer site for Ubuntu users and developers. It only takes a minute to sign up.Sign up to join this community
The syntax is the other way around; you give the name of the
.zip file to create first in the list. Also, use the
-r flag for recursion into directories:
zip -r wordcount.zip META-INF org
This creates a file
wordcount.zip (you may be able to omit the
.zip in the command as this is automatically added if possible) with all the contents of the two directories