| 1 |
name: Release |
| 2 |
on: |
| 3 |
push: |
| 4 |
tags: |
| 5 |
- 'v*' |
| 6 |
jobs: |
| 7 |
build: |
| 8 |
runs-on: ubuntu-latest |
| 9 |
env: |
| 10 |
GO111MODULE: on |
| 11 |
ACTIONS_ALLOW_UNSECURE_COMMANDS: true |
| 12 |
steps: |
| 13 |
- name: Checkout Source |
| 14 |
uses: actions/checkout@v4 |
| 15 |
- name: Unshallow |
| 16 |
run: git fetch --prune --unshallow |
| 17 |
- name: Set up Go |
| 18 |
uses: actions/setup-go@v5 |
| 19 |
- name: Generate SBOM |
| 20 |
uses: CycloneDX/gh-gomod-generate-sbom@v2 |
| 21 |
with: |
| 22 |
version: v1 |
| 23 |
args: mod -licenses -json -output bom.json |
| 24 |
- name: Release Module |
| 25 |
uses: goreleaser/goreleaser-action@v6 |
| 26 |
with: |
| 27 |
version: latest |
| 28 |
args: release --clean |
| 29 |
env: |
| 30 |
GITHUB_TOKEN: ${{ github.token }} |