diff options
author | W. Trevor King <wking@drexel.edu> | 2008-11-15 18:35:41 -0500 |
---|---|---|
committer | W. Trevor King <wking@drexel.edu> | 2008-11-15 18:35:41 -0500 |
commit | 03011f286420d8e091052019ee41eba021041e61 (patch) | |
tree | fcf389e28c1142d61015bf37134925d4b209ba25 /becommands | |
parent | 137f084f2931a0e2e1fa3076beadac17b88ef6b6 (diff) | |
download | bugseverywhere-03011f286420d8e091052019ee41eba021041e61.tar.gz |
Moved libbe.cmdutil.bug_summary() to libbe.bug.Bug.string().
This seems like a natual place for a function that only operates on Bugs.
Diffstat (limited to 'becommands')
-rw-r--r-- | becommands/list.py | 3 | ||||
-rw-r--r-- | becommands/show.py | 2 | ||||
-rw-r--r-- | becommands/upgrade.py | 3 |
3 files changed, 3 insertions, 5 deletions
diff --git a/becommands/list.py b/becommands/list.py index e127c50..6cd7826 100644 --- a/becommands/list.py +++ b/becommands/list.py @@ -107,8 +107,7 @@ def execute(args): if title != None: print cmdutil.underlined(title) for bug in cur_bugs: - print cmdutil.bug_summary(bug, all_bugs, no_target=no_target, - shortlist=True), + print bug.string(all_bugs, shortlist=True), list_bugs(bugs, no_target=False) diff --git a/becommands/show.py b/becommands/show.py index 786ba29..678a607 100644 --- a/becommands/show.py +++ b/becommands/show.py @@ -25,7 +25,7 @@ def execute(args): raise cmdutil.UserError("Please specify a bug id.") bug_dir = cmdutil.bug_tree() bug = cmdutil.get_bug(args[0], bug_dir) - print cmdutil.bug_summary(bug, list(bug_dir.list())).rstrip("\n") + print bug.string().rstrip("\n") unique_name = cmdutil.unique_name(bug, bug_dir.list()) comments = [] name_map = {} diff --git a/becommands/upgrade.py b/becommands/upgrade.py index 8f7c3a4..f5b12ef 100644 --- a/becommands/upgrade.py +++ b/becommands/upgrade.py @@ -18,7 +18,6 @@ import os.path import errno from libbe import bugdir, rcs, cmdutil -from libbe.bug import Bug def execute(args): options, args = get_parser().parse_args(args) @@ -26,7 +25,7 @@ def execute(args): for uuid in root.list_uuids(): old_bug = OldBug(root.bugs_path, uuid) - new_bug = Bug(root.bugs_path, None) + new_bug = root.get_bug(uuid) new_bug.uuid = old_bug.uuid new_bug.summary = old_bug.summary new_bug.creator = old_bug.creator |