feat: Add environment variable expansion for docker config plugin dirs
- What I did
- Added environment variable expansion to the config plugin dirs
- Added an example test (I guess 😅 )
Closes #6486
- How I did it
- searching for config file references in the code, thinking and assisted by GitHub Copilot
- How to verify it
- run the tests (I guess 😅 )
- Human readable description for the release notes
Add support to expand environment variables in docker plugin config directory string
- Add support to expand environment variables in docker plugin config directory string
I am really really new to Go like 0.5% experience. The test is mainly assisted by Copilot with a bit of brain usage by my side. Feel free to help me to add like a negative test or something like that if the current one is not enough
- A picture of a cute animal (not mandatory but encouraged)
Hi @vvoland, any updates on this?
LGTM after squashing commits
I'm slightly on the fence; wondering; does the (for the example) $HOMEBREW_PREFIX env-var ever change? And would it be an option to expand the env-var before adding the path to the config?
The point here is that we don't to env-var expansion for any of the other paths, so this may now become a sliding slope where it needs to be added to every path that's in config; the extraPaths was already added to allow customisation with a custom set of extra directories.
I'm slightly on the fence; wondering; does the (for the example)
$HOMEBREW_PREFIXenv-var ever change? And would it be an option to expand the env-var before adding the path to the config?
In general the $HOMEBREW_PREFIX env-var shouldn't really change as far as I know. At least when using standard configuration. However when writing a guide for example it's more helpful / clear wo write the path with the prefix into the guide so the reader has to think less about the content. So I think it would be a nice and helpful feature which shouldn't break somethin.
The point here is that we don't to env-var expansion for any of the other paths, so this may now become a sliding slope where it needs to be added to every path that's in config; the extraPaths was already added to allow customisation with a custom set of extra directories.
Feel free to tell me about the option names / code files and I will have a look whether I can implement it for the additional options
@thaJeztah
LGTM after squashing commits
done 👍
Hey @vvoland are the changes fine and is it fine when I ping you? I don't wanna annoy you 😅