A
A
and7ey2014-01-18 15:21:53
Command line
and7ey, 2014-01-18 15:21:53

How to exclude @eaDir folders from zip or tar archive?

You need to create an archive from the command line on the NASe without installing additional packages.
It has:

  • Zip 3.0 (July 5th 2008)
  • tar (unknown version, BusyBox v1.16.1)
(man'a on NASe, unfortunately, no)
The folder structure is something like this:
- photos
    - 2011
      - 2011.01.01 - album1
        - @eaDir
      - 2011.02.01 - album 2
        - @eaDir

I'm trying to do:
zip -r -x "arw" "*.arw" "@eaDir" ".DS_Store" -0 -o -s 30g -db -lf /volume1/zip.log -li -e -P pass photos.zip /volume1/photo

But the @eaDir folders still end up in the archive. I can't figure out whether it's necessary to specify that the exception should also apply to subfolders, or whether the @ symbol needs to be escaped somehow.
With tar, the situation is even more interesting - it does not understand the `--exclude` option.

Answer the question

In order to leave comments, you need to log in

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question