Skip to content

fix: remove Antigravity MCP registration on uninstall - #144

Open
bobthecomputer wants to merge 1 commit into
monk-io:mainfrom
bobthecomputer:fix/antigravity-uninstall-registration
Open

fix: remove Antigravity MCP registration on uninstall#144
bobthecomputer wants to merge 1 commit into
monk-io:mainfrom
bobthecomputer:fix/antigravity-uninstall-registration

Conversation

@bobthecomputer

Copy link
Copy Markdown

Summary

  • Remove only mcpServers.monk from Antigravity's global MCP configuration during uninstall.
  • Remove mcpServers when the Monk entry was its final member.
  • Preserve unrelated MCP servers and top-level configuration.
  • Leave malformed JSON unchanged and print a warning instead of destroying the file.
  • Apply the fix to all three POSIX and all three PowerShell rendered uninstallers.
  • Add isolated Windows and POSIX regressions to the existing install E2E workflow.

Why

The launcher registers Monk in ~/.gemini/config/mcp_config.json, but the official uninstallers removed only the agent binary and data. Antigravity therefore retained a dead Monk MCP server after an apparently successful uninstall.

Fixes #27.

Validation

  • ./tests/uninstall-antigravity-mcp-windows.ps1
  • sh tests/uninstall-antigravity-mcp.sh under WSL
  • sh -n for all changed POSIX uninstallers and the new test
  • PowerShell AST parsing for all three rendered PowerShell uninstallers
  • git diff --check

Both test suites execute every rendered platform copy against isolated temporary homes and configurations. They verify unrelated data is preserved, the Monk registration is removed, an empty server container is removed, and malformed JSON remains byte-for-byte unchanged.

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.

[Bug bounty] official uninstall leaves Antigravity MCP registration active

1 participant