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

doc(api) XDG user dirs are not env vars, fix: #3090 #3092

Merged
merged 1 commit into from
Dec 27, 2021

Conversation

OJFord
Copy link
Contributor

@OJFord OJFord commented Dec 21, 2021

This commit points the docs on path.downloadDir for XDG_DOWNLOAD_DIR
on Linux, and similar XDG user dirs, at the xdg-user-dirs program for
more information, and fixes that they currently imply these are
environment variables; which they a) are unfortunately not by any sort
of standard; b) such env vars are ignored by dirs-next which tauri
uses for resolving them.

This does not address the issue of
${XDG_CONFIG_HOME:-$HOME/.config}/user-dirs.dir needing to already
exist and contain the appropriate key for this to work (i.e. they do not
default to $HOME as the output of xdg-user-dir does) - because that
IMO is a shortcoming of dirs-next and is better addressed there.

Closes #3090

What kind of change does this PR introduce? (check at least one)

  • Bugfix
  • Feature
  • Docs
  • New Binding Issue #___
  • Code style update
  • Refactor
  • Build-related changes
  • Other, please describe:

Does this PR introduce a breaking change? (check one)

  • Yes. Issue #___
  • No

The PR fulfills these requirements:

  • When resolving a specific issue, it's referenced in the PR's title (e.g. fix: #xxx[,#xxx], where "xxx" is the issue number)
  • A change file is added if any packages will require a version bump due to this PR per the instructions in the readme.

If adding a new feature, the PR's description includes:

  • A convincing reason for adding this feature (to avoid wasting your time, it's best to open a suggestion issue first and wait for approval before working on it)

Other information:

This commit points the docs on `path.downloadDir` for XDG_DOWNLOAD_DIR
on Linux, and similar XDG user dirs, at the `xdg-user-dirs` program for
more information, and fixes that they currently imply these are
environment variables; which they a) are unfortunately not by any sort
of standard; b) such env vars are ignored by `dirs-next` which tauri
uses for resolving them.

This does not address the issue of
`${XDG_CONFIG_HOME:-$HOME/.config}/user-dirs.dir` needing to already
exist and contain the appropriate key for this to work (i.e. they do not
default to `$HOME` as the output of `xdg-user-dir` does) - because that
IMO is a shortcoming of `dirs-next` and is better addressed there.
@OJFord OJFord requested a review from a team December 21, 2021 17:37
@lucasfernog lucasfernog merged commit 722d9ed into tauri-apps:next Dec 27, 2021
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.

XDG user directories (e.g. path.downloadDir) are not env vars [docs]
2 participants