Path: blob/main/notebooks/publish_benchmarks.sh
597 views
# Push the latest benchmark run to git under the tag 'latest_benchmark'1# and a daily tag with the date2set -ex34THIS_DIR=$(dirname "$0")56BENCHMARK_DIR=$THIS_DIR/benchmarks789mkdir -p $BENCHMARK_DIR1011cp -r $THIS_DIR/output/benchmark/* $BENCHMARK_DIR/1213git add $BENCHMARK_DIR1415# if there are no changes, push to git16if [ -z "$(git status --porcelain)" ]; then17echo "No changes to commit"18else19git commit -m "latest benchmark"20fi2122# push the changes to git under tag 'latest_benchmark'23git tag -f latest_benchmark24git push -f origin latest_benchmark2526# create a daily tag with the date27tagname=benchmark-$(date +%Y-%m-%d)28git tag -f $tagname29git push -f origin $tagname303132