diff options
author | W. Trevor King <wking@drexel.edu> | 2008-11-27 09:26:52 -0500 |
---|---|---|
committer | W. Trevor King <wking@drexel.edu> | 2008-11-27 09:26:52 -0500 |
commit | adb7e854b56aa7c3df6fae677fe383f417e364c4 (patch) | |
tree | a396ad3ba0d175f8a157c2e8ec6a19240b56510e /be | |
parent | 998525bf43305b1d53927975621ab9f211d0ed95 (diff) | |
download | bugseverywhere-adb7e854b56aa7c3df6fae677fe383f417e364c4.tar.gz |
Basic bash completion is now supported.
I'm still working on a clean implementation though...
Diffstat (limited to 'be')
-rwxr-xr-x | be | 5 |
1 files changed, 5 insertions, 0 deletions
@@ -27,6 +27,8 @@ if len(sys.argv) == 1 or sys.argv[1] in ('--help', '-h'): elif sys.argv[1] == '--commands': for command, module in cmdutil.iter_commands(): print command +elif sys.argv[1] == '--options': + print '\n'.join(cmdutil.options()) else: try: try: @@ -36,6 +38,9 @@ else: except cmdutil.GetHelp: print cmdutil.help(sys.argv[1]) sys.exit(0) + except cmdutil.GetCompletions, e: + print '\n'.join(e.completions) + sys.exit(0) except cmdutil.UsageError, e: print "Invalid usage:", e print "\nArgs:", sys.argv[1:] |