-
Notifications
You must be signed in to change notification settings - Fork 335
ci: remove dev branch jobs and add static.sh #549
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: master
Are you sure you want to change the base?
Conversation
Remove bench-dev and test-dev jobs from daily workflow since the dev branch no longer exists. Add ci/static.sh script to generate coverage badge for GitHub Pages. Refs #539
| rm -rf ./ci/out/static | ||
| mkdir -p ./ci/out/static | ||
| cp ./ci/out/coverage.html ./ci/out/static/coverage.html | ||
| percent=$(go tool cover -func ./ci/out/profile.txt | tail -n1 | awk '{print $3}' | tr -d '%') |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
set pipefail?
| #!/usr/bin/env bash | ||
| set -eu | ||
|
|
||
| cd -- "$(dirname "$0")/.." |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
cd --
bonus 👍 for the edge case, but I'm curious if you stumbled upon it :)
| mkdir -p ./ci/out/static | ||
| cp ./ci/out/coverage.html ./ci/out/static/coverage.html | ||
| percent=$(go tool cover -func ./ci/out/profile.txt | tail -n1 | awk '{print $3}' | tr -d '%') | ||
| wget -O ./ci/out/static/coverage.svg "https://img.shields.io/badge/coverage-${percent}%25-success" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
isn't curl more universal option?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
nit: you can parametrize batch color depending on the percent (high/medium/low)
Remove bench-dev and test-dev jobs from daily workflow since the dev
branch no longer exists.
Add ci/static.sh script to generate coverage badge for GitHub Pages.
Refs #539