ziputil

package
v0.0.0-...-c39e8e5 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 27, 2022 License: AGPL-3.0 Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func OpenInTemp

func OpenInTemp(r io.Reader, tmp *tempfile.File) (*zip.Reader, error)

OpenInTemp copies all bytes of r into a temp file, and then opens the creates a zip reader that is backed by f.

func UnzipDir

func UnzipDir(dir string, r *zip.Reader, clear bool) error

UnzipDir unzips a zip file into a directory. If the directory already exists, it removes all stuff in the directory if the clear flag is set to true.

func ZipDir

func ZipDir(dir string, w io.Writer) error

ZipDir creates a zip file of a directory with all file in it.

func ZipFile

func ZipFile(file string, w io.Writer) error

ZipFile creates a zip file of a single file.

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL