Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
826: Refactor option and argument parsing r=00vareladavid a=00vareladavid Changes: - move option parsing to `parse`: it is purely syntactical and does not depend on the command specs - remove redundant option check - fold `enforce_argument_order` into `parse_pkg`: `enforce_argument_order` was needlessly abstract - break up `arg_spec` into `arg_count` and `arg_parser`. - Omitting `arg_parser` means "don't do any special parsing on the arguments" (i.e. the "parser" is just `identity`). - Omitting `arg_count` means "this command does not take arguments". - added some docstrings and comments Co-authored-by: David Varela <[email protected]>
- Loading branch information