[Reproducible-commits] [misc] 04/07: Prefer interpolation of concatenation.

Chris Lamb lamby at moszumanska.debian.org
Thu Jul 9 09:43:10 UTC 2015


This is an automated email from the git hooks/post-receive script.

lamby pushed a commit to branch master
in repository misc.

commit 3156dbfffa11d8429cb68264d748396bd65cc750
Author: Chris Lamb <lamby at debian.org>
Date:   Thu Jul 9 10:39:09 2015 +0100

    Prefer interpolation of concatenation.
---
 clean-notes | 20 ++++++++++----------
 1 file changed, 10 insertions(+), 10 deletions(-)

diff --git a/clean-notes b/clean-notes
index 81c909c..ca6392b 100755
--- a/clean-notes
+++ b/clean-notes
@@ -389,28 +389,28 @@ def write_out(notes):
             continue
 
         if pkg[0:2] == '0x':  # otherwise something converts 0xffff to 65535
-            out += ("!!str " + str(pkg) + ":\n")
+            out += "!!str %s:\n" % pkg
         else:
-            out += (str(pkg) + ":\n")
+            out += "%s:\n" % pkg
         try:
             if str(values['version']) == '3.6e-1':
-                out += ("  version: !!str " + str(values['version']) + "\n")
+                out += "  version: !!str %s\n" % values['version']
             else:
-                out += ("  version: " + str(values['version']) + "\n")
+                out += "  version: %s\n" % values['version']
         except KeyError:
             pass
         if 'comments' in values:
-            out += ("  comments: |\n")
+            out += "  comments: |\n"
             for line in values['comments'].strip().split('\n'):
-                out += ("    " + line + "\n")
+                out += "    %s\n" % line
         if 'issues' in values and values['issues']:
-            out += ("  issues:\n")
+            out += "  issues:\n"
             for issue in values['issues']:
-                out += ("    - " + issue + "\n")
+                out += "    - %s\n" % issue
         if 'bugs' in values:
-            out += ("  bugs:\n")
+            out += "  bugs:\n"
             for bug in values['bugs']:
-                out += ("    - " + str(bug) + "\n")
+                out += "    - %s\n" % bug
     with open(notes_yaml, 'wb') as fd:
         fd.write(out.encode('utf-8'))
 

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/reproducible/misc.git



More information about the Reproducible-commits mailing list