refactor(komorebic): the KDE komorebic takes Messages and Opts<KdeCommands> from komorebic-core

The 121 subcommands that are one message in all three komorebic are no longer declared in the KDE komorebic: its SubCommand enum becomes KdeCommands (the 44 subcommands that are KDE's own, start, stop, check, hotkeys, quickstart, completions and the ones whose help still differs between the trees), the command line is komorebic_core::cli::Opts<KdeCommands>, and one send_or_query turns any Messages into its SocketMessage and writes it or prints the answer. The docgen arm calls komorebic_core::docgen with DocFormat::KDE. main.rs goes from 2294 to 911 lines. The platform enum stays in the KDE package because hotkeys needs komorebi-hotkeys.

One visible difference outside the generated pages: komorebic --help lists the subcommands of Messages first and the KDE ones after (a flattened enum is listed where it is declared, and Opts flattens Messages before the platform enum), where the old order was one hand-sorted list. The pages, aliases and arguments are unchanged.

Verified: oracle (step4/oracle-check.sh): kde 166 of 166 pages byte-identical (windows 187 and macos 158 still pass); KDE cargo test -p komorebic --locked: 10 + 12 + 49 + 9 passed, 0 failed.
This commit is contained in:
LGUG2Z committed 2026-10-31 01:37:54 -07:00
1 parent a23cd0a78e
commit cee49b4238
1 file changed
+376 -1482
File diff suppressed because it is too large. Load diff