Skip to content

Commit

Permalink
Update wording to conform to XDG cache dir spec
Browse files Browse the repository at this point in the history
  • Loading branch information
nikkelma committed Nov 17, 2021
1 parent 32d24b2 commit 07213d0
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions cmd/hauler/cli/cli.go
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ func New() *cobra.Command {

pf := cmd.PersistentFlags()
pf.StringVarP(&ro.logLevel, "log-level", "l", "info", "")
pf.StringVar(&ro.cacheDir, "cache", "", "Location of where to store cache data (defaults to $XDG_CACHE_DIR/hauler)")
pf.StringVar(&ro.cacheDir, "cache", "", "Location of where to store cache data (defaults to $XDG_CACHE_HOME/hauler)")
pf.StringVarP(&ro.storeDir, "store", "s", "", "Location to create store at (defaults to $PWD/store)")

// Add subcommands
Expand Down Expand Up @@ -94,7 +94,7 @@ func (o *rootOpts) getCache(ctx context.Context) (cache.Cache, error) {
dir := o.cacheDir

if dir == "" {
// Default to $XDG_CACHE_DIR
// Default to $XDG_CACHE_HOME
cachedir, err := os.UserCacheDir()
if err != nil {
return nil, err
Expand Down

0 comments on commit 07213d0

Please sign in to comment.