Migrate to GitHub Actions #1
Workflow file for this run
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
on: | |
push: | |
branches: | |
- main | |
pull_request: | |
merge_group: | |
name: CI | |
jobs: | |
test: | |
strategy: | |
matrix: | |
include: | |
- os: ubuntu-latest | |
allow-failure: false | |
- os: macos-latest | |
allow-failure: true | |
name: "test (${{ matrix.os }})" | |
runs-on: ${{ matrix.os }} | |
continue-on-error: ${{ matrix.allow-failure }} | |
steps: | |
- name: Check out source code | |
uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 | |
- name: Set up PDM | |
uses: pdm-project/setup-pdm@v4 | |
with: | |
cache: true | |
- name: Install dependencies | |
run: | | |
pdm lock --dev | |
pdm install | |
- name: Run tests | |
run: | | |
pdm run test | |
license: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Check out source code | |
uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 | |
- name: Check source code licenses | |
run: | | |
docker run --platform=linux/amd64 -v ${PWD}:/src ghcr.io/google/addlicense -v -check -l BSD-2-Clause -c "ChipFlow" -s=only -ignore **/__init__.py **/*.py |