From 477140f53cf387f09b1336630ed45bebad2b5ff8 Mon Sep 17 00:00:00 2001 From: Sven Gothel Date: Thu, 3 Mar 2011 03:58:43 +0100 Subject: add git script to tag, changelog and tar for release --- git/funcs_git.sh | 19 +++++++++++++++++++ git/git-changelog.sh | 16 ---------------- git/git-tag-tar-changelog.sh | 31 +++++++++++++++++++++++++++++++ 3 files changed, 50 insertions(+), 16 deletions(-) create mode 100755 git/funcs_git.sh delete mode 100755 git/git-changelog.sh create mode 100755 git/git-tag-tar-changelog.sh (limited to 'git') diff --git a/git/funcs_git.sh b/git/funcs_git.sh new file mode 100755 index 0000000..86b8f2c --- /dev/null +++ b/git/funcs_git.sh @@ -0,0 +1,19 @@ +#!/bin/bash + +function git-new-milestone() { + local module="$1" + local last="$2" + local new="$3" + + if [ -z "$module" -o -z "$last" -o -z "$new" ] ; then + echo "Usage: $0 module last-ref new-ref" + exit 1 + fi + + echo "Module $module - Tag $new" + git archive --format=tar --prefix=$module-$new/ $new | xz -z -9 > ../archive/$module-$new.tar.xz + git archive --format=zip --prefix=$module-$new/ $new -o ../archive/$module-$new.zip + git log --no-merges $new ^$last > ../archive/$module-ChangeLog-$new + git shortlog --no-merges $new ^$last > ../archive/$module-ShortLog-$new + git diff --stat --summary -M $last $new > ../archive/$module-diffstat-$new +} diff --git a/git/git-changelog.sh b/git/git-changelog.sh deleted file mode 100755 index 33719ec..0000000 --- a/git/git-changelog.sh +++ /dev/null @@ -1,16 +0,0 @@ -#!/bin/bash - -module="$1" -last="$2" -new="$3" - -if [ -z "$module" -o -z "$last" -o -z "$new" ] ; then - echo "Usage: $0 module last-ref new-ref" - exit 1 -fi - -echo "Module $module - Tag $new" -#echo "git archive --prefix=$module-$new/ $new | lzma -9 > ../$module-$new.tar.lzma" -git log --no-merges $new ^$last > ../$module-ChangeLog-$new -git shortlog --no-merges $new ^$last > ../$module-ShortLog -git diff --stat --summary -M $last $new > ../$module-diffstat-$new diff --git a/git/git-tag-tar-changelog.sh b/git/git-tag-tar-changelog.sh new file mode 100755 index 0000000..81a570d --- /dev/null +++ b/git/git-tag-tar-changelog.sh @@ -0,0 +1,31 @@ +#! /bin/bash + +artifacts=$1 +shift + +if [ -z "$artifacts" ] ; then + echo Usage $0 artifacts file + exit 1 +fi + +branch=rc +tag_old=v2.0-rc1 +tag=v2.0-rc2 + +sdir=`dirname $0` +thisdir=`pwd` + +. $sdir/funcs_git.sh + +for i in gluegen joal joal-demos jogl jogl-demos jocl jocl-demos ; do + sha=`grep $i.build.commit $artifacts | awk --field-separator "=" ' { print $2 } ' ` + echo $i sha $sha + cd $i + git checkout $branch + git pull jogamp $branch + git tag -u 0x8ED60127 -m "Signed Candidate $i $tag $sha" $tag $sha + git-new-milestone $i $tag_old $tag + cd $thisdir + echo done $i + echo +done -- cgit v1.2.3