mirror of
https://github.com/lowRISC/ibex.git
synced 2025-04-20 11:57:12 -04:00
[CI] change pr_lint to run on pull_request instead of target
Signed-off-by: Gary Guo <gary.guo@lowrisc.org>
This commit is contained in:
parent
33a1740dd2
commit
1c5da195b6
1 changed files with 6 additions and 18 deletions
|
@ -6,32 +6,19 @@
|
|||
#
|
||||
# See https://github.com/chipsalliance/verible-linter-action.
|
||||
|
||||
name: pr-lint-review
|
||||
name: pr-lint
|
||||
|
||||
# Triggers when there is any activity on a pull request, e.g. opened, updated.
|
||||
#
|
||||
# The action runs in the context of the _base_ of the pull request, but later we
|
||||
# checkout the repository at the pull request's HEAD to run linting.
|
||||
on:
|
||||
pull_request_target:
|
||||
pull_request:
|
||||
|
||||
jobs:
|
||||
verible-lint:
|
||||
runs-on: ubuntu-latest
|
||||
# Grant write permissions only for setting checks and adding review comments
|
||||
# to pull requests.
|
||||
permissions:
|
||||
checks: write
|
||||
contents: read
|
||||
pull-requests: write
|
||||
env:
|
||||
verible_config: 'vendor/lowrisc_ip/lint/tools/veriblelint/lowrisc-styleguide.rules.verible_lint'
|
||||
verible_config: "vendor/lowrisc_ip/lint/tools/veriblelint/lowrisc-styleguide.rules.verible_lint"
|
||||
steps:
|
||||
- uses: actions/checkout@v3
|
||||
with:
|
||||
# Because `pull_request_target` runs at the PR's base, we need to
|
||||
# checkout the head of the PR before running the lint.
|
||||
ref: ${{ github.event.pull_request.head.sha }}
|
||||
- uses: actions/checkout@v4
|
||||
- name: Display Verible config
|
||||
run: |
|
||||
echo "::group::Verible config"
|
||||
|
@ -41,5 +28,6 @@ jobs:
|
|||
uses: chipsalliance/verible-linter-action@main
|
||||
with:
|
||||
github_token: ${{ secrets.GITHUB_TOKEN }}
|
||||
suggest_fixes: 'false'
|
||||
reviewdog_reporter: github-pr-check
|
||||
suggest_fixes: "false"
|
||||
config_file: ${{ env.verible_config }}
|
Loading…
Add table
Add a link
Reference in a new issue