Skip to content

Instantly share code, notes, and snippets.

@cartazio
Created January 18, 2014 01:52
Show Gist options
  • Save cartazio/8485095 to your computer and use it in GitHub Desktop.
Save cartazio/8485095 to your computer and use it in GitHub Desktop.
wee benchmarking harnesss. Assumes youre using git, and criterion. also assume you're using multicriterion benchmarking templates https://bitbucket.org/carter/multicriterion-templates
#! /bin/bash
thedate=$(date "+%Y-%m-%d-%Hh-%Mm-%Ss")
thecommit=$(git log --format=%H HEAD^1..HEAD)
if git status | grep "Changes"; then
echo "the are uncommited changes in the repo. We can't benchmark that.";
exit 1;
fi
./dist/build/benchmarks/benchmarks -o "BenchmarkLog/${thedate}-bench-commit=${thecommit}.html" --template=templates/report.tpl
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment