How to zip specific files that are located in subdirectories

by Nasser   Last Updated April 15, 2019 11:02 AM - source

I have a directory that consists of many subdirectories, and each subdirectory contains different files such as:

Directory All contains subdirectories A, B, C, and D. Each subdirectory contains files such as:

A (Run1.csv, Run4.csv)
B (Run2.csv, Run3.csv)
C (Run1.csv, Run3.csv)
D (Run2.csv, Run4.csv)

As you can see, each file has different duplicates in different subdirectories. For example, Run1.csv in folder A has different data from Run1.csv in folder C.

What I want to do is that I want to zip a specific run file, for example, I want to zip all the files of run2. I used the following commands:

zip run2.zip All Run2.csv 

zip run2.zip Run2.csv 

But none of them works.

How can I fix that?



Related Questions



Run command with spaces on startup

Updated October 19, 2017 11:02 AM



How to install ZIP file

Updated May 08, 2017 22:02 PM