Skip to content

Commit

Permalink
add a version field to buoy version output that uses the mod version
Browse files Browse the repository at this point in the history
Signed-off-by: everettraven <[email protected]>
  • Loading branch information
everettraven committed Dec 8, 2023
1 parent eddcdd1 commit 12fef01
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions internal/cli/version.go
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@ var versionCommand = &cobra.Command{
out.WriteString(header + "\n\n")
settingNameStyle := lipgloss.NewStyle().Bold(true)
if bi, ok := debug.ReadBuildInfo(); ok {
out.WriteString(fmt.Sprintf("%s: %s\n\n", settingNameStyle.Render("version"), bi.Main.Version))
for _, setting := range bi.Settings {
name := settingNameStyle.Render(setting.Key)
out.WriteString(fmt.Sprintf("%s: %s\n", name, setting.Value))
Expand Down

0 comments on commit 12fef01

Please sign in to comment.