-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
GitPrivacy: kx4ajimwYx43dyiED39TJEC2Wooa7aqfP9sragrwz+RFYwnNEQFn5pNetGcAl1rEzPvbLEAywGg= XyVL8+s39j1GC1jN7ZQzsNkORo/o4yeAfurZ5u1Qi57F6CtzdeZeKOnAhh7ZXJ6npT6PXeGPtgk=
- Loading branch information
Showing
1 changed file
with
8 additions
and
5 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -34,23 +34,26 @@ jobs: | |
run: | | ||
git config --global user.name "github-actions" | ||
git config --global user.email "[email protected]" | ||
# Create a fresh gh-pages branch based on the latest master | ||
git checkout --orphan gh-pages | ||
git reset --hard | ||
# Copy only the coverage report files | ||
# Copy README.md as index.md for GitHub Pages | ||
cp README.md index.md | ||
# Copy the coverage report | ||
mkdir -p coverage | ||
cp -r target/scala-*/scoverage-report/* coverage/ | ||
# Generate the badge as an SVG | ||
BADGE_URL="https://img.shields.io/badge/coverage-${{ env.COVERAGE }}%25-brightgreen.svg" | ||
curl -o coverage/coverage-badge.svg "$BADGE_URL" | ||
# Clean up any other unnecessary files in the target folder | ||
# Clean up unnecessary files in target folder | ||
rm -rf target | ||
# Commit and force-push to gh-pages | ||
git add coverage/ | ||
git commit -m "Update gh-pages with latest coverage report and badge" | ||
git add index.md coverage/ | ||
git commit -m "Update gh-pages with latest coverage report, badge, and homepage" | ||
git push --force origin gh-pages |