Skip to content

[dart_mcp_server] Support refactorings #300

@dcharkes

Description

@dcharkes

Gemini CLI takes quite a lot of time to rename private members to public members with text replacements. It would be much better to expose refactoring tools to in the MCP:

  • Rename symbol
  • Change modifiers of classes
  • Extract method (though then Gemini must provide the correct range selected)

Likely we'd need a separate tool for each refactoring in an MCP? (E.g. there are no sub-tools in MCP servers.) It looks like pub is set up with a command parameter. I have no idea whether LLMs perform better or worse with sub-commands. 🙃

And we'd need to specify in the tool-description that the refactoring tools likely only work if dart_analyze tool doesn't report any errors.

@jakemac53 Have we considered adding support for refactorings in the Dart MCP?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions