Documentation ¶
Index ¶
- func CreateJar(source, target string) error
- func CreateTar(destination io.Writer, source string) error
- func CreateTarGz(destination io.Writer, source string) error
- func Extract(source io.Reader, destination string, stripComponents int) error
- func ExtractTar(source io.Reader, destination string, stripComponents int) errordeprecated
- func ExtractTarBz2(source io.Reader, destination string, stripComponents int) errordeprecated
- func ExtractTarGz(source io.Reader, destination string, stripComponents int) errordeprecated
- func ExtractTarXz(source io.Reader, destination string, stripComponents int) errordeprecated
- func ExtractZip(source io.Reader, destination string, stripComponents int) errordeprecated
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CreateJar ¶ added in v1.70.0
CreateJar heavily inspired by: https://gosamples.dev/zip-file/ Be aware that this function does not create a MANIFEST.MF file, not does it strictly enforce jar format in regard to elements that need to be STORE'd versus other that need to be DEFLATE'd; here everything is STORE'd Finally, source path must end with a trailing "/"
func CreateTar ¶ added in v1.14.0
CreateTar writes a TAR to the destination io.Writer containing the directories and files in the source folder.
func CreateTarGz ¶ added in v1.14.0
CreateTarGz writes a GZIP'd TAR to the destination io.Writer containing the directories and files in the source folder.
func Extract ¶ added in v1.59.0
Extract decompresses and extract source files to a destination directory or path. For archives, an arbitrary number of top-level directory components can be stripped from each path.
func ExtractTar
deprecated
added in
v1.14.0
func ExtractTarBz2
deprecated
added in
v1.24.0
func ExtractTarGz
deprecated
added in
v1.14.0
func ExtractTarXz
deprecated
added in
v1.14.0
func ExtractZip
deprecated
added in
v1.14.0
Types ¶
This section is empty.