You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@wicket.apache.org by da...@apache.org on 2013/12/08 16:29:07 UTC

[2/2] git commit: Using MacGPG2 instead of homebrew gpg stuff...

Using MacGPG2 instead of homebrew gpg stuff...


Project: http://git-wip-us.apache.org/repos/asf/wicket/repo
Commit: http://git-wip-us.apache.org/repos/asf/wicket/commit/2658f512
Tree: http://git-wip-us.apache.org/repos/asf/wicket/tree/2658f512
Diff: http://git-wip-us.apache.org/repos/asf/wicket/diff/2658f512

Branch: refs/heads/wicket-6.x
Commit: 2658f512ea37a7100a6d197652e80f6fa95b251f
Parents: d9dfb19
Author: Martijn Dashorst <ma...@gmail.com>
Authored: Sun Dec 8 16:11:50 2013 +0100
Committer: Martijn Dashorst <ma...@gmail.com>
Committed: Sun Dec 8 16:11:50 2013 +0100

----------------------------------------------------------------------
 release-dashorst.sh | 64 ++++++++++++++++++++++++------------------------
 1 file changed, 32 insertions(+), 32 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/wicket/blob/2658f512/release-dashorst.sh
----------------------------------------------------------------------
diff --git a/release-dashorst.sh b/release-dashorst.sh
index 5592515..fe173b8 100755
--- a/release-dashorst.sh
+++ b/release-dashorst.sh
@@ -26,6 +26,37 @@ function fail {
 }
 
 function setup_gpg {
+
+	if [ "$agentcount" -ne 1 ]; then
+		echo "Found gpg-agent running, killing all agents"
+		killall gpg-agent
+	fi
+
+	echo ""
+	echo "You are asked twice for your passphrase, one for scripting purposes, and one "
+	echo "for gpg-agent using pinentry such that gpg and git are able to sign things."
+	echo ""
+	echo "Enter your GPG passphrase (input will be hidden) \c"
+	stty_orig=`stty -g` 
+	stty -echo 
+	read passphrase
+	stty $stty_orig
+
+	# test the GPGP passphrase to fail-fast:
+	echo "$passphrase" | gpg --passphrase-fd 0 --armor --output pom.xml.asc --detach-sig pom.xml
+	gpg --verify pom.xml.asc
+	if [ $? -ne 0 ]; then
+	        echo "It appears that you fat-fingered your GPG passphrase"
+			rm pom.xml.asc
+	        exit $?
+	fi
+	rm pom.xml.asc
+
+	echo "Starting new gpg-agent"
+	eval $(gpg-agent --daemon --pinentry-program $(which pinentry))
+	if [ $? -ne 0 ] ; then
+		fail "ERROR: Unable to start gpg-agent"
+	fi
 	gpg --armor --detach-sign --use-agent --sign pom.xml >& $log
 	if [ $? -ne 0 ] ; then
 		fail "ERROR: Unable to run gpg properly"
@@ -83,38 +114,7 @@ read
 branch="build/wicket-$version"
 tag="wicket-$version"
 
-if [ "$agentcount" -ne 1 ]; then
-	echo "Found gpg-agent running, killing all agents"
-	killall gpg-agent
-fi
-
-echo ""
-echo "You are asked twice for your passphrase, one for scripting purposes, and one "
-echo "for gpg-agent using pinentry such that gpg and git are able to sign things."
-echo ""
-echo "Enter your GPG passphrase (input will be hidden) \c"
-stty_orig=`stty -g` 
-stty -echo 
-read passphrase
-stty $stty_orig
-
-# test the GPGP passphrase to fail-fast:
-echo "$passphrase" | gpg --passphrase-fd 0 --armor --output pom.xml.asc --detach-sig pom.xml
-gpg --verify pom.xml.asc
-if [ $? -ne 0 ]; then
-        echo "It appears that you fat-fingered your GPG passphrase"
-		rm pom.xml.asc
-        exit $?
-fi
-rm pom.xml.asc
-
-echo "Starting new gpg-agent"
-eval $(gpg-agent --daemon --pinentry-program $(which pinentry))
-if [ $? -ne 0 ] ; then
-	fail "ERROR: Unable to start gpg-agent"
-fi
-
-setup_gpg
+# setup_gpg
 
 echo "Ensuring we are starting from wicket-6.x"
 # otherwise we can't remove a previous release branch that failed