File tree Expand file tree Collapse file tree 2 files changed +8
-5
lines changed
Expand file tree Collapse file tree 2 files changed +8
-5
lines changed Original file line number Diff line number Diff line change @@ -3,9 +3,12 @@ name: codeql-wrapper-monorepo-only-changed-files
33
44# Trigger workflow
55on :
6+ push :
7+ branches :
8+ - main
69 pull_request :
710 workflow_dispatch :
8- push :
11+
912jobs :
1013 codeql-analysis :
1114 name : codeql-wrapper-monorepo-pr
Original file line number Diff line number Diff line change @@ -25,15 +25,15 @@ jobs:
2525 name : Run CodeQL Analysis
2626 command : |
2727 export GITHUB_TOKEN=${PAT} # Set PAT as environment variable in CircleCI project settings
28- # export GITHUB_BASE_REF=<< pipeline.event.github.pull_request.base.ref >>
29- # export GITHUB_REF=refs/pull/<< pipeline.event.github.pull_request.number >>/merge
28+ export GITHUB_BASE_REF=<< pipeline.event.github.pull_request.base.ref >>
29+ export GITHUB_REF=refs/pull/<< pipeline.event.github.pull_request.number >>/merge
3030 curl -s -H "Authorization: token $GITHUB_TOKEN" https://api.github.com/user
31- printenv
3231 codeql-wrapper --verbose analyze ./monorepo \
3332 --monorepo \
3433 --upload-sarif \
3534 --only-changed-files \
36- --max-workers 1
35+ --base-ref origin/"$GITHUB_BASE_REF" \
36+ --ref "$GITHUB_REF"
3737
3838workflows :
3939 version : 2
You can’t perform that action at this time.
0 commit comments