Repository navigation
Miner Integration Test: Create a miner and pledges a sector through Forest #2017
Workflow file for this run
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: Go code linters | |
| permissions: | |
| contents: read | |
| # Cancel workflow if there is a new change to the branch. | |
| concurrency: | |
| group: ${{ github.workflow }}-${{ github.ref }} | |
| cancel-in-progress: ${{ github.ref != 'refs/heads/main' }} | |
| on: | |
| workflow_dispatch: | |
| merge_group: | |
| pull_request: | |
| branches: | |
| - main | |
| paths: | |
| - ".github/workflows/go-lint.yml" | |
| - "go.work" | |
| - "mise.toml" | |
| - "f3-sidecar/**" | |
| - "interop-tests/**" | |
| - "build.rs" | |
| - "src/f3/go_ffi.rs" | |
| push: | |
| branches: | |
| - main | |
| paths: | |
| - ".github/workflows/go-lint.yml" | |
| - "go.work" | |
| - "mise.toml" | |
| - "f3-sidecar/**" | |
| - "interop-tests/**" | |
| - "build.rs" | |
| - "src/f3/go_ffi.rs" | |
| jobs: | |
| # Merge groups don't support path filters, so detect the relevant changes | |
| # explicitly and skip the lint job when nothing Go-related changed. | |
| # https://github.com/community/community/discussions/45899 | |
| changes: | |
| runs-on: ubuntu-slim | |
| outputs: | |
| changesFound: ${{ steps.filter.outputs.changesFound }} | |
| steps: | |
| - uses: actions/checkout@v7 | |
| - uses: dorny/paths-filter@v4 | |
| id: filter | |
| with: | |
| filters: | | |
| changesFound: | |
| - '.github/workflows/go-lint.yml' | |
| - 'go.work' | |
| - 'mise.toml' | |
| - 'f3-sidecar/**' | |
| - 'interop-tests/**' | |
| - 'build.rs' | |
| - 'src/f3/go_ffi.rs' | |
| lint-go: | |
| name: Go lint checks | |
| needs: changes | |
| if: ${{ needs.changes.outputs.changesFound == 'true' || github.event_name == 'workflow_dispatch' }} | |
| runs-on: ubuntu-24.04-arm | |
| steps: | |
| - uses: actions/checkout@v7 | |
| - uses: jdx/mise-action@v5 | |
| - name: Apt Dependencies | |
| uses: nick-fields/retry@v4 | |
| with: | |
| timeout_minutes: 5 | |
| max_attempts: 3 | |
| command: | | |
| sudo apt-get install -y libclang-dev # required by rust2go's bindgen | |
| - run: mise lint:go-ffi | |
| - run: mise lint:golang |