Skip to content

Commit

Permalink
set version during build
Browse files Browse the repository at this point in the history
  • Loading branch information
crhuber committed May 16, 2024
1 parent a8d24ef commit 4f07b01
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 2 deletions.
3 changes: 3 additions & 0 deletions .goreleaser.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -10,3 +10,6 @@ builds:
goarm:
- 6
- 7

ldflags:
- -s -w -X main.Version={{.Version}}
4 changes: 2 additions & 2 deletions main.go
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ import (
"github.com/urfave/cli/v2"
)

var version = "1.12.6"
var Version = "dev"

func main() {

Expand All @@ -24,7 +24,7 @@ func main() {

app := &cli.App{
Name: "kelp",
Version: version,
Version: Version,
Flags: []cli.Flag{
&cli.StringFlag{
Name: "config",
Expand Down

0 comments on commit 4f07b01

Please sign in to comment.