From 96ab3b8ce7c91afe576062d44f2e25b44e26890a Mon Sep 17 00:00:00 2001 From: kim pham Date: Fri, 15 Nov 2024 10:26:24 +0100 Subject: [PATCH] Badge (#6) * add badge from gist * Update test.yml gist * Update README.md badge link update --- .github/workflows/test.yml | 15 ++++++++++++++- README.md | 4 ++++ 2 files changed, 18 insertions(+), 1 deletion(-) diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 8d88441..baab60a 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -68,4 +68,17 @@ jobs: python -m coverage run -p -m pytest src/jp2_remediator/tests/unit python -m coverage xml -o coverage-base.xml git checkout - - diff-cover --compare-branch=main coverage.xml --fail-under=85 \ No newline at end of file + diff-cover --compare-branch=main coverage.xml --fail-under=85 + + - name: "Make badge" + uses: schneegans/dynamic-badges-action@v1.4.0 + with: + # GIST_TOKEN is a GitHub personal access token with scope "gist". + auth: ${{ secrets.GIST_TOKEN }} + gistID: 67d4eba1556653d896d2d36fcb3e5c7c + filename: covbadge.json + label: Coverage + message: ${{ env.total }}% + minColorRange: 50 + maxColorRange: 90 + valColorRange: ${{ env.total }} diff --git a/README.md b/README.md index f505367..2ee9c2b 100644 --- a/README.md +++ b/README.md @@ -1,5 +1,9 @@ # jp2_remediator + + + + README for the module to validate jp2images https://pypi.org/project/jp2_remediator/