Fix formatting in update message for current version#18
Open
chitralverma wants to merge 1 commit intoDeusData:mainfrom
Open
Fix formatting in update message for current version#18chitralverma wants to merge 1 commit intoDeusData:mainfrom
chitralverma wants to merge 1 commit intoDeusData:mainfrom
Conversation
There was a problem hiding this comment.
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
vonto 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
versionand can already include a leading "v", users can still see "vv0.x.y" in the update-available path. Consider normalizingcurrentVersionto 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.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
shows version with double v currently