Skip to content

build: prepare game for deployment to itch.io (#7) #22

build: prepare game for deployment to itch.io (#7)

build: prepare game for deployment to itch.io (#7) #22

Workflow file for this run

name: CI
on:
push:
branches: [master]
pull_request:
branches: [master]
# Cancel any currently running job in the same group if a new one is triggered
concurrency:
group: ${{ github.workflow }}-${{ github.head_ref || github.run_id }}
cancel-in-progress: true
# Force color output for all steps, even if not running in a TTY
env:
FORCE_COLOR: 1
jobs:
lint:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: astral-sh/ruff-action@v3
with:
args: "check --output-format=github"
- uses: astral-sh/ruff-action@v3
with:
args: "format --diff"
typecheck:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Install UV
uses: astral-sh/setup-uv@v7
with:
enable-cache: true
- name: Install the project
run: uv sync --locked --all-groups
- run: uv run ty check
- run: uv cache prune --ci
test:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Install UV
uses: astral-sh/setup-uv@v7
with:
enable-cache: true
- name: Install the project
run: uv sync --locked --all-groups
- name: Run tests with coverage
run: uv run pytest -v tests/ --cov=gameoflife/ --cov-branch --cov-report=xml
- name: Upload coverage reports to Codecov
uses: codecov/codecov-action@v5
with:
token: ${{ secrets.CODECOV_TOKEN }}
- name: Prune UV cache
run: uv cache prune --ci