Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type DirTargzipper ¶
type DirTargzipper struct {
// contains filtered or unexported fields
}
DirTargzipper targz's a directory and respects ignore files. By default, it will respect ignore patterns present in any .gitignore and .dockerignore files.
func NewDirTargzipper ¶
func NewDirTargzipper(sourcePath string, writer io.Writer, opts ...DirTargzipperOption) (*DirTargzipper, error)
NewDirTargzipper creates a new targzipper that compresses a directory.
type DirTargzipperOption ¶
type DirTargzipperOption func(*DirTargzipper)
DirTargzipperOption configures a DirTargzipper.
func WithIgnoreFiles ¶
func WithIgnoreFiles(ignoreFiles []string) DirTargzipperOption
WithIgnoreFiles configures which ignore files to respect during compression.
type Progress ¶
type Progress struct { // Percentage of the operation that is complete. Percentage float64 // Processed bytes thus far. Processed int64 // Total number of bytes to process. Total int64 // Filename being processed. Could be empty if this is the begining or end of the compression operation. Filename string // Done is true when compression is complete. Done bool }
Progress of the compression.
Click to show internal directories.
Click to hide internal directories.