-
Notifications
You must be signed in to change notification settings - Fork 47
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
Honor XDG variables on MacOS #56
Comments
Hi @AntoinePrv, please see dirs-dev/directories-rs#47 (comment). |
This doesn't feel like a duplicate to me. In the linked issue, you mentioned that macOS has a standard location for these directories, and dirs uses those standard directories. That sounds completely reasonable. However, this issue is about providing a user-facing customization hook hook for this (XDG environment variables), in particular one that plays nicely with customization hooks available on other platforms (which many of the consumers of this crate are compiling for as well). In particular, the linked comment gives an example: "add exclusions to macOS' backup software (Library/Caches is excluded, .cache isn't)". If the user is setting a custom XDG_CACHE_DIR, it's safe to assume they have added the exclusion mentioned. Can you clarify your stance on why support for the environment variables should not be added to |
@CGamesPlay This library intends to implement the platform conventions as defined by the respective OS vendors, not what people want it to be. |
Thanks for taking the time to respond! |
I know I probably won't change your mind, but I'll say it anyway: Those folder conventions you link to, are for GUI apps. E.g. MacOS ships with zsh as the default shell. Its default configuration is in Look, I'm not claiming that there is an official guideline similar to XDG for mac. But the vast majority of cli tools you can install via homebrew, use either |
The CLI tools are wrong and should fix their implementation. |
Some MacOS users would like to use XDG configuration, especially for everything terminal related. Many tools out-there actually support it.
It would be great if
dirs
could honor these environment variables on MacOS too. I'm only talking of honoring the environment variables, not the default locations, so that this remains strictly opt-in.Another way to make this even safer is to check an additional
XDG_FORCE_MACOS
environment variable. That way updatingdirs
will not break workflow of users that are already usingXDG
and~/Library
.The text was updated successfully, but these errors were encountered: