From 0778554984c091a72ec19fa5f4e1454d00f8052f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E9=9B=B7=E7=94=B5=E8=8A=BD=E8=A1=A3?= Date: Tue, 25 Aug 2026 10:55:45 -0400 Subject: [PATCH] Add Kimi Code and Deep Code to the default agent roster kimi installs through its official script rather than mise; deepcode rides the existing mise path as npm:@vegamo/deepcode-cli. Both gain launch branches and Default Agent menu entries, plus an AI Hub entry for provider combos (Kimi/DeepSeek/Z.AI/MiniMax over Claude Code) via the omarchycn setup wizard. Co-Authored-By: Claude Fable 5 Claude-Session: https://claude.ai/code/session_01QKxGW1raAWaqeU8WdHsMsp --- bin/omarchy-agent | 8 ++++++ bin/omarchy-default-agent | 39 +++++++++++++++++++++--------- default/omarchy/omarchy-menu.jsonc | 3 +++ 3 files changed, 38 insertions(+), 12 deletions(-) diff --git a/bin/omarchy-agent b/bin/omarchy-agent index 3c009460..4005dfbf 100755 --- a/bin/omarchy-agent +++ b/bin/omarchy-agent @@ -99,6 +99,14 @@ pi) command=(pi) [[ -n ${prompt:-} ]] && command+=("$prompt") ;; +kimi) + command=(kimi) + [[ -n ${prompt:-} ]] && command+=("$prompt") + ;; +deepcode) + command=(deepcode) + [[ -n ${prompt:-} ]] && command+=("$prompt") + ;; *) echo "Unsupported default agent: $agent" >&2 exit 1 diff --git a/bin/omarchy-default-agent b/bin/omarchy-default-agent index 1f89b765..d5358cd4 100755 --- a/bin/omarchy-default-agent +++ b/bin/omarchy-default-agent @@ -1,8 +1,8 @@ #!/bin/bash # omarchy:summary=Set and launch the default coding agent -# omarchy:args=[pi|omp|opencode|ori|claude|codex|grok|agy|copilot|crush] -# omarchy:examples=omarchy default agent | omarchy default agent codex | omarchy default agent claude +# omarchy:args=[pi|omp|opencode|ori|claude|codex|grok|agy|copilot|crush|kimi|deepcode] +# omarchy:examples=omarchy default agent | omarchy default agent codex | omarchy default agent kimi installing=false if [[ ${1:-} == "--install" ]]; then @@ -34,25 +34,40 @@ crush) agent="crush"; name="Crush" ;; grok) agent="grok"; name="Grok"; agent_package="npm:@xai-official/grok" ;; agy | antigravity | antigravity-cli | gemini | gemini-cli) agent="agy"; name="Antigravity"; agent_package="antigravity-cli" ;; copilot | github-copilot) agent="copilot"; name="GitHub Copilot" ;; +kimi | kimi-code) agent="kimi"; name="Kimi Code" ;; +deepcode | deep-code) agent="deepcode"; name="Deep Code"; agent_package="npm:@vegamo/deepcode-cli" ;; *) - echo "Usage: omarchy-default-agent " + echo "Usage: omarchy-default-agent " exit 1 ;; esac agent_package=${agent_package:-$agent} -if [[ $installing == "false" ]] && ! mise where "$agent_package" &>/dev/null; then - exec omarchy-launch-floating-terminal-with-presentation omarchy-default-agent --install "$agent" -fi +# Kimi Code installs via its official script, not mise +if [[ $agent == "kimi" ]]; then + if omarchy-cmd-missing kimi; then + if [[ $installing == "false" ]]; then + exec omarchy-launch-floating-terminal-with-presentation omarchy-default-agent --install kimi + fi + if ! curl -fsSL https://code.kimi.com/kimi-code/install.sh | bash; then + echo "Could not install $name with the official installer" >&2 + exit 1 + fi + fi +else + if [[ $installing == "false" ]] && ! mise where "$agent_package" &>/dev/null; then + exec omarchy-launch-floating-terminal-with-presentation omarchy-default-agent --install "$agent" + fi -if ! mise use -g "$agent_package"; then - if [[ $installing == "true" ]]; then - echo "Could not install $name with mise" >&2 - else - echo "Could not set $name as the default coding agent" >&2 + if ! mise use -g "$agent_package"; then + if [[ $installing == "true" ]]; then + echo "Could not install $name with mise" >&2 + else + echo "Could not set $name as the default coding agent" >&2 + fi + exit 1 fi - exit 1 fi mkdir -p "$(dirname "$agent_file")" diff --git a/default/omarchy/omarchy-menu.jsonc b/default/omarchy/omarchy-menu.jsonc index 08066b6a..67bb2d30 100644 --- a/default/omarchy/omarchy-menu.jsonc +++ b/default/omarchy/omarchy-menu.jsonc @@ -145,6 +145,9 @@ "setup.default.agent.opencode": {"icon":"","iconFont":"omarchy","label":"OpenCode","checked":"[[ \"$(omarchy-default-agent)\" == \"opencode\" ]]","action":"omarchy-default-agent opencode"}, "setup.default.agent.ori": {"icon":"","iconFont":"omarchy","label":"Ori","checked":"[[ \"$(omarchy-default-agent)\" == \"ori\" ]]","action":"omarchy-default-agent ori"}, "setup.default.agent.pi": {"icon":"","iconFont":"omarchy","label":"Pi","checked":"[[ \"$(omarchy-default-agent)\" == \"pi\" ]]","action":"omarchy-default-agent pi"}, + "setup.default.agent.kimi": {"icon":"󱚤","label":"Kimi Code","checked":"[[ \"$(omarchy-default-agent)\" == \"kimi\" ]]","action":"omarchy-default-agent kimi"}, + "setup.default.agent.deepcode": {"icon":"󱚤","label":"Deep Code","checked":"[[ \"$(omarchy-default-agent)\" == \"deepcode\" ]]","action":"omarchy-default-agent deepcode"}, + "setup.default.agent.cn-hub": {"icon":"󱚤","label":"国产模型组合 (AI Hub)","action":"omarchy-launch-floating-terminal-with-presentation omarchy-cn-ai-setup"}, "setup.default.browser": {"icon":"","label":"浏览器","title":"默认浏览器"}, "setup.default.browser.chromium": {"icon":"","label":"Chromium","checked":"[[ \"$(omarchy-default-browser)\" == \"chromium\" ]]","action":"omarchy-default-browser chromium"}, "setup.default.browser.chrome": {"icon":"󰊯","label":"Chrome","checked":"[[ \"$(omarchy-default-browser)\" == \"chrome\" ]]","action":"omarchy-default-browser chrome"},