Skip to content

Commit

Permalink
version cmd: move tree state into git sha line
Browse files Browse the repository at this point in the history
Signed-off-by: Steve Kriss <[email protected]>
  • Loading branch information
skriss committed Dec 7, 2018
1 parent ac317a8 commit 246d758
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 7 deletions.
2 changes: 1 addition & 1 deletion .github/ISSUE_TEMPLATE/bug_report.md
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ about: Tell us about a problem you are experiencing

**Environment:**

- Ark version (use `ark version`):
- Ark version (use `ark version`):
- Kubernetes version (use `kubectl version`):
- Kubernetes installer & version:
- Cloud provider or hardware configuration:
Expand Down
6 changes: 2 additions & 4 deletions pkg/cmd/cli/bug/bug.go
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ about: Tell us about a problem you are experiencing
**Environment:**
- Ark version (use ` + "`ark version`" + `):{{.ArkVersion}} {{.GitCommit}} {{.GitTreeState}}
- Ark version (use ` + "`ark version`" + `):{{.ArkVersion}} {{.GitCommit}}
- Kubernetes version (use ` + "`kubectl version`" + `):
{{- if .KubectlVersion}}
` + "```" + `
Expand Down Expand Up @@ -109,7 +109,6 @@ func NewCommand() *cobra.Command {
type ArkBugInfo struct {
ArkVersion string
GitCommit string
GitTreeState string
RuntimeOS string
RuntimeArch string
KubectlVersion string
Expand Down Expand Up @@ -162,8 +161,7 @@ func getKubectlVersion() (string, error) {
func newBugInfo(kubectlVersion string) *ArkBugInfo {
return &ArkBugInfo{
ArkVersion: buildinfo.Version,
GitCommit: buildinfo.GitSHA,
GitTreeState: buildinfo.GitTreeState,
GitCommit: buildinfo.FormattedGitSHA(),
RuntimeOS: runtime.GOOS,
RuntimeArch: runtime.GOARCH,
KubectlVersion: kubectlVersion}
Expand Down
3 changes: 1 addition & 2 deletions pkg/cmd/version/version.go
Original file line number Diff line number Diff line change
Expand Up @@ -30,8 +30,7 @@ func NewCommand() *cobra.Command {
Short: "Print the ark version and associated image",
Run: func(cmd *cobra.Command, args []string) {
fmt.Printf("Version: %s\n", buildinfo.Version)
fmt.Printf("Git commit: %s\n", buildinfo.GitSHA)
fmt.Printf("Git tree state: %s\n", buildinfo.GitTreeState)
fmt.Printf("Git commit: %s\n", buildinfo.FormattedGitSHA())
},
}

Expand Down

0 comments on commit 246d758

Please sign in to comment.