diff --git a/bin/omarchy-remove-ai-antigravity b/bin/omarchy-remove-ai-antigravity new file mode 100755 index 000000000000..e1ffde8816e0 --- /dev/null +++ b/bin/omarchy-remove-ai-antigravity @@ -0,0 +1,24 @@ +#!/bin/bash + +# omarchy:summary=Remove the Antigravity desktop app along with its configuration and caches. +# omarchy:requires-sudo=true + +# -u so an unset HOME is an error rather than a set of rm -rf paths rooted at /. +set -euo pipefail + +# The app rewrites its config directory for as long as it runs, so a removal +# that leaves it running deletes the directory and watches it come straight back. +pkill -x antigravity || true + +omarchy-pkg-drop antigravity + +# Not ~/.gemini/antigravity, ~/.gemini/antigravity-cli, or ~/.gemini/config: +# those hold Antigravity CLI (agy) state, shared skills, and user data that +# outlive the desktop app. The desktop app pins its Electron state to +# ~/.config/Antigravity, and its updater caches beside it. +rm -rf \ + "$HOME/.config/Antigravity" \ + "$HOME/.cache/antigravity-updater" + +echo "" +echo "Antigravity has been removed." diff --git a/default/i18n/en/menu.json b/default/i18n/en/menu.json index fde230fa9665..1f83da143500 100644 --- a/default/i18n/en/menu.json +++ b/default/i18n/en/menu.json @@ -886,6 +886,9 @@ "install.ai.amp": { "label": "Amp Desktop" }, + "install.ai.antigravity": { + "label": "Antigravity Desktop" + }, "install.ai.chatgpt": { "label": "ChatGPT Desktop" }, @@ -1120,6 +1123,9 @@ "remove.ai.amp": { "label": "Amp Desktop" }, + "remove.ai.antigravity": { + "label": "Antigravity Desktop" + }, "remove.ai.chatgpt": { "label": "ChatGPT Desktop" }, diff --git a/default/omarchy/omarchy-menu.jsonc b/default/omarchy/omarchy-menu.jsonc index b58b846b43c9..a772cc16fa4d 100644 --- a/default/omarchy/omarchy-menu.jsonc +++ b/default/omarchy/omarchy-menu.jsonc @@ -333,6 +333,7 @@ "install.terminal.ghostty": {"icon":"","label":"Ghostty","disabled":"omarchy-pkg-present ghostty","action":"omarchy-launch-floating-terminal-with-presentation 'omarchy-install-terminal ghostty'"}, "install.terminal.kitty": {"icon":"","label":"Kitty","disabled":"omarchy-pkg-present kitty","action":"omarchy-launch-floating-terminal-with-presentation 'omarchy-install-terminal kitty'"}, "install.ai.amp": {"icon":"","iconFont":"omarchy","label":"Amp Desktop","disabled":"omarchy-pkg-present amp-desktop-bin","action":"omarchy-install-and-launch 'Amp Desktop' amp-desktop-bin amp-desktop"}, + "install.ai.antigravity": {"icon":"","iconFont":"omarchy","label":"Antigravity Desktop","disabled":"omarchy-pkg-present antigravity","action":"omarchy-install-and-launch 'Antigravity Desktop' antigravity antigravity"}, "install.ai.chatgpt": {"icon":"","iconFont":"omarchy","label":"ChatGPT Desktop","disabled":"omarchy-pkg-present openai-codex-desktop","action":"omarchy-launch-floating-terminal-with-presentation omarchy-install-ai-chatgpt"}, "install.ai.claude": {"icon":"","iconFont":"omarchy","label":"Claude Desktop","disabled":"omarchy-pkg-present claude-desktop","action":"omarchy-launch-floating-terminal-with-presentation omarchy-install-ai-claude"}, "install.ai.grok-bot": {"icon":"","iconFont":"omarchy","label":"Grok Bot","disabled":"omarchy-pkg-present grok-bot","action":"omarchy-install-and-launch 'Grok Bot' grok-bot grok-bot"}, @@ -412,6 +413,7 @@ "remove.service.microsoft": {"icon":"󰍲","label":"Microsoft","when":"[[ -f \"$HOME/.local/share/applications/Microsoft Outlook.desktop\" || -f \"$HOME/.local/share/applications/Microsoft Word.desktop\" || -f \"$HOME/.local/share/applications/Microsoft Excel.desktop\" || -f \"$HOME/.local/share/applications/Microsoft PowerPoint.desktop\" || -f \"$HOME/.local/share/applications/Microsoft Teams.desktop\" || -f \"$HOME/.local/share/applications/Microsoft OneDrive.desktop\" ]]","action":"omarchy-launch-floating-terminal-with-presentation omarchy-remove-service-microsoft"}, "remove.service.ssh-agent": {"icon":"󰣀","label":"SSH Agent","when":"systemctl --user -q is-enabled gcr-ssh-agent.socket","action":"omarchy-launch-floating-terminal-with-presentation omarchy-remove-service-ssh-agent"}, "remove.ai.amp": {"icon":"","iconFont":"omarchy","label":"Amp Desktop","when":"omarchy-pkg-present amp-desktop-bin","action":"omarchy-launch-floating-terminal-with-presentation omarchy-remove-ai-amp"}, + "remove.ai.antigravity": {"icon":"","iconFont":"omarchy","label":"Antigravity Desktop","when":"omarchy-pkg-present antigravity","action":"omarchy-launch-floating-terminal-with-presentation omarchy-remove-ai-antigravity"}, "remove.ai.chatgpt": {"icon":"","iconFont":"omarchy","label":"ChatGPT Desktop","when":"omarchy-pkg-present openai-codex-desktop","action":"omarchy-launch-floating-terminal-with-presentation omarchy-remove-ai-chatgpt"}, "remove.ai.claude": {"icon":"","iconFont":"omarchy","label":"Claude Desktop","when":"omarchy-pkg-present claude-desktop","action":"omarchy-launch-floating-terminal-with-presentation omarchy-remove-ai-claude"}, "remove.dictation.hex": {"icon":"","label":"Hex","when":"omarchy-pkg-present hex-bin","action":"omarchy-launch-floating-terminal-with-presentation omarchy-remove-dictation-hex"}, diff --git a/manual/17-ai.md b/manual/17-ai.md index bb94b4d5b430..0745a45b7754 100644 --- a/manual/17-ai.md +++ b/manual/17-ai.md @@ -88,7 +88,7 @@ Crashes can also be silenced one program at a time, which is what the diagnosis ### Desktop apps -The _Install > AI_ menu also carries a few graphical AI apps: the ChatGPT desktop app, the Claude desktop app (Anthropic's Linux beta, with Chat, Cowork, and Claude Code tabs), Grok Bot for chatting with xAI's models, Herdr Desktop, Hermes Desktop, OpenClaw, the Perplexity desktop app, and T3 Code. Grok Bot is the desktop chat app. The coding agent is the `grok` command. +The _Install > AI_ menu also carries a few graphical AI apps: Antigravity Desktop, the ChatGPT desktop app, the Claude desktop app (Anthropic's Linux beta, with Chat, Cowork, and Claude Code tabs), Grok Bot for chatting with xAI's models, Herdr Desktop, Hermes Desktop, OpenClaw, the Perplexity desktop app, and T3 Code. Grok Bot is the desktop chat app. The coding agent is the `grok` command. Hermes Desktop is the one to know about, because a machine has one Hermes, and it is the app's: Hermes is only ever installed through the app, and the `hermes` command the default agent runs is the app's. Choosing Hermes as the default agent installs the same thing the _Install > AI_ entry does: the package, and a Hermes runtime under `~/.hermes` set up by Hermes' own installer, which takes a few minutes the first time. That runtime is the one Hermes the terminal `hermes` command, the default agent and the app all use, and it updates itself with `hermes update` rather than waiting on an Omarchy release. Installing it also hands Hermes the Omarchy theme as a skin named `omarchy`, which every Hermes surface follows as you switch themes; pick another under Hermes' Appearance settings or with `/skin` if you'd rather it didn't, and Omarchy leaves that choice alone. Removing the app under _Remove > AI_ closes Hermes first, gateway included, takes that runtime with it, and keeps your chats, memories, and the skills Hermes wrote for itself unless you tell it otherwise: it asks, defaulting to no, whether that data and your connection settings should go too. diff --git a/test/shell.d/remove-ai-test.sh b/test/shell.d/remove-ai-test.sh index be69425e9a82..bf3bd7882635 100644 --- a/test/shell.d/remove-ai-test.sh +++ b/test/shell.d/remove-ai-test.sh @@ -449,3 +449,27 @@ fi fail "OpenClaw removal drops a service's restart record with the service, before anything else can fail" mv "$tmp_dir/omarchy-pkg-drop.real" "$tmp_dir/bin/omarchy-pkg-drop" pass "OpenClaw removal drops a service's restart record with the service, before anything else can fail" + +# Antigravity CLI (agy) state and shared skills live under ~/.gemini, while +# the desktop app keeps its Electron state in ~/.config/Antigravity. +: >"$TEST_LOG" +fresh_home +mkdir -p "$HOME/.config/Antigravity" "$HOME/.cache/antigravity-updater" \ + "$HOME/.gemini/antigravity" "$HOME/.gemini/antigravity-cli" "$HOME/.gemini/config" +"$ROOT/bin/omarchy-remove-ai-antigravity" >/dev/null + +for gone in .config/Antigravity .cache/antigravity-updater; do + [[ ! -e $HOME/$gone ]] || fail "Antigravity removal deletes the desktop app's config and caches" "$gone" +done +pass "Antigravity removal deletes the desktop app's config and caches" + +for kept in .gemini/antigravity .gemini/antigravity-cli .gemini/config; do + [[ -d $HOME/$kept ]] || fail "Antigravity removal keeps ~/.gemini CLI and shared data" "$kept" +done +pass "Antigravity removal keeps ~/.gemini CLI and shared data" + +grep -qx 'pkill:-x antigravity' "$TEST_LOG" || fail "Antigravity removal quits the running app before deleting its state" +pass "Antigravity removal quits the running app before deleting its state" + +grep -qx 'drop:antigravity' "$TEST_LOG" || fail "Antigravity removal drops the antigravity package" +pass "Antigravity removal drops the antigravity package"