]> git.donarmstrong.com Git - neurodebian.git/blob - tools/nd_adddistall
Also for stats report which repo and which job number use our setup
[neurodebian.git] / tools / nd_adddistall
1 #!/bin/bash
2 # Little helper to bootstrap all ND chroots as specified in
3 # /etc/neurodebian/cmdsettings.sh unless a list provided in command line
4
5 . /etc/neurodebian/cmdsettings.sh
6
7 [ -z "$@" ] && dists="$alldists" || dists="$@"
8
9 echo "Initiating creation of chroots for $dists"
10
11 set -eu
12
13 CMD=
14 MSGS="SUMMARY:\n"
15 for dist in $dists; do
16         if [ -e "$cowbuilderroot/cow/$dist-amd64.cow" ]; then
17                 status=exists
18         else
19                 $CMD sudo nd_adddist ${dist%%-*} ${dist#*-} && status=ok || status=failed
20         fi
21         MSGS+=" $(printf '%-30s\\t%s' $dist $status)\n"
22 done
23 echo -en $MSGS
24