Skip to content

Fix formatting in update message for current version#18

Open
chitralverma wants to merge 1 commit intoDeusData:mainfrom
chitralverma:patch-2
Open

Fix formatting in update message for current version#18
chitralverma wants to merge 1 commit intoDeusData:mainfrom
chitralverma:patch-2

Conversation

@chitralverma
Copy link

shows version with double v currently

codebase-memory-mcp v0.3.4 — checking for updates...
Already up to date (vv0.3.4).

Copilot AI review requested due to automatic review settings March 4, 2026 07:24
Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR adjusts the CLI self-update messaging to avoid displaying the current version with a duplicated v prefix when reporting that the binary is already up to date.

Changes:

  • Update the “Already up to date …” message formatting to avoid prefixing v onto a version string that may already include it.
Comments suppressed due to low confidence (1)

cmd/codebase-memory-mcp/update.go:57

  • This fixes the double-"v" in the "Already up to date" message, but other output in this same function still prefixes "v" onto currentVersion (e.g., "Update available: v%s → v%s"). Since currentVersion is derived from version and can already include a leading "v", users can still see "vv0.x.y" in the update-available path. Consider normalizing currentVersion to a bare semver (strip a leading "v") for comparisons/printing, or stop adding an extra "v" when printing the current version so all messages are consistent.
		fmt.Printf("Already up to date (%s).\n", currentVersion)

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants