diff options
Diffstat (limited to 'third_party/rust/jsparagus/.metrics/create-ci-branch.sh')
-rwxr-xr-x | third_party/rust/jsparagus/.metrics/create-ci-branch.sh | 38 |
1 files changed, 38 insertions, 0 deletions
diff --git a/third_party/rust/jsparagus/.metrics/create-ci-branch.sh b/third_party/rust/jsparagus/.metrics/create-ci-branch.sh new file mode 100755 index 0000000000..2415ed7ce9 --- /dev/null +++ b/third_party/rust/jsparagus/.metrics/create-ci-branch.sh @@ -0,0 +1,38 @@ +#!/usr/bin/env bash + +set -ue # its like javascript, everything is allowed unless you prevent it. +shopt -s extglob + +# export the ci_branch we will be using in all shell scripts +export ci_branch=ci_results + +topdir=$(git rev-parse --show-toplevel) + +cd $topdir + +if [ `git branch --list $ci_branch` ] +then + echo "Branch exists" #We don't need to do anything +else + git checkout -b $ci_branch + + # clear out the repostory + git rm -r !(.metrics|.git|tmp) + git rm -r .github + + cp .metrics/generated_README.md README.md + mkdir .metrics/badges + mkdir .metrics/count + + git add . + git commit -m"Initial commit for results branch" + + # scripts needed to populated. Should be self contained with cleanup of extra files + cd .metrics && ./populate_not_implemented.sh + cd $topdir + cd .metrics && ./populate_fuzzbug.sh + + cd $topdir + git add . + git commit -m"Inital run of Populate scripts" +fi |