summaryrefslogtreecommitdiff
path: root/examples
Commit message (Collapse)AuthorAgeFilesLines
* Minor housekeeping. Updated CODEOWNERS with recent additionsEric Lin2020-08-071-1/+1
|
* Moved code which copies subparser's settings to _register_subcommands().Kevin Van Brunt2020-08-071-5/+7
| | | | | Changed alias and macro commands to use as_subcommand_to() decorator. Updated CommandSet subcommand example to use help and description text.
* Removed obsolete argument1.3.0Kevin Van Brunt2020-08-041-1/+1
|
* Marked with_arparser_and_unknown_args deprecated and consolidatedEric Lin2020-08-043-3/+3
| | | | implementation as an option to with_argparser instead.
* Minor formatting fixes. Injecting a function into namespace objects before ↵Eric Lin2020-08-041-3/+3
| | | | passing to command handlers to access sub-command handlers
* Suggested PR Fixes.Eric Lin2020-08-041-3/+3
| | | | | sub-commande => subcommand Added help/aliases to `as_subcommand_to` decorator.
* Adds support for injectable subcommands as part of CommandSetEric Lin2020-08-041-0/+110
| | | | | | load/unload. Updated examples and documentation to include discussion of injectable sub-commands.
* updated importsEric Lin2020-08-045-5/+128
| | | | Added additional documentation
* Updates the example to remove usage of the now remove ability toEric Lin2020-08-044-43/+56
| | | | | | | | | | 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.
* cleanupEric Lin2020-08-041-7/+7
|
* Sort imports using isortTodd Leonhardt2020-08-042-2/+2
|
* Fixes issue with locating help_ annd complete_ functions when autoloading ↵Eric Lin2020-08-041-0/+17
| | | | | | command functions Adds handling of some edge cases. More thorough test coverage.
* Some minor cleanup of how imports work. Fixed issue with help documentation ↵Eric Lin2020-08-042-4/+2
| | | | | | for CommandSet commands. Issue #943
* Initial implementation of modular command loadingEric Lin2020-08-044-0/+265
| | | | | | | | | | 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.
* Updated argparse_completer to use TableCreator for the hint tableKevin Van Brunt2020-05-281-1/+1
|
* Added info on semantic versioning and branching strategy to CONTRIBUTING.mdTodd Leonhardt2020-04-2415-14/+20
| | | | | | | 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
* Updated tab completion documentationKevin Van Brunt2020-04-231-1/+1
|
* Removed tableformatter example since cmd2 now has its own table creator ↵Kevin Van Brunt2020-04-211-204/+0
| | | | library and example program
* Added configurable padding to BorderedTable/AlternatingTableKevin Van Brunt2020-04-191-1/+1
| | | | Updated comments
* Initial commit of table creation APIKevin Van Brunt2020-04-091-0/+77
|
* Added documentation about decorator order and updated an exampleTodd Leonhardt2020-04-091-6/+23
| | | | | Also: - Deal with warnings when building docs with Sphinx 3.0.0
* Update scripting docs. Closes #765.kotfu2020-02-281-13/+19
|
* Updated python scripting exmaple to illustrate howEric Lin2020-02-242-21/+25
| | | | | stdout/stderr is automatically captured in CommandResult during python scripting. Fixes #898
* Added apply_style to CompletionErrorKevin Van Brunt2020-02-181-2/+1
| | | | Simplified error class structure in argparse_completer.py
* Added use of CompletionError to basic completion exampleKevin Van Brunt2020-02-181-6/+23
|
* Made CompletionError exception available to non-argparse tab completionKevin Van Brunt2020-02-171-2/+2
|
* Fixed missing importKevin Van Brunt2020-02-131-0/+2
|
* Updated documentationKevin Van Brunt2020-02-131-5/+5
|
* Finished argparse completion exampleKevin Van Brunt2020-02-131-21/+49
|
* Wrote examples for CompletionError and CompletionItemKevin Van Brunt2020-02-131-13/+34
|
* Start of new argparse completion exampleKevin Van Brunt2020-02-131-0/+73
|
* Removed dash from 'tab complete' stringKevin Van Brunt2020-02-131-6/+6
|
* Removed use of argparse from basic completion exampleKevin Van Brunt2020-02-131-46/+30
|
* Overhauling tab completion examplesKevin Van Brunt2020-02-123-272/+29
|
* Updated release data for 1.0.0-rc1 in preparation for a release candidateTodd Leonhardt2020-02-072-2/+2
| | | | | Also: - Updated some very outdated comments in transcript files
* Updated plumbum exampleKevin Van Brunt2020-02-071-32/+33
|
* Updated changelog to address removal of ansi.FG_COLORS and ansi.BG_COLORS ↵Todd Leonhardt2020-02-071-8/+8
| | | | | | | and mention their replacement by ansi.fg and ansi.bg enums Also: - Use ansi.fg in async_printing.py and README.md
* Having two parallel datastructures each for foreground and background colors ↵Todd Leonhardt2020-02-063-7/+6
| | | | | | felt really clunky - now we just have one The Enum classes are now smart and deal with it all.
* Added convenience `ansi.fg` and `ansi.bg` enums of foreground and background ↵Todd Leonhardt2020-02-061-2/+2
| | | | | | colors which style() can now optionally use This is to make it easier to autocomplete color names in an IDE
* Fixed example codeKevin Van Brunt2020-02-061-1/+1
|
* Documentation updateskotfu2020-02-051-3/+7
|
* Updated documentationKevin Van Brunt2020-02-051-1/+1
|
* Removed unnecessary inheritance from objectKevin Van Brunt2020-02-041-1/+1
|
* Updated example transcriptsTodd Leonhardt2020-02-042-2/+2
|
* Added cmd2.utils.Settable to the cmd2 namespace and updated examples and docsTodd Leonhardt2020-02-0410-11/+32
|
* Renamed locals_in_py to self_in_pyTodd Leonhardt2020-01-278-8/+8
| | | | This more accurately reflects what it controls
* Made three public attributes of cmd2.Cmd no longer settable at runtime by ↵Todd Leonhardt2020-01-273-7/+3
| | | | | | | | | end users The 3 attributes are: - continuation_prompt - locals_in_py - prompt
* Improved example in initialiation docsTodd Leonhardt2020-01-261-0/+60
|
* Merge branch 'master' into generating_output_docsTodd Leonhardt2020-01-095-22/+36
|\ | | | | | | | | | | # Conflicts: # docs/features/generating_output.rst # docs/features/settings.rst
| * Merge branch 'master' into ansi_to_styleKevin Van Brunt2020-01-071-6/+20
| |\