Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion .github/workflows/go-build-release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,7 @@
fetch-depth: ${{ inputs.fetch-depth }}

- name: Set build environment variables
run: |

Check failure on line 89 in .github/workflows/go-build-release.yml

View workflow job for this annotation

GitHub Actions / lint

shellcheck reported issue in this script: SC2086:info:4:32: Double quote to prevent globbing and word splitting

Check failure on line 89 in .github/workflows/go-build-release.yml

View workflow job for this annotation

GitHub Actions / lint

shellcheck reported issue in this script: SC2086:info:3:55: Double quote to prevent globbing and word splitting

Check failure on line 89 in .github/workflows/go-build-release.yml

View workflow job for this annotation

GitHub Actions / lint

shellcheck reported issue in this script: SC2086:info:2:34: Double quote to prevent globbing and word splitting

Check failure on line 89 in .github/workflows/go-build-release.yml

View workflow job for this annotation

GitHub Actions / lint

shellcheck reported issue in this script: SC2086:info:1:100: Double quote to prevent globbing and word splitting

Check failure on line 89 in .github/workflows/go-build-release.yml

View workflow job for this annotation

GitHub Actions / lint

shellcheck reported issue in this script: SC2129:style:1:1: Consider using { cmd1; cmd2; } >> file instead of individual redirects
echo "GIT_STATE=$(if git diff-index --quiet HEAD --; then echo 'clean'; else echo 'dirty'; fi)" >> $GITHUB_ENV
echo "BUILD_HOST=$(hostname)" >> $GITHUB_ENV
echo "GO_VERSION=$(go version | awk '{print $3}')" >> $GITHUB_ENV
Expand All @@ -94,7 +94,7 @@

- name: Set CGO_ENABLED if specified
if: ${{ inputs.cgo-enabled != '' }}
run: echo "CGO_ENABLED=${{ inputs.cgo-enabled }}" >> $GITHUB_ENV

Check failure on line 97 in .github/workflows/go-build-release.yml

View workflow job for this annotation

GitHub Actions / lint

shellcheck reported issue in this script: SC2086:info:1:49: Double quote to prevent globbing and word splitting

- name: Set additional environment variables
if: ${{ inputs.additional-env-vars != '' }}
Expand Down Expand Up @@ -137,6 +137,7 @@

- name: Process GoReleaser output
id: process_goreleaser_output
if: ${{ !contains(steps.snapshot_flags.outputs.flags, '--snapshot') }}
run: |
echo "const fs = require('fs');" > process.js
echo 'const artifacts = ${{ steps.goreleaser.outputs.artifacts }}' >> process.js
Expand All @@ -152,7 +153,7 @@
subject-path: ${{ inputs.attestation-binary-path }}

- name: Generate build provenance for container
if: ${{ steps.process_goreleaser_output.outputs.digest != '' && steps.process_goreleaser_output.outputs.digest != 'undefined' }}
if: ${{ !contains(steps.snapshot_flags.outputs.flags, '--snapshot') && steps.process_goreleaser_output.outputs.digest != '' && steps.process_goreleaser_output.outputs.digest != 'undefined' }}
uses: actions/attest-build-provenance@v1
with:
subject-name: ${{ inputs.registry-name }}
Expand Down
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ Use major version tags for stability:
# For reusable workflows
jobs:
release:
uses: OpenCHAMI/github-actions/.github/workflows/go-build-release.yml@v3.1
uses: OpenCHAMI/github-actions/.github/workflows/go-build-release.yml@v3.2
```

Pin a commit SHA internally for maximum supply‑chain safety if desired.
Expand Down Expand Up @@ -49,7 +49,7 @@ on:

jobs:
release:
uses: OpenCHAMI/github-actions/.github/workflows/go-build-release.yml@v3.1
uses: OpenCHAMI/github-actions/.github/workflows/go-build-release.yml@v3.2
with:
pre-build-commands: |
go install github.com/swaggo/swag/cmd/swag@latest
Expand Down
Loading