summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBenjamin Drung <bdrung@debian.org>2014-03-10 23:27:54 +0100
committerBenjamin Drung <bdrung@debian.org>2014-03-10 23:27:54 +0100
commitbf2f52698d2fae3a1cb642d5ba300860e1487449 (patch)
tree718d88806120df3346ed69ae9ef19f8dc40b5c13
parentc74d4c37e53f79da2be5d230efd4b3f22bbdd615 (diff)
xpi-repack: Replace built-in functions by list comprehensions.
-rwxr-xr-xxpi-repack4
1 files changed, 2 insertions, 2 deletions
diff --git a/xpi-repack b/xpi-repack
index e7408c7..2f7fea5 100755
--- a/xpi-repack
+++ b/xpi-repack
@@ -71,8 +71,8 @@ def get_source_package_name(script_name):
"source package or provide a source package name.\n")
sys.exit(1)
lines = open("debian/control").readlines()
- package_lines = filter(lambda x: x.find("Source:") >= 0, lines)
- packages = map(lambda x: x[x.find(":")+1:].strip(), package_lines)
+ package_lines = [x for x in lines if x.find("Source:") >= 0]
+ packages = [x[x.find(":")+1:].strip() for x in package_lines]
return packages[0]