Skip to content

fix(antigravity): stabilize config injection paths across variants and enforce engram tool profile #779

@mgaldamez

Description

@mgaldamez

Pre-flight Checklist

  • I have searched existing issues and this is not a duplicate
  • I understand that PRs will be rejected if the linked issue does not have status:approved

📝 Bug Description

The current Antigravity integration suffers from two primary issues during the gentle-ai install, gentle-ai sync, and uninstall processes:

  1. Path Injection & OS-Specific Paths: The integration failed to resolve and synchronize configuration files to standard OS-specific directories for desktop/IDE GUI variants on Linux (~/.config/), macOS (~/Library/Application Support/), and Windows (AppData\Roaming\). Furthermore, if the syncing/installation logic iterates over all potential configuration directories unconditionally without verifying their physical existence (via os.Stat), it creates empty folders for variants that aren't actually installed on the system. The uninstall process also failed to dynamically clean up all active paths.
  2. Missing Engram Profile: The injected Engram MCP configuration intentionally omitted the --tools=agent flag exclusively for Antigravity. Without this explicit profile, the Antigravity orchestrator fails to expose critical persistent memory tools (mem_save, mem_search, etc.) natively to the agent session ("unknown tool name").

🔄 Steps to Reproduce

1. Path Sync & OS-Specific Directories (Linux/macOS/Windows GUI Variants):

  1. On a Linux, macOS, or Windows system, install a GUI variant of Google Antigravity (e.g., Antigravity IDE, which configures settings under ~/.config/Antigravity IDE, ~/Library/Application Support/Antigravity IDE, or AppData\Roaming\Antigravity IDE).
  2. Run gentle-ai install --agent antigravity or gentle-ai sync --agent antigravity.
  3. Check the IDE's configuration directory — notice that no configurations, skills, or plugins are synchronized because the system only target paths under ~/.gemini/.

2. Path Injection Idempotency (Unconditional Folder Creation):

  1. Have only antigravity-cli installed on the host system (residing under ~/.gemini/antigravity-cli).
  2. If the integration loops over all candidate paths unconditionally to synchronize configurations, run gentle-ai install --agent antigravity.
  3. Check ~/.gemini/ — notice that empty folders for other variants (like ~/.gemini/antigravity-ide) are created unconditionally.

3. Engram Profile:

  1. Run gentle-ai install --agent antigravity --component engram.
  2. Inspect the injected MCP config at ~/.gemini/antigravity-cli/plugins/gentle-ai-engram/mcp_config.json.
  3. Notice the command arguments are just ["mcp"] instead of ["mcp", "--tools=agent"].
  4. Start an Antigravity session — the agent lacks native access to mem_* tools.

✅ Expected Behavior

  • Path Injection: The install and sync pipelines should use os.Stat to validate if an Antigravity variant directory exists before injecting configurations (skills, SDD, MCP, plugins), falling back to antigravity-cli only if none exist. Uninstaller should clean all valid paths across OS-specific configurations dynamically.
  • Engram Profile: Antigravity should receive the exact same --tools=agent profile configuration as the other IDEs.

❌ Actual Behavior

Unconditional directory creation litters the user's home folder with empty configuration paths, desktop/IDE variants on Linux/macOS/Windows do not receive settings/plugins, and the missing --tools=agent flag breaks native MCP memory functionality.

Gentle AI Version

v1.36.6

Operating System

Linux (Fedora/RHEL) / macOS / Windows

AI Agent / Client

Other

📋 Affected Area

Agent Detection

💡 Logs / Error Output

Additional Context

This fix is necessary due to the recent Google release structuring for Antigravity 2.0. They replaced the legacy Antigravity 1.x with the new antigravity-ide 2.x and introduced antigravity-cli as a standalone component.

Because each variant (Desktop, IDE, CLI, and Config) now uses its own distinct configuration path depending on the OS, our injection logic needs to be resilient enough to validate which variants are actually installed on the user's host instead of blindly creating directories for all of them.

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't workingstatus:needs-reviewAwaiting maintainer review

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions