This section is empty.


This section is empty.


func CopyFile

func CopyFile(src, dst string) error

    CopyFile copies a file. It truncates the destination file if it exists.

    func EnsureDir

    func EnsureDir(dir string, mode os.FileMode) error

      EnsureDir ensures the given directory exists, creating it if necessary. Errors if the path already exists as a non-directory.

      func Exit

      func Exit(s string)

      func FileExists

      func FileExists(filePath string) bool

      func Kill

      func Kill() error

        Kill the running process by sending itself SIGTERM.

        func MustReadFile

        func MustReadFile(filePath string) []byte

        func MustWriteFile

        func MustWriteFile(filePath string, contents []byte, mode os.FileMode)

        func ReadFile

        func ReadFile(filePath string) ([]byte, error)

        func TrapSignal

        func TrapSignal(logger logger, cb func())

          TrapSignal catches the SIGTERM/SIGINT and executes cb function. After that it exits with code 0.

          func WriteFile

          func WriteFile(filePath string, contents []byte, mode os.FileMode) error


          This section is empty.

          Source Files