Skip to content

Just try branch.

Just try branch. #11

Workflow file for this run

name: Coverage
on:
push:
# branches:
# - main
jobs:
test:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
with:
fetch-depth: 1
- name: Prepare
uses: ./.github/actions/prepare
- name: Set up Python 3.11
uses: actions/[email protected]
with:
python-version: "3.11"
- name: Install Poetry
uses: abatilo/[email protected]
with:
poetry-version: 1.6.1
- name: Set Poetry config
run: |
poetry config virtualenvs.path ~/.virtualenvs3.11
- name: Install dependencies
run: poetry install
- name: Generate coverage badge
run: |
chmod +x generate_badge.sh
./generate_badge.sh
# - name: Archive code coverage results for the current SHA
# uses: actions/upload-artifact@v4
# with:
# name: coverage-${LAST_COMMIT_SHA:0:7}.svg
# path: badges/coverage.svg
- name: Archive code coverage results for the current branch
uses: actions/upload-artifact@v4
with:
name: coverage-${{ github.head_ref || github.ref_name }}.svg
path: badges/coverage.svg
# - name: Commit and push coverage badge
# continue-on-error: true
# env:
# GITHUB_TOKEN: ${{ secrets.GH_TOKEN }}
# run: |
# git config --global user.name "github-actions[bot]"
# git config --global user.email "github-actions[bot]@users.noreply.github.com"
# git add badges/coverage.svg
# git commit -m "Update coverage badge"
# git push