/[cvs]/eggdrop1.8/misc/newversion
ViewVC logotype

Contents of /eggdrop1.8/misc/newversion

Parent Directory Parent Directory | Revision Log Revision Log | View Revision Graph Revision Graph


Revision 1.1.1.1 - (show annotations) (download) (vendor branch)
Mon Jul 26 21:11:06 2010 UTC (8 years, 10 months ago) by simple
Branch: eggheads, MAIN
CVS Tags: v1, HEAD
Branch point for: gettext
Changes since 1.1: +0 -0 lines
Imported Eggdrop 1.6.20

1 #! /bin/sh
2 #
3 # newversion - prepares the tree for a new version number in CVS
4 #
5 # Copyright (C) 2004 - 2010 Eggheads Development Team
6 #
7 # This file is free software; you can redistribute it and/or modify it
8 # under the terms of the GNU General Public License as published by
9 # the Free Software Foundation; either version 2 of the License, or
10 # (at your option) any later version.
11 #
12 # This program is distributed in the hope that it will be useful, but
13 # WITHOUT ANY WARRANTY; without even the implied warranty of
14 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
15 # General Public License for more details.
16 #
17 # You should have received a copy of the GNU General Public License
18 # along with this program; if not, write to the Free Software
19 # Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
20 #
21 # As a special exception to the GNU General Public License, if you
22 # distribute this file as part of a program that contains a
23 # configuration script generated by Autoconf, you may include it under
24 # the same distribution terms that you use for the rest of that program.
25 #
26 # $Id: newversion,v 1.10 2010/01/03 13:27:23 pseudo Exp $
27
28 MOD_CONFIGURE_ACS="src/mod/compress.mod/configure.ac src/mod/dns.mod/configure.ac"
29 DOCS="doc/COMPILE-GUIDE doc/PATCH-HOWTO doc/tcl-commands.doc doc/TEXT-SUBSTITUTIONS \
30 doc/html/app-textsub.html doc/html/compiling.html doc/html/tcl-commands.html \
31 doc/html/patch-howto.html"
32
33 fix_main_c() {
34 sed -e 's:egg_numver = .*$:egg_numver = '${NEW_NUMVERSION}';:' \
35 -e 's:egg_version\[1024\] = ".*":egg_version[1024] = "'${NEW_EGGVERSION}'":' src/main.c > src/main.c_
36 mv src/main.c_ src/main.c
37 }
38
39 if test ! -f src/main.c; then
40 echo "You are not in the Eggdrop root directory."
41 exit 1
42 fi
43
44 umask 022
45
46 OLD_EGGVERSION=$(grep AC_INIT configure.ac | sed -e 's/AC_INIT(\[Eggdrop\],\[//g' -e 's/\],\[bugs@eggheads.org\])//g')
47 NEW_EGGVERSION=$(echo $OLD_EGGVERSION | cut -d. -f1-2).$(($(echo $OLD_EGGVERSION | cut -d. -f3) + 1))
48 NEW_NUMVERSION=$(($(grep 'egg_numver =' src/main.c | sed -e 's/.*= //' -e 's/;$//') + 100))
49
50 # Change the patch to 'none'.
51 echo -n "Adding patch 'none'..."
52 misc/addpatch none >/dev/null
53 echo " done."
54
55 # Fix main.c.
56 echo -n "Updating src/main.c..."
57 fix_main_c
58 echo " done."
59
60 # Fix configure.ac's.
61 echo -n "Fixing configure.ac files..."
62 for i in $MOD_CONFIGURE_ACS configure.ac; do
63 sed 's:'${OLD_EGGVERSION}':'${NEW_EGGVERSION}':g' $i > ${i}_
64 mv ${i}_ $i
65 done
66 echo " done."
67
68 echo -n "Fixing docs..."
69 for i in $DOCS; do
70 sed 's:'${OLD_EGGVERSION}':'${NEW_EGGVERSION}':g' $i > ${i}_
71 mv ${i}_ $i
72 done
73 echo " done."
74
75 echo Current patch: `misc/addpatch -s`
76 echo ""
77 echo "Complete."
78 echo ""
79 echo "Now, cvs commit, and then run the following, and commit again:"
80 echo " autoconf"
81 CURRENT_PWD=$PWD
82 for i in $MOD_CONFIGURE_ACS; do
83 echo " cd ${CURRENT_PWD}/`dirname $i` && autoconf"
84 done
85 echo " cd $PWD"
86 echo ""
87 echo "Don't forget to add $NEW_EGGVERSION to the current doc/Changes file."
88 echo ""

webmaster@eggheads.org
ViewVC Help
Powered by ViewVC 1.1.23