generated from populationgenomics/cpg-python-template-repo
-
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.
ci(.github/workflows/,docs/): mv update-badges from test workflow
- Loading branch information
1 parent
8a2467e
commit 3b90377
Showing
3 changed files
with
52 additions
and
33 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
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 |
---|---|---|
@@ -0,0 +1,33 @@ | ||
name: Update Badges | ||
on: | ||
workflow_run: | ||
workflows: ["Test"] | ||
types: | ||
- completed | ||
|
||
jobs: | ||
update-badges: | ||
name: Update Badges | ||
runs-on: ubuntu-latest | ||
if: ${{ github.event.workflow_run.conclusion == 'success' }} | ||
steps: | ||
- uses: actions/checkout@v4 | ||
|
||
- name: Update badges.yaml | ||
run: | | ||
cat <<EOF > docs/badges.yaml | ||
test-badge: | ||
status: ${{ github.event.workflow_run.output.TEST_PASSED }} / ${{ github.event.workflow_run.output.TEST_COUNT }} passed | ||
color: ${{ github.event.workflow_run.output.TEST_COLOR }} | ||
coverage-badge: | ||
status: ${{ github.event.workflow_run.output.COVERAGE }} | ||
color: ${{ github.event.workflow_run.output.COVERAGE_COLOR }} | ||
EOF | ||
- name: Commit and push badges.yaml | ||
run: | | ||
git config --global user.name 'github-actions[bot]' | ||
git config --global user.email 'github-actions[bot]@users.noreply.github.com' | ||
git add docs/badges.yaml | ||
git commit -m "chore: update badges.yaml with test results and coverage" | ||
git push |
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 |
---|---|---|
@@ -1,7 +1,8 @@ | ||
docker.yaml: "Builds and pushes Docker images for the project." | ||
lint.yaml: "Runs linting checks using pre-commit hooks." | ||
package.yaml: "Packages the project and publishes it to PyPI and GitHub Releases." | ||
renovate.yaml: "Runs Renovate to update dependencies." | ||
security.yaml: "Performs security checks using pip-audit." | ||
test.yaml: "Runs unit tests and generates coverage reports." | ||
update-badges.yaml: "Updates badges.yaml with test results and coverage." | ||
web_docs.yaml: "Deploys API documentation to GitHub Pages." | ||
security.yaml: "Performs security checks using pip-audit." | ||
renovate.yaml: "Runs Renovate to update dependencies." | ||
package.yaml: "Packages the project and publishes it to PyPI and GitHub Releases." | ||
lint.yaml: "Runs linting checks using pre-commit hooks." | ||
docker.yaml: "Builds and pushes Docker images for the project." |