Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Respect XDG_DATA_DIRS #115

Closed
Serpentian opened this issue Feb 7, 2024 · 1 comment · Fixed by #116
Closed

Respect XDG_DATA_DIRS #115

Serpentian opened this issue Feb 7, 2024 · 1 comment · Fixed by #116

Comments

@Serpentian
Copy link

Currently path to the power icons is hardcoded to /usr/share/.... However, XDG_DATA_DIRS doesn't always include this directory on read-only OSs, like NixOS. There this data is stored inside $HOME/.nix-profile/share/

btn := powerButton("/usr/share/nwg-drawer/img/lock.svg", *pbLock)

$XDG_DATA_DIRS should be respected, when we search for the power icons. The same thing applies to the desktop-entries.


The possible solution would be to add $HOME/.nix-profile/share to the xdgDataDirs. Or we can get env variable XDG_DATA_DIRS directly, without hardcoding it (it seems better).

xdgDataDirs = "/usr/local/share/:/usr/share/"

@nwg-piotr
Copy link
Owner

I don't care much about Nix, but yes, it could be done. If it comes to .desktop dirs, XDG_DATA_DIRS are already respected.

nwg-piotr added a commit that referenced this issue Feb 8, 2024
nwg-piotr added a commit that referenced this issue Feb 8, 2024
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 a pull request may close this issue.

2 participants