summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTodd Leonhardt <todd.leonhardt@gmail.com>2019-07-20 17:43:29 -0400
committerTodd Leonhardt <todd.leonhardt@gmail.com>2019-07-20 17:43:29 -0400
commitd0203602b79902df183d007b777234011b68efa9 (patch)
treefd4659cd8f59a89c1e37bd013d8ef64dc1cc2ff6
parentc58807934de73cfc2a53ae1c6d8f4ef38a982872 (diff)
downloadcmd2-git-d0203602b79902df183d007b777234011b68efa9.tar.gz
Added a self.default_category attribute which gets set to 'Uncategorized'
-rw-r--r--cmd2/cmd2.py4
1 files changed, 3 insertions, 1 deletions
diff --git a/cmd2/cmd2.py b/cmd2/cmd2.py
index 9d8c67dc..1ab86824 100644
--- a/cmd2/cmd2.py
+++ b/cmd2/cmd2.py
@@ -559,6 +559,8 @@ class Cmd(cmd.Cmd):
# values are DisabledCommand objects.
self.disabled_commands = dict()
+ self.default_category = 'Uncategorized'
+
# ----- Methods related to presenting output to the user -----
@property
@@ -2797,7 +2799,7 @@ class Cmd(cmd.Cmd):
self.poutput('{}'.format(str(self.doc_header)), end="\n\n")
for category in sorted(cmds_cats.keys(), key=self.default_sort_key):
self._print_topics(category, cmds_cats[category], verbose)
- self._print_topics('Other', cmds_doc, verbose)
+ self._print_topics(self.default_category, cmds_doc, verbose)
self.print_topics(self.misc_header, help_topics, 15, 80)
self.print_topics(self.undoc_header, cmds_undoc, 15, 80)