filesutils

package
v0.406.0 Latest Latest
Warning

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

Go to latest
Published: Jul 25, 2025 License: Apache-2.0 Imports: 6 Imported by: 0

README

filesutils package

Contains various implementations to work with files:

  • tempfileoo: Create temporary files and directories in a object oriented way.

For developers

To run the tests of filesutils use:

bash -c "cd $(git rev-parse --show-toplevel) && go test -v ./pkg/filesutils/..."

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Create added in v0.365.0

func Create(ctx context.Context, path string) error

func CreateNamedTemporaryFile added in v0.365.0

func CreateNamedTemporaryFile(ctx context.Context, fileName string) (string, error)

func CreateTempDir added in v0.365.0

func CreateTempDir(ctx context.Context) (string, error)

func CreateTemporaryFile added in v0.365.0

func CreateTemporaryFile(ctx context.Context) (string, error)

func Exists added in v0.365.0

func Exists(ctx context.Context, pathToCheck string) bool

func IsDir added in v0.365.0

func IsDir(ctx context.Context, pathToCheck string) bool

func IsFile

func IsFile(ctx context.Context, pathToCheck string) bool

func SecureDelete added in v0.365.0

func SecureDelete(ctx context.Context, path string) error

Overwrite the file before deleting it to prevent data restore. Like 'shred' on linux systems.

Types

This section is empty.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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