aboutsummaryrefslogtreecommitdiffstats
path: root/becommands/open.py
diff options
context:
space:
mode:
authorW. Trevor King <wking@drexel.edu>2008-11-27 11:03:21 -0500
committerW. Trevor King <wking@drexel.edu>2008-11-27 11:03:21 -0500
commit84551c20fe603ee9832b0b17061660cdf31a913e (patch)
tree20a4e0924b74baee0402213ed9b1dde4214fd840 /becommands/open.py
parent216e39db0bd3491ee3740f69a8f2afd49f76eb2f (diff)
downloadbugseverywhere-84551c20fe603ee9832b0b17061660cdf31a913e.tar.gz
Added bugid_args option to cmdutil.default_complete.
Now most of the bug-id arguments support Bash completion. Since there will hopefully be lots of bugs in the database, I decided to filter the list of available bugs. Currently, we just auto-complete active bugs for most commands, with the exceptions of open (obviously) and status (which needs to work on all types of bugs).
Diffstat (limited to 'becommands/open.py')
-rw-r--r--becommands/open.py3
1 files changed, 2 insertions, 1 deletions
diff --git a/becommands/open.py b/becommands/open.py
index 41db5e9..7a18fd0 100644
--- a/becommands/open.py
+++ b/becommands/open.py
@@ -32,7 +32,8 @@ def execute(args, test=False):
"""
parser = get_parser()
options, args = parser.parse_args(args)
- cmdutil.default_complete(options, args, parser)
+ cmdutil.default_complete(options, args, parser,
+ bugid_args={0: lambda bug : bug.active==False})
if len(args) == 0:
raise cmdutil.UsageError, "Please specify a bug id."
if len(args) > 1: