
find:ai:bf859
zip excluding all files with recurring name in subdirectories
$ find ${directory} -type f -not -path '*/recurring_name/*' -exec zip archive.zip {} +
try on your machine
This command uses the find utility to search for all files in the specified directory and its subdirectories. It excludes any files with a recurring name in their path. The -exec option is used to pass the found files to the zip command and create a zip archive named 'archive.zip'.
This explanation was created by an AI. In most cases those are correct. But please always be careful and
never run a command you are not sure if it is safe.
Questions that are answered by this command:
- zip excluding all files with recurring name in subdirectories?