Documentation ¶
Index ¶
Constants ¶
View Source
const ChmodPath = "chmod"
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ExecCmdRunner ¶
ExecCmdRunner is the interface that wraps exec.Command from the os package
type Filesystem ¶
type Filesystem struct { TimeSince func(time.Time) time.Duration TimeUnix func(int64, int64) time.Time IoutilTempDir func(string, string) (name string, err error) OsMkdirAll func(string, fs.FileMode) error OsRename func(string, string) error OsExecCommand func(string, ...string) ExecCmdRunner OsStat func(string) (fs.FileInfo, error) }
Filesystem creates multiple signatures representing functions that would normally interact directly with the filesystem
func (*Filesystem) ChangeDirectoryPermissions ¶
func (f *Filesystem) ChangeDirectoryPermissions(directory string, permissions string) ([]byte, error)
ChangeDirectoryPermissions will update a directory to have the given permissions
func (*Filesystem) GetAccessTime ¶
func (f *Filesystem) GetAccessTime(workspace fs.FileInfo) time.Duration
GetAccessTime finds the most recent time that a file was created, modified or accessed
func (*Filesystem) MoveDirectoryToTmp ¶
func (f *Filesystem) MoveDirectoryToTmp(dir string, name string) (string, error)
MoveDirectoryToTmp will move a given directory to /tmp
Click to show internal directories.
Click to hide internal directories.