Skip to content

Optargs#45

Merged
dparrish merged 4 commits intodparrish:Optargsfrom
RobSanders:optargs
Jul 20, 2019
Merged

Optargs#45
dparrish merged 4 commits intodparrish:Optargsfrom
RobSanders:optargs

Conversation

@RobSanders
Copy link
Copy Markdown
Collaborator

Added new 'CLI_CMD_SPOT_CHECK' optarg to allow for sanity checking of required optargs before proceeding with command line evaluation. The developer would insert a spot check before any place in the evaluation of arguments where evaluation should not continue if the required optarg state is incorrect.
The clitest.c program show this. Before entering the 'shape' optarg we need to have at least one of 'transparent' and 'color' set, but we can not have 'transparent' if 'color' is set to 'black'.
Added show/unset to the restricted commands when trying to enter buildmode, and made some comment changes.

RobSanders and others added 4 commits July 19, 2019 09:19
CLI_CMD_SPOT_CHECK is designed to allow a 'spot check' to ensure
that the optargs seen so far are 'sane' to allow parsing to continue.
The check will  *only* be done if there are no potential candidates
at the point where the spot check is being evaluated.  The recommended
place to put any spot check is immediately prior to any command that
would need 'sane' arguments to continue.
@dparrish dparrish merged commit 7093e49 into dparrish:Optargs Jul 20, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants