-
Notifications
You must be signed in to change notification settings - Fork 0
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
Switch flags package to one that allows "not set" or nil as default value #44
Comments
From looking over the existing documentation and diving into the code, the Here are some example long form names currently defined:
Looking over the docs, I don't think that the dash-separated flag names are automatically supported/mapped. |
I heard back some time ago and after brief testing confirmed that both short and long form flags are supported. |
While working on a new project I reviewed the configuration handling for this one, in particular, the log format and log level handling. Currently, if the user does not specify a log format, the Ultimately, there are workarounds (such as using something like |
On a related note, see GH-108. That functionality should be reviewed/updated at the same time that I make required changes to resolve this issue. |
See GH-10 and GH-43 for background details.
In short, since this project allows for specifying options via config file (TOML) and flags, we need a way to determine when a flag was not specified so that we can fallback to the config file (if applicable) and only then the application default.
If we go with
alexflint/go-arg
we have the atc0005/elbow project to use as a reference; instead of using that project's handling of config values, I'd like to keep the current Getter behavior of this project. The current logic used in this project allows for per-setting overrides vs the global merge behavior that I implemented for atc0005/elbow.If possible I'd like to keep all existing flags with the possible exception of the one for ignoring errors (as discussed in GH-43).
The text was updated successfully, but these errors were encountered: