mirror of
https://github.com/clash-verge-rev/clash-verge-rev.git
synced 2026-11-10 04:12:08 +08:00
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 Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>