narval/piuparts: replace @DIST@ with the actual dist in apt repository uris

authorJulien Cristau <julien.cristau@logilab.fr>
changeset9ef256811ba1
branchstable
phasedraft
hiddenno
parent revision#26d2b1b856b4 narval: add piuparts checker
child revision<not specified>
files modified by this revision
narval/apycot.py
# HG changeset patch
# User Julien Cristau <julien.cristau@logilab.fr>
# Date 1387385651 -3600
# Wed Dec 18 17:54:11 2013 +0100
# Branch stable
# Node ID 9ef256811ba18caaa03622dd339b4d153b03ec1a
# Parent 26d2b1b856b442f0c82cd72572ec2600010a39d7
narval/piuparts: replace @DIST@ with the actual dist in apt repository uris

diff --git a/narval/apycot.py b/narval/apycot.py
@@ -213,11 +213,11 @@
1 
2      def get_output(self, path, dist, arch):
3          basetgz = osp.join(self.basetgz, '%s-%s.tgz' % (dist, arch))
4          command = ['sudo', 'piuparts', '-b', basetgz, '-d', dist]
5          for extra_repo in self.options.get('extra-repos'):
6 -            command += ['--extra-repo', extra_repo]
7 +            command += ['--extra-repo', extra_repo.replace('@DIST@', dist)]
8          command.append(path)
9          cmd = subprocess.Popen(command, stdout=subprocess.PIPE,
10                  stdin=open('/dev/null'), stderr=subprocess.STDOUT)
11          output = []
12          for line in cmd.stdout: