[arch-projects] [devtools] [PATCH] commitpkg: Fix commit message

Lukas Fleischer archlinux at cryptocrack.de
Thu Nov 3 04:09:46 EDT 2011


Move the message template before the if block. We moved this to the else
branch in commit aaa68e49e8e5a68950a63b9aa4a8c1f6aed2e2d2 which lead to
"msgtemplate" being unset if one specifies a commit message on the
command line, thus stripping the "upgpkg:" part.

Signed-off-by: Lukas Fleischer <archlinux at cryptocrack.de>
---
 commitpkg.in |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/commitpkg.in b/commitpkg.in
index d7f7513..b83b6ce 100644
--- a/commitpkg.in
+++ b/commitpkg.in
@@ -90,12 +90,12 @@ done
 shift $(( OPTIND - 1 ))
 
 if [ -n "$(svn status -q)" ]; then
+	msgtemplate="upgpkg: $pkgbase $(get_full_version)"$'\n\n'
 	if [ -n "$1" ]; then
 		stat_busy 'committing changes to trunk'
 		svn commit -q -m "${msgtemplate}${1}" || die
 		stat_done
 	else
-		msgtemplate="upgpkg: $pkgbase $(get_full_version)"$'\n\n'
 		msgfile="$(mktemp)"
 		echo "$msgtemplate" > "$msgfile"
 		if [ -n "$SVN_EDITOR" ]; then
-- 
1.7.7.2



More information about the arch-projects mailing list