Tested, it works when only the exlucde mask use relative path. Thanks alot~ i.e. 7z a e:\temp\Basefolder.7z -x!Basefolder\data\*\ e:\temp\Basefolder
Sorry, just found that it does not work if I use full file path. i.e. 7z a e:\temp\Basefolder.7z -x!e:\temp\Basefolder\data\*\ e:\temp\Basefolder With full file path, it simply includes everything. And for your information, I am using version 9.20 because it is the version installed in the environment I need to do the compression on.
Sorry, just found that it does not work if I use full file path. i.e. 7z a e:\temp\Basefolder.7z -x!e:\temp\Basefolder\data*\ e:\temp\Basefolder With full file path, it simply includes everything. And for your information, I am using version 9.20 because it is the version installed in the environment I need to do the compression on.
It works. Thanks alot~
Assume we have a folder structure like this: Basefolder |--data |--system1 |--personal |--testing |--doc |--photo i.e. "data", "doc", "photo" are level 1 subfolder under "Basefolder". "system1", "personal", "testing" are level 2 subfolder under "data". And assume there are files under every subfolders. When creating a 7z archive of "Basefolder" by 7zip command line options, is it possible to exclude all subfolders under "data", but include all files directly inside "data"? The folder name "data"...
Assume we have a folder structure like this: Basefolder |--data |--system1 |--personal |--testing |--doc |--photo i.e. "data", "doc", "photo" are level 1 subfolder under "Basefolder". "system1", "personal", "testing" are level 2 subfolder under "data". And assume there are files under every subfolders. When creating a 7z archive of "Basefolder" by 7zip command line options, is it possible to exclude all subfolders under "data", but include all files directly inside "data"? The folder name "data"...