Hi Hernán, Thank you for your help. Although the zips now seem to be getting created properly, I'm running into another problem. When I try to unzip them I get an error that says: "Archive Utility Unable to expand filename.zip into "Resources". (Error 1 - Operation not permitted.) " I'm running on OSX lion. The error persists regardless of what directory I write the archive to. Any ideas? thanks, larry On Thu, Jan 5, 2012 at 9:30 AM, Hernán Morales Durand < hernan.morales@gmail.com> wrote:
| zip fileName myInputDir | myInputDir := #('Users' 'data' 'files' 'arabic') inject: '' into: [:path :suffix | path, FileDirectory slash , suffix]. zip := ZipArchive new. zip addTree: ( FileDirectory default fullName , myInputDir ) match: [: e | true ]. fileName := 'foo.zip'. zip writeToFileNamed: fileName.
2012/1/2 Larry White <ljw1001@gmail.com>:
zip := ZipArchive new. zipArchive addDirectory: '/Users/data/files/arabic' as: 'arabic'. fileName := 'Users/data/downloads/foo.zip'. zip writeToFileNamed: fileName.
-- Hernán Morales Information Technology Manager, Institute of Veterinary Genetics. National Scientific and Technical Research Council (CONICET). La Plata (1900), Buenos Aires, Argentina. Telephone: +54 (0221) 421-1799. Internal: 422 Fax: 425-7980 or 421-1799.