gopass: github.com/justwatchcom/gopass/pkg/fsutil Index | Files

package fsutil

import "github.com/justwatchcom/gopass/pkg/fsutil"

Index

Package Files

fsutil.go umask.go

func CleanFilename Uses

func CleanFilename(in string) string

CleanFilename strips all possibly suspicious characters from a filename WARNING: NOT suiteable for pathnames as slashes will be stripped as well!

func CleanPath Uses

func CleanPath(path string) string

CleanPath resolves common aliases in a path and cleans it as much as possible

func IsDir Uses

func IsDir(path string) bool

IsDir checks if a certain path exists and is a directory https://stackoverflow.com/questions/10510691/how-to-check-whether-a-file-or-directory-denoted-by-a-path-exists-in-golang

func IsEmptyDir Uses

func IsEmptyDir(path string) (bool, error)

IsEmptyDir checks if a certain path is an empty directory

func IsFile Uses

func IsFile(path string) bool

IsFile checks if a certain path is actually a file

func Shred Uses

func Shred(path string, runs int) error

Shred overwrite the given file any number of times

func Umask Uses

func Umask() int

Umask extracts the umask from env

Package fsutil imports 11 packages (graph). Updated 2018-12-04. Refresh now. Tools for package owners.