Skip to content

Commit

Permalink
Fix cache path
Browse files Browse the repository at this point in the history
  • Loading branch information
garazdawi committed Mar 2, 2025
1 parent 878ab88 commit 11ad1db
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions .github/workflows/main.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -669,7 +669,7 @@ jobs:
uses: actions/cache@v3
id: ort-cache
with:
path: .ort/ort-results/scanner-result.json
path: /home/runner/.ort/ort-results/current-result.json
key: ort-scan-result-${{ env.ORT_VERSION }}-${{ github.ref_name }}-${{ github.sha }}
restore-keys: |
ort-scan-result-${{ env.ORT_VERSION }}-${{ github.ref_name }}-
Expand All @@ -679,11 +679,11 @@ jobs:
- name: Restore from cache
if: ${{ steps.ort-cache.outputs.cache-hit == true }}
run: |
cp .ort/ort-results/scan-result.json .ort/ort-results/scan-result.json.orig
./scripts/scan-code.escript --scan-result-cache .ort/ort-results/scan-result.json.orig \
--analyzer-result .ort/ort-results/analyzer-result.json --file-or-dir . \
--scan-result .ort/ort-results/scan-result.json
diff .ort/ort-results/scan-result.json.orig .ort/ort-results/scan-result.json
cp $HOME/.ort/ort-results/scan-result.json $HOME/.ort/ort-results/scan-result.json.orig
./scripts/scan-code.escript --scan-result-cache $HOME/.ort/ort-results/scan-result.json.orig \
--analyzer-result $HOME/.ort/ort-results/analyzer-result.json --file-or-dir . \
--scan-result $HOME/.ort/ort-results/scan-result.json
diff $HOME/.ort/ort-results/scan-result.json.orig $HOME/.ort/ort-results/scan-result.json
- name: Run scanner
if: ${{ steps.ort-cache.outputs.cache-hit == false }}
Expand Down

0 comments on commit 11ad1db

Please sign in to comment.