npck

package module
v1.2.0 Latest Latest
Warning

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

Go to latest
Published: Jan 8, 2023 License: Apache-2.0 Imports: 13 Imported by: 1

README

PkgGoDev GitHub Actions CI Status GitHub Actions CodeQL Status Coverage Status Codebeat badge

InstallationUsage exampleCI StatusLicense


npck is a Go package for unpacking various types of archives.

Installation

Make sure you have a working Go 1.18+ workspace (instructions), then:

go get -d github.com/essentialkaos/npck

For update to the latest stable release, do:

go get -d -u github.com/essentialkaos/npck

Usage example

package main

import (
  "fmt"

  "github.com/essentialkaos/npck/tgz"
)

func main() {
  err := tgz.Unpack("file.tar.gz", "/home/john")

  if err != nil {
    panic("Can't unpack file: %v", err)
  }

  fmt.Printf("File %s successfully unpacked!\n")
}

CI Status

Branch Status
master CI
develop CI

License

Apache License, Version 2.0

Documentation

Overview

Package npck provides methods for unpacking various types of archives

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Unpack

func Unpack(file, dir string) error

Unpack unpacks given file

Types

This section is empty.

Directories

Path Synopsis
Package bz2 provides methods for unpacking bz2 files
Package bz2 provides methods for unpacking bz2 files
Package gz provides methods for unpacking gz files
Package gz provides methods for unpacking gz files
Package tar provides method for unpacking tar files
Package tar provides method for unpacking tar files
Package tbz2 provides methods for unpacking tar.bz2 files
Package tbz2 provides methods for unpacking tar.bz2 files
Package tgz provides methods for unpacking tar.gz files
Package tgz provides methods for unpacking tar.gz files
Package txz provides methods for unpacking tar.xz files
Package txz provides methods for unpacking tar.xz files
Package tzst provides methods for unpacking tar.zst files
Package tzst provides methods for unpacking tar.zst files
Package xz provides methods for unpacking xz files
Package xz provides methods for unpacking xz files
Package zip provides methods for unpacking zip files
Package zip provides methods for unpacking zip files
Package zst provides methods for unpacking zst files
Package zst provides methods for unpacking zst files

Jump to

Keyboard shortcuts

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