Skip to content

fix(cli): align mcp existing server advice#348

Open
OnlyYu1996 wants to merge 1 commit into
CortexLM:mainfrom
OnlyYu1996:fix-mcp-existing-server-advice
Open

fix(cli): align mcp existing server advice#348
OnlyYu1996 wants to merge 1 commit into
CortexLM:mainfrom
OnlyYu1996:fix-mcp-existing-server-advice

Conversation

@OnlyYu1996
Copy link
Copy Markdown

Fixes inconsistent advice when cortex mcp rename targets an existing MCP server.

Bounty issue: PlatformNetwork/bounty-challenge#53102

Changes:

  • Share the existing-server conflict advice between mcp add and mcp rename.
  • Add mcp rename --force / -f so the advice points to a working overwrite path.
  • Cover clap command validity and rename force parsing with tests.
  • Keep the current main test import fix needed for cortex-cli tests/checks to pass.

Validation:

  • cargo +stable fmt --package cortex-cli --check
  • cargo +stable test --package cortex-cli mcp_cmd::types::tests::test_mcp_cli_command_aliases_are_valid -- --nocapture
  • cargo +stable test --package cortex-cli mcp_cmd:: -- --nocapture
  • cargo +stable check --package cortex-cli --lib
  • cargo +stable build --package cortex-cli --bin Cortex
  • real CLI smoke for add conflict, rename conflict, and rename --force
  • git diff --check

Copy link
Copy Markdown

@greptile-apps greptile-apps Bot left a comment

Choose a reason for hiding this comment

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

Your free trial has ended. If you'd like to continue receiving code reviews, you can add a payment method here.

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.

1 participant