chore(release): bump to v0.7.2 — 高级设置 + WebUI 快捷入口 + loop_control 兼容 + macOS 安装脚本
Release / Attach macOS install script (push) Canceled after 0s
Release / Version consistency (push) Canceled after 0s
Release / Build (macos-latest) (push) Canceled after 0s
Release / Build (ubuntu-latest) (push) Canceled after 0s
Release / Build (windows-latest) (push) Canceled after 0s
Release / Attach macOS install script (push) Canceled after 0s
Release / Version consistency (push) Canceled after 0s
Release / Build (macos-latest) (push) Canceled after 0s
Release / Build (ubuntu-latest) (push) Canceled after 0s
Release / Build (windows-latest) (push) Canceled after 0s
This commit is contained in:
1 parent
24d37fbbf4
commit
fc09a29b9f
21 files changed
+492
-230
No files matched your search
Generated
+1
-1
@@ -1958,7 +1958,7 @@ dependencies = [
|
||||
|
||||
[[package]]
|
||||
name = "kimiswitch"
|
||||
version = "0.7.1"
|
||||
version = "0.7.2"
|
||||
dependencies = [
|
||||
"anyhow",
|
||||
"chrono",
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
[package]
|
||||
name = "kimiswitch"
|
||||
version = "0.7.1"
|
||||
version = "0.7.2"
|
||||
description = "Kimi Switch - model config manager"
|
||||
authors = ["codingplan.site"]
|
||||
edition = "2021"
|
||||
|
||||
@@ -949,6 +949,32 @@ pub fn open_installer(app: tauri::AppHandle, path: String) -> Result<(), String>
|
||||
.open_path(&path, None::<&str>)
|
||||
.map_err(|e| e.to_string())
|
||||
}
|
||||
|
||||
/// Launch `kimi web` — starts the local Kimi Code Web UI server and opens it
|
||||
/// in the default browser (the code-app web bundle built into kimi-code 0.33+).
|
||||
/// The kimi CLI must be on PATH; the spawned process is detached so the server
|
||||
/// keeps running while Kimi Switch stays open.
|
||||
#[tauri::command]
|
||||
pub fn open_kimi_web() -> Result<(), String> {
|
||||
use std::process::Command;
|
||||
let mut cmd = Command::new("kimi");
|
||||
cmd.arg("web");
|
||||
#[cfg(windows)]
|
||||
{
|
||||
use std::os::windows::process::CommandExt;
|
||||
// CREATE_NO_WINDOW: avoid a console window flashing next to the GUI.
|
||||
cmd.creation_flags(0x08000000);
|
||||
}
|
||||
cmd.spawn()
|
||||
.map(|_| ())
|
||||
.map_err(|e| {
|
||||
if e.kind() == std::io::ErrorKind::NotFound {
|
||||
"kimi executable not found on PATH — install Kimi Code CLI first".to_string()
|
||||
} else {
|
||||
format!("failed to start `kimi web`: {e}")
|
||||
}
|
||||
})
|
||||
}
|
||||
/// Preference for Linux is AppImage (portable, no install). If the preferred
|
||||
/// extension is not present, returns None so the UI can fall back to
|
||||
/// "open release page" instead of guessing a less-preferred format.
|
||||
|
||||
@@ -109,6 +109,7 @@ pub fn run() {
|
||||
commands::download_update,
|
||||
commands::open_installer,
|
||||
commands::open_external_url,
|
||||
commands::open_kimi_web,
|
||||
commands::kimi_oauth_start,
|
||||
commands::kimi_oauth_poll,
|
||||
commands::get_experimental_env_status,
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"productName": "Kimi Switch",
|
||||
"version": "0.7.1",
|
||||
"version": "0.7.2",
|
||||
"identifier": "com.kimiswitch.app",
|
||||
"build": {
|
||||
"beforeDevCommand": "npm run dev",
|
||||
|
||||
Reference in new issue
Block a user