Skip to content

Commit

Permalink
Fix skywire verson in goreleaser
Browse files Browse the repository at this point in the history
The .Version variable in the goreleaser yaml file gives the version without the v. So we are adding the v manually in ldflags of all the binaries just like the name_template.
  • Loading branch information
ersonp committed Oct 26, 2021
1 parent 5638eb0 commit 1adeabb
Showing 1 changed file with 7 additions and 7 deletions.
14 changes: 7 additions & 7 deletions .goreleaser.yml
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ builds:
env:
- CGO_ENABLED=0
main: ./cmd/skywire-visor/
ldflags: -s -w -X github.com/skycoin/dmsg/buildinfo.version={{.Version}} -X github.com/skycoin/dmsg/buildinfo.commit={{.ShortCommit}} -X github.com/skycoin/dmsg/buildinfo.date={{.Date}} -X github.com/skycoin/skywire/pkg/visor.BuildTag=skybian
ldflags: -s -w -X github.com/skycoin/dmsg/buildinfo.version=v{{.Version}} -X github.com/skycoin/dmsg/buildinfo.commit={{.ShortCommit}} -X github.com/skycoin/dmsg/buildinfo.date={{.Date}} -X github.com/skycoin/skywire/pkg/visor.BuildTag=skybian

- id: skywire-cli
binary: skywire-cli
Expand All @@ -53,7 +53,7 @@ builds:
env:
- CGO_ENABLED=0
main: ./cmd/skywire-cli/
ldflags: -s -w -X github.com/skycoin/dmsg/buildinfo.version={{.Version}} -X github.com/skycoin/dmsg/buildinfo.commit={{.ShortCommit}} -X github.com/skycoin/dmsg/buildinfo.date={{.Date}}
ldflags: -s -w -X github.com/skycoin/dmsg/buildinfo.version=v{{.Version}} -X github.com/skycoin/dmsg/buildinfo.commit={{.ShortCommit}} -X github.com/skycoin/dmsg/buildinfo.date={{.Date}}

- id: skychat
binary: apps/skychat
Expand All @@ -73,7 +73,7 @@ builds:
env:
- CGO_ENABLED=0
main: ./cmd/apps/skychat/
ldflags: -s -w -X github.com/skycoin/dmsg/buildinfo.version={{.Version}} -X github.com/skycoin/dmsg/buildinfo.commit={{.ShortCommit}} -X github.com/skycoin/dmsg/buildinfo.date={{.Date}}
ldflags: -s -w -X github.com/skycoin/dmsg/buildinfo.version=v{{.Version}} -X github.com/skycoin/dmsg/buildinfo.commit={{.ShortCommit}} -X github.com/skycoin/dmsg/buildinfo.date={{.Date}}

- id: skysocks
binary: apps/skysocks
Expand All @@ -93,7 +93,7 @@ builds:
env:
- CGO_ENABLED=0
main: ./cmd/apps/skysocks/
ldflags: -s -w -X github.com/skycoin/dmsg/buildinfo.version={{.Version}} -X github.com/skycoin/dmsg/buildinfo.commit={{.ShortCommit}} -X github.com/skycoin/dmsg/buildinfo.date={{.Date}}
ldflags: -s -w -X github.com/skycoin/dmsg/buildinfo.version=v{{.Version}} -X github.com/skycoin/dmsg/buildinfo.commit={{.ShortCommit}} -X github.com/skycoin/dmsg/buildinfo.date={{.Date}}
- id: skysocks-client
binary: apps/skysocks-client
goos:
Expand All @@ -112,7 +112,7 @@ builds:
env:
- CGO_ENABLED=0
main: ./cmd/apps/skysocks-client/
ldflags: -s -w -X github.com/skycoin/dmsg/buildinfo.version={{.Version}} -X github.com/skycoin/dmsg/buildinfo.commit={{.ShortCommit}} -X github.com/skycoin/dmsg/buildinfo.date={{.Date}}
ldflags: -s -w -X github.com/skycoin/dmsg/buildinfo.version=v{{.Version}} -X github.com/skycoin/dmsg/buildinfo.commit={{.ShortCommit}} -X github.com/skycoin/dmsg/buildinfo.date={{.Date}}
- id: vpn-server
binary: apps/vpn-server
goos:
Expand All @@ -131,7 +131,7 @@ builds:
env:
- CGO_ENABLED=0
main: ./cmd/apps/vpn-server/
ldflags: -s -w -X github.com/skycoin/dmsg/buildinfo.version={{.Version}} -X github.com/skycoin/dmsg/buildinfo.commit={{.ShortCommit}} -X github.com/skycoin/dmsg/buildinfo.date={{.Date}}
ldflags: -s -w -X github.com/skycoin/dmsg/buildinfo.version=v{{.Version}} -X github.com/skycoin/dmsg/buildinfo.commit={{.ShortCommit}} -X github.com/skycoin/dmsg/buildinfo.date={{.Date}}
- id: vpn-client
binary: apps/vpn-client
goos:
Expand All @@ -150,7 +150,7 @@ builds:
env:
- CGO_ENABLED=0
main: ./cmd/apps/vpn-client/
ldflags: -s -w -X github.com/skycoin/dmsg/buildinfo.version={{.Version}} -X github.com/skycoin/dmsg/buildinfo.commit={{.ShortCommit}} -X github.com/skycoin/dmsg/buildinfo.date={{.Date}}
ldflags: -s -w -X github.com/skycoin/dmsg/buildinfo.version=v{{.Version}} -X github.com/skycoin/dmsg/buildinfo.commit={{.ShortCommit}} -X github.com/skycoin/dmsg/buildinfo.date={{.Date}}
archives:
- format: tar.gz
wrap_in_directory: false
Expand Down

0 comments on commit 1adeabb

Please sign in to comment.