uce/site/doc/pages/zip_create.txt
2026-06-16 12:21:31 +00:00

31 lines
849 B
Plaintext

:sig
bool zip_create(String zip_file_name, DValue entries)
:params
zip_file_name : path to the archive to create
entries : map or list of archive entries
return value : `true` when the archive is written
:see
>sys
zip_list
zip_read
zip_extract
DValue
:content
Creates a ZIP archive at `zip_file_name`.
`entries` can be a simple map where each key is the archive member name and each value is the file content:
For list-shaped input or when the map key should not be the member name, each child can provide explicit fields:
An entry may also provide `file` instead of `content`; UCE reads that source file and stores its contents under `name`.
Entry names are normalized to forward slashes and rejected when they are absolute paths, drive-qualified paths, empty names, or contain `..` path segments.
:example
print("zip_create example\n");