Skip to content

Switch to astral

Switch to astral #701

Workflow file for this run

---
name: Lint
on:
pull_request: {}
push:
branches:
- main
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
jobs:
lint:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: "3.12"
- name: Install venv
run: ./tools/uv sync --extra tools --locked
- name: Ensure linter is happy
run: ./tools/ci lint
format:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: "3.12"
- name: Install venv
run: ./tools/uv sync --extra tools --locked
- name: Ensure code is formatted
run: |
./tools/ci format
# Complain if there were changes
if [[ ! -z "$(git status --porcelain)" ]]; then
echo "=========================================="
echo "Found changes!"
echo "Please run ./format before committing code"
echo "=========================================="
git diff
exit 1
fi