summaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
-rwxr-xr-xgit-dch6
1 files changed, 5 insertions, 1 deletions
diff --git a/git-dch b/git-dch
index 147c9b36..74c41540 100755
--- a/git-dch
+++ b/git-dch
@@ -40,9 +40,13 @@ def system(cmd):
raise GbpError
+def escape_commit(msg):
+ return msg.replace('"','\\\"').replace("$","\$")
+
+
def add_changelog_entry(msg, author, email):
"add aa single changelog entry"
- cmd = """DEBFULLNAME="%s" DEBEMAIL="%s" dch --no-auto-nmu --append -- "%s" """ % (author, email, msg.replace('"','\\\"'))
+ cmd = """DEBFULLNAME="%s" DEBEMAIL="%s" dch --no-auto-nmu --append -- "%s" """ % (author, email, escape_commit(msg))
system(cmd)