package
0.0.0-20231126024412-02539191b02e
Repository: https://github.com/mjpitz/myago.git
Documentation: pkg.go.dev
# README
dirset
Package dirset provides discovery of common application directories for things like caching, locks, and logs.
import go.pitz.tech/lib/dirset
Usage
type DirectorySet
type DirectorySet struct {
CacheDir string
StateDir string
LocalStateDir string
LockDir string
LogDir string
}
DirectorySet defines a common set of paths that applications can use for a variety of reasons.
func Local
func Local(appName string) (DirectorySet, error)
Local uses information about the local system to determine a common set of paths for use by the application.
func Must
func Must(appName string) DirectorySet
Must panics if Local fails to obtain the directory set.
# Structs
DirectorySet defines a common set of paths that applications can use for a variety of reasons.