[Fusionforge-commits] FusionForge branch 6.0 updated. 2914f3e Cope with commit messages containing special characters

Roland Mas lolando at libremir.placard.fr.eu.org
Tue Jun 2 11:37:24 CEST 2015


This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "FusionForge".

The branch, 6.0 has been updated
       via  2914f3eaf3c347bcf43b10bc2d6eebb341aa3a6d (commit)
      from  c330909cdf48a4dae7fe084c0afd55e0ad34cb95 (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
commit 2914f3eaf3c347bcf43b10bc2d6eebb341aa3a6d
Author: Roland Mas <lolando at debian.org>
Date:   Tue Jun 2 11:37:10 2015 +0200

    Cope with commit messages containing special characters

diff --git a/src/plugins/scmhook/library/scmgit/hooks/postreceiveemail/post-receive-email b/src/plugins/scmhook/library/scmgit/hooks/postreceiveemail/post-receive-email
index a6e09fe..8cc5686 100755
--- a/src/plugins/scmhook/library/scmgit/hooks/postreceiveemail/post-receive-email
+++ b/src/plugins/scmhook/library/scmgit/hooks/postreceiveemail/post-receive-email
@@ -251,11 +251,6 @@ generate_email()
 	# Email parameters
 	# The email subject will contain the best description of the ref
 	# that we can build from the parameters
-	describe=$(git show --no-patch --format="%h %s" $rev 2>/dev/null)
-	if [ -z "$describe" ]; then
-		describe=$rev
-	fi
-
 	generate_email_header
 
 	# Call the correct body generation function
@@ -296,7 +291,7 @@ generate_email_header()
 	X-Git-Reftype: $refname_type
 	X-Git-Oldrev: $oldrev
 	X-Git-Newrev: $newrev
-	$(perl -Mutf8 -MEncode -e "print encode('MIME-Q', 'Subject: ${emailprefix}$shortdesc $refname_type $short_refname ${change_type}d. $describe');")
+	$(perl -Mutf8 -MEncode -e "print encode('MIME-Q', 'Subject: ${emailprefix}$shortdesc $refname_type $short_refname ${change_type}d. '.qx/git show --no-patch --format='%h %s' $newrev/);")
 	Auto-Submitted: auto-generated
 
 	This is an automated email from the git hooks/post-receive script. It was

-----------------------------------------------------------------------

Summary of changes:
 .../library/scmgit/hooks/postreceiveemail/post-receive-email       | 7 +------
 1 file changed, 1 insertion(+), 6 deletions(-)

diff --git a/src/plugins/scmhook/library/scmgit/hooks/postreceiveemail/post-receive-email b/src/plugins/scmhook/library/scmgit/hooks/postreceiveemail/post-receive-email
index a6e09fe..8cc5686 100755
--- a/src/plugins/scmhook/library/scmgit/hooks/postreceiveemail/post-receive-email
+++ b/src/plugins/scmhook/library/scmgit/hooks/postreceiveemail/post-receive-email
@@ -251,11 +251,6 @@ generate_email()
 	# Email parameters
 	# The email subject will contain the best description of the ref
 	# that we can build from the parameters
-	describe=$(git show --no-patch --format="%h %s" $rev 2>/dev/null)
-	if [ -z "$describe" ]; then
-		describe=$rev
-	fi
-
 	generate_email_header
 
 	# Call the correct body generation function
@@ -296,7 +291,7 @@ generate_email_header()
 	X-Git-Reftype: $refname_type
 	X-Git-Oldrev: $oldrev
 	X-Git-Newrev: $newrev
-	$(perl -Mutf8 -MEncode -e "print encode('MIME-Q', 'Subject: ${emailprefix}$shortdesc $refname_type $short_refname ${change_type}d. $describe');")
+	$(perl -Mutf8 -MEncode -e "print encode('MIME-Q', 'Subject: ${emailprefix}$shortdesc $refname_type $short_refname ${change_type}d. '.qx/git show --no-patch --format='%h %s' $newrev/);")
 	Auto-Submitted: auto-generated
 
 	This is an automated email from the git hooks/post-receive script. It was


hooks/post-receive
-- 
FusionForge



More information about the Fusionforge-commits mailing list