Skip to content

Commit

Permalink
Upload code scanning results to correct ref when releasing
Browse files Browse the repository at this point in the history
  • Loading branch information
alcaeus committed Jun 17, 2024
1 parent 42f5a49 commit 6f89939
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions .github/workflows/static-analysis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,11 @@ jobs:
with:
ref: ${{ github.event_name == 'workflow_dispatch' && inputs.ref || github.ref }}

- name: "Get SHA hash of checked out ref"
if: ${{ github.event_name == 'workflow_dispatch' }}
run: |
echo CHECKED_OUT_SHA=$(git rev-parse HEAD) >> $GITHUB_ENV
- name: Setup PHP
uses: shivammathur/setup-php@v2
with:
Expand Down Expand Up @@ -64,6 +69,8 @@ jobs:
uses: "github/codeql-action/upload-sarif@v3"
with:
sarif_file: phpstan.sarif
ref: ${{ github.event_name == 'workflow_dispatch' && inputs.ref || github.ref }}
sha: ${{ github.event_name == 'workflow_dispatch' && env.CHECKED_OUT_SHA || github.sha }}

- name: Save cache PHPStan results
id: phpstan-cache-save
Expand Down

0 comments on commit 6f89939

Please sign in to comment.