[Reproducible-commits] [notes] 02/05: bin/filter-packages: use with statement

Chris Lamb lamby at moszumanska.debian.org
Sat Feb 7 22:55:38 UTC 2015


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

lamby pushed a commit to branch master
in repository notes.

commit 6abf4e3132e4165eb1f2178fab048ac1e63ce941
Author: Chris Lamb <lamby at debian.org>
Date:   Sat Feb 7 22:50:49 2015 +0000

    bin/filter-packages: use with statement
---
 bin/filter-packages | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/bin/filter-packages b/bin/filter-packages
index b41a804..42d9ed2 100755
--- a/bin/filter-packages
+++ b/bin/filter-packages
@@ -25,7 +25,8 @@ def main():
     if options.issues is not None:
         options.issues = set(options.issues.split(','))
 
-    packages = yaml.safe_load(open('./packages.yml'))
+    with open('./packages.yml') as f:
+        packages = yaml.safe_load(f)
 
     for x, y in sorted(packages.iteritems()):
         if not options.issues <= set(y.get('issues', ())):

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



More information about the Reproducible-commits mailing list