diff options
author | Kevin Van Brunt <kmvanbrunt@gmail.com> | 2020-08-13 14:19:05 -0400 |
---|---|---|
committer | Kevin Van Brunt <kmvanbrunt@gmail.com> | 2020-08-13 14:20:31 -0400 |
commit | e6da8596c433f46bc337c7e8a14c7de1b0310e4c (patch) | |
tree | 09f5a3225376e26dcb03419d6243c8fc52433b07 /examples/modular_commands/commandset_basic.py | |
parent | 5dd2d03ef35a3d33ff53d82c8039d68e263246ee (diff) | |
download | cmd2-git-e6da8596c433f46bc337c7e8a14c7de1b0310e4c.tar.gz |
Replaced choices_function / choices_method with choices_provider.
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
Diffstat (limited to 'examples/modular_commands/commandset_basic.py')
-rw-r--r-- | examples/modular_commands/commandset_basic.py | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/examples/modular_commands/commandset_basic.py b/examples/modular_commands/commandset_basic.py index 2ceda439..9c94e01e 100644 --- a/examples/modular_commands/commandset_basic.py +++ b/examples/modular_commands/commandset_basic.py @@ -4,8 +4,7 @@ A simple example demonstrating a loadable command set """ from typing import List -from cmd2 import Cmd, CommandSet, Statement, with_category, with_default_category -from cmd2.utils import CompletionError +from cmd2 import Cmd, CommandSet, CompletionError, Statement, with_category, with_default_category @with_default_category('Basic Completion') |