-
Notifications
You must be signed in to change notification settings - Fork 353
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
Feature request: mark a flag as deprecated or retired #275
Comments
I can think of a couple approaches. One would be to add a deprecated flag, but that would add overhead on every option in terms of size and checking a flag. Probably not a lot but some. The other options would be to add a wrapper function like A retired function could be similar but would probably need to replace the callback so it does nothing instead of the original callback. Some advantages and disadvantages to both approaches. I could see it being a useful thing to have available though. |
This is a very interesting request :) |
I suppose I could see if you were wanting to shift the format conventions of a long form option to be consistent with other parts of a program, then you may only want to deprecate one of the names. Though by far most of the use cases I might want this for would apply to the whole option. So in #358 I was only dealing with whole options. |
While maintaining a program that accepts CLI flags, one often wants to deprecate an option - still leaving it functional but providing a warning to the user, or retiring an option, meaning the flag is consumed but otherwise ignored.
Any thoughts on what that functionality could look inside CLI11?
The text was updated successfully, but these errors were encountered: