summaryrefslogtreecommitdiff
path: root/examples/python_scripting.py
diff options
context:
space:
mode:
authorkotfu <kotfu@kotfu.net>2020-02-14 20:51:21 -0700
committerkotfu <kotfu@kotfu.net>2020-02-14 20:51:21 -0700
commitc8ba8b94950edcad47f791cceec949f174ea7c71 (patch)
treedbae3fa7482c24d6cca9a52d597f498c61d18be0 /examples/python_scripting.py
parent9c6f1304816707e38c74926c93f62e48836b95c9 (diff)
parent013b9e0a2c75e17f8aa0e0f7cbe50d84d2f657d8 (diff)
downloadcmd2-git-c8ba8b94950edcad47f791cceec949f174ea7c71.tar.gz
Merge branch 'master' into api_docs
# Conflicts: # cmd2/ansi.py # docs/features/completion.rst
Diffstat (limited to 'examples/python_scripting.py')
-rwxr-xr-xexamples/python_scripting.py1
1 files changed, 1 insertions, 0 deletions
diff --git a/examples/python_scripting.py b/examples/python_scripting.py
index fc23c562..198e784d 100755
--- a/examples/python_scripting.py
+++ b/examples/python_scripting.py
@@ -87,6 +87,7 @@ class CmdLineApp(cmd2.Cmd):
# Enable tab completion for cd command
def complete_cd(self, text, line, begidx, endidx):
+ # Tab complete only directories
return self.path_complete(text, line, begidx, endidx, path_filter=os.path.isdir)
dir_parser = argparse.ArgumentParser()