Add npx wrapper installer for packages moving too fast for normal repos

They're lazy loaded too. So we don't need manual install from a menu.
This commit is contained in:
David Heinemeier Hansson
2026-03-15 19:11:43 +01:00
parent 506348ef4b
commit e294394b8a
6 changed files with 33 additions and 8 deletions
+1 -6
View File
@@ -355,13 +355,8 @@ show_install_ai_menu() {
echo ollama
)
case $(menu "Install" " Dictation\n󱚤 Claude Code\n󱚤 Codex\n󱚤 Gemini CLI\n󱚤 Copilot CLI\n󱚤 Cursor CLI\n󱚤 LM Studio\n󱚤 Ollama\n󱚤 Crush") in
case $(menu "Install" " Dictation\n󱚤 LM Studio\n󱚤 Ollama\n󱚤 Crush") in
*Dictation*) present_terminal omarchy-voxtype-install ;;
*Claude*) install "Claude Code" "claude-code" ;;
*Codex*) install "Codex" "openai-codex" ;;
*Gemini*) install "Gemini CLI" "gemini-cli" ;;
*Copilot*) install "Copilot CLI" "github-copilot-cli" ;;
*Cursor*) install "Cursor CLI" "cursor-cli" ;;
*Studio*) install "LM Studio" "lmstudio-bin" ;;
*Ollama*) install "Ollama" $ollama_pkg ;;
*Crush*) install "Crush" "crush-bin" ;;
+22
View File
@@ -0,0 +1,22 @@
#!/bin/bash
# Install an npx wrapper for a given npm package.
# Usage: omarchy-npx-install <package> [command-name]
#
# If command-name is omitted, it defaults to the package name.
# Example: omarchy-npx-install opencode-ai opencode
if [[ -z $1 ]]; then
echo "Usage: omarchy-npx-install <package> [command-name]"
exit 1
fi
package=$1
command=${2:-$1}
cat > "$HOME/.local/bin/$command" <<EOF
#!/bin/bash
exec npx --yes $package "\$@"
EOF
chmod +x "$HOME/.local/bin/$command"
-2
View File
@@ -16,7 +16,6 @@ brightnessctl
btop
chromium
clang
claude-code
cups
cups-browsed
cups-filters
@@ -92,7 +91,6 @@ obs-studio
obsidian
omarchy-nvim
omarchy-walker
opencode
pamixer
pinta
playerctl
+1
View File
@@ -4,6 +4,7 @@ run_logged $OMARCHY_INSTALL/packaging/nvim.sh
run_logged $OMARCHY_INSTALL/packaging/icons.sh
run_logged $OMARCHY_INSTALL/packaging/webapps.sh
run_logged $OMARCHY_INSTALL/packaging/tuis.sh
run_logged $OMARCHY_INSTALL/packaging/npx.sh
run_logged $OMARCHY_INSTALL/packaging/asus-rog.sh
run_logged $OMARCHY_INSTALL/packaging/framework16.sh
run_logged $OMARCHY_INSTALL/packaging/surface.sh
+6
View File
@@ -0,0 +1,6 @@
omarchy-npx-install @anthropic-ai/claude-code claude
omarchy-npx-install @openai/codex codex
omarchy-npx-install @google/gemini-cli gemini
omarchy-npx-install @github/copilot copilot
omarchy-npx-install opencode-ai opencode
omarchy-npx-install playwright-cli
+3
View File
@@ -0,0 +1,3 @@
echo "Install npx wrappers for AI CLI tools and playwright"
source "$OMARCHY_PATH/install/packaging/npx.sh"