From 179c68aed72e9a3f4aab6915c4e693b0020b6024 Mon Sep 17 00:00:00 2001 From: Rob Austein Date: Thu, 11 Mar 2010 04:13:05 +0000 Subject: Help messages. svn path=/rpkid/rpki/cli.py; revision=3072 --- rpkid/rpki/cli.py | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/rpkid/rpki/cli.py b/rpkid/rpki/cli.py index 2443e1b3..38bef37a 100644 --- a/rpkid/rpki/cli.py +++ b/rpkid/rpki/cli.py @@ -47,11 +47,17 @@ class Cmd(cmd.Cmd): self.cmdloop_with_history() def do_EOF(self, arg): + """ + Exit program. + """ if self.EOF_exits_command_loop and self.prompt: print return self.EOF_exits_command_loop def do_exit(self, arg): + """ + Exit program. + """ return True do_quit = do_exit @@ -76,6 +82,13 @@ class Cmd(cmd.Cmd): result.add(result.pop() + " ") return list(result) + def help_help(self): + """ + Type "help [topic]" for help on a command, + or just "help" for a list of commands. + """ + self.stdout.write(self.help_help.__doc__ + "\n") + if have_readline: def cmdloop_with_history(self): -- cgit v1.2.3