diff options
author | Artur Signell <artur.signell@itmill.com> | 2012-01-27 08:28:24 +0000 |
---|---|---|
committer | Artur Signell <artur.signell@itmill.com> | 2012-01-27 08:28:24 +0000 |
commit | f08f86caf9bba1304ff42669e8b97ad8e81236e4 (patch) | |
tree | 0bfab048cc2d2b46de661f5cf45947a7fd80ae33 /scripts/merge.sh | |
parent | 94dddf055a57b344d326c7c1e04a982862ce4382 (diff) | |
download | vaadin-framework-f08f86caf9bba1304ff42669e8b97ad8e81236e4.tar.gz vaadin-framework-f08f86caf9bba1304ff42669e8b97ad8e81236e4.zip |
Scripts for easing merge from 6.7
svn changeset:22783/svn branch:6.8
Diffstat (limited to 'scripts/merge.sh')
-rwxr-xr-x | scripts/merge.sh | 39 |
1 files changed, 39 insertions, 0 deletions
diff --git a/scripts/merge.sh b/scripts/merge.sh new file mode 100755 index 0000000000..775bc6a839 --- /dev/null +++ b/scripts/merge.sh @@ -0,0 +1,39 @@ +#!/bin/bash +FROM=$1 +REVISION=$2 +AUTOCOMMIT=$3 + +if [ "$FROM" = "" ] || [ "$REVISION" = "" ] +then + echo "Usage: $0 <from version> <changeset> [autocommit]" + exit 2 +fi + +localchanges=`svn stat|wc -l` +if [ "$localchanges" != "0" ] +then + echo "You must have a clean working space copy" + exit 2 +fi + +svn up + +msg=`svn log http://dev.vaadin.com/svn/versions/$FROM -r $REVISION --xml|grep "<msg>"|sed "s/<msg>//"|sed "s/<\/msg>//"` +svn merge http://dev.vaadin.com/svn/versions/$FROM . -c $REVISION +msg="[merge from $FROM] $msg" +if [ "$AUTOCOMMIT" = "autocommit" ] +then + echo "Trying to commit..." + svn commit -m "$msg" + RET=$? + if [ "$RET" != "0" ] + then + exit 1 + fi + exit 0 +else + echo "Run the following command to commit..." + echo svn commit -m \"$msg\" + exit 1 +fi + |