Unix & Linux Stack Exchange is a question and answer site for users of Linux, FreeBSD and other Un*x-like operating systems. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I want to zip numerous files from different directories(paths) in one line. How can I do that?

share|improve this question
up vote 7 down vote accepted

I'm probably misunderstanding you, but you just specify the paths one after the other:

zip foo.zip /path/to/first/file /path/to/second/file
share|improve this answer
Ah... Thank you. New to linux... – JohnRoach Aug 27 '10 at 6:25

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.