]> git.pond.sub.org Git - empserver/commitdiff
Switch nightlybuilds to git
authorRon Koenderink <rkoenderink@yahoo.ca>
Tue, 5 Feb 2008 02:26:46 +0000 (20:26 -0600)
committerRon Koenderink <rkoenderink@yahoo.ca>
Tue, 5 Feb 2008 02:26:46 +0000 (20:26 -0600)
Create a local git repository on the SuSE nightly build machine.
Update local git repository from the Markus's public repository
at the beginnning of the nightlybuilds for SuSE and WIN32.
For the SuSE and WIN32 nightlybuilds drawn from the local
git repository on SuSE machine.

src/scripts/nightly/conf/suse.i386.config
src/scripts/nightly/conf/win32.i386.config
src/scripts/nightly/cron/cron.suse.i386
src/scripts/nightly/nightlybuild.sh

index b37c25461edcc08637a348e086a3c2b388cbd622..67bad668a39196005652e8278f9bb642c0948d33 100644 (file)
@@ -4,5 +4,5 @@ LOGDIR=logs
 INSTANCE=suse.i386
 EMPPORT=8889
 NIGHTLY_SKIP_STEP=
-export CVS_RSH=ssh
-export CVSROOT=:ext:koenderink@empserver.cvs.sourceforge.net/cvsroot/empserver
+GITROOT=/home/empire/empserver.git
+export LANG=C
index 3c2bf2a74feb847bcb55ba8f2496c6adc1793a15..920360a31dde9b2ba2b68d9488f802fe0ee6e83f 100644 (file)
@@ -4,6 +4,6 @@ LOGDIR=logs
 INSTANCE=win32.i386
 EMPPORT=8889
 NIGHTLY_SKIP_STEP=
-export CVS_RSH=ssh
-export CVSROOT=:ext:koenderink@empserver.cvs.sourceforge.net:/cvsroot/empserver
+GITROOT=ssh://ron-VM2/~empire/empserver.git
+PATH=$PATH:/c/Progra~1/git/bin
 
index 549007f9f56b74978426de473987e9a814a2cc3e..7d8a793f036873c03165152557fe254c619398df 100644 (file)
@@ -1,4 +1,6 @@
 #!/bin/sh
+cd /home/empire/empserver.git
+git pull 2>&1 >/dev/null
 cd /home/empire
 ./nightlybuild.sh suse.i386.config
 ./report.sh suse.i386.config | mutt -s 'empserver suse.i386' empserver-devel@lists.sourceforge.net
index cbbc2abaedfa17802c57099dfe0c5ff6c57fa0fc..67c6bf69ee9a8a08d1bcf8fd4e476df37c42bbcb 100755 (executable)
@@ -91,23 +91,39 @@ in
        *)
 
 # Make sandbox
-mkdir "${WORKDIR}" || warn "Could not create ${BOXDIR}/${WORKDIR}"
+if [ -d "${WORKDIR}" ]
+then
+       ! [ -d "${WORKDIR}"/empserver/.git ]  || err "Invalid sandbox, missing .git directory"
+else
+       echo making directory
+       mkdir "${WORKDIR}" || warn "Could not create ${BOXDIR}/${WORKDIR}"
+fi
 cd "${WORKDIR}" || err "Could not cd to ${BOXDIR}/${WORKDIR}"
 
-echo "Getting source from CVS:"
+echo "Getting source from GIT:"
 # Extract source
-export CVS_RSH=${CVS_RSH:=ssh}
-export CVSROOT=${CVSROOT:=:pserver:anonymous@empserver.cvs.sourceforge.net:/cvsroot/empserver}
+export GITROOT=${GITROOT:= git://git.pond.sub.org/~armbru/empserver}
 RETR=0
-while ! cvs -z3 co empserver >/dev/null
-do
-       sleep "`expr 5 + ${RETR}`"
-       RETR="`expr 1 + ${RETR}`"
-       [ "${RETR}" -gt 5 ] && err "CVS Timeout after ${RETR} retres."
+if ! [ -d empserver ]
+then
+       while ! git clone $GITROOT empserver >/dev/null
+       do
+               sleep "`expr 5 + ${RETR}`"
+               RETR="`expr 1 + ${RETR}`"
+               [ "${RETR}" -gt 5 ] && err "git-clone Timeout after ${RETR} retres."
+       done
+else
+       while ! git pull $GITROOT master >/dev/null
+       do
+               sleep "`expr 5 + ${RETR}`"
+               RETR="`expr 1 + ${RETR}`"
+               [ "${RETR}" -gt 5 ] && err "GIT pull Timeout after ${RETR} retres."
 done
-echo "Done (CVS)."
-echo ""
 
+fi
+
+echo "Done (GIT)."
+echo ""
                ;;
 esac
 #
@@ -156,7 +172,7 @@ fi
 
 cd empserver || err "Could not cd to ${BOXDIR}/${WORKDIR}/empserver."
 
-cvs up -d
+git-pull
 sh ./bootstrap
 ./configure --prefix ${BOXDIR}/${WORKDIR}/emp4
 
@@ -523,11 +539,18 @@ in
 
 echo "Cleaning sandbox"
 cd "${BOXDIR}" || err "Could not cd back to sandbox root !"
+case "${NIGHTLY_SKIP_STEP}"
+in
+       *REMOVE_REPOSITORY*)
+rm -rf `find "${WORKDIR}" -maxdepth 1 ! -name .git` || warn "Directory ${WORKDIR} could not be forcibly removed !"
+               ;;
+       *)
 rm -r "${WORKDIR}" || warn "Directory ${WORKDIR} could not be cleanly removed !"
 rm -rf "${WORKDIR}" || warn "Directory ${WORKDIR} could not be forcibly removed !"
 [ -d "${WORKDIR}/." ] && warn "Directory ${WORKDIR} still present"
 echo "Done (cleaning)."
-
+               ;;
+esac
                ;;
 esac
 #