From fcc94d9c0d9d797784d612664cea6c5d05ce4977 Mon Sep 17 00:00:00 2001 From: Marjan Schiller Date: Thu, 13 Jun 2013 15:13:18 +0200 Subject: [PATCH] Added script for setting the test state in the liveboot web interface. --- liveboot_set_test_state.sh | 31 +++++++++++++++++++++++++++++++ 1 file changed, 31 insertions(+) create mode 100755 liveboot_set_test_state.sh diff --git a/liveboot_set_test_state.sh b/liveboot_set_test_state.sh new file mode 100755 index 0000000..743e22c --- /dev/null +++ b/liveboot_set_test_state.sh @@ -0,0 +1,31 @@ +#!/bin/bash +# copyright 2012 Holger Levsen GPL2 licenced, holger@layer-acht.org + +set -e + +if [ -z "${BUILD_NUMBER}" ] +then + echo "\$BUILD_NUMBER is empty, not using Jenkins? Please export manually!" + exit 1 +fi + +if [ -z "${TEST_STATE}" ] +then + echo "\$TEST_STATE is empty, not using Jenkins? Please export manually!" + exit 1 +fi + +# Checkout liveboot repo +BUILD_SCRIPT=$(mktemp) +cat > $BUILD_SCRIPT <<-EOF +cd /srv/build +rm liveboot_test_state -rf +git clone git://git/ri/liveboot.git liveboot_test_state +cd liveboot_test_state +git checkout $GIT_BRANCH +./liveboot_test_reporter.py $BUILD_NUMBER $TEST_STATE +EOF + +bash -x $BUILD_SCRIPT + +figlet "OK" \ No newline at end of file -- 2.39.5