[projects/geninitrd] update release procedure to git

draenog draenog at pld-linux.org
Sat Nov 2 23:58:31 CET 2013


commit 52c68694200b3c3de5e5c622e6ee8c09b94e8e03
Author: Kacper Kornet <draenog at pld-linux.org>
Date:   Sat Nov 2 23:57:51 2013 +0100

    update release procedure to git

 RELEASE      |  2 --
 changelog.sh | 37 ++-----------------------------------
 make-tag.sh  |  7 ++++---
 3 files changed, 6 insertions(+), 40 deletions(-)
---
diff --git a/RELEASE b/RELEASE
index 4c49efa..94fb0e8 100644
--- a/RELEASE
+++ b/RELEASE
@@ -1,9 +1,7 @@
 HOW TO MAKE A RELEASE
 
-- svn up
 - ./changelog.sh
 - update Makefile with new desired version
-- svn ci ChangeLog Makefile
 - make dist
 - ./make-tag.sh
 - upload tarball to distfiles, update geninitrd.spec:HEAD
diff --git a/changelog.sh b/changelog.sh
index 0aa6951..54baf7d 100755
--- a/changelog.sh
+++ b/changelog.sh
@@ -1,41 +1,8 @@
 #!/bin/sh
-# $Id$
 # Run this to generate ChangeLog.
 
-[ -z "$svn2log" -a -x ~/bin/svn2log.py ] && svn2log=~/bin/svn2log.py
-[ -z "$svn2log" -a -x /usr/bin/svn2log ] && svn2log=/usr/bin/svn2log
-if [ -z "$svn2log" ]; then
-	echo >&2 'Need svn2log program!'
-	exit 1
-fi
-
-# create users for svn2log format
-tmp=$(mktemp -q svn2logXXXXXX 2>/dev/null || echo ${TMPDIR:-/tmp}/svn2log.tmp)
-> $tmp
-
-[ -z "$users" -a -f ../CVSROOT/users ] && users=../CVSROOT/users
-[ -z "$users" -a -f ~/rpm/CVSROOT/users ] && users=~/rpm/CVSROOT/users
-[ -z "$users" -a -f ~/.CVS-PLD/CVSROOT/users ] && users=~/.CVS-PLD/CVSROOT/users
-if [ -z "$users" ]; then
-	echo >&2 "Can't find users file!"
-	echo >&2 'Run in parent dir to fetch one:'
-	echo >&2 '$ cvs -d :pserver:cvs at cvs.pld-linux.org:/cvsroot co CVSROOT/users'
-	exit 1
-fi
-# bring users file up to date
-cd $(dirname "$users")
-cvs up $(basename "$users")
-cd -
-
-awk -F":" ' { login=$1; if ($3 != "") { name=$3 } else { name=$1 }; email=$2; printf "%s\t%s <%s at pld-linux.org>\n", login, name, login } ' $users > $tmp
-
-if grep -q vim:encoding=utf-8 $users; then
-	charset=UTF-8
-else
-	charset=ISO8859-2
-fi
-LC_ALL=C svn log -v --xml | LC_ALL=C $svn2log --users-charset=$charset --domain "pld-linux.org" -p /geninitrd/trunk -u $tmp --exclude ChangeLog -o ChangeLog
-rm -f $tmp
+[ -e .git/shallow ] && git fetch --unshallow
+git log --format='%+ai [%h] %aN <%ae>%n%n%x09* %s' --stat | sed '1d' > ChangeLog
 
 # obfuscate emails <user at domain> and (user at domain)
 sed -i -e 's,\([<(].*\)@\(.*[)>]\),\1/at/\2,g' ChangeLog
diff --git a/make-tag.sh b/make-tag.sh
index 9482c87..a1cd511 100755
--- a/make-tag.sh
+++ b/make-tag.sh
@@ -1,6 +1,6 @@
 #!/bin/sh
-url=$(svn info | awk '/^URL:/{gsub("/trunk$", "", $2); print $2}')
-rev=$(svn info | awk '/^Revision:/{print $2}')
+set -e
+rev=$(git rev-parse HEAD)
 
 version=$(awk '/^VERSION.*=/{print $3}' Makefile)
 tag="$version"
@@ -10,4 +10,5 @@ echo ""
 echo "Press ENTER to continue..."
 read a
 
-svn cp $url/trunk $url/tags/$tag
+git tag -a "$tag" $rev
+git push --dry-run origin "refs/tags/$tag"
================================================================

---- gitweb:

http://git.pld-linux.org/gitweb.cgi/projects/geninitrd.git/commitdiff/52c68694200b3c3de5e5c622e6ee8c09b94e8e03



More information about the pld-cvs-commit mailing list