fileutils

package
v2.63.1 Latest Latest
Warning

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

Go to latest
Published: Apr 5, 2026 License: Apache-2.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CommonPrefix

func CommonPrefix(sep byte, paths ...string) string

CommonPrefix returns common directory path of provided files

func Copy

func Copy(afs afero.Fs, src, dst string, fileMode, dirMode fs.FileMode) error

Copy copies a file or folder from one place to another.

func CopyDir

func CopyDir(afs afero.Fs, source, dest string, fileMode, dirMode fs.FileMode) error

CopyDir copies a directory from source to dest and all of its sub-directories. It doesn't stop if it finds an error during the copy. Returns an error if any.

func CopyFile

func CopyFile(afs afero.Fs, source, dest string, fileMode, dirMode fs.FileMode) error

CopyFile copies a file from source to dest and returns an error if any.

func MoveFile

func MoveFile(afs afero.Fs, src, dst string, fileMode, dirMode fs.FileMode) error

MoveFile moves file from src to dst. By default the rename filesystem system call is used. If src and dst point to different volumes the file copy is used as a fallback

Types

This section is empty.

Jump to

Keyboard shortcuts

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