Documentation ¶
Overview ¶
Package bilib provides common stuff for bisync and bisync_test
Package bilib provides common stuff for bisync and bisync_test Here it's got local file/directory helpers (nice to have in lib/file)
Package bilib provides common stuff for bisync and bisync_test
Index ¶
- Constants
- func CanonicalPath(remote string) string
- func CaptureOutput(fun func()) []byte
- func CopyDir(src string, dst string) (err error)
- func CopyFile(src, dst string) (err error)
- func CopyFileIfExists(srcFile, dstFile string) error
- func FileExists(file string) bool
- func FsPath(f fs.Fs) string
- func IsLocalPath(path string) bool
- func SaveList(list []string, path string) error
- func SessionName(fs1, fs2 fs.Fs) string
- type Names
Constants ¶
const PermSecure = 0600
PermSecure is a Unix permission for a file accessible only by its owner
Variables ¶
This section is empty.
Functions ¶
func CanonicalPath ¶
CanonicalPath converts a remote to a suitable base file name
func CaptureOutput ¶
func CaptureOutput(fun func()) []byte
CaptureOutput runs a function capturing its output.
func CopyFileIfExists ¶
CopyFileIfExists is like CopyFile but does to fail if source does not exist
func FileExists ¶
FileExists returns true if the local file exists
func IsLocalPath ¶
IsLocalPath returns true if its argument is a non-remote path. Empty string or a relative path will be considered local. Note: `c:dir` will be considered local on Windows but remote on Linux.
func SessionName ¶
SessionName makes a unique base name for the sync operation