From b403dedbfbf43a1abb43b55918cc4fd69a7425f3 Mon Sep 17 00:00:00 2001 From: Benjamin Drung Date: Sat, 30 Oct 2010 19:58:08 +0200 Subject: [PATCH] syncpackage: Don't add quotation marks to changelog entries (LP: #668805). --- debian/changelog | 6 ++++-- syncpackage | 11 +++++++---- 2 files changed, 11 insertions(+), 6 deletions(-) diff --git a/debian/changelog b/debian/changelog index 18e8cb5..de41ec0 100644 --- a/debian/changelog +++ b/debian/changelog @@ -30,9 +30,11 @@ ubuntu-dev-tools (0.105) UNRELEASED; urgency=low Debian chroot, working around #599695 [ Benjamin Drung ] - * syncpackage: Don't crash if environment variables aren't set (LP: #665202). + * syncpackage: + - Don't crash if environment variables aren't set (LP: #665202). + - Don't add quotation marks to changelog entries (LP: #668805). - -- Benjamin Drung Sat, 30 Oct 2010 19:12:08 +0200 + -- Benjamin Drung Sat, 30 Oct 2010 19:56:33 +0200 ubuntu-dev-tools (0.104) experimental; urgency=low diff --git a/syncpackage b/syncpackage index 465283f..bb1b470 100755 --- a/syncpackage +++ b/syncpackage @@ -109,11 +109,14 @@ class Version(debian.debian_support.Version): return self.full_version.find('ubuntu') > 0 +def quote_parameter(parameter): + if parameter.find(" ") >= 0: + return '"' + parameter + '"' + else: + return parameter + def print_command(script_name, cmd): - for i in xrange(len(cmd)): - if cmd[i].find(" ") >= 0: - cmd[i] = '"' + cmd[i] + '"' - print "%s: I: %s" % (script_name, " ".join(cmd)) + print "%s: I: %s" % (script_name, " ".join(map(quote_parameter, cmd))) def remove_signature(dscname, script_name=None, verbose=False): '''Removes the signature from a .dsc file if the .dsc file is signed.'''