Bring standard help option for applets into core structures #1440
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
While working on a new applet, I found that every applet was defining their own -h/--help options independently, most in very similar manners. This seems unnecessary as I am unaware of any cases where a tool would want to do something overly special for
--help
that they wouldn't do with a more specialized help command (that they of course would define).This branch is an attempt at pulling in a standard "help" option that is applied and handled for any applet.
Such a help option is defined before an applet defines it's own options in
add_command_options
, and the generic help option is handled before an applet'srun()
is invoked.This is currently marked as a "draft" as this change has ramifications to disseminate into the existing applets. Initial observations show that this should not be difficult or time consuming to disseminate.Actually just went and fixed the existing applets because it was "easy."