Commit Graph
5119 Commits
Author SHA1 Message Date
Tunglies c95c8ac2ce refactor(subscription): decode deep links in the subscription crate 2026-11-30 19:09:13 +08:00
Tunglies f338f1625a refactor(backup): extract the backup archive crate 2026-11-30 19:05:19 +08:00
Tunglies 75910b8db8 refactor(task): move retry primitives into the task crate 2026-11-30 18:48:04 +08:00
Tunglies 03554601a6 refactor(config): inject the profile script executor 2026-11-30 18:44:12 +08:00
Tunglies a0e72fbbf0 docs(agents): define dependencies between capability crates 2026-11-30 18:44:12 +08:00
Tunglies 2c8b532f68 fix(profile): recover interrupted subscription refreshes
Recover pending redo at startup, coordinate profile readers and writers, and publish Draft state only after persistence. Keep the Windows legacy path by default.
2026-11-30 18:44:12 +08:00
Tunglies 0415133c88 refactor(profile): separate subscription refresh and scheduling policy
Separate download and scheduling policy from the subscription use case while retaining the existing write path.
2026-11-30 18:44:12 +08:00
Tunglies e31c01894a refactor(profile): extract profile models and index rules
Move profile models and index rules into the crate, preserving serialization and returning a typed missing-profile error.
2026-11-30 18:44:12 +08:00
Tunglies b1281d78fe refactor(proxy): extract proxy view and its use case
Project the Mihomo snapshot into the existing IPC DTO and move use-case orchestration out of the command.
2026-11-30 18:44:12 +08:00
Tunglies dfeebd145b refactor(config): extract configuration renderer
Render from inputs supplied by the app, reuse the script crate, and preserve the default template fast path.
2026-11-30 18:44:11 +08:00
Tunglies b232c4506d refactor(profile): extract script validation and execution
Share the Boa validation and execution API while preserving the save-side timeout and diagnostics.
2026-11-30 18:13:50 +08:00
Tunglies 96c926c33f perf(runtime-bundle): share destination strings with tristr
Share destination storage within bundle planning and preserve the Service wire strings and provider readback.
2026-11-30 18:13:50 +08:00
Tunglies c71b9c579d refactor(runtime-bundle): extract runtime bundle planning
Plan provider destinations and assets in the crate. Adapt the plan to the Service wire format at the call site.
2026-11-30 18:13:49 +08:00
Tunglies 1baa72c2f4 refactor(subscription): extract response decoding
Keep HTTP and persistence in the app. Decode response metadata and framing in the crate, and fall back when the server filename is invalid.
2026-11-30 18:13:49 +08:00
Tunglies a0d4426f0a refactor(logging): use typed logger errors
Expose crate-owned logger errors and preserve the underlying error sources.
2026-11-30 18:13:48 +08:00
Tunglies 1c7bc3200b refactor(draft): type async publication conflicts
Return typed conflicts for async Draft edits. Release the lock and edit permit before converting the error, and exercise overlapping updates.
2026-11-30 18:13:47 +08:00
Tunglies 7b43bac198 docs(agents): define Rust backend architecture boundaries
Document which layer owns Rust capabilities, fallible inputs, background work, and crate validation.
2026-11-30 18:13:47 +08:00
Tunglies 1fa03291f3 chore(clippy): scope crate lint policy
Keep panic-on-error lints at application target roots and scope signal dependencies to Linux.
2026-11-30 18:13:46 +08:00
❤是纱雾酱哟~andrenovate[bot] <29139614+renovate[bot]@users.noreply.github.com> e04fae62d9 chore(deps): update dependency tar to v8 (#8769)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2026-11-29 14:25:03 +00:00
❤是纱雾酱哟~andrenovate[bot] <29139614+renovate[bot]@users.noreply.github.com> 4ce69ec2b1 chore(deps): update dependency knip to v6.49.0 (#8768)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2026-11-29 14:19:06 +00:00
❤是纱雾酱哟~ 8d242b5732 chore(agents): adds instructions for GitHub Copilot (#8765)
- Create `.github/copilot-instructions.md` as agent-specific instruction
  file for GitHub Copilot
- Use "one-line-wrapper" prompt to `AGENTS.md`, like `GEMINI.md`
- Use "at annotation syntax" for instructions importing, like
  `CLAUDE.md`

Assisted-by: Copilot Fusion (High), actually GPT-6.1 Sol, GPT-6.1 Terra and GPT-6 Luna

Signed-off-by: ❤是纱雾酱哟~ <49941141+Dragon1573@users.noreply.github.com>
2026-11-29 08:30:36 +00:00
Tunglies 929bb6a0a1 refactor(backend): share single-owner drivers for background tasks (#8759)
* docs(backend): define background task ownership

* refactor(backend): give background operations single task owners

* test(backend): remove actor migration regression cases

* docs(changelog): drop backend actor migration entry

* refactor(backend): extract workspace task drivers

* fix(timer): omit profile identifier from panic log

* docs(backend): define workspace crate boundaries

* refactor(lightweight): use the task countdown driver

* refactor(lightweight): name countdown callbacks

* refactor(task): simplify driver startup and coalescing requests

* refactor(core): bind service handoff to the sidecar generation

* refactor(tun): coalesce background run state reconciliation

* refactor(core): own sidecar exit resources in one session

* refactor(core): remove automatic Windows service handoff

* refactor(task): simplify coalescing job signals

* refactor(runstate): keep operation status with service state

* refactor(dns): coalesce background override synchronization

* refactor(sysproxy): own the local guard under its operation lock

* fix(tray): read menu settings at publication

* fix(dns): retain script lock across caller cancellation

* refactor(profiles): own selected node restoration in one task

* refactor(timer): own subscription schedules in the scheduler

* test(timer): remove the added application test

* fix(service): renew provider sync retry budget on refresh
2026-11-29 00:42:52 +00:00
doTHTYanddoTHTY 9724aa6d4d docs(i18n): align contributor guidance with PR template (#8760)
- The i18n guide told contributors to list routine command results in a PR checklist, which conflicts with the PR template's rule to keep only review-relevant evidence.

Co-authored-by: doTHTY <362276034+doTHTY@users.noreply.github.com>
2026-11-28 15:22:14 +00:00
❤是纱雾酱哟~andrenovate[bot] <29139614+renovate[bot]@users.noreply.github.com> 1be3ee67f8 chore(deps): update dependency tldts to v7.6.2 (#8763)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2026-11-28 15:19:05 +00:00
❤是纱雾酱哟~andrenovate[bot] <29139614+renovate[bot]@users.noreply.github.com> cc99c90a66 chore(deps): update npm dependencies (#8758)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2026-11-28 12:51:55 +00:00
❤是纱雾酱哟~andrenovate[bot] <29139614+renovate[bot]@users.noreply.github.com> 377d497eb3 chore(deps): update rust toolchain to v1.100.1 (#8757)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2026-11-28 09:55:39 +00:00
❤是纱雾酱哟~andrenovate[bot] <29139614+renovate[bot]@users.noreply.github.com> 2bce842968 chore(deps): update rust crate zip to 9.9.0 (#8756)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2026-11-28 08:35:13 +00:00
renovate[bot]renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>❤是纱雾酱哟~
e813a80902 chore(deps): update github/gh-aw-actions action to v1.4.1 (#8755)
* chore(deps): update github/gh-aw-actions action to v1.4.1

* chore(deps): bump agentic workflows to v1.4.1

- Upgrade via `gh aw upgrade`

Signed-off-by: ❤是纱雾酱哟~ <49941141+Dragon1573@users.noreply.github.com>

---------

Signed-off-by: ❤是纱雾酱哟~ <49941141+Dragon1573@users.noreply.github.com>
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: ❤是纱雾酱哟~ <49941141+Dragon1573@users.noreply.github.com>
2026-11-28 07:51:25 +00:00
Tunglies 055dbf5d35 feat(windows): reinstall an existing Service during NSIS upgrades (#8605)
The reinstall page runs the previous uninstaller, which removes the
Service, and the new installer only tried to start one. Record whether
clash_verge_service exists, with its start type and running state, in
.onInit before that uninstaller can run. When it existed, Section Install
reinstalls it with the bundled cores and their hashes through the
installer's own elevation, then restores a non-automatic start type and
the stopped state. A first install still never adds a Service.

A failed reinstall or restore is logged, shown in a warning dialog that is
auto-confirmed under /S, and sets exit code 2, so the installer does not
report success.

Validated only by compiling the macros with makensis -WX against the real
SimpleSC plugin; not run on Windows.

Refs #8553
2026-11-27 15:48:41 +08:00
Tunglies 876d287152 refactor(updater): retire the startup install UI (#8747)
* refactor(updater): retire the startup install UI

* fix(updater): keep daily checks running and harden the cache path
2026-11-27 07:17:15 +00:00
Tunglies 385022bd13 refactor(updater): drop the never-matching break-change gate (#8742) 2026-11-27 06:18:37 +00:00
Tunglies 1a92ac9c95 fix(updater): unify install lifecycle across startup and dialog paths (#8741) 2026-11-27 06:18:36 +00:00
renovate[bot]andrenovate[bot] <29139614+renovate[bot]@users.noreply.github.com> 1daee71a9e chore(deps): update rust crate sha2 to 0.11.2 (#8745)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2026-11-27 02:12:24 +00:00
Tunglies 8fe3cc1fe3 build(macos): add local debug signing profile 2026-11-25 23:58:34 +08:00
lrehmann 52bb25531c perf(packaging): losslessly compress app and tray icons (#8733) 2026-11-25 09:39:24 +00:00
renovate[bot]andrenovate[bot] <29139614+renovate[bot]@users.noreply.github.com> 8db62c93af chore(deps): update npm dependencies (#8735)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2026-11-25 09:12:05 +00:00
Link 71df1f0d74 fix(i18n): translate Spanish backup settings (#8736) 2026-11-25 08:59:34 +00:00
renovate[bot]renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>Tunglies
4015f37eb3 chore(deps): update cargo dependencies (#8705)
* chore(deps): update cargo dependencies

* fix(deps): align flexi_logger with tracing-estuary

---------

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Tunglies <77394545+Tunglies@users.noreply.github.com>
2026-11-25 06:31:42 +00:00
wonfen 39ea2ceea3 fix(proxies): stop auto delay test on entering chain mode 2026-11-25 12:16:31 +08:00
susu-Sugarandsusu-Sugar 5918918976 fix(update): show manual check result in update dialog (#8701)
Co-authored-by: susu-Sugar <214122492+susu-Sugar@users.noreply.github.com>
2026-11-24 13:09:55 +00:00
renovate[bot]❤是纱雾酱哟~renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
3862a69eca chore(deps): update github/gh-aw-actions action to v1.4.0 (#8728)
* chore(deps): update github/gh-aw-actions action to v1.4.0

Co-authored-by: ❤是纱雾酱哟~ <49941141+Dragon1573@users.noreply.github.com>
Signed-off-by: ❤是纱雾酱哟~ <49941141+Dragon1573@users.noreply.github.com>

* ci(gh-aw): upgrade agentic workflows to 1.4.0

- Upgrade via `gh aw upgrade`

Signed-off-by: ❤是纱雾酱哟~ <49941141+Dragon1573@users.noreply.github.com>

---------

Signed-off-by: ❤是纱雾酱哟~ <49941141+Dragon1573@users.noreply.github.com>
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: ❤是纱雾酱哟~ <49941141+Dragon1573@users.noreply.github.com>
2026-11-24 10:04:23 +00:00
Tunglies 332de8a178 refactor(service)!: remove the development service channel workflow (#8727)
* perf(traffic): shorten sidebar graph animation

* refactor(service)!: remove the development service channel workflow

Delete the verge-dev/dev-sidecar features, the dev.mjs script family,
and the CLASH_VERGE_DEV_SERVICE_DIR staging chain. Debug builds keep
the isolated .dev application data directory and dev sidecar IPC names
through #[cfg(debug_assertions)] instead of the removed feature.

Point clash_verge_service_ipc at tag v2.8.2.

* chore(service): track the development-channel removal draft

Point clash_verge_service_ipc at the removal branch while its PR is
open; flip to tag v2.8.2 once the service side merges.

* chore(service): track the released service 2.8.2

The removal branch merged as clash-verge-rev/clash-verge-service-ipc#105
(with the digest opt-in from clash-verge-rev/clash-verge-service-ipc#106
and the 2.8.2 release bump on top), so track the service repository's
main directly instead of the draft branch.
2026-11-24 06:23:53 +00:00
❤是纱雾酱哟~andrenovate[bot] <29139614+renovate[bot]@users.noreply.github.com> 09da5a6a69 chore(deps): update dependency pnpm to v12.23.0 (#8725)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2026-11-23 16:09:16 +00:00
❤是纱雾酱哟~andrenovate[bot] <29139614+renovate[bot]@users.noreply.github.com> 54876965f2 chore(deps): update dependency tldts to v7.5.5 (#8724)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2026-11-23 15:01:42 +00:00
❤是纱雾酱哟~ e8aafac962 fix(workflows): enhance quota exceeded condition for non-blocking behavior (#8722)
* fix(workflows): enhance quota exceeded condition for non-blocking behavior

Assisted-by: Copilot Fusion (Standard) > GPT-6.1 Terra (Medium)
Signed-off-by: ❤是纱雾酱哟~ <49941141+Dragon1573@users.noreply.github.com>

* ci(gh-aw): Upgrade entire agentic workflows

- Upgrade via `gh aw upgrad`

Signed-off-by: ❤是纱雾酱哟~ <49941141+Dragon1573@users.noreply.github.com>

---------

Signed-off-by: ❤是纱雾酱哟~ <49941141+Dragon1573@users.noreply.github.com>
2026-11-23 09:56:17 +00:00
Tunglies 6bb7d71156 perf(backend): move instead of copy in enhance, tray and sidecar fallback (#8721)
* perf(enhance): move tun mapping and alpn strings instead of cloning

enforce_tun deep-cloned the tun mapping two lines before overwriting
it; take_mapping now moves it instead (end state identical for absent,
non-mapping and mapping values, including key order). builtin_hy_alpn
cloned each hysteria node's alpn String only to dodge a borrow conflict
while re-inserting under the same key; take it in place via get_mut +
mem::take. The in-place guard preserves non-string alpn values that a
remove-based shape would silently drop.

Measured per enhance run on 200 hysteria nodes: hy_alpn 600 -> 200
allocations; enforce_tun 29 -> 3.

* perf(tray): hoist tooltip version string

update_tooltip re-derived the version string from CARGO_PKG_VERSION on
every tray refresh; compute it once in a LazyLock. std::string::String
is spelled out because bare String in this module resolves to the
tristr alias.

* refactor(cmd): take sidecar fallback as AsyncFnOnce(&str)

finish_service_installation's FnOnce(String) -> FallbackFuture bound
forced reason.clone() before the call. AsyncFnOnce(&str) borrows the
reason and moves it into the Sidecar outcome - one allocation instead
of two - and drops the FallbackFuture generic entirely. The
windows-only call site's closure shape is verified with standalone
rustc (edition 2024) repros; Windows CI compiles it definitively.

* refactor(tray): store the tooltip version as a static str

The only consumer reads the value as a str, so the String static
allocated even when the version carries no build metadata. Return the
env! literal directly in that case and leak the trimmed form otherwise;
the LazyLock already owns the value for the process lifetime.

* chore(enhance): drop comment on the alpn take
2026-11-23 09:23:15 +00:00
Tunglies 09d05b3f36 perf(backend): skip runtime mapping copies in proxy-port save (#8719)
* perf(feat): share runtime mappings across port-save probes via Arc

Every proxy-port save deep-copied the full runtime Mapping twice (current
and candidate) so the rare post-restart re-probe could retain ownership.
Wrap both in Arc once: the first probe takes refcount clones, the re-probe
moves the same Arcs. Probe inputs are identical mappings and the
spawn_blocking Send + 'static bounds are unchanged.

Measured on a representative 200-proxy/30-group runtime config: one
Mapping clone costs 10,053 allocations / 1.02 MiB; the Arc handoff costs
0 / 0. Both copies per save are gone.

* perf(config): borrow through selected-node persistence closures

record_selected_node and persist_reconciled_selected copied the group,
node and profile strings up-front for the persist_selected_update
closure, including on the no-change early-return path. The closure bound
is FnOnce + Send without 'static (the same shape forget_selected_node
already relies on), so capture &str and &[PrfSelected] borrows instead
and construct owned strings only at the storage points. as_deref
comparisons keep content semantics.

* chore(feat): drop a narration comment on the Arc handoff
2026-11-23 09:23:13 +00:00
Tunglies a85640a571 perf(backend): trim redundant copies on service IPC paths (#8720)
* perf(core): remove redundant copies on service IPC paths

Allocation and copy trims on the service IPC hot paths; the wire format
is untouched:

- store the owner session proof as Arc: active_service_session()
  retrieval becomes a refcount clone instead of a 64-char string copy
  per call (~12 call sites, including the frontend-polled log path).
  The one external caller takes Proof: Borrow<OwnerSessionProof> so its
  four test closures stay unchanged.
- build the session token hex with one allocation instead of 32
  format! allocations plus Vec growth (35 -> 1 allocations measured),
  mirroring owner_identity::encode_token.
- reuse one RuntimeFileRequest across the provider cache-sync chunk
  loop; only .offset changes per chunk.
- move the proposed session token out of StartClashRequest on success
  instead of cloning it up-front.
- report the non-actionable service status by reference before
  set_status takes ownership.
- hoist the macOS install markers to LazyLock, pass osascript args as
  an array, compare the install-wait core name via the requirement
  array, and log the silent-updater version by reference.

* fix(core): gate the LazyLock import to macOS

The install-marker static is the only LazyLock user in the module and
is macOS-gated; the ungated import made clippy -D warnings fail the
Linux and Windows builds. Co-locate the import with its cfg.
2026-11-23 09:11:58 +00:00
Tunglies 08d09cc5f3 feat(connections): configure rules from connection details (#8649)
* fix(connections): align detail actions in narrow layouts

* feat(connections): configure domain and process rules

* feat(connections): prefer clicked targets and support IP rules

* feat(connections): support parent domain rule editing

Closes #7900

* feat(connections): select the root domain for suffix rules

* fix(connections): accept empty rule extensions

* feat(connections): allow editing IP rule ranges
2026-11-23 07:50:37 +00:00
Tunglies 43be8ead4c test(perf): add proxy scroll scene to the perf adapter (#8718)
Adds a proxy page scenario to the measurement adapter: a core-module
shim serves synthetic proxy/clash/run-state data at the invoke seam
(active only for the proxy scenario; other scenarios stay
byte-identical), and a sawtooth scroll driver keeps the virtualizer
measuring and the throttled scroll-position save running. Running the
scene additionally requires the harness-side scenario contract and
schema v10 from the clash-verge-rev-harness repository.
2026-11-23 07:45:26 +00:00