Skip to content

Commit

Permalink
fix: Use gha run number rather than ref_name for non releases
Browse files Browse the repository at this point in the history
  • Loading branch information
cpswan committed Nov 14, 2024
1 parent 9ae2fe4 commit 2f05109
Showing 1 changed file with 10 additions and 2 deletions.
12 changes: 10 additions & 2 deletions .github/workflows/at_server.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -127,7 +127,7 @@ jobs:
COMPONENT_ID: '3hQHrn8mwK'
LOCK_FILE: ${{ env.root-working-directory }}/pubspec.lock
SBOM_VERSION: ${{github.ref_name}}
OUTPUT_FILE: 'sboms/atdirectory-${{github.ref_name}}-sbom.cdx.json'
OUTPUT_FILE: 'sboms/atdirectory-gha${{github.run_number}}-sbom.cdx.json'
AUGMENT: true
ENRICH: true
UPLOAD: true
Expand All @@ -139,10 +139,18 @@ jobs:
COMPONENT_ID: 'wF66pn8rHZ'
LOCK_FILE: ${{ env.secondary-working-directory }}/pubspec.lock
SBOM_VERSION: ${{github.ref_name}}
OUTPUT_FILE: 'sboms/atserver-${{github.ref_name}}-sbom.cdx.json'
OUTPUT_FILE: 'sboms/atserver-gha${{github.run_number}}-sbom.cdx.json'
AUGMENT: true
ENRICH: true
UPLOAD: true
- if: ${{ matrix.dart-channel == 'stable' && startsWith(github.ref, 'refs/tags/') }}
name: Rename SBOMs to use release tag
run: |
cd sboms
mv atdirectory-gha${{github.run_number}}-sbom.cdx.json \
atdirectory-${{github.ref_name}}-sbom.cdx.json
mv atserver-gha${{github.run_number}}-sbom.cdx.json \
atserver-${{github.ref_name}}-sbom.cdx.json
- if: ${{ matrix.dart-channel == 'stable' }}
name: Generate SHA256 checksums
working-directory: sboms
Expand Down

0 comments on commit 2f05109

Please sign in to comment.