Skip to content

fix(cli): use $XDG_DATA_HOME instead of $HOME on Linux#7

Open
echozio wants to merge 3 commits intodotse:masterfrom
echozio:fix/xdg-user-dirs
Open

fix(cli): use $XDG_DATA_HOME instead of $HOME on Linux#7
echozio wants to merge 3 commits intodotse:masterfrom
echozio:fix/xdg-user-dirs

Conversation

@echozio
Copy link

@echozio echozio commented Dec 13, 2021

Follow Freedesktop.org's XDG Base Directory Specification by either using $XDG_DATA_HOME or falling
back to ~/.local/share. Ifdef'd to only apply to Linux builds, but could probably safely be enabled
on *BSDs by someone more familiar with the prevalence of XDG directories on those platforms.

BREAKING CHANGE: This changes the data directory and makes no attempt at falling back to the old
one. User data must be manually migrated to the new location if the user wishes to keep it.

echozio and others added 3 commits December 13, 2021 22:44
Follow Freedesktop.org's XDG Base Directory Specification by either using $XDG_DATA_HOME or falling
back to ~/.local/share. Ifdef'd to only apply to Linux builds, but could probably safely be enabled
on *BSDs by someone more familiar with the prevalence of XDG directories on those platforms.

BREAKING CHANGE: This changes the data directory and makes no attempt at falling back to the old
one. User data must be manually migrated to the new location if the user wishes to keep it.
@echozio
Copy link
Author

echozio commented Jan 18, 2024

I updated this to create the determined XDG data home if it doesn't exist already. Also included @odeneriksson's (#12) fix since I was no longer able to build it.
🦗 🦗 🦗

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants