summaryrefslogtreecommitdiff
diff options
authorRobert C Jennings <robert.jennings@canonical.com>2017-06-26 11:36:06 -0500
committerRobert C Jennings <robert.jennings@canonical.com>2017-06-26 11:36:06 -0500
commit6c0547bbbb194f8ce50ba3d8c13521485df8a116 (patch)
tree9259f55fa86c3e81dd6d9fc9ec2e780b22d57a76
parent5bb73fa03c1016b75f2bd049a1e479a5974ffd1d (diff)
Rearrange summary printout and changelog printing for later refactor
bzr-revno: 18.2.16
-rwxr-xr-xmfdiff21
1 files changed, 10 insertions, 11 deletions
diff --git a/mfdiff b/mfdiff
index 2d4908a..454571c 100755
--- a/mfdiff
+++ b/mfdiff
@@ -461,12 +461,16 @@ def main():
removed = find_removed(h_from, h_to)
changed = find_changed(h_from, h_to)
+ print("new: %s" % new)
+ print("removed: %s" % removed)
+ print("changed: %s" % changed)
+
cache_d = prep_cacheroot(arch, release, options.cache_d)
# if modified packages, download all changelogs from changelogs.
- srcs = {}
- exceptions = []
if changed:
+ srcs = {}
+ exceptions = []
cache = get_cache(cache_d)
src2bins = map_source_to_binary(cache, changed)
@@ -530,11 +534,6 @@ def main():
exceptions.append(exp)
continue
- print("new: %s" % new)
- print("removed: %s" % removed)
- print("changed: %s" % changed)
-
- if changed:
# Print changelog ranges for changed packages
for src in sorted(src2bins):
binlist = sorted(src2bins[src])
@@ -544,10 +543,10 @@ def main():
print("==== %s" % ' '.join(binlist))
print_blocks(srcs[src]["changeblocks"])
- if exceptions:
- print("**** Errors ****")
- for error in exceptions:
- print(error)
+ if exceptions:
+ print("**** Errors ****")
+ for error in exceptions:
+ print(error)
if __name__ == "__main__":