#1
|
|||
|
|||
Zip Function for adding sub directories
I am using the built in Zip function and have the following directory structure.
C:\ CodeDir\ ProgramA\ ProgramB\ ProgramC\ I want to zip up sub folders ProgramA and ProgramC but want to exclude ProgramB. I have set the source folder to C:\CodeDir. I then tried excluding ProgramB\*.* but this zip everything including ProgramB. Therefore, I then tried including just ProgramA and ProgramC but this did not zip anything. The option is set for including sub folders.My questions is how can I just zip ProgramA and ProgramC without including ProgramB? As a side question, what is the benefit of “Append to existing file (don’t use temporary file)”? I can not find anything in the help about this option. Thanks ahead of time... |
#2
|
|||
|
|||
I'm not sure, a similar test here works as expected:
<step action='ZIP Files' type='0'> <Action type='3'>2</Action> <Compression>5</Compression> <Delete type='11'>-1</Delete> <Dest>%TEMP%\test.zip</Dest> <ExclExt>User Actions\*.*</ExclExt> <Hidden type='11'>-1</Hidden> <LogDetail type='11'>-1</LogDetail> <Recurse type='11'>-1</Recurse> <Source>%VISBUILDDIR%\Samples</Source> <indent type='3'>1</indent> <name>zip</name> </step> You can copy and paste the text above into VisBuildPro. On my box, it excludes the files in the Samples\User Actions folder but includes all the other ones; if the exclude field is cleared, the files in that folder are included in the ZIP file. The 'append to existing file' option does basically what it says, modifying the existing ZIP file rather than creating a temporary file and replacing the original with it when performing an update. It might be beneficial when working with really large ZIP files or when disk space is low. |
#3
|
|||
|
|||
Thanks for the quick reply. The problem comes from the "Save full path info". If you check this check box, then the includes and excludes are ignored. If you uncheck this box, then it works as described. Is this how it is supposed to work?
|
#4
|
|||
|
|||
Ah. Then you will need to specify the full path in the exclude field (%VISBUILDDIR%\Samples\User Actions\*.* in my sample).
|
#5
|
|||
|
|||
This is supported in the Enhanced ZIP Files action in v8.0.
|
Thread Tools | |
Display Modes | Rate This Thread |
|
|