Conversation
|
This is super overkill I think -
|
|
@mtwebster - Thanks for reviewing the PR and for the suggestion to use The current implementation does indeed ignore To illustrate, here's an example from my own environment where I use non-standard paths, but still designed to conform to the XDG SPEC to control the creation and clutter of various XDG spec dirs or similar: # Using prefix: 'XDG_'
# Environment variables starting with 'XDG_':
XDG_BIN_HOME = /home/dwarf/.xdg/bin
XDG_CACHE_HOME = /home/dwarf/.xdg/cache
XDG_CACHE_LOCAL_HOME = /home/dwarf/.xdg/local
XDG_CONFIG_HOME = /home/dwarf/.config
XDG_DATA_HOME = /home/dwarf/.xdg/data
XDG_STATE_HOME = /home/dwarf/.xdg/stateIn this setup, the app should ideally use something like I think combining your GLib suggestion with the custom env var support could strike a good balance—simpler core logic while keeping the extra flexibility. What are your thoughts? |
|
I really can't see any reason to have additional environment variables here - The GLib function uses https://gitlab.gnome.org/GNOME/glib/-/blob/main/glib/gutils.c?ref_type=heads#L1875-1938 |
Summary
Closes: #366
Attempt to expand
XDG_DATA_HOMEwhen creating constants, falling back to~/.local/shareif not set.Change also allows users to set application specific env. variables if they wiish to do so.
Testing
Seemingly no python req's file so entirely blind on versions.
There's also no actual testing tooling I could see in the entire repo - not without nuking my local copy too.