-
Notifications
You must be signed in to change notification settings - Fork 3k
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
XDG compliance for Unix/Linux (~/.config) #582
Conversation
…ult to ~/.config if not)
Please also update the docs and add to NEWS and yourself to AUTHORS if you are not in. |
There, I've now done both. |
Failure was unrelated |
So... with an unrelated failure, is there something I have to do to get the pull request built again? |
Sorry for lag - probably simplest now is to add something to |
Looks like a slow build. I'll try running the tests locally before I merge. |
XDG compliance for Unix/Linux (~/.config)
Currently, on everything but Windows, pip's configuration directory is located in
~/.pip
. That is, a hidden directory in a user's home folder.This pull request attempts to move away from this and towards the XDG specification (available here: http://standards.freedesktop.org/basedir-spec/basedir-spec-latest.html), which suggests that instead write configuration to
$XDG_CONFIG_DIRS
- which by default is~/.config
. So I've modified locations.py to do so.I've also tried to ensure a migration path- if there is a pip.conf in the old
~/.pip
folder that will get copied over to~/.config/pip
on pip's first run (after which it will be deleted).There are a few issues this raises though:
sudo pip install somepkg
), pip will not look for a configuration file in your configuration folder but instead for one in/root/
. This isn't a new issue (there are already long-open bugs like Provide a global (system-wide) config file. #309 about it), but as this pull request deals with config files.. I thought I'd mention it.