github.com/cloudwego/hertz@v0.9.3/.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  
    11        - name: Check License Header
    12          uses: apache/skywalking-eyes/header@v0.4.0
    13  
    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@v4
    21        - name: Set up Go
    22          uses: actions/setup-go@v5
    23          with:
    24            go-version: stable
    25            # For self-hosted, the cache path is shared across projects
    26            # and it works well without the cache of github actions
    27            # Enable it if we're going to use Github only
    28            cache: false
    29  
    30        - uses: reviewdog/action-staticcheck@v1
    31          with:
    32            github_token: ${{ secrets.github_token }}
    33            # Change reviewdog reporter if you need [github-pr-check,github-check,github-pr-review].
    34            reporter: github-pr-review
    35            # Report all results.
    36            filter_mode: nofilter
    37            # Exit with 1 when it find at least one finding.
    38            fail_on_error: true
    39            # Set staticcheck flags
    40            staticcheck_flags: -checks=inherit,-SA1029,-SA5008
    41  
    42    lint:
    43      runs-on: [ self-hosted, X64 ]
    44      steps:
    45        - uses: actions/checkout@v4
    46        - name: Set up Go
    47          uses: actions/setup-go@v5
    48          with:
    49            go-version: stable
    50            cache: false # don't use cache for self-hosted runners
    51  
    52        - name: Golangci Lint
    53          # https://golangci-lint.run/
    54          uses: golangci/golangci-lint-action@v6
    55          with:
    56            version: latest