Skip to content

Commit

Permalink
ci: add dry run, update goreleaser yaml archive template
Browse files Browse the repository at this point in the history
  • Loading branch information
aksmo committed Mar 7, 2024
1 parent 892082f commit 8acdc42
Show file tree
Hide file tree
Showing 2 changed files with 28 additions and 0 deletions.
25 changes: 25 additions & 0 deletions .github/workflows/release-dryrun.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
name: dryrun

on:
workflow_dispatch:

jobs:
goreleaser-dryrun:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Set up Go
uses: actions/setup-go@v5
with:
go-version: 1.22.1
- name: Release CLI (GoReleaser)
uses: goreleaser/goreleaser-action@v5
with:
version: latest
args: release --clean --skip=publish
env:
GITHUB_TOKEN: ${{ github.token }}
HOMEBREW_TAP_GITHUB_TOKEN: ${{ secrets.GIT_COMMITTER_TOKEN }}
3 changes: 3 additions & 0 deletions .goreleaser.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,9 @@ builds:
ldflags: -s -w -X github.com/optum/runiac/cmd/cli/cmd.Version={{.Version}} -X github.com/optum/runiac/cmd/cli/cmd.Commit={{.Commit}} -X github.com/optum/runiac/cmd/cli/cmd.Date={{.Date}}
archives:
- name_template: >-
{{- .ProjectName }}_
{{- .Version }}_
{{- .Os }}_
{{- if eq .Arch "amd64" }}x86_64
{{- else if eq .Arch "386" }}i386
{{- else }}{{ .Arch }}{{ end }}
Expand Down

0 comments on commit 8acdc42

Please sign in to comment.