Commit message (Collapse) | Author | Age | Files | Lines | |
---|---|---|---|---|---|
* | Updating docs | Kevin Van Brunt | 2021-09-01 | 1 | -0/+2 |
| | |||||
* | Added ap_completer_type arg to Cmd2ArgumentParser.__init__(). | Kevin Van Brunt | 2021-09-01 | 1 | -0/+11 |
| | | | | Added unit tests for custom ArgparseCompleter | ||||
* | Refactored custom ArgparseCompleter functionality so they will now be set ↵ | Kevin Van Brunt | 2021-09-01 | 1 | -3/+65 |
| | | | | | | using methods on ArgumentParser objects. This fixes issue where subcommands did not use the correct custom ArgparseCompleter type. | ||||
* | Merge branch 'master' into topic_width | Kevin Van Brunt | 2021-08-23 | 1 | -1/+83 |
|\ | |||||
| * | Updated documentation for setting custom parsers | Kevin Van Brunt | 2021-08-23 | 1 | -1/+4 |
| | | |||||
| * | Applied black format | Eric Lin | 2021-08-23 | 1 | -0/+1 |
| | | |||||
| * | * New function `set_default_command_completer_type()` allows developer to ↵ | Eric Lin | 2021-08-23 | 1 | -0/+78 |
| | | | | | | | | | | | | | | | | | | extend and modify the behavior of `ArgparseCompleter`. * New function `register_argparse_argument_parameter()` allows developers to specify custom parameters to be passed to the argparse parser's `add_argument()` method. These parameters will become accessible in the resulting argparse Action object when modifying `ArgparseCompleter` behavior. | ||||
* | | Updated documentationtopic_width | Kevin Van Brunt | 2021-08-19 | 1 | -0/+1 |
| | | |||||
* | | Merge branch 'master' into topic_width | Kevin Van Brunt | 2021-08-19 | 1 | -25/+0 |
|\ \ | |/ | |||||
| * | Deleted set_choices_provider() and set_completer() which were deprecated in ↵ | Kevin Van Brunt | 2021-08-19 | 1 | -25/+0 |
| | | | | | | | | 2.1.2 | ||||
* | | set command output now uses SimpleTable. | Kevin Van Brunt | 2021-08-19 | 1 | -0/+1 |
|/ | | | | | | | Tabled tab completion now includes divider row. Tab completion results for aliases, macros, and Settables wrap long fields. SimpleTable now accepts blank for the divider character. It is identical to passing None. Removed --verbose flag from set command so the descriptions always show. | ||||
* | Added accessor methods for cmd2-specific attributes to the argparse.Action ↵ | Kevin Van Brunt | 2021-07-04 | 1 | -50/+269 |
| | | | | | | class. Deprecated set_choices_provider() and set_completer() functions in favor of these new methods. | ||||
* | Fixed handling of argparse's default options group name which was changed in ↵ | Kevin Van Brunt | 2021-06-17 | 1 | -2/+7 |
| | | | | Python 3.10 | ||||
* | Updated main code to use f-strings | Kevin Van Brunt | 2021-04-13 | 1 | -12/+10 |
| | |||||
* | And that's the last of it. Passes mypy. | Eric Lin | 2021-04-06 | 1 | -3/+31 |
| | |||||
* | More mypy fixes | Eric Lin | 2021-04-06 | 1 | -10/+21 |
| | |||||
* | More mypy validation changes. cmd2.py is nearly fully mypy compliant now. | Eric Lin | 2021-04-02 | 1 | -4/+3 |
| | |||||
* | More things to make mypy happy. | Eric Lin | 2021-04-02 | 1 | -2/+2 |
| | |||||
* | Resolves comments from PR | Eric Lin | 2021-03-18 | 1 | -31/+110 |
| | |||||
* | Some mypy validation fixes | Eric Lin | 2021-03-18 | 1 | -27/+43 |
| | |||||
* | Start making small changes to fix mypy warnings | Todd Leonhardt | 2021-02-21 | 1 | -4/+5 |
| | |||||
* | Fixed black, isort, flake8, and doc8 issues | Todd Leonhardt | 2021-02-19 | 1 | -13/+17 |
| | |||||
* | Merge branch 'master' into black | Todd Leonhardt | 2021-02-19 | 1 | -119/+62 |
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | # Conflicts: # cmd2/__init__.py # cmd2/argparse_completer.py # cmd2/argparse_custom.py # cmd2/cmd2.py # cmd2/decorators.py # cmd2/exceptions.py # cmd2/utils.py # examples/arg_decorators.py # examples/argparse_completion.py # examples/modular_commands_main.py # tests/test_argparse_completer.py # tests/test_argparse_custom.py # tests/test_cmd2.py # tests/test_completion.py # tests/test_history.py | ||||
| * | Merge branch 'master' into 2.0 | Kevin Van Brunt | 2021-01-22 | 1 | -4/+19 |
| |\ | |||||
| * \ | Merge branch 'master' into 2.0 | Todd Leonhardt | 2020-11-11 | 1 | -11/+13 |
| |\ \ | | | | | | | | | | | | | | | | | # Conflicts: # CHANGELOG.md | ||||
| * \ \ | Merge branch 'master' into 2.0 | Kevin Van Brunt | 2020-08-27 | 1 | -1/+19 |
| |\ \ \ | |||||
| * | | | | Documented support for standalone functions being used as completers and ↵ | Kevin Van Brunt | 2020-08-18 | 1 | -3/+8 |
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | choices_providers. Added unit tests for this case. | ||||
| * | | | | Replaced choices_function / choices_method with choices_provider. | Kevin Van Brunt | 2020-08-13 | 1 | -100/+48 |
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Replaced completer_function / completer_method with completer. ArgparseCompleter now always passes cmd2.Cmd or CommandSet instance as the self argument to choices_provider and completer functions. Moved basic_complete from utils into cmd2.Cmd class. Moved CompletionError to exceptions.py | ||||
* | | | | | Add black for automatic code format | Todd Leonhardt | 2021-01-31 | 1 | -36/+55 |
| |_|_|/ |/| | | | |||||
* | | | | Changed isort to force wrapping of imports to reduce merge conflicts from ↵ | Eric Lin | 2021-01-22 | 1 | -4/+19 |
| |_|/ |/| | | | | | | | | minor import changes. | ||||
* | | | Fixed issue where instantiating more than one cmd2-based class which uses ↵duplicate_subcommand | Kevin Van Brunt | 2020-09-30 | 1 | -11/+13 |
| |/ |/| | | | | | | | | | the @as_subcommand_to decorator resulted in duplicated help text in the base command the subcommands belong to. | ||||
* | | The functions cmd2 adds to Namespaces (get_statement() and get_handler()) ↵ | Kevin Van Brunt | 2020-08-26 | 1 | -1/+19 |
|/ | | | | | | | are now Cmd2AttributeWrapper objects named cmd2_statement and cmd2_handler. This makes it easy to filter out which attributes in an argparse.Namespace were added by cmd2. | ||||
* | Fixed bug when trying to format help text of argument which used a tuple as ↵ | Kevin Van Brunt | 2020-08-12 | 1 | -18/+27 |
| | | | | its metavar | ||||
* | Breaking change: Removed cmd2 app as a required second parameter to | Eric Lin | 2020-08-12 | 1 | -9/+2 |
| | | | | | | CommandSet command functions (do_, complete_, help_). Renamed install_command_set and uninstall_command_set to register_command_set and unregister_command_set. | ||||
* | Minor formatting fixes. Injecting a function into namespace objects before ↵ | Eric Lin | 2020-08-04 | 1 | -1/+0 |
| | | | | passing to command handlers to access sub-command handlers | ||||
* | Now maintains a command->CommandSet mapping and passes the CommandSet | anselor | 2020-08-04 | 1 | -11/+35 |
| | | | | | | | | | | | | | | | through to the ArgparseCompleter if one is registered. For subcommands, the registered argparse instance for the subcommand is now tagged with the CommandSet from which it originated. If a CommandSet is detected, it's now passed in as 'self' for the completion functions. Fixes some issue found with removing a subcommand. Adds additional tests. Added a check to prevent removal of a CommandSet if it has commands with sub-commands from another CommandSet bound to it. Documentation improvements. Standardized around using CommandSetRegistrationException during commandset install/uninstall related errors. Added support for nested sub-command injection. | ||||
* | Updated documentation | Kevin Van Brunt | 2020-08-04 | 1 | -2/+10 |
| | |||||
* | Updated documentation | Kevin Van Brunt | 2020-08-04 | 1 | -1/+5 |
| | |||||
* | Fixed typo in documentation | Kevin Van Brunt | 2020-08-04 | 1 | -3/+3 |
| | |||||
* | Removed sub-class and instead patch argparse._SubParsersAction | Eric Lin | 2020-08-04 | 1 | -24/+26 |
| | |||||
* | Suggested PR Fixes. | Eric Lin | 2020-08-04 | 1 | -1/+1 |
| | | | | | sub-commande => subcommand Added help/aliases to `as_subcommand_to` decorator. | ||||
* | Adds support for injectable subcommands as part of CommandSet | Eric Lin | 2020-08-04 | 1 | -2/+30 |
| | | | | | | load/unload. Updated examples and documentation to include discussion of injectable sub-commands. | ||||
* | Updates the example to remove usage of the now remove ability to | Eric Lin | 2020-08-04 | 1 | -5/+26 |
| | | | | | | | | | | register arbitrary functions as commands. Added example that demonstrates use of each of the command decorators with CommandSets. Adds unit test that verifies that CommandSets containing decorators load and process commands correctly. Updated the constructor declaration for Cmd2ArgumentParser to explicitly re-declare argparse constructor parameters. | ||||
* | Added info on semantic versioning and branching strategy to CONTRIBUTING.md | Todd Leonhardt | 2020-04-24 | 1 | -1/+1 |
| | | | | | | | Also: - Added isort to Pipenv dev - Added setup.cfg to make it easy to run flake8, doc8, and isort directly from the command line without using invoke - Ran isort to sort includes | ||||
* | Completion doc updates | Kevin Van Brunt | 2020-04-23 | 1 | -12/+9 |
| | |||||
* | Merge branch 'master' into table_creator | Kevin Van Brunt | 2020-04-22 | 1 | -1/+1 |
|\ | |||||
| * | Consistently use :raises: instead of :raises (make sure there is a trailing ↵ | Todd Leonhardt | 2020-04-20 | 1 | -1/+1 |
| | | | | | | | | colon) | ||||
* | | Initial commit of table creation API | Kevin Van Brunt | 2020-04-09 | 1 | -11/+8 |
|/ | |||||
* | Removed duplicate word and capitalized two comment sentences | Kevin Van Brunt | 2020-02-25 | 1 | -2/+2 |
| | |||||
* | Add argparse stuff to api | kotfu | 2020-02-22 | 1 | -142/+173 |
| |