Fix China app installs and wire the CN AI stack into Install > AI
Offline installs ship no pacman sync db, so yay resolved official repo dependencies as AUR packages and every catalog install failed; omarchy-cn-app-install now runs a full -Syu first (verified end to end: WeChat builds and installs in the VM). Kimi Code gains a real installer command reused by the harness registry, the default-agent path, and new Install > AI entries (Kimi Code, Deep Code, AI Hub), and the AI Hub wizard offers to launch native harnesses immediately so their official CLI login runs, matching how Claude Code works. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01QKxGW1raAWaqeU8WdHsMsp
This commit is contained in:
@@ -40,7 +40,10 @@ proto=$(cn_ai_harness_field "$harness" protocol)
|
||||
if [[ $proto == "native" ]]; then
|
||||
omarchy-cn-ai-profile-create "$name" "$harness" "$provider" "$model"
|
||||
omarchy-cn-ai-profile-use "$name"
|
||||
echo "$harness 自管鉴权:首次启动时按其官方流程登录/配置"
|
||||
echo "$harness 自管鉴权:首次启动时在 CLI 内完成官方登录"
|
||||
if gum confirm "立即启动并完成官方登录?"; then
|
||||
exec omarchy-cn-ai-launch "$name"
|
||||
fi
|
||||
echo "完成。启动: omarchycn ai launch"
|
||||
exit 0
|
||||
fi
|
||||
|
||||
@@ -32,6 +32,11 @@ fi
|
||||
|
||||
case "$source_type" in
|
||||
aur)
|
||||
# Offline installs ship no sync db; yay then treats repo deps as AUR
|
||||
if ! compgen -G "/var/lib/pacman/sync/*.db" > /dev/null; then
|
||||
echo "首次安装:正在同步软件仓库并更新系统(pacman -Syu)……"
|
||||
sudo pacman -Syu --noconfirm
|
||||
fi
|
||||
omarchy-pkg-aur-add "$(jq -r '.package' <<<"$entry")"
|
||||
;;
|
||||
webapp)
|
||||
|
||||
@@ -0,0 +1,15 @@
|
||||
#!/bin/bash
|
||||
# omarchy:summary=Install Kimi Code with the official installer script
|
||||
# omarchy:examples=omarchycn kimi install
|
||||
|
||||
set -euo pipefail
|
||||
|
||||
if omarchy-cmd-present kimi; then
|
||||
echo "Kimi Code 已安装"
|
||||
exit 0
|
||||
fi
|
||||
|
||||
installer=$(mktemp)
|
||||
trap 'rm -f "$installer"' EXIT
|
||||
curl -fsSL https://code.kimi.com/kimi-code/install.sh -o "$installer"
|
||||
bash "$installer"
|
||||
@@ -50,13 +50,10 @@ if [[ $agent == "kimi" ]]; then
|
||||
if [[ $installing == "false" ]]; then
|
||||
exec omarchy-launch-floating-terminal-with-presentation omarchy-default-agent --install kimi
|
||||
fi
|
||||
installer=$(mktemp)
|
||||
if ! curl -fsSL https://code.kimi.com/kimi-code/install.sh -o "$installer" || ! bash "$installer"; then
|
||||
rm -f "$installer"
|
||||
if ! omarchy-cn-kimi-install; then
|
||||
echo "Could not install $name with the official installer" >&2
|
||||
exit 1
|
||||
fi
|
||||
rm -f "$installer"
|
||||
fi
|
||||
else
|
||||
if [[ $installing == "false" ]] && ! mise where "$agent_package" &>/dev/null; then
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
{
|
||||
"_verified": "2026-08-24",
|
||||
"_verified": "2026-08-25",
|
||||
"harnesses": {
|
||||
"claude-code": {
|
||||
"display_name": "Claude Code",
|
||||
@@ -25,7 +25,7 @@
|
||||
"kimi-code": {
|
||||
"display_name": "Kimi Code CLI",
|
||||
"command": "kimi",
|
||||
"install": "doc:https://www.kimi.com/code/docs/en/",
|
||||
"install": "omarchy-cn-kimi-install",
|
||||
"config_method": "native",
|
||||
"protocol": "native"
|
||||
},
|
||||
|
||||
@@ -240,11 +240,14 @@
|
||||
"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.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.deep-code": {"icon":"","label":"Deep Code","disabled":"omarchy-cmd-present deepcode","action":"omarchy-launch-floating-terminal-with-presentation 'omarchy-mise-install npm:@vegamo/deepcode-cli deepcode && deepcode'"},
|
||||
"install.ai.dictation": {"icon":"","label":"语音听写","disabled":"omarchy-pkg-present voxtype-bin","action":"omarchy-launch-floating-terminal-with-presentation omarchy-voxtype-install"},
|
||||
"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"},
|
||||
"install.ai.kimi-code": {"icon":"","label":"Kimi Code","disabled":"omarchy-cmd-present kimi","action":"omarchy-launch-floating-terminal-with-presentation 'omarchy-cn-kimi-install && kimi'"},
|
||||
"install.ai.lm-studio": {"icon":"","iconFont":"omarchy","label":"LM Studio","disabled":"omarchy-pkg-present lmstudio-bin","action":"omarchy-install-app 'LM Studio' lmstudio-bin"},
|
||||
"install.ai.ollama": {"icon":"","iconFont":"omarchy","label":"Ollama","disabled":"omarchy-cmd-present ollama","action":"if omarchy-cmd-present nvidia-smi; then ollama_pkg=ollama-cuda; elif omarchy-cmd-present rocminfo; then ollama_pkg=ollama-rocm; else ollama_pkg=ollama; fi; omarchy-install-app Ollama \"$ollama_pkg\""},
|
||||
"install.ai.t3-code": {"icon":"","iconFont":"omarchy","label":"T3 Code","disabled":"omarchy-pkg-present t3code-bin","action":"omarchy-install-and-launch 'T3 Code' t3code-bin t3code"},
|
||||
"install.ai.cn-hub": {"icon":"","label":"国产模型组合 (AI Hub)","action":"omarchy-launch-floating-terminal-with-presentation omarchy-cn-ai-setup"},
|
||||
"install.gaming.steam": {"icon":"","label":"Steam","disabled":"omarchy-pkg-present steam","action":"omarchy-launch-floating-terminal-with-presentation omarchy-install-gaming-steam"},
|
||||
"install.gaming.retroarch": {"icon":"","label":"RetroArch","disabled":"omarchy-pkg-present retroarch","action":"omarchy-launch-floating-terminal-with-presentation omarchy-install-gaming-retroarch"},
|
||||
"install.gaming.minecraft": {"icon":"","label":"Minecraft","disabled":"omarchy-pkg-present minecraft-launcher","action":"omarchy-install-and-launch Minecraft minecraft-launcher minecraft-launcher"},
|
||||
|
||||
Reference in New Issue
Block a user