Feature Request: Set global CLI option defaults
See original GitHub issueHey team, really enjoying using garden so far. I’ve been running into this issue where the default value of fancy
for --logger-type
does not play nicely with the terminal in my IDE (webstorm), and I’m constantly forgetting to pass the flag to change it to basic
, which made me think this may be a useful feature. Apologies if this functionality is available and I somehow missed it, I’ve gone through the docs pretty thoroughly and haven’t seen it mentioned.
What should the user be able to do
Set a default value for global CLI options. I’ve thought of two ways this of implementing this (though I’m not familiar with the internals of the project so I’m sure you’ll have better ideas).
Idea A. Set the default value for a global cli option via the garden config
command. Example:
$ garden config logger-type basic
✔ Global default for CLI flag --logger-type set to 'basic'
Idea B: A cli
key in the project configuration file. Example:
kind: Project
name: myProject
cli:
loggerType: basic
...
Why do they want to do this
Like I mentioned above, I have an immediate need for this because remembering to pass the --logger-type=basic
flag for every command is quite tedious. Other global options where I could see this being useful is --log-level
, --env
, and --output
.
Priority: Probably pretty low, though I would greatly appreciate it 😃
Thanks! Parker
Issue Analytics
- State:
- Created 4 years ago
- Comments:7 (2 by maintainers)
I also really liked the structure. This could maybe be turned into a feature request template. Maybe your first PR @parkerself22? 😃
If not I will take care of it in the next days. Again thanks for the request.
This issue has been automatically marked as stale because it hasn’t had any activity in 60 days. It will be closed in 14 days if no further activity occurs (e.g. changing labels, comments, commits, etc.). Please feel free to remove the label if you think it doesn’t apply. Thank you for submitting this issue and helping make Garden a better product!