Taskwarrior: [feature request] Make ~/.config/task the default data directory

Created on 18 Aug 2019  路  6Comments  路  Source: GothenburgBitFactory/taskwarrior

It would be nice to have the data directory location in .taskrc default to data.location=~/.config/task. It's current accepted best practice on many Linux distros to prefer the ~/.config directory for user specific configuration files whenever possible.

I realize the current default can be easily overridden at install time or changed later by the user. It just makes the installation a bit smoother reduces dot directory clutter inside of home directories.

Most helpful comment

The XDG Base Directory specification is hardly useless; it promotes good standards for storing user configuration files in a unified directory, rather than scattered throughout $HOME. Adopting the standard in taskwarrior would be an example of best practice, as the configuration files would be located where users expect. Expecting users to junk up their environment, add aliases, or create an additional wrapper shell script just to get taskwarrior to conform to the most widely adopted configuration standard seems nonsensical. In case you want evidence of the wide adoption of the XDG spec, see neovim, htop, sway, systemd, vlc, pulseaudio, podman, etc.

Would you consider reopening this issue, since the patch is trivial yet so helpful?

All 6 comments

I have no interest supporting the useless XDG "spec". This is already supported via overrides as you say, there is no need for this.

The XDG Base Directory specification is hardly useless; it promotes good standards for storing user configuration files in a unified directory, rather than scattered throughout $HOME. Adopting the standard in taskwarrior would be an example of best practice, as the configuration files would be located where users expect. Expecting users to junk up their environment, add aliases, or create an additional wrapper shell script just to get taskwarrior to conform to the most widely adopted configuration standard seems nonsensical. In case you want evidence of the wide adoption of the XDG spec, see neovim, htop, sway, systemd, vlc, pulseaudio, podman, etc.

Would you consider reopening this issue, since the patch is trivial yet so helpful?

@pbeckingham , you may have no interest, but it's apparent that others do have interest.

If this were Windows would you be annoyed if someone asked for %appdata% support, or ~/Library for macOS?

XDG is the equivalent here, and by expressing hostility to it implies that Linux+some other OSes are not valuable.

The XDG spec has been here for some years and is not going away. Please don't make it a worse experience because you disagree with it.

Yes, another request to re-open this.

Would really like to see taskwarrior respect XDG variables like most other modern programs. I left a implementation rough-draft in https://github.com/GothenburgBitFactory/taskwarrior/pull/2248#issuecomment-719078159.

Support for taskrc location defined by XDG_CONFIG_HOME implemented in #2316. The other data locations can be then defined in the taskrc file itself.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

pinpox picture pinpox  路  6Comments

xerus2000 picture xerus2000  路  5Comments

kirillbobyrev picture kirillbobyrev  路  4Comments

gour picture gour  路  5Comments

taskwarrior picture taskwarrior  路  8Comments