Please note: the Wiki entry for the Zip module still reads: "It may soon be replaced by the Archive Module. "
I agree, the wording is a bit fuzzy. Indeed we wanted to remove the ZIP Module, but as it’s still used in some applications, it’s still available. What better wording do you have in mind? Maybe something like "We recommend you to use the newer Archive Module."?
Kind regards, C.
-----Original Message----- From: Christian Grün [mailto:christian.gruen@gmail.com] Sent: 17 November 2015 19:31 To: Hondros, Constantine (ELS-AMS) Cc: basex-talk@mailman.uni-konstanz.de Subject: Re: [basex-talk] zip:update-entries - unexpected results
We didn’t spend energy in the ZIP Module for a long time. Did you try to use the Archive Module?
On Mon, Nov 16, 2015 at 5:06 PM, Hondros, Constantine (ELS-AMS) C.Hondros@elsevier.com wrote:
Hi all,
I’m attempting to create a modified copy a zipfile using zip:update-entries, but my output is a zip structure with zero-byte files. Am I missing a step? I’ve followed the example in: http://docs.basex.org/wiki/ZIP_Module#zip:update-entries
Code snippet as follows:
declare function util:clean-zip($zip as xs:string, $out as xs:string) {
copy $doc := zip:entries($zip)
modify delete node $doc//zip:entry[ends-with(lower-case(@name), '.pdf')]
return zip:update-entries($doc, $out)
};
Thanks for any pointers ;-)
C.
Elsevier B.V. Registered Office: Radarweg 29, 1043 NX Amsterdam, The Netherlands, Registration No. 33156677, Registered in The Netherlands.
Elsevier B.V. Registered Office: Radarweg 29, 1043 NX Amsterdam, The Netherlands, Registration No. 33156677, Registered in The Netherlands.