mirror of
https://github.com/danielmiessler/Fabric.git
synced 2026-01-09 22:38:10 -05:00
- Add garble tool installation to release workflow - Configure garble obfuscation for Windows builds only - Fix changelog walker to handle unreleased commits - Update changelog database with latest changes - Add mvdan to VSCode dictionary settings - Implement boundary detection for released vs unreleased - Keep newer commits as "Unreleased" until tagged
53 lines
1.4 KiB
YAML
53 lines
1.4 KiB
YAML
# Read the documentation at https://goreleaser.com
|
|
|
|
version: 2
|
|
|
|
project_name: fabric
|
|
before:
|
|
hooks:
|
|
# You may remove this if you don't use go modules.
|
|
- go mod tidy
|
|
# you may remove this if you don't need go generate
|
|
# - go generate ./...
|
|
|
|
builds:
|
|
- id: default
|
|
env:
|
|
- CGO_ENABLED=0
|
|
goos:
|
|
- darwin
|
|
- linux
|
|
main: ./cmd/fabric
|
|
binary: fabric
|
|
- id: windows-garbled
|
|
env:
|
|
- CGO_ENABLED=0
|
|
goos:
|
|
- windows
|
|
main: ./cmd/fabric
|
|
binary: fabric
|
|
tool: garble
|
|
# From https://github.com/eyevanovich/garble-goreleaser-example/blob/main/.goreleaser.yaml
|
|
# command is a single string.
|
|
# garble's 'build' needs the -literals and -tiny args before it, so we
|
|
# trick goreleaser into using -literals as command, and pass -tiny and
|
|
# build as flags.
|
|
command: "-literals"
|
|
flags: [ "-tiny", "-seed=random", "build" ]
|
|
ldflags: [ "-s", "-w" ]
|
|
|
|
archives:
|
|
- formats: [tar.gz]
|
|
# this name template makes the OS and Arch compatible with the results of `uname`.
|
|
name_template: >-
|
|
{{ .ProjectName }}_
|
|
{{- title .Os }}_
|
|
{{- if eq .Arch "amd64" }}x86_64
|
|
{{- else if eq .Arch "386" }}i386
|
|
{{- else }}{{ .Arch }}{{ end }}
|
|
{{- if .Arm }}v{{ .Arm }}{{ end }}
|
|
# use zip for windows archives
|
|
format_overrides:
|
|
- goos: windows
|
|
formats: [zip]
|