From: Ian Jackson Subject: [OSSTEST PATCH 7/9] standalone-generate-dump-flight-runvars: New utility Date: Fri, 27 Jun 2014 17:58:20 +0100 Message-ID: <1403888302-30822-8-git-send-email-ian.jackson@eu.citrix.com> References: <1403888302-30822-1-git-send-email-ian.jackson@eu.citrix.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: Received: from mail6.bemta3.messagelabs.com ([195.245.230.39]) by lists.xen.org with esmtp (Exim 4.72) (envelope-from ) id 1X0ZTv-00009e-Rv for xen-devel@lists.xenproject.org; Fri, 27 Jun 2014 16:58:35 +0000 In-Reply-To: <1403888302-30822-1-git-send-email-ian.jackson@eu.citrix.com> List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xen.org Errors-To: xen-devel-bounces@lists.xen.org To: xen-devel@lists.xenproject.org Cc: Ian Jackson , Ian Campbell List-Id: xen-devel@lists.xenproject.org This is helpful for showing the effect of changes to make-flight, cr-daily-branch, et al. Signed-off-by: Ian Jackson --- standalone-generate-dump-flight-runvars | 70 +++++++++++++++++++++++++++++++ 1 file changed, 70 insertions(+) create mode 100755 standalone-generate-dump-flight-runvars diff --git a/standalone-generate-dump-flight-runvars b/standalone-generate-dump-flight-runvars new file mode 100755 index 0000000..90c6ea8 --- /dev/null +++ b/standalone-generate-dump-flight-runvars @@ -0,0 +1,70 @@ +#!/bin/bash +# +# Prints the results of each cr-daily-branch's make-flight +# +# Usage: +# ./standalone-generate-dump-flight-runvars [BRANCH....] +# +# If no BRANCHes specified, does all that are normally run by +# cr-daily-branch or out of crontab. + +# This is part of "osstest", an automated testing framework for Xen. +# Copyright (C) 2009-2014 Citrix Inc. +# +# This program is free software: you can redistribute it and/or modify +# it under the terms of the GNU Affero General Public License as published by +# the Free Software Foundation, either version 3 of the License, or +# (at your option) any later version. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU Affero General Public License for more details. +# +# You should have received a copy of the GNU Affero General Public License +# along with this program. If not, see . + +set -e + +set -o pipefail + +mkdir -p tmp + +procs="" + +if [ $# = 0 ]; then + set `./mg-list-all-branches` +fi + +perbranch () { + log=tmp/make-flight.$branch.log + flight=check_${branch//[-._]/_} +} + +for branch in $@; do + perbranch + DAILY_BRANCH_POSTMAKE_HOOK='exit 0' \ + ./standalone make-flight -f $flight $branch >$log 2>&1 & + procs+=" $branch=$!" +done + +perproc () { + branch=${proc%=*} + pid=${proc##*=} + perbranch +} + +for proc in $procs; do + perproc + if ! wait $pid; then + set +e + cat $log >&2 + echo >&2 "make-flight $branch failed" + exit 1 + fi +done + +for proc in $procs; do + perproc + ./mg-show-flight-runvars $flight | sed "s/^/`printf '%-20s' $branch`/" +done -- 1.7.10.4