From 9bfac949bf3764f61a42633b88e54ce766d95786 Mon Sep 17 00:00:00 2001 From: Aaron Bentley Date: Mon, 21 Mar 2005 14:10:43 +0000 Subject: [PATCH] Stopped showing targets under target-specific headings --- becommands/list.py | 12 +++++++----- libbe/cmdutil.py | 4 ++-- 2 files changed, 9 insertions(+), 7 deletions(-) diff --git a/becommands/list.py b/becommands/list.py index 94ca10a..f647564 100644 --- a/becommands/list.py +++ b/becommands/list.py @@ -45,19 +45,21 @@ def execute(args): else: other_bugs.append(bug) - def list_bugs(cur_bugs, title): + def list_bugs(cur_bugs, title, no_target=False): cur_bugs.sort(bugdir.cmp_severity) if len(cur_bugs) > 0: print cmdutil.underlined(title) for bug in cur_bugs: - print cmdutil.bug_summary(bug, all_bugs) + print cmdutil.bug_summary(bug, all_bugs, no_target=no_target) list_bugs(my_target_bugs, - "Bugs assigned to you for target %s" % tree.target) + "Bugs assigned to you for target %s" % tree.target, + no_target=True) list_bugs(unassigned_target_bugs, - "Unassigned bugs for target %s" % tree.target) + "Unassigned bugs for target %s" % tree.target, no_target=True) list_bugs(other_target_bugs, - "Bugs assigned to others for target %s" % tree.target) + "Bugs assigned to others for target %s" % tree.target, + no_target=True) list_bugs(my_bugs, "Bugs assigned to you") list_bugs(unassigned_bugs, "Unassigned bugs") list_bugs(other_bugs, "Bugs assigned to others") diff --git a/libbe/cmdutil.py b/libbe/cmdutil.py index 7ce8ac2..86fee80 100644 --- a/libbe/cmdutil.py +++ b/libbe/cmdutil.py @@ -42,9 +42,9 @@ def get_bug(spec, bug_dir=None): raise UserError("No bug matches %s" % spec) return matches[0] -def bug_summary(bug, bugs): +def bug_summary(bug, bugs, no_target=False): target = bug.target - if target is None: + if target is None or no_target: target = "" else: target = " Target: %s" % target -- 2.26.2