name: Test on: pull_request: push: jobs: test: strategy: matrix: # os: [windows-latest, ubuntu-latest, macos-latest] os: [ubuntu-latest] runs-on: ${{ matrix.os }} steps: - uses: actions/checkout@v4 - uses: actions/cache@v4 with: path: ~/.cache/pre-commit key: pre-commit|${{ env.PY }}|${{ hashFiles('.pre-commit-config.yaml') }} - uses: actions/cache@v4 with: path: | ~/.cargo/bin/ ~/.cargo/registry/index/ ~/.cargo/registry/cache/ ~/.cargo/git/db/ target/ key: ${{ runner.os }}-cargo-${{ hashFiles('**/Cargo.lock') }} - name: Install Nix uses: https://github.com/cachix/install-nix-action@v31 if: runner.os == 'linux' - name: Test run: nix develop --command pre-commit run -a if: runner.os == 'linux'