c4milo/unpackit

Go package to natively decompress and unarchive tar.gz, tar.bzip2, tar.xz, zip and tar files.

Go

83

70 commits

updated Aug 28, 2025

See the code

README

UnpackIt

GoDoc Build Status

This Go library allows you to easily unpack the following files using magic numbers:

  • tar.gz
  • tar.bzip2
  • tar.xz
  • zip
  • tar

Usage

Unpack a file:

    file, _ := os.Open(test.filepath)
    err := unpackit.Unpack(file, tempDir)

Unpack a stream (such as a http.Response):

    res, err := http.Get(url)
    err := unpackit.Unpack(res.Body, tempDir)
bzip2
decompression-library
go
golang
gzip
tar
unpack
xz
zip

c4milo/unpackit

Go package to natively decompress and unarchive tar.gz, tar.bzip2, tar.xz, zip and tar files.

Go

83

70 commits

updated Aug 28, 2025

See the code

README

UnpackIt

GoDoc Build Status

This Go library allows you to easily unpack the following files using magic numbers:

  • tar.gz
  • tar.bzip2
  • tar.xz
  • zip
  • tar

Usage

Unpack a file:

    file, _ := os.Open(test.filepath)
    err := unpackit.Unpack(file, tempDir)

Unpack a stream (such as a http.Response):

    res, err := http.Get(url)
    err := unpackit.Unpack(res.Body, tempDir)
bzip2
decompression-library
go
golang
gzip
tar
unpack
xz
zip

Project health

Overall

2.0/10

Maintained

0/10

Code review

1/10
OpenSSF Scorecard

Latest release

v1.0.0 · Oct 4, 2022

Releases this year

0