Skip to content

Commit

Permalink
add v2 scripts as separate archive in releases
Browse files Browse the repository at this point in the history
  • Loading branch information
consolethinks committed Jun 28, 2024
1 parent 54788c0 commit c817113
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 33 deletions.
46 changes: 13 additions & 33 deletions .goreleaser.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
# Now you can run GoReleaser at the root of your repository: `goreleaser release`
# For dry run, see https://goreleaser.com/quick-start/#dry-run

version: 1
version: 2

before:
hooks:
Expand All @@ -31,32 +31,16 @@ builds:
dir: ./cmd/
goos:
- linux
- darwin
goarch:
- amd64
main: .
binary: scicat-cli
- id: "scicat-cli-win"
flags:
- -trimpath
ldflags:
- "-s -w -X 'github.com/paulscherrerinstitute/scicat/cmd/commands.VERSION={{.Version}}'"
env:
- CGO_ENABLED=0
dir: ./cmd/
goos:
- windows
- darwin
goarch:
- amd64
main: .
binary: scicat-cli


archives:
- id: scicat-cli
format: tar.gz
builds:
- scicat-cli
- format: tar.gz
wrap_in_directory: true
name_template: >-
{{ .ProjectName }}_
Expand All @@ -66,23 +50,19 @@ archives:
{{- else if eq .Arch "386" }}i386
{{- else }}{{ .Arch }}{{ end }}
{{- if .Arm }}v{{ .Arm }}{{ end }}
# use zip for windows archives
format_overrides:
- goos: windows
format: zip
- id: scicat-cli-scripts
format: tar.gz
wrap_in_directory: true
name_template: >-
{{ .ProjectName }}_V2Scripts_{{- .Version }}
files:
- src: cmd/scripts/*
strip_parent: true
- id: scicat-cli-win
format: zip
builds:
- scicat-cli-win
wrap_in_directory: true
name_template: >-
{{ .ProjectName }}_
{{- .Version }}_
{{- title .Os }}_
{{- if eq .Arch "amd64" }}x86_64
{{- else if eq .Arch "386" }}i386
{{- else }}{{ .Arch }}{{ end }}
{{- if .Arm }}v{{ .Arm }}{{ end }}
meta: true
changelog:
sort: asc
filters:
Expand Down
Binary file removed cmd/scripts/scicat-cli
Binary file not shown.

0 comments on commit c817113

Please sign in to comment.