Documentation
¶
Index ¶
Constants ¶
View Source
const ( DefaultFilePermissions fs.FileMode = 0o600 DefaultDirPermissions fs.FileMode = 0o755 )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type FileSystem ¶
type FileSystem interface {
GetLocalExecutable(name string) (string, error)
FileExists(filename string) (bool, error)
WriteFile(filename string, content []byte) error
WriteLockFileFunc(filename string, writeFunc func(io.Writer) error) (LockFile, error)
DeleteFile(filename string) (bool, error)
ReadFileLines(filename string) ([]string, error)
// ReadDirRecursive recurses into a given directory ('path') up to 'depth'
// levels deep. If 'strictDepth' is true, only the entries at *exactly* the
// given depth are returned (if any). If 'strictDepth' is false, though, the
// results will also include any files or empty directories for a depth <
// 'depth'.
//
// If 'depth' is <= 0, ReadDirRecursive returns an empty list.
ReadDirRecursive(path string, depth int, strictDepth bool) ([]ReadDirEntry, error)
}
func NewFileSystem ¶
func NewFileSystem() FileSystem
type ReadDirEntry ¶
type UserProvider ¶
func NewUserProvider ¶
func NewUserProvider() UserProvider
Click to show internal directories.
Click to hide internal directories.