aboutsummaryrefslogtreecommitdiffstats
path: root/libbe/cmdutil.py
diff options
context:
space:
mode:
Diffstat (limited to 'libbe/cmdutil.py')
-rw-r--r--libbe/cmdutil.py11
1 files changed, 11 insertions, 0 deletions
diff --git a/libbe/cmdutil.py b/libbe/cmdutil.py
index 2214260..ffd141e 100644
--- a/libbe/cmdutil.py
+++ b/libbe/cmdutil.py
@@ -33,3 +33,14 @@ def get_bug(spec, bug_dir):
if len(matches) == 0:
raise UserError("No bug has the name %s" % spec)
return matches[0]
+
+def bug_summary(bug, bugs):
+ target = bug.target
+ if target is None:
+ target = ""
+ else:
+ target = " target: %s" % target
+ return "id: %s severity: %s%s creator: %s \n%s\n" % \
+ (unique_name(bug, bugs), bug.severity, target, bug.creator,
+ bug.summary)
+