question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Support $XDG_CONFIG_HOME on macOS

See original GitHub issue
  • I have searched the issues of this repo and believe that this is not a duplicate.
  • I have searched the documentation and believe that my question is not covered.

Feature Request

Follow configurations under $XDG_CONFIG_HOME on macOS too!

Current situation

Although macOS is a genuine UNIX OS and the document says

For Unix, we follow the XDG spec

you don’t, on macOS.

https://github.com/sdispater/poetry/blob/ce124603e57ac8ede4addc6f96fc810a82090259/poetry/utils/appdirs.py#L128-L132

Rationale to support it

I’m using $XDG_CONFIG_HOME to manage configurations.

$ ls $XDG_CONFIG_HOME
alacritty/  configstore/  git/  iterm/      micro/  tmux/
anyenv/     fish/         hub   karabiner/  ssh/

As you see, many tools like git, fish, anyenv and karabiner-elements supports XDG by nature (some are not by nature, but can be configured).

I believe this is good strategy since it’s more suitable to version-control in my “dotfiles” repository GitHub.

I know this will be breaking change, but at least, I want some way to configure it (such as env variable like PYPOETRY_FOLLOW_XDG).

Issue Analytics

  • State:closed
  • Created 4 years ago
  • Reactions:25
  • Comments:7 (3 by maintainers)

github_iconTop GitHub Comments

5reactions
wangkevcommented, Dec 9, 2020

Have there been any developments here? Would be interested in this as well.

4reactions
Townkcommented, Jan 4, 2020

I created a PR to solve this issue, but since I don’t know it is considered a new feature or a bug fix, I create it against the develop branch. If this can be a bug fix for 1.0, I can submit another PR:

~#1507~ #1823

Read more comments on GitHub >

github_iconTop Results From Across the Web

macos - Equivalents of XDG_CONFIG_HOME and ...
Comparing Apple's documentation for the various paths to the XDG Base Directory ... XDG_CONFIG_HOME → $HOME/Library/Application Support.
Read more >
Allow XDG_CONFIG_HOME on macOS · Issue #4 - GitHub
XDG talks about using a shared directory structure for a user across multiple platforms and how some directories need to be distinct and...
Read more >
12. Follow XDG-spec I'm so glad to see this included. I don't ...
Regrettably, OSX recommends the use of the Library/Application Support directory, and provides several utility APIs for getting config/cache/data locations ...
Read more >
XDG Base Directory - ArchWiki
Application Legacy Path Supported Since ALSA ~/.asoundrc 577df36 · 1.2.3 Android Studio ~/.AndroidStudioX.X Android Studio 4.1 Anki ~/Anki , ~/Documents/Anki
Read more >
Location of personal init file (XDG_CONFIG_HOME)
Github issue#491 proposes to use the XDG base directory specification ... Other Unix: $XDG_CONFIG_HOME if present and ~/.config otherwise.
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found