Commit message (Collapse) | Author | Age | Files | Lines | ||
---|---|---|---|---|---|---|
... | ||||||
* | Now maintains a command->CommandSet mapping and passes the CommandSet | anselor | 2020-08-04 | 7 | -80/+539 | |
| | | | | | | | | | | | | | | | 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. | |||||
* | Ignore plugins directory when running doc8 by itself outside of invoke | Todd Leonhardt | 2020-08-04 | 1 | -1/+1 | |
| | ||||||
* | Updated Pipfile to do an editable/dev install of cmd2_ext_test so that "inv ↵ | Todd Leonhardt | 2020-08-04 | 1 | -0/+1 | |
| | | | | pytest" doesn't crash | |||||
* | Fix it so py.test by itself doesn't crash | Todd Leonhardt | 2020-08-04 | 1 | -0/+4 | |
| | | | | | | Change setup.cfg so that pytest only runs tests in the tests directory by default. Attempting to run tests in the isolated_tests directory was causing a crash | |||||
* | Fix a couple doc8 warnings | Todd Leonhardt | 2020-08-04 | 1 | -5/+7 | |
| | ||||||
* | Updated documentation | Kevin Van Brunt | 2020-08-04 | 1 | -2/+10 | |
| | ||||||
* | Updated documentation | Kevin Van Brunt | 2020-08-04 | 1 | -1/+5 | |
| | ||||||
* | Added handling for disabled commands to CommandSet functions | Kevin Van Brunt | 2020-08-04 | 1 | -6/+19 | |
| | ||||||
* | Fixes to how command callables are filtered from CommandSet | Eric Lin | 2020-08-04 | 1 | -4/+5 | |
| | ||||||
* | Fixed issue where we attempted to remove CommandSet from a list it was not in | Kevin Van Brunt | 2020-08-04 | 1 | -1/+2 | |
| | ||||||
* | 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 | 3 | -28/+30 | |
| | ||||||
* | Suggested PR Fixes. | Eric Lin | 2020-08-04 | 7 | -36/+44 | |
| | | | | | sub-commande => subcommand Added help/aliases to `as_subcommand_to` decorator. | |||||
* | Adds unit tests for sub-commands and additional commandset edge cases | Eric Lin | 2020-08-04 | 2 | -12/+187 | |
| | ||||||
* | Adds support for injectable subcommands as part of CommandSet | Eric Lin | 2020-08-04 | 7 | -8/+396 | |
| | | | | | | load/unload. Updated examples and documentation to include discussion of injectable sub-commands. | |||||
* | updated imports | Eric Lin | 2020-08-04 | 22 | -48/+374 | |
| | | | | Added additional documentation | |||||
* | Updates the example to remove usage of the now remove ability to | Eric Lin | 2020-08-04 | 6 | -66/+154 | |
| | | | | | | | | | | 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. | |||||
* | Removed support for functions outside of CommandSets | Eric Lin | 2020-08-04 | 4 | -308/+13 | |
| | ||||||
* | Moved commandset tests into an isolated test | Eric Lin | 2020-08-04 | 4 | -2/+208 | |
| | ||||||
* | added additional documentation for new decorator behavior | Eric Lin | 2020-08-04 | 1 | -3/+24 | |
| | ||||||
* | Added an additional check for isinstance(method, Callable) since there are ↵ | Eric Lin | 2020-08-04 | 1 | -1/+2 | |
| | | | | scenarios where inspect.ismethod() fails for some reason | |||||
* | Adjusted decorators to accept variable positional parameters | Eric Lin | 2020-08-04 | 1 | -18/+41 | |
| | ||||||
* | cleanup | Eric Lin | 2020-08-04 | 1 | -7/+7 | |
| | ||||||
* | Sort imports using isort | Todd Leonhardt | 2020-08-04 | 4 | -14/+6 | |
| | ||||||
* | Appears to be a type hinting olution that works for flake, sphinx, and PyCharm | Eric Lin | 2020-08-04 | 1 | -8/+11 | |
| | ||||||
* | Added more command validation. Moved some common behavior into private ↵ | Eric Lin | 2020-08-04 | 3 | -36/+101 | |
| | | | | functions. | |||||
* | Added explicit tests for dir and setattr. Minor type hinting changes | Eric Lin | 2020-08-04 | 1 | -0/+24 | |
| | ||||||
* | Fixes to sphinx generation | Eric Lin | 2020-08-04 | 4 | -2/+8 | |
| | ||||||
* | Fixes issue with locating help_ annd complete_ functions when autoloading ↵ | Eric Lin | 2020-08-04 | 4 | -36/+188 | |
| | | | | | | command functions Adds handling of some edge cases. More thorough test coverage. | |||||
* | add ability to remove commands and commandsets | Eric Lin | 2020-08-04 | 4 | -8/+148 | |
| | | | | Issue #943 | |||||
* | Added new constructor parameter to flag whether commands should autoload. ↵ | Eric Lin | 2020-08-04 | 2 | -31/+169 | |
| | | | | | | Added unit tests. Moved installing commands into separate functions that can be called Issue #943 | |||||
* | Some minor cleanup of how imports work. Fixed issue with help documentation ↵ | Eric Lin | 2020-08-04 | 6 | -14/+34 | |
| | | | | | | for CommandSet commands. Issue #943 | |||||
* | Initial implementation of modular command loading | Eric Lin | 2020-08-04 | 6 | -2/+451 | |
| | | | | | | | | | | Issue #943 New class CommandSet can be used to tag a class as a command class. If the constructor is simple, the object will automatically be instantiated and loaded. New register_command decorator to tag any arbitrary function as a command. | |||||
* | Added 'no cover' for code block which cannot be tested in our unit tests | Kevin Van Brunt | 2020-08-03 | 1 | -1/+1 | |
| | ||||||
* | Added type annotations for fields in cmd2.Cmd. | Eric Lin | 2020-07-21 | 9 | -45/+66 | |
| | | | | | | | Cleaned up docstring in external test plugin Updated some initialization to match new approach for version info discovery. Tagged some IDE-only lines as no-cover Adds plugin coverage reporting. | |||||
* | Merge pull request #959 from python-cmd2/doc_fix | Kevin Van Brunt | 2020-07-17 | 2 | -13/+13 | |
|\ | | | | | Fixed hook documentation | |||||
| * | Fixed hook documentation | Kevin Van Brunt | 2020-07-17 | 2 | -13/+13 | |
|/ | ||||||
* | Updated release date for 1.2.1 in CHANGELOG1.2.1 | Todd Leonhardt | 2020-07-14 | 1 | -2/+2 | |
| | ||||||
* | Brought in cmd2 plugin template as a first-class member of cmd2 proper | Eric Lin | 2020-07-14 | 17 | -16/+900 | |
| | ||||||
* | Merge pull request #956 from python-cmd2/importlib-metadata | Todd Leonhardt | 2020-07-13 | 2 | -1/+5 | |
|\ | | | | | Fix a dependency version requirement which was too restrictive | |||||
| * | Fix a dependency version requirement which was too restrictive and required ↵ | Todd Leonhardt | 2020-07-13 | 2 | -1/+5 | |
|/ | | | | bleeding edge for no good reason | |||||
* | Updated CHANGELOG | Todd Leonhardt | 2020-07-13 | 1 | -0/+2 | |
| | ||||||
* | Merge pull request #955 from python-cmd2/typing_deque1.2.0 | Todd Leonhardt | 2020-07-13 | 2 | -1/+11 | |
|\ | | | | | Fix compatibility with Python 3.5 versions prior to 3.5.4 | |||||
| * | Added PyCharm warning suppressions | Todd Leonhardt | 2020-07-13 | 1 | -0/+2 | |
| | | ||||||
| * | small simplification | Todd Leonhardt | 2020-07-13 | 1 | -2/+1 | |
| | | ||||||
| * | slight cleanup | Todd Leonhardt | 2020-07-13 | 1 | -2/+2 | |
| | | ||||||
| * | Address fact that typing.Deque wasn't defined prior to 3.5.4 | Todd Leonhardt | 2020-07-13 | 2 | -1/+10 | |
|/ | ||||||
* | Update release date in CHANGELOG | Todd Leonhardt | 2020-07-13 | 1 | -1/+1 | |
| | ||||||
* | Updated CHANGELOG | Todd Leonhardt | 2020-07-12 | 1 | -0/+6 | |
| | ||||||
* | Merge pull request #953 from dhellmann/drop-pkg-resources | Todd Leonhardt | 2020-07-12 | 4 | -12/+22 | |
|\ | | | | | replace pkg_resources with importlib.metadata |