source: MondoRescue/trunk/tools/mknewtag@ 1043

Last change on this file since 1043 was 1043, checked in by Bruno Cornec, 17 years ago

merge -r978:1042 $SVN_M/branches/stable

  • Property svn:executable set to *
File size: 884 bytes
RevLine 
[617]1#!/bin/bash
2#
3# Prepare a new delivery of the same version by changing TAG
4#
5# $Id$
6#
7# Syntax: mknewtag
8#
9
10dname=`dirname $0`
11prem=`echo $dname |cut -c1`
[1043]12if [ _${prem} = _"/" ]; then
[617]13 export TOOLHOME=$dname
14else
15 export TOOLHOME=${PWD}/$dname
16fi
17
18if [ "$1" = "" ]; then
[932]19 mods="mindi mondo mondo-doc mindi-busybox mindi-kernel"
[617]20else
[932]21 mods="$*"
[617]22fi
23
[932]24cd $TOOLHOME/..
25nb=`svn diff | wc -l`
[617]26if [ $nb -gt 0 ]; then
[649]27 echo "You'll have to check in before updating the TAG"
[782]28 exit -1
[617]29else
[932]30 for p in $mods; do
31 grep -q "${v}" $p/ChangeLog
[649]32 if [ $? -ne 0 ]; then
[782]33 echo "You'll have to document in ${p}'s ChangeLog for ${v} related modifications"
[649]34 exit -1
35 fi
36 done
[932]37 for p in $mods; do
38 TAG=`cat $p/TAG`
39 v=`cat $p/VERSION`
40 echo -n "Changing TAG of $p-$v value from $TAG to "
41 ((TAG=$TAG+1))
42 echo "$TAG"
43 echo "$TAG" > $p/TAG
44 done
45 svn ci -m "Automatic update of TAGs" ; svn up
[617]46fi
Note: See TracBrowser for help on using the repository browser.