-
Notifications
You must be signed in to change notification settings - Fork 2.3k
gopls/internal/mcp: add go_rename tool #585
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: master
Are you sure you want to change the base?
Conversation
This PR (HEAD: c9a4e51) has been imported to Gerrit for code review. Please visit Gerrit at https://go-review.googlesource.com/c/tools/+/694036. Important tips:
|
This tool uses the LSP server's Rename method to rename Go symbols (variables, functions, types, etc.) at a specified position. It supports both preview mode (dryRun: true, default) and actual application (dryRun: false) of changes across the workspace. - Add renameTool() and renameHandler() to the MCP server - Support dryRun parameter: true for preview, false to apply changes - Add TestMCPRename to test the tool for both dryRun modes - Update MCP instructions with go_rename usage examples for both modes Fixes golang/go#74887
c9a4e51
to
3f86730
Compare
Message from Gopher Robot: Patch Set 1: (1 comment) Please don’t reply on this GitHub thread. Visit golang.org/cl/694036. |
This PR (HEAD: 3f86730) has been imported to Gerrit for code review. Please visit Gerrit at https://go-review.googlesource.com/c/tools/+/694036. Important tips:
|
Message from Arjun Mahishi: Patch Set 1: (1 comment) Please don’t reply on this GitHub thread. Visit golang.org/cl/694036. |
Message from Robert Findley: Patch Set 2: (2 comments) Please don’t reply on this GitHub thread. Visit golang.org/cl/694036. |
Message from Arjun Mahishi: Patch Set 2: (2 comments) Please don’t reply on this GitHub thread. Visit golang.org/cl/694036. |
This tool uses the LSP server's Rename method to rename Go symbols
(variables, functions, types, etc.) at a specified position. It supports
both preview mode (dryRun: true, default) and actual application
(dryRun: false) of changes across the workspace.
Fixes golang/go#74887