X-Git-Url: http://git.ozlabs.org/?a=blobdiff_plain;f=make_tree_file;h=5a468e0a4d2c69c9832d18e4423443d8d726861e;hb=543f60ec729701d7db73ce2d4ebd7b6f68722182;hp=c14a6dad62709eb6cd1f754e879ccf72c0d53a06;hpb=72d7f5ce5648d1259b26d463aa2a59ec588e1197;p=next-scripts diff --git a/make_tree_file b/make_tree_file index c14a6da..5a468e0 100755 --- a/make_tree_file +++ b/make_tree_file @@ -1,5 +1,7 @@ #!/bin/bash +. "$(dirname $0)/common.sh" + # Don't do releases in the wee hours :-) h=$(date '+%H') (( "$h" < 10 && "$h" > 4 )) && { @@ -22,6 +24,7 @@ echo 'Trees included into this release: Name Type URL ---- ---- ---' > Next/Trees +( IFS=' ' while read email type name url ref build; do [[ "$email" =~ '^#.*$' ]] && continue @@ -29,8 +32,9 @@ while read email type name url ref build; do [ $(echo "$name" | wc -c) -le 8 ] && tab="\t\t" [ "${ref%:*}" = "${ref}" ] || ref=${ref##*:} [ "$type" = "git" ] && url="$url#$ref" - printf "%s$tab%s\t%s\n" $name $type $url -done <../real_control >>Next/Trees + printf "%s$tab%s\t%s\n" $name $type $url >>Next/Trees +done <$CTRL_FILE +) mv ../SHA1s Next/SHA1s @@ -51,7 +55,7 @@ git diff-tree -p "$l.." >"../$p" gpg2 -u 41D5C07A -a -b "../$p" #echo "$l" > "../LATEST-IS-$n" -$(dirname $0)/make_abat_scripts "$d" "$l" +"$bin_dir/make_abat_scripts" "$d" "$l" oldest=$(date --date "3 months ago" '+%Y%m%d') echo "Removing old releases ... <= next-$oldest"