diff options
Diffstat (limited to 'tools/snapshot')
-rwxr-xr-x | tools/snapshot | 69 |
1 files changed, 0 insertions, 69 deletions
diff --git a/tools/snapshot b/tools/snapshot deleted file mode 100755 index 9fa61cf..0000000 --- a/tools/snapshot +++ /dev/null | |||
@@ -1,69 +0,0 @@ | |||
1 | #! /bin/sh | ||
2 | |||
3 | # This scipt assumes that you have anonCVS for nagios and nagiosplug | ||
4 | # in ${IN} | ||
5 | |||
6 | # cvs -d:pserver:anonymous@cvs.nagiosplug.sourceforge.net:/cvsroot/nagiosplug login | ||
7 | # cvs -z3 -d:pserver:anonymous@cvs.nagiosplug.sourceforge.net:/cvsroot/nagiosplug co nagiosplug | ||
8 | # | ||
9 | # cvs -d:pserver:anonymous@cvs.nagios.sourceforge.net:/cvsroot/nagios login | ||
10 | # cvs -z3 -d:pserver:anonymous@cvs.nagios.sourceforge.net:/cvsroot/nagios co nagios | ||
11 | |||
12 | # Set directories | ||
13 | IN=${HOME}/sf | ||
14 | OUT=/col/htdocs/src/nagios | ||
15 | RPM_TOPDIR=${HOME}/redhat | ||
16 | |||
17 | # Update nagiosplug CVS | ||
18 | cd ${IN}/nagiosplug | ||
19 | rm configure configure.in Makefile.in | ||
20 | cvs update | ||
21 | DS=`date -u +%Y%m%d%H%M` | ||
22 | sed "s/^VER=.*/VER=${DS}/;s/^REL=.*/REL=snapshot/" configure.in > configure.tmp | ||
23 | mv configure.tmp configure.in | ||
24 | aclocal | ||
25 | autoheader | ||
26 | autoconf | ||
27 | automake | ||
28 | autoreconf | ||
29 | |||
30 | # Make the Nagiosplug dist tarball | ||
31 | rm -r build-dist | ||
32 | mkdir build-dist | ||
33 | cd build-dist | ||
34 | ../configure | ||
35 | make dist | ||
36 | cp -fv *.gz ${OUT} | ||
37 | |||
38 | # Make the Nagiosplug custom RPM | ||
39 | echo "%_topdir ${RPM_TOPDIR}" > ./.rpmrc | ||
40 | mkdir -p ${RPM_TOPDIR}/RPMS/i386 ${RPM_TOPDIR}/SRPMS ${RPM_TOPDIR}/SOURCES ${RPM_TOPDIR}/BUILD ${RPM_TOPDIR}/SPECS | ||
41 | rpm --rcfile "/usr/lib/rpm/rpmrc:${IN}/rpmrc" --define 'custom 1' -ta *.gz | ||
42 | cp -fv ~/redhat/RPMS/i386/nagios-plugins-custom-*.i386.rpm /col/htdocs/src/nagios | ||
43 | |||
44 | # Copy the new snapshot and delete the old ones | ||
45 | cd ${OUT} | ||
46 | GLOBIGNORE=nagios-plugins-${DS}-snapshot.tar.gz | ||
47 | rm -f nagios-plugins-*.tar.gz | ||
48 | GLOBIGNORE=nagios-plugins-custom-${DS}-snapshot.i386.rpm | ||
49 | rm -f nagios-plugins-custom-*-snapshot.i386.rpm | ||
50 | cd ~/redhat/SRPMS | ||
51 | rm nagios-plugins-custom-${DS}-snapshot.src.rpm | ||
52 | cd ~/redhat/RPMS/i386 | ||
53 | rm nagios-plugins-custom-${DS}-snapshot.i386.rpm | ||
54 | |||
55 | # Update Nagios CVS | ||
56 | cd ${IN}/sf/nagios | ||
57 | rm configure configure.in nagios.spec base/nagios.c common/common.h \ | ||
58 | html/main.html Makefile.in | ||
59 | cvs update | ||
60 | |||
61 | # Make the Nagios tarball | ||
62 | DS=`date -u +%Y%m%d%H%M` | ||
63 | ./make-tarball ${DS} | ||
64 | |||
65 | # Copy the new snapshot and delete the old ones | ||
66 | mv ../nagios-${DS}.tar.gz /col/htdocs/src/nagios/ | ||
67 | GLOBIGNORE=${OUT}/nagios-${DS}.tar.gz | ||
68 | rm ${OUT}/nagios-20*.tar.gz | ||
69 | |||