app
adom-vscode
Public Made by Adomby adom
Let Claude, Codex and Kimi drive VS Code inside your Adom container
← Commit history
install.sh+20−9@@ -1,15 +1,25 @@ #!/usr/bin/env bash # adompkg install script for adom-vscode. #-# Drops the binary into ~/.local/bin (matches every other adompkg CLI —-# adom-google, adom-mouser, adom-tts, the parts CLIs — so no `--allow-sudo`-# needed). Then runs `adom-vscode install` to register the VS Code extension-# with code-server, fetch SKILL.md, install bash completions, and patch the-# paste-screenshot interceptor into workbench.html.+# This script runs as the regular user — `needs_sudo: false` in package.json,+# matching every other adompkg CLI (adom-google, adom-mouser, adom-tts, the+# parts CLIs, etc.). The binary goes into ~/.local/bin so daemon-managed+# updates never need a sudo gate. #-# The workbench.html patch is the only step that touches a root-owned path;-# it's idempotent (re-runs return "Browser scripts already up to date") so-# daemon-managed updates after the initial bake are pure user-space refreshes.+# The CLI itself (`adom-vscode install`, invoked at the bottom of this script)+# will SELF-ELEVATE to sudo for the one step that truly needs root — patching+# /usr/lib/code-server/lib/vscode/.../workbench.html to install the+# paste-screenshot interceptor that lets users Ctrl+V images into a Claude CLI+# terminal. That patch is idempotent (re-runs return "Browser scripts already+# up to date") so most installs never invoke sudo at all; only the first patch+# (or one that follows a code-server upgrade that overwrote workbench.html, or+# one that follows a PASTE_SCREENSHOT_JS change) actually shells `sudo cp`.+#+# Self-elevation is safe here because adom-vscode is an Adom-container-only+# tool, and Adom containers grant the user passwordless sudo by design.+# Hooking into workbench.html is load-bearing for the Claude CLI image-paste+# UX — and any future browser-side instrumentation we want to add into+# code-server's main HTML load — so we keep it explicit rather than degrade. set -euo pipefail @@ -26,10 +36,11 @@ mkdir -p "$(dirname "$BIN_DST")" install -m 0755 "$BIN_SRC" "$BIN_DST" echo "Installed adom-vscode -> $BIN_DST" -# Sanity check $PATH so users actually pick up the new binary. case ":${PATH}:" in *":${HOME}/.local/bin:"*) ;; *) echo "Note: $HOME/.local/bin is not on PATH. Add: export PATH=\"\$HOME/.local/bin:\$PATH\"" ;; esac +# The CLI handles the rest, including self-elevating to sudo for the+# workbench.html patch (see inject_browser_scripts in cli/src/main.rs). "$BIN_DST" install
package.json+1−1@@ -1,6 +1,6 @@ { "slug": "adom-vscode",- "version": "4.0.8",+ "version": "4.0.9", "type": "app", "description": "CLI + VS Code extension that lets AI assistants drive VS Code from inside an Adom Docker container \u2014 open files, switch modes, paste screenshots, and run any VS Code command via a local HTTP API on port 8821.", "license": "PROPRIETARY",