-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix: changes binary name in release pipeline (#6)
- Loading branch information
Showing
3 changed files
with
75 additions
and
3 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,74 @@ | ||
before: | ||
hooks: | ||
- go mod tidy | ||
|
||
# Build a universal macOS binary | ||
universal_binaries: | ||
- replace: false | ||
|
||
# Build the different combination of goos/arch binaries | ||
builds: | ||
- env: | ||
- CGO_ENABLED=0 | ||
goos: | ||
- linux | ||
- darwin | ||
ldflags: | ||
- -s -w -X 'github.com/defenseunicorns/maru-runner/src/config.CLIVersion={{.Tag}}' -X 'github.com/defenseunicorns/zarf/src/config.ActionsCommandZarfPrefix=zarf' | ||
goarch: | ||
- amd64 | ||
- arm64 | ||
binary: maru | ||
|
||
# Save the built artifacts as binaries (instead of wrapping them in a tarball) | ||
archives: | ||
- format: binary | ||
name_template: "{{ .ProjectName }}_{{ .Tag }}_{{- title .Os }}_{{ .Arch }}" | ||
|
||
# generate a sha256 checksum of all release artifacts | ||
checksum: | ||
name_template: "checksums.txt" | ||
algorithm: sha256 | ||
|
||
# generate sboms for each binary artifact | ||
sboms: | ||
- artifacts: binary | ||
documents: | ||
- "sbom_{{ .ProjectName }}_{{ .Tag }}_{{- title .Os }}_{{ .Arch }}.sbom" | ||
|
||
snapshot: | ||
name_template: "{{ incpatch .Version }}-snapshot" | ||
|
||
# Use the auto-generated changelog github provides | ||
changelog: | ||
use: github-native | ||
|
||
brews: | ||
- name: maru | ||
repository: | ||
owner: defenseunicorns | ||
name: homebrew-tap | ||
token: "{{ .Env.HOMEBREW_TAP_GITHUB_TOKEN }}" | ||
commit_msg_template: "Brew formula update for {{ .ProjectName }} version {{ .Tag }}" | ||
homepage: "https://github.com/defenseunicorns/maru-runner" | ||
description: "CLI for Unicorn Delivery Service" | ||
|
||
# NOTE: We are using .Version instead of .Tag because homebrew has weird semver parsing rules and won't be able to | ||
# install versioned releases that has a `v` character before the version number. | ||
- name: "maru@{{ .Version }}" | ||
repository: | ||
owner: defenseunicorns | ||
name: homebrew-tap | ||
token: "{{ .Env.HOMEBREW_TAP_GITHUB_TOKEN }}" | ||
commit_msg_template: "Brew formula update for {{ .ProjectName }} versioned release {{ .Tag }}" | ||
homepage: "https://github.com/defenseunicorns/maru-runner" | ||
description: "unicorn-flavored build tool" | ||
|
||
# Generate a GitHub release and publish the release for the tag | ||
release: | ||
github: | ||
owner: defenseunicorns | ||
name: maru | ||
prerelease: auto | ||
mode: append | ||
draft: false |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters