File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 11name : Lint Code Base
22
33on :
4+ pull_request :
5+ types : [opened, synchronize, reopened, ready_for_review]
46 pull_request_review :
57 types : [submitted]
68
@@ -9,7 +11,7 @@ permissions:
911
1012jobs :
1113 lint :
12- if : github.event_name == 'pull_request_review' && github.event.review.state == 'approved'
14+ if : github.event_name == 'pull_request' || (github.event_name == ' pull_request_review' && github.event.review.state == 'approved')
1315 name : Lint Code Base
1416 runs-on : ubuntu-latest
1517 steps :
2325 # Disable credential persistence to harden the runner
2426 persist-credentials : false
2527
28+ - name : Fetch base branch for diff
29+ run : git fetch --no-tags --prune origin "+refs/heads/${{ github.event.pull_request.base.ref }}:refs/remotes/origin/${{ github.event.pull_request.base.ref }}"
30+
2631 - name : Lint Code Base
2732 uses : super-linter/super-linter@12150456a73e248bdc94d0794898f94e23127c88 # v7
2833 env :
2934 VALIDATE_ALL_CODEBASE : false
3035 DEFAULT_BRANCH : ${{ github.event.pull_request.base.ref }}
36+ GITHUB_SHA : ${{ github.event.pull_request.head.sha }}
3137 GITHUB_TOKEN : ${{ secrets.GITHUB_TOKEN }}
You can’t perform that action at this time.
0 commit comments