Magellan Linux

Contents of /trunk/mage-buildserver/queue-run.sh

Parent Directory Parent Directory | Revision Log Revision Log


Revision 2862 - (show annotations) (download) (as text)
Wed Feb 11 12:39:18 2015 UTC (9 years, 3 months ago) by niro
File MIME type: application/x-sh
File size: 714 byte(s)
-added a initial queue progression functionality
1 #!/bin/bash
2
3 die() { echo "error: $@"; exit 1; }
4
5 BUILDSERVER_CONFIG_DIR="/etc/mage-buildserver"
6 source ${BUILDSERVER_CONFIG_DIR}/buildserver.conf
7
8 : ${SVN_HOME="/home/tjoke/svn/smage/trunk"}
9
10 [ -e ${QUEUEDIR} ] || die "queue '${QUEUEFILE}' does not exist"
11
12 for id in $(find ${QUEUEDIR} -mindepth 1 -printf '%f\n' | sort -V)
13 do
14 smage="$(< ${QUEUEDIR}/${id})"
15 case ${smage} in
16 '#') continue ;;
17 "") continue ;;
18 esac
19
20 FULLPATH_SMAGEFILE="${SVN_HOME}/${smage}"
21 if [[ -e ${FULLPATH_SMAGEFILE} ]]
22 then
23 ${BUILDSERVER_LIB_DIR}/runme.sh ${smage} || die "build failed"
24 # remove from queue
25 ${BUILDSERVER_LIB_DIR}/queue-del.sh -n "${id}"
26 else
27 die "smagefile '${FULLPATH_SMAGEFILE}' does not exist"
28 fi
29 done

Properties

Name Value
svn:executable *