cmd

package
v1.1.0 Latest Latest
Warning

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

Go to latest
Published: Jan 10, 2025 License: MPL-2.0 Imports: 13 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Run

func Run(version, commit, date string)

Run the entrypoint into go-extract as a cli tool

Types

type CLI

type CLI struct {
	Archive                    string           `arg:"" name:"archive" help:"Path to archive. (\"-\" for STDIN)" type:"existing file"`
	ContinueOnError            bool             `short:"C" help:"Continue extraction on error."`
	ContinueOnUnsupportedFiles bool             `short:"S" help:"Skip extraction of unsupported files."`
	CreateDestination          bool             `short:"c" help:"Create destination directory if it does not exist."`
	CustomCreateDirMode        int              `optional:"" default:"750" help:"File mode for created directories, which are not listed in the archive. (respecting umask)"`
	CustomDecompressFileMode   int              `optional:"" default:"640" help:"File mode for decompressed files. (respecting umask)"`
	DenySymlinks               bool             `short:"D" help:"Deny symlink extraction."`
	Destination                string           `arg:"" name:"destination" default:"." help:"Output directory/file."`
	DropFileAttributes         bool             `short:"d" help:"Drop file attributes (mode, modtime, access time)."`
	InsecureTraverseSymlinks   bool             `help:"Traverse symlinks to directories during extraction."`
	MaxFiles                   int64            `` /* 147-byte string literal not displayed */
	MaxExtractionSize          int64            `` /* 131-byte string literal not displayed */
	MaxExtractionTime          int64            `` /* 137-byte string literal not displayed */
	MaxInputSize               int64            `optional:"" default:"${default_max_input_size}" help:"Maximum input size that allowed is (in bytes). (disable check: -1)"`
	NoUntarAfterDecompression  bool             `short:"N" optional:"" default:"false" help:"Disable combined extraction of tar.gz."`
	Overwrite                  bool             `short:"O" help:"Overwrite if exist."`
	Pattern                    []string         `optional:"" short:"P" name:"pattern" help:"Extracted objects need to match shell file name pattern."`
	PreserveOwner              bool             `short:"p" help:"Preserve owner and group of files from archive (only root/uid:0 on unix systems for tar files)."`
	Telemetry                  bool             `short:"T" optional:"" default:"false" help:"Print telemetry data to log after extraction."`
	Type                       string           `short:"t" optional:"" default:"${default_type}" name:"type" help:"Type of archive. (${valid_types})"`
	Verbose                    bool             `short:"v" optional:"" help:"Verbose logging."`
	Version                    kong.VersionFlag `short:"V" optional:"" help:"Print release version information."`
}

CLI are the cli parameters for go-extract binary

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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