4887 Commits
Author SHA1 Message Date
oomeow b06a966a4b fix(ui): use utf-8 encoding for inline SVG icons to support non-latin characters (#7892)
* fix(ui): use utf-8 encoding for inline SVG icons to support non-latin characters

* chore(test-item): re-add data-sortable-handle to TestItem box

* docs: update changelog
2026-09-09 12:00:10 +00:00
Rusty Ravenandoomeow 380d03cb97 fix(macos): discard a core cache the current user cannot write (#7883)
* fix(macos): discard a core cache the current user cannot write

* docs(changelog): add the unwritable core cache fix

* docs: update changelog to include Linux in cache.db ownership fix

---------

Co-authored-by: oomeow <oomeow@outlook.com>
2026-09-09 11:34:43 +00:00
oomeow 78d6f8eeae fix(proxy-group): prevent PASS-RULE from being filtered out (#7893)
* feat(enhance): add PASS-RULE to BUILTIN_POLICIES

* docs: update changelog
2026-09-09 11:22:14 +00:00
wonfen 3253828bf0 feat/fix: service core staging (#7899)
* feat(service): hand upgraded cores to the service through the installer

The service now only executes administrator-staged core copies, so an
in-app core upgrade has to deliver the new bytes there before the
restart asks for them; otherwise a service-mode restart keeps running
the previous core while the UI reports the new version.

After publishing the downloaded core, service-mode upgrades invoke the
elevated service installer with --install-core <path> --sha256 <hex>.
The digest is computed over the published file and rides the elevated
command line, which no other local account can alter, so a file
swapped after hashing is refused rather than staged. Sidecar-mode
upgrades run the file directly and prompt for nothing.

Rollback distinguishes staging that never ran, was refused, or
succeeded: only a successful staging obliges the rollback to restore
the approved copy too (deliberately not gated on the running mode,
which reads NotRunning after the very crash being rolled back), and a
refused staging restores the file so a retry does not see the new
version on disk and conclude there is nothing to do.

Requires clash-verge-service-ipc >= 2.6.7. The pinned dependency and
the packaged service release must move together with this change, or
the old installer silently treats --install-core as a plain install.

* feat(installer): attest bundled cores to the service at install time

prebuild computes sha256 digests of the downloaded mihomo sidecars
into packages/windows/core-hashes.nsh (gitignored), included through
the NSIS installerHooks path. After unpacking and before starting the
service, the installer stages both cores into the service's approved
directory with those digests, so what gets attested is exactly what
this installer shipped: a core swapped on disk in a user-writable
install directory is refused, not published. Failure is logged and
does not abort the install; a later elevated service install can
stage the cores again.

* chore(deps): require clash-verge-service-ipc v2.6.8

v2.6.8 is the first service whose installer understands
--install-core --sha256; the staging this branch introduces is inert
against anything older, because the old installer treats the flag as a
plain service installation and reports success. The service release and
this pin therefore have to ship in the same app release.

* fix(service): heap-allocate the core hashing buffer

clippy::large_stack_arrays denies the 64 KiB stack array.
2026-09-09 18:25:25 +08:00
renovate[bot]andrenovate[bot] <29139614+renovate[bot]@users.noreply.github.com> c56e78a726 chore(deps): update rust crate dirs to v7 (#7897)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2026-09-09 04:03:52 +00:00
❤是纱雾酱哟~andrenovate[bot] <29139614+renovate[bot]@users.noreply.github.com> c1dcacf032 chore(deps): update dependency vitest to v5 (#7894)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2026-09-09 03:50:36 +00:00
Nikolai A. c3ceea6258 refactor: extract sidebar into standalone component (#7859) 2026-09-08 12:31:44 +00:00
Tunglies f754ee53a0 ci(ai-slop): cap review cost with per-run budgets and a leaner prompt
Two months of usage data (56 evaluated runs, 1372 AI credits) show a
median of 22 credits and 6 tool turns per review, with 97% of billed
context being cache tokens anchored on the prompt itself.

Cap each run at 12 turns and 60 credits so only runaway sessions are
stopped, and stop triggering on reopened, which carries no new
implementation evidence; workflow_dispatch remains available for
manual re-reviews.

Compact the policy body from 367 to 177 lines by merging the signal
lists with the weighting/escalation sections that repeated them, with
no verdict, label, rerun-stability, or output-contract semantics
dropped. Add a tool-call budget for normal evaluations and a fast path
for fork-sync and placeholder PRs, which were 29% of measured
credits.
2026-09-08 15:14:42 +08:00
Tunglies 37fa9b65fa ci: add AI-collaboration contract and PR gates for slop review
Codify the rules agents and contributors are judged by: a tracked
AGENTS.md instruction contract, a Contribution Expectations section in
CONTRIBUTING, and a minimal PR template. Align the AI-slop review
policy with them - linkage substance, test/defensive-code padding,
write-access skips, disclosure as transparency - and add two
tamper-resistant checks: an ai-slop:high merge gate with a linked-issue
requirement (no-issue-needed exemption), plus a docs-consistency anchor
check guarding the cross-references.
2026-09-08 14:13:58 +08:00
Cong Liand❤是纱雾酱哟~ 66d3e70160 fix(ci): align AI review configuration with the gh-aw runtime (#7887)
* fix(ci): align AI review configuration with the gh-aw runtime

* ci(gh-aw): Bump entire Agentic Workflows to 0.88.5

- Regenerate all gh-aw configurations and version lockfiles with gh aw upgrade

Assisted-by: vscode-copilot-chat:gemini-3.7-flash codegraph
Signed-off-by: ❤是纱雾酱哟~ <49941141+Dragon1573@users.noreply.github.com>

---------

Signed-off-by: ❤是纱雾酱哟~ <49941141+Dragon1573@users.noreply.github.com>
Co-authored-by: ❤是纱雾酱哟~ <49941141+Dragon1573@users.noreply.github.com>
2026-09-08 01:05:06 +00:00
Tunglies 2f370d6490 refactor(log): in-place writer lifecycle and span-based core observability (#7889)
* refactor(log): migrate logging to tracing-estuary pipeline

Swap flexi_logger + clash-verge-logger wiring for the tracing-estuary
crate: buffered file sink with explicit panic/exit drains, live level
switching, and tokio-trace/chrome-trace behind crate features.

AsyncLogger moves in-house (VecDeque ring); file format and rotation
stay unchanged.

* fix(log): reset sidecar writer in place and re-pin service-ipc v2.6.7

Rebuilding the sidecar FileLogWriter on config changes leaked flexi's
unstoppable flusher thread plus an fd each time; the writer is now flushed
and reset in place, matching what the service crate does.
get_clash_logs_by_service drops the CompactString conversion layer now that
service-ipc v2.6.7 returns plain Vec<String>, and AsyncLogger is renamed
LogRing to match.

* refactor(log): span-based observability and log noise cleanup

Instrument spans carry the structure flat lines never could: the core-start
spine (mode, readiness/owner generations, pid, config file), proxy apply and
clear routes with guard generations, service IPC sessions with refusal codes
and outcomes, profile-switch terminal outcomes, subscription fetch strategies,
core upgrades with per-proxy version probes, backup flows, timer tasks, config
generation uids, and the startup setup flow; running-mode changes emit one
guarded transition event each.
~90 hand-written noise lines are gone or demoted (entry+success pairs, polled
getter echoes, phase brackets, window sub-steps, platform install chatter);
errors keep their anyhow chain, operation name, and item id, and swallowed
retry results surface per attempt.
2026-09-08 05:51:04 +08:00
wonfen f8b69b5d62 fix(sysproxy): tell the window when a background apply lands 2026-09-07 22:19:51 +08:00
Tunglies 4ddd021826 Revert "chore(deps): update pnpm to v12.3.4 (#7878)"
pnpm 12.3.4 deterministically breaks every Windows CI build: the install inside the tauri beforeBuildCommand fails importing into the pnpm store with os error 32 (ERROR_SHARING_VIOLATION). Reproduced on fresh runners with caches wiped; 12.3.3 was green on the same pipeline. Re-pin to 12.3.3 until upstream ships a fix.
2026-09-07 20:01:26 +08:00
oomeow 800e11a718 feat(window): clear all WebSocket connections before stopping core (#7862) 2026-09-07 10:04:09 +08:00
renovate[bot]andrenovate[bot] <29139614+renovate[bot]@users.noreply.github.com> 714a84c91f chore(deps): update dependency ws to v8.21.0 [security] (#7879)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2026-09-07 01:24:54 +00:00
❤是纱雾酱哟~andrenovate[bot] <29139614+renovate[bot]@users.noreply.github.com> 3c689a9233 chore(deps): update pnpm to v12.3.4 (#7878)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2026-09-07 01:24:02 +00:00
Tunglies 6de0a59756 chore(deps): bump tauri-plugin-mihomo to 0.6.0 and move home card to count stream
Locks both sides to upstream main 17c7757: the WS channel now uses a
single Json transport (connections wire shrinks ~3.4x) and count-stream
error frames are forwarded unchanged; JS/Rust API surfaces stay
identical, so upper-layer code is untouched except the card below.

The home Active Connections card now subscribes to the count-only
ws_connections_count stream instead of parsing the full connections
snapshot every second; the full stream runs only while the Connections
page is mounted.
2026-09-07 07:13:27 +08:00
Tunglies b39c5f9b6d test(perf): add macOS Tauri WebView performance harness
Drive the production home traffic graph through embedded WebDriver in an
isolated optimized measurement build. Record attributed WebContent and main
process CPU/RSS distributions across foreground, hidden and restored phases.

Keep replay, raw reports, independent-run comparison, cleanup checks and
focused validation available through project commands. Normal release builds
exclude the automation service and measurement entry points.
2026-09-07 07:13:24 +08:00
Tunglies dd7b032cb1 refactor: retire application portable mode 2026-09-06 20:53:36 +08:00
Tunglies 9c9b7c3992 perf(proxy): read delays once per latency sort 2026-09-06 20:50:15 +08:00
Tunglies ee497cc65d refactor(ipc): remove unused commands 2026-09-06 04:38:46 +08:00
Tunglies 4ed474706a refactor(frontend): consolidate query state ownership
Consolidate ordinary query snapshots on SWR and make Profiles own its query key, cache mutation, and invalidation policy.

Impact:
- remove the generic synchronous query Map while keeping dedicated Mihomo WebSocket snapshots
- eliminate duplicate Profiles refreshes while preserving retries and the 800 ms event throttle
- preserve preload-backed Verge updates and system proxy rollback behavior
- scope uptime polling to the Home Clash info card instead of the app lifetime
- leave RunState, Connections, Traffic, backend, and IPC contracts unchanged
- reduce frontend code by 72 net lines without adding dependencies
2026-09-06 04:32:22 +08:00
renovate[bot]andrenovate[bot] <29139614+renovate[bot]@users.noreply.github.com> 00a8518e7a chore(deps): update rust toolchain to v1.98.1 (#7871)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2026-09-05 13:17:39 +00:00
❤是纱雾酱哟~andrenovate[bot] <29139614+renovate[bot]@users.noreply.github.com> e179ce9ac5 chore(deps): update pnpm to v12.3.3 (#7870)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2026-09-05 12:58:31 +00:00
❤是纱雾酱哟~andrenovate[bot] <29139614+renovate[bot]@users.noreply.github.com> 3e0a773bd7 chore(deps): update github actions (#7869)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2026-09-05 12:54:17 +00:00
Tunglies d8b94d12dd perf(core): batch close connections on mode change 2026-09-04 18:20:39 +08:00
Tunglies 836199cfe2 fix: unify font-family usage across GUI
- Remove hardcoded body font-family from index.scss, use MUI theme dt.font_family instead
- Extract monospace font stack to shared MONACO_FONT_FAMILY constant in utils/font-family.ts
- Add platform check for twemoji mozilla in ip-info-card.tsx
- Consolidate 5 Monaco Editor font-family declarations into single constant
2026-09-04 09:57:24 +08:00
❤是纱雾酱哟~ a640010bc3 fix(clippy): Restrict 2 imports to macOS only (#7858)
* fix(clippy): Remove 2 unused imports

- Drop 2 unused imports according to clippy suggestions

* fix(clippy): Re-add 2 imports and limit to macOS

- Those "unused imports" are only for Windows and Linux
- macOS environment requires those identifiers
2026-09-03 22:31:19 +00:00
wonfen c0c1fbcfc2 refactor(sysproxy): watch the network from the main run loop 2026-09-03 22:42:50 +08:00
wonfen e57d115110 feat(sysproxy): re-apply the proxy when macOS gains a network service 2026-09-03 22:42:49 +08:00
wonfen c89f431cb0 fix(sysproxy): wait for the network before the login-time proxy write 2026-09-03 22:42:49 +08:00
Tunglies 7ffb0ef23b test: remove useless test 2026-09-03 19:18:50 +08:00
Tunglies ff4b4dd822 chore: cleanup build script 2026-09-03 11:28:00 +08:00
renovate[bot]andrenovate[bot] <29139614+renovate[bot]@users.noreply.github.com> dab1647125 chore(deps): update ghcr.io/devcontainers/features/node docker tag to v2 (#7854)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2026-09-03 02:54:54 +00:00
Nikolai A. 9cb4ce6cb1 refactor: simplify side menu layout and drag-and-drop logic (#7838)
* refactor: remove duplicated list wrapper in side menu

* refactor: simplify side menu layout and drag drop logic

- Always render DragDropProvider and pass disabled prop to menu items
- Remove redundant layout branches and unused sortable component
2026-09-02 13:40:36 +00:00
oomeow 86b5493a9d fix: windows shutdown being blocked (#7848)
make tauri-plugin-devtools and console-subscriber optional
2026-09-02 06:47:07 +00:00
wonfen ef042ddf82 fix(sysproxy): stop turning a missing network service into a hard failure 2026-09-02 11:46:37 +08:00
renovate[bot]andrenovate[bot] <29139614+renovate[bot]@users.noreply.github.com> 78cc4dc532 chore(deps): update github/gh-aw-actions action to v0.88.0 (#7833)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2026-09-02 02:26:30 +00:00
❤是纱雾酱哟~ aca9c34dfb ci(renovate): Unlock auto updates for basic built tools and group updates together (#7835)
* ci(workflows): Revert nodejs version to v24.18.1

- Exactly match what was defined in `.tool-versions`

* ci(renovate): Prevent 3 build tools from being automatically upgraded

- Lock Nodejs, PNPM and Rust version in the repository
  - Nodejs, PNPM and Rust are infrastructure build tools or package manager for this repo
  - Human manual-bump is required for consistency and stability
  - Prevent bumping by Renovate Bot

* ci(renovate): Unlock auto updates of 3 build tools

- Re-allow Nodejs, PNPM and Rust from being automatically upgrade
- Group version bumps together across version lockfiles, GitHub Workflows and Dev Containers

Assisted-by: vscode-copilot-chat:gemini-3.7-flash codegraph

* chore(deps): Bump 2 build tools to latest version

- Bump Nodejs to `v24.20.0` across version lockfiles, GitHub Workflows and Dev Containers
- Bump Rust toolchain to `v1.98.0` across version lockfiles, GitHub Workflows and Dev Containers

Assisted-by: vscode-copilot-chat:gemini-3.7-flash codegraph
2026-09-02 01:13:15 +00:00
oomeow f5cc24ec9f chore: update tauri-plugin-mihomo dep (#7847)
* chore: update tauri-plugin-mihomo dep

* refactor(tauri): remove unnecessary await from clear_all_ws_connections
2026-09-01 13:26:35 +00:00
wonfen e60285b4ae fix(tun): make the TUN switch reflect what the Core actually runs
The switch read enable_tun_mode while the Core was given
enable_tun_mode && !session_suppression, so falling back to Sidecar left it
showing a TUN that was not running, with nothing to write the flag back.
Drop the session flag: the stored preference is the only truth, re-checked
at startup and written off when the conditions for it are not met, and the
switch renders it against current capability.
2026-08-31 17:09:36 +08:00
Tunglies 8611fdc34f chore(deps): update mihomo plugin 2026-08-30 18:34:11 +08:00
❤是纱雾酱哟~ eafa91938d chore(gitattributes): Lock end of line style for shell scripts (#7834)
Assisted-by: vscode-copilot-chat:gemini-3.7-flash codegraph
2026-08-30 06:24:59 +00:00
Tunglies 44f6f6e19b fix(profile): preserve files until explicit deletion 2026-08-30 14:34:28 +08:00
wonfen 632c5b2bc5 fix(windows): repair a data root owned by another account 2026-08-30 11:45:04 +08:00
oomeow 1b76b222fb fix(sysproxy): gsettings command is no longer mandatory on KDE desktop (#7829)
* fix(sysproxy): gsettings command is no longer mandatory on KDE desktop

* chore(tauri): update sysproxy dependency to use main branch

* chore(deps): update clash_verge_service_ipc to v2.6.6

* docs(changelog): add KDE proxy setting support note
2026-08-29 17:26:29 +00:00
Tunglies 598b5e690c feat(updater): sanitize release notes and standardize semver 2026-08-29 11:52:08 +08:00
oomeowandTunglies b6de05ffe4 refactor: migrate to @dnd-kit/react and simplify sortable components (#7819)
* refactor: migrate to @dnd-kit/react and simplify sortable components

* chore: enable css formatting in biome.json

* refactor(profile): simplify icon rendering logic and add alt text

* style(profiles): add overflow hidden to profile grid container

* refactor(profile): add radix for parseInt and improve type safety in profiles

* docs: update changelog with drag-and-drop styling improvements

* refactor(profile): move hasValidName function out of ProxiesEditorViewer

* refactor(proxy): refactor proxy chain into sortable components

* feat(proxy): add drop state styling and arrow animations to proxy chain

* style(profiles): reduce horizontal padding in profile grid

* feat(profile): add vertical margin to editor viewer items

* chore: refresh pnpm lockfile

* fix: preserve drag and drop behavior

---------

Co-authored-by: Tunglies <77394545+Tunglies@users.noreply.github.com>
2026-08-28 08:17:02 +00:00
Tunglies 181dfb87a4 chore: migrate to pnpm 12 2026-08-28 11:16:51 +08:00
Christine. 3503a2da29 fix: reset fake-ip-range6: "2001:2::0/64" as default on Tun Mode (#7811)
* fix: reset fake-ip-range6: "2001:2::0/48" as default on Tun Mode

* update: fake-ip-range6 to "2001:2::0/64"

* fix: sync test data
2026-08-26 00:24:28 +08:00