puller

package
v1.6.2 Latest Latest
Warning

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

Go to latest
Published: Dec 9, 2024 License: Apache-2.0 Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CheckSanePath

func CheckSanePath(path string, baseFolder string) error

checkSanePath just to make sure we don't delete or overwrite somewhere where we are not supposed to

func ExtractTarGz

func ExtractTarGz(ctx context.Context, checkOnly bool, archivePath string, basePath string, maxArchiveSize int64) error

func IsTarGz

func IsTarGz(ctx context.Context, filePath string, maxArchiveSize int64) (bool, error)

Types

type DataPuller

type DataPuller interface {
	Pull(ctx context.Context, path string) (string, error)
	Extract(ctx context.Context, archivePath string) error
	Close(ctx context.Context, basePath string) error
	ListFiles(ctx context.Context, prefix string, recursive bool) ([]*ListObject, error)
}

type ListObject added in v1.3.3

type ListObject struct {
	Key string
	// ModTime is the time the blob was last modified.
	ModTime time.Time
}

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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