Module luarocks.tools.zip
(no description)
Functions
write_open (name) | Return a zip handle open for writing. |
write_open_new_file_in_zip (zf, filename) | Begin a new file to be stored inside the zipfile. |
write_in_file_in_zip (zf, buf) | Write data to the file currently being stored in the zipfile. |
write_close_file_in_zip (zf) | Complete the writing of a file stored in the zipfile. |
write_close (zf) | Complete the writing of the zipfile. |
zip (zipfile, ...) | Compress files in a .zip archive. |
Functions
- write_open (name)
-
Return a zip handle open for writing.
Parameters:
name
: filename of the zipfile to be created.
Returns:
-
a zip handle, or nil in case of error.
- write_open_new_file_in_zip (zf, filename)
-
Begin a new file to be stored inside the zipfile.
Parameters:
zf
: handle of the zipfile being written.filename
: filenome of the file to be added to the zipfile.
Returns:
-
true if succeeded, nil in case of failure.
- write_in_file_in_zip (zf, buf)
-
Write data to the file currently being stored in the zipfile.
Parameters:
zf
: handle of the zipfile being written.buf
: string containing data to be written.
Returns:
-
true if succeeded, nil in case of failure.
- write_close_file_in_zip (zf)
-
Complete the writing of a file stored in the zipfile.
Parameters:
zf
: handle of the zipfile being written.
Returns:
-
true if succeeded, nil in case of failure.
- write_close (zf)
-
Complete the writing of the zipfile.
Parameters:
zf
: handle of the zipfile being written.
Returns:
-
true if succeeded, nil in case of failure.
- zip (zipfile, ...)
-
Compress files in a .zip archive.
Parameters:
zipfile
: string: pathname of .zip archive to be created....
: Filenames to be stored in the archive are given as additional arguments.
Returns:
-
boolean or (boolean, string): true on success,
false and an error message on failure.