Skip to content

Commit

Permalink
manually trigger attestations (#1379)
Browse files Browse the repository at this point in the history
* use dispatch parameter to include attestation.

* restrict attestation to release flavor
  • Loading branch information
tsteven4 authored Nov 11, 2024
1 parent 162eb00 commit 838bc9d
Show file tree
Hide file tree
Showing 3 changed files with 26 additions and 8 deletions.
10 changes: 8 additions & 2 deletions .github/workflows/macos.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,13 @@ on:
branches: [ master ]
schedule:
- cron: '27 4 * * 2'
workflow_dispatch: ~
workflow_dispatch:
inputs:
attestation:
description: 'Generate attestation for binary artifacts'
required: false
default: false
type: boolean

jobs:
macos:
Expand Down Expand Up @@ -99,7 +105,7 @@ jobs:
./tools/ci_script_osx.sh . ${{ matrix.QT_VERSION }} ${{ matrix.GENERATOR }}
- name: Generate artifact attestation
if: ( github.event_name == 'push' ) && ( github.ref == 'refs/heads/master' ) && matrix.RELEASE
if: ${{ inputs.attestation && matrix.RELEASE }}
uses: actions/attest-build-provenance@v1
with:
subject-path: 'gui/GPSBabel-*.dmg'
Expand Down
10 changes: 8 additions & 2 deletions .github/workflows/ubuntu.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,13 @@ on:
branches: [ master ]
schedule:
- cron: '27 4 * * 2'
workflow_dispatch: ~
workflow_dispatch:
inputs:
attestation:
description: 'Generate attestation for binary artifacts'
required: false
default: false
type: boolean

jobs:
ubuntu:
Expand Down Expand Up @@ -111,7 +117,7 @@ jobs:
./testo -p /snap/bin/gpsbabel
- name: Generate artifact attestation
if: ( github.event_name == 'push' ) && ( github.ref == 'refs/heads/master' )
if: ${{ inputs.attestation }}
uses: actions/attest-build-provenance@v1
with:
subject-path: ${{ steps.build-snap.outputs.snap }}
Expand Down
14 changes: 10 additions & 4 deletions .github/workflows/windows.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,13 @@ on:
branches: [ master ]
schedule:
- cron: '27 4 * * 2'
workflow_dispatch: ~
workflow_dispatch:
inputs:
attestation:
description: 'Generate attestation for binary artifacts'
required: false
default: false
type: boolean

jobs:

Expand Down Expand Up @@ -103,7 +109,7 @@ jobs:
PNAME=./bld/gui/package/gpsbabel.exe GBTEMP=./gbtemp ./test_encoding_utf8 2>&1
- name: Generate artifact attestation
if: ( github.event_name == 'push' ) && ( github.ref == 'refs/heads/master' ) && matrix.RELEASE
if: ${{ inputs.attestation && matrix.RELEASE }}
uses: actions/attest-build-provenance@v1
with:
subject-path: 'bld/gui/GPSBabel-*-Setup.exe'
Expand All @@ -124,6 +130,6 @@ jobs:
with:
name: Windows_Installer ${{ join(matrix.*) }}
path: |
./bld/gui/GPSBabel-*-Setup.exe
./bld/gui/GPSBabel-*-Manifest.txt
bld/gui/GPSBabel-*-Setup.exe
bld/gui/GPSBabel-*-Manifest.txt
retention-days: 7

0 comments on commit 838bc9d

Please sign in to comment.