-
Notifications
You must be signed in to change notification settings - Fork 3.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
Use xdg basedir spec on linux #9007
Comments
Hi @ogarcia thanks for reaching out here. Packer, along with other HashiCorp tools, have standardized around the use of a placing the product configuration files on By setting |
Hi @nywilken thanks for your quick response! But if cache and config dir are well supported, why is not the default behavior use the XDG spec? I think that the implementation is simple in this case. For Linux systems:
Sample in bash: export PACKER_CONFIG_DIR=${XDG_CONFIG_HOME:-${HOME}/.config}/packer
export PACKER_CACHE_DIR=${XDG_CACHE_HOME:-${HOME}/.cache}/packer |
I can take a look into this. |
That would be great! |
@SwampDragons I believe I have addressed issue in attached PR, but had issues issues with testing os specific paths. Please see comment on PR about issue, any ideas for testing welcome! |
Current content of |
https://specifications.freedesktop.org/basedir-spec/basedir-spec-latest.html
Instead of ~/.packer.d, configuration should be in the $XDG_CONFIG_HOME/packer/ and cache (safely-deletable files) should be in $XDG_CACHE_HOME/packer.
The text was updated successfully, but these errors were encountered: