aboutsummaryrefslogtreecommitdiffhomepage
path: root/gbp
diff options
context:
space:
mode:
authorGuido Günther <agx@sigxcpu.org>2018-11-24 19:22:14 +0100
committerGuido Günther <agx@sigxcpu.org>2018-11-24 19:46:00 +0100
commitad904b89f001bf3c6b4548916b5e27399b9d6a5d (patch)
tree04badeede8091e25a1a312c3c2fcbc7478bae52d /gbp
parentef84b92caea18143fca81346767982f6e8237e4f (diff)
PristienTar: Properly detect signature feature
Diffstat (limited to 'gbp')
-rw-r--r--gbp/pkg/pristinetar.py8
1 files changed, 4 insertions, 4 deletions
diff --git a/gbp/pkg/pristinetar.py b/gbp/pkg/pristinetar.py
index 76f1d3c8..3cadf482 100644
--- a/gbp/pkg/pristinetar.py
+++ b/gbp/pkg/pristinetar.py
@@ -32,7 +32,7 @@ class PristineTar(Command):
cwd=repo.path,
capture_stderr=True)
- def _has_in_output(self, feature):
+ def _has_in_output(self, match):
"""
Check if pristine_tar has a certain feature enabled.
@@ -42,7 +42,7 @@ class PristineTar(Command):
@rtype: C{bool}
"""
self.call(['--help'], quiet=True) # There's no --help so we always exit 1
- r = re.compile('.* pristine-tar .* %s' % feature)
+ r = re.compile(match)
for line in self.stderr.splitlines():
if r.match(line):
return True
@@ -50,11 +50,11 @@ class PristineTar(Command):
def has_feature_verify(self):
"""Does this pristine-tar support tarball verification"""
- return self._has_in_output("verify")
+ return self._has_in_output(".* pristine-tar .* verify")
def has_feature_sig(self):
"""Does this pristine-tar support detached upstream signatures"""
- return self._has_in_output(r'\[-s signaturefile\]')
+ return self._has_in_output(r'.*--signature-file')
def has_commit(self, archive_regexp):
"""