fix: update test script and vibrator_haptics nil safety #62
This file contains hidden or 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
| name: CI | |
| on: | |
| push: | |
| branches: [main] | |
| pull_request: | |
| branches: [main] | |
| permissions: | |
| contents: read | |
| jobs: | |
| test: | |
| name: Test (tools) | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - uses: actions/setup-go@v5 | |
| with: | |
| go-version: "1.24.x" | |
| - uses: actions/cache@v4 | |
| with: | |
| path: | | |
| ~/go/pkg/mod | |
| ~/.cache/go-build | |
| key: ${{ runner.os }}-go-${{ hashFiles('go.sum') }} | |
| restore-keys: | | |
| ${{ runner.os }}-go- | |
| - name: Run tests | |
| run: go test ./tools/... | |
| vet: | |
| name: Vet | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - uses: actions/setup-go@v5 | |
| with: | |
| go-version: "1.24.x" | |
| - uses: actions/cache@v4 | |
| with: | |
| path: | | |
| ~/go/pkg/mod | |
| ~/.cache/go-build | |
| key: ${{ runner.os }}-go-${{ hashFiles('go.sum') }} | |
| restore-keys: | | |
| ${{ runner.os }}-go- | |
| - name: Vet packages | |
| run: go vet ./tools/... | |
| lint: | |
| name: Lint | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - uses: actions/setup-go@v5 | |
| with: | |
| go-version: "1.24.x" | |
| - uses: actions/cache@v4 | |
| with: | |
| path: | | |
| ~/go/pkg/mod | |
| ~/.cache/go-build | |
| key: ${{ runner.os }}-go-${{ hashFiles('go.sum') }} | |
| restore-keys: | | |
| ${{ runner.os }}-go- | |
| - name: Install golangci-lint v2 | |
| run: go install github.com/golangci/golangci-lint/v2/cmd/golangci-lint@latest | |
| - name: Lint (tools) | |
| run: golangci-lint run --build-tags="" ./tools/... | |
| proofs: | |
| name: Verify proofs | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Install elan | |
| run: | | |
| curl -sSf https://raw.githubusercontent.com/leanprover/elan/master/elan-init.sh | sh -s -- -y | |
| echo "$HOME/.elan/bin" >> "$GITHUB_PATH" | |
| - uses: actions/cache@v4 | |
| with: | |
| path: proofs/.lake | |
| key: ${{ runner.os }}-lean-${{ hashFiles('proofs/lean-toolchain', 'proofs/lakefile.toml') }} | |
| restore-keys: | | |
| ${{ runner.os }}-lean- | |
| - name: Build proofs | |
| run: cd proofs && lake build |