aboutsummaryrefslogtreecommitdiffstats
path: root/be
diff options
context:
space:
mode:
authorW. Trevor King <wking@drexel.edu>2008-11-27 09:26:52 -0500
committerW. Trevor King <wking@drexel.edu>2008-11-27 09:26:52 -0500
commitadb7e854b56aa7c3df6fae677fe383f417e364c4 (patch)
treea396ad3ba0d175f8a157c2e8ec6a19240b56510e /be
parent998525bf43305b1d53927975621ab9f211d0ed95 (diff)
downloadbugseverywhere-adb7e854b56aa7c3df6fae677fe383f417e364c4.tar.gz
Basic bash completion is now supported.
I'm still working on a clean implementation though...
Diffstat (limited to 'be')
-rwxr-xr-xbe5
1 files changed, 5 insertions, 0 deletions
diff --git a/be b/be
index 2e038a5..ab6ddeb 100755
--- a/be
+++ b/be
@@ -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:]