github.com/cloudwego/runtimex@v0.1.0/.github/workflows/pr-check.yml (about) 1 name: Pull Request Check 2 3 on: [ pull_request ] 4 5 jobs: 6 compliant: 7 runs-on: [ self-hosted, X64 ] 8 steps: 9 - uses: actions/checkout@v3 10 - name: Check License Header 11 uses: apache/skywalking-eyes/header@v0.4.0 12 env: 13 GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} 14 - name: Check Spell 15 uses: crate-ci/typos@master 16 17 staticcheck: 18 runs-on: [ self-hosted, X64 ] 19 steps: 20 - uses: actions/checkout@v3 21 - name: Set up Go 22 uses: actions/setup-go@v3 23 with: 24 go-version: "1.20" 25 - uses: actions/cache@v3 26 with: 27 path: ~/go/pkg/mod 28 key: reviewdog-${{ runner.os }}-go-${{ hashFiles('**/go.sum') }} 29 restore-keys: | 30 reviewdog-${{ runner.os }}-go- 31 - uses: reviewdog/action-staticcheck@v1 32 with: 33 github_token: ${{ secrets.github_token }} 34 # Change reviewdog reporter if you need [github-pr-check,github-check,github-pr-review]. 35 reporter: github-pr-review 36 # Report all results. 37 filter_mode: nofilter 38 # Exit with 1 when it find at least one finding. 39 fail_on_error: true 40 # Set staticcheck flags 41 staticcheck_flags: -checks=inherit,-SA1029 42 43 lint: 44 runs-on: [ self-hosted, X64 ] 45 steps: 46 - uses: actions/checkout@v3 47 - name: Set up Go 48 uses: actions/setup-go@v3 49 with: 50 go-version: "1.20" 51 - name: Golangci Lint 52 # https://golangci-lint.run/ 53 uses: golangci/golangci-lint-action@v3 54 with: 55 version: latest