When I do
7z a test.zip -x!*discarded* test
with
test/test/a.txttest/subfolder/test/subfolder/a.txttest/subfolder/discarded/test/subfolder/discarded/a.txttest/subfolder2/a.txttest/subfolder2/subfolder3/a.txttest/subfolder2/subfolder3/discarded/test/subfolder2/subfolder3/discarded/a.txt
then, unfortunately, everything is still included!
How to exclude every file/folder like */discarded/*
? (or, alternatively, exclude any file/folder whose absolute path contains discarded
?)
Also, how to exclude all files ending by .txt
? (-x!*.txt
doesn't work)
I use 7z on Windows.
Note: 7Zip - Command Line : Exclude folder(s) by wildcard pattern? didn't help here.