Skip to content

Commit dc17383

Browse files
author
Enda
authored
ci: automate CLI versioning (#154)
1 parent af354c8 commit dc17383

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

.goreleaser.yml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,8 @@ builds:
99
- main: ./cmd/rhoas/main.go
1010
id: rhoas_cli
1111
binary: rhoas
12+
ldflags:
13+
- -s -w -X github.com/bf2fc6cc711aee1a0c2a/cli/pkg/version.CLI_VERSION={{.Version}}
1214
goos:
1315
- linux
1416
- windows

pkg/version/version.go

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,4 @@
11
package version
22

3-
/**
4-
* Version for the cli used in various places.
5-
*/
6-
const CLI_VERSION = "0.6.0" // nolint
3+
// CLI_VERSION is the version for the cli used in various places
4+
var CLI_VERSION = "development" // nolint

0 commit comments

Comments
 (0)