All your AI agent sessions in one place — browse, search, resume. Rust + GPUI.
Rust
Wake 0.1.0 — initial public release
Corey Chiu705f431df44d
diff --git a/.gitignore b/.gitignorenew file mode 100644index 0000000..b25458e--- /dev/null+++ b/.gitignore@@ -0,0 +1,12 @@+/target+/dist+.impeccable/+.codex/+crates/wake/assets/icon-1024.png+*.log+.DS_Store+*.local++# agent 指令/配置,本地开发用,不入库+CLAUDE.md+.claude/diff --git a/Cargo.lock b/Cargo.locknew file mode 100644index 0000000..59cabfe--- /dev/null+++ b/Cargo.lock@@ -0,0 +1,8155 @@+# This file is automatically @generated by Cargo.+# It is not intended for manual editing.+version = 4++[[package]]+name = "adler2"+version = "2.0.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "320119579fcad9c21884f5c4861d16174d0e06250625266f50fe6898340abefa"++[[package]]+name = "aes"+version = "0.8.4"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "b169f7a6d4742236a0a00c541b845991d0ac43e546831af1249753ab4c3aa3a0"+dependencies = [+ "cfg-if",+ "cipher",+ "cpufeatures 0.2.17",+ "zeroize",+]++[[package]]+name = "ahash"+version = "0.8.12"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "5a15f179cd60c4584b8a8c596927aadc462e27f2ca70c04e0071964a73ba7a75"+dependencies = [+ "cfg-if",+ "const-random",+ "once_cell",+ "version_check",+ "zerocopy",+]++[[package]]+name = "aho-corasick"+version = "1.1.5"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "c982642fa9e8606056828ee9a8505737230110bb1099153c79efe865c59d12ba"+dependencies = [+ "memchr",+]++[[package]]+name = "aligned"+version = "0.4.3"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "ee4508988c62edf04abd8d92897fca0c2995d907ce1dfeaf369dac3716a40685"+dependencies = [+ "as-slice",+]++[[package]]+name = "aligned-vec"+version = "0.6.4"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "dc890384c8602f339876ded803c97ad529f3842aba97f6392b3dba0dd171769b"+dependencies = [+ "equator",+]++[[package]]+name = "android_system_properties"+version = "0.1.6"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "ae221649c9976a6f6c56ae1facf410f3ddb33cc661c4b7b61020a912d4237fbc"+dependencies = [+ "libc",+]++[[package]]+name = "anyhow"+version = "1.0.104"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "330a5ed07fa54e4702c9d6c4174f74427fc0ef6e214bbd677ae50a5099946470"++[[package]]+name = "ar_archive_writer"+version = "0.5.3"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "73cd58deff2140a0a8eae87e417bd01db68a33e148aa93d1e8cd837e55e312b6"+dependencies = [+ "object",+]++[[package]]+name = "arbitrary"+version = "1.4.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "c3d036a3c4ab069c7b410a2ce876bd74808d2d0888a82667669f8e783a898bf1"++[[package]]+name = "arc-swap"+version = "1.9.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "c049c0be4daef0b145cb3555416b3b8ef5b7888a38aea1a3a155801fe7b0810b"+dependencies = [+ "rustversion",+]++[[package]]+name = "arg_enum_proc_macro"+version = "0.3.4"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "0ae92a5119aa49cdbcf6b9f893fe4e1d98b04ccbf82ee0584ad948a44a734dea"+dependencies = [+ "proc-macro2",+ "quote",+ "syn 2.0.119",+]++[[package]]+name = "arrayref"+version = "0.3.9"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "76a2e8124351fda1ef8aaaa3bbd7ebbcb486bbcd4225aca0aa0d84bb2db8fecb"++[[package]]+name = "arrayvec"+version = "0.7.8"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "d3fb67a6e08acf24fdeccbac2cb6ac4305825bd1f117462e0e6f2f193345ad56"++[[package]]+name = "as-raw-xcb-connection"+version = "1.0.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "175571dd1d178ced59193a6fc02dde1b972eb0bc56c892cde9beeceac5bf0f6b"++[[package]]+name = "as-slice"+version = "0.2.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "516b6b4f0e40d50dcda9365d53964ec74560ad4284da2e7fc97122cd83174516"+dependencies = [+ "stable_deref_trait",+]++[[package]]+name = "ash"+version = "0.38.0+1.3.281"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "0bb44936d800fea8f016d7f2311c6a4f97aebd5dc86f09906139ec848cf3a46f"+dependencies = [+ "libloading",+]++[[package]]+name = "ash-window"+version = "0.13.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "52bca67b61cb81e5553babde81b8211f713cb6db79766f80168f3e5f40ea6c82"+dependencies = [+ "ash",+ "raw-window-handle",+ "raw-window-metal",+]++[[package]]+name = "ashpd"+version = "0.11.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "d2f3f79755c74fd155000314eb349864caa787c6592eace6c6882dad873d9c39"+dependencies = [+ "async-fs",+ "async-net",+ "enumflags2",+ "futures-channel",+ "futures-util",+ "rand 0.9.5",+ "serde",+ "serde_repr",+ "url",+ "wayland-backend",+ "wayland-client",+ "wayland-protocols 0.32.13",+ "zbus",+]++[[package]]+name = "ashpd"+version = "0.12.3"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "33a3c86f3fd70c0ffa500ed189abfa90b5a52398a45d5dc372fcc38ebeb7a645"+dependencies = [+ "async-fs",+ "async-net",+ "enumflags2",+ "futures-channel",+ "futures-util",+ "rand 0.9.5",+ "serde",+ "serde_repr",+ "url",+ "zbus",+]++[[package]]+name = "async-broadcast"+version = "0.7.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "435a87a52755b8f27fcf321ac4f04b2802e337c8c4872923137471ec39c37532"+dependencies = [+ "event-listener 5.4.2",+ "event-listener-strategy",+ "futures-core",+ "pin-project-lite",+]++[[package]]+name = "async-channel"+version = "1.9.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "81953c529336010edd6d8e358f886d9581267795c61b19475b71314bffa46d35"+dependencies = [+ "concurrent-queue",+ "event-listener 2.5.3",+ "futures-core",+]++[[package]]+name = "async-channel"+version = "2.5.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "924ed96dd52d1b75e9c1a3e6275715fd320f5f9439fb5a4a11fa51f4221158d2"+dependencies = [+ "concurrent-queue",+ "event-listener-strategy",+ "futures-core",+ "pin-project-lite",+]++[[package]]+name = "async-compression"+version = "0.4.43"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "3976abdc8fe7d1133d43d304afd42abdf5bc3e1319d263d223bde07b5efc4be8"+dependencies = [+ "compression-codecs",+ "compression-core",+ "futures-io",+ "pin-project-lite",+]++[[package]]+name = "async-executor"+version = "1.14.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "c96bf972d85afc50bf5ab8fe2d54d1586b4e0b46c97c50a0c9e71e2f7bcd812a"+dependencies = [+ "async-task",+ "concurrent-queue",+ "fastrand 2.5.0",+ "futures-lite 2.6.1",+ "pin-project-lite",+ "slab",+]++[[package]]+name = "async-fs"+version = "2.2.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "8034a681df4aed8b8edbd7fbe472401ecf009251c8b40556b304567052e294c5"+dependencies = [+ "async-lock",+ "blocking",+ "futures-lite 2.6.1",+]++[[package]]+name = "async-global-executor"+version = "2.4.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "05b1b633a2115cd122d73b955eadd9916c18c8f510ec9cd1686404c60ad1c29c"+dependencies = [+ "async-channel 2.5.0",+ "async-executor",+ "async-io",+ "async-lock",+ "blocking",+ "futures-lite 2.6.1",+ "once_cell",+]++[[package]]+name = "async-io"+version = "2.6.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "456b8a8feb6f42d237746d4b3e9a178494627745c3c56c6ea55d92ba50d026fc"+dependencies = [+ "autocfg",+ "cfg-if",+ "concurrent-queue",+ "futures-io",+ "futures-lite 2.6.1",+ "parking",+ "polling",+ "rustix 1.1.4",+ "slab",+ "windows-sys 0.61.2",+]++[[package]]+name = "async-lock"+version = "3.4.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "290f7f2596bd5b78a9fec8088ccd89180d7f9f55b94b0576823bbbdc72ee8311"+dependencies = [+ "event-listener 5.4.2",+ "event-listener-strategy",+ "pin-project-lite",+]++[[package]]+name = "async-net"+version = "2.0.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "b948000fad4873c1c9339d60f2623323a0cfd3816e5181033c6a5cb68b2accf7"+dependencies = [+ "async-io",+ "blocking",+ "futures-lite 2.6.1",+]++[[package]]+name = "async-process"+version = "2.5.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "fc50921ec0055cdd8a16de48773bfeec5c972598674347252c0399676be7da75"+dependencies = [+ "async-channel 2.5.0",+ "async-io",+ "async-lock",+ "async-signal",+ "async-task",+ "blocking",+ "cfg-if",+ "event-listener 5.4.2",+ "futures-lite 2.6.1",+ "rustix 1.1.4",+]++[[package]]+name = "async-recursion"+version = "1.1.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "3b43422f69d8ff38f95f1b2bb76517c91589a924d1559a0e935d7c8ce0274c11"+dependencies = [+ "proc-macro2",+ "quote",+ "syn 2.0.119",+]++[[package]]+name = "async-signal"+version = "0.2.14"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "52b5aaafa020cf5053a01f2a60e8ff5dccf550f0f77ec54a4e47285ac2bab485"+dependencies = [+ "async-io",+ "async-lock",+ "atomic-waker",+ "cfg-if",+ "futures-core",+ "futures-io",+ "rustix 1.1.4",+ "signal-hook-registry",+ "slab",+ "windows-sys 0.61.2",+]++[[package]]+name = "async-std"+version = "1.13.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "2c8e079a4ab67ae52b7403632e4618815d6db36d2a010cfe41b02c1b1578f93b"+dependencies = [+ "async-channel 1.9.0",+ "async-global-executor",+ "async-io",+ "async-lock",+ "async-process",+ "crossbeam-utils",+ "futures-channel",+ "futures-core",+ "futures-io",+ "futures-lite 2.6.1",+ "gloo-timers",+ "kv-log-macro",+ "log",+ "memchr",+ "once_cell",+ "pin-project-lite",+ "pin-utils",+ "slab",+ "wasm-bindgen-futures",+]++[[package]]+name = "async-task"+version = "4.7.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "8b75356056920673b02621b35afd0f7dda9306d03c79a30f5c56c44cf256e3de"++[[package]]+name = "async-trait"+version = "0.1.92"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "82f6aeea286b8eb4dd3431a1be1b59d290ace00f5bfd8e2a159bc2a05e2c1667"+dependencies = [+ "proc-macro2",+ "quote",+ "syn 3.0.3",+]++[[package]]+name = "async_zip"+version = "0.0.17"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "00b9f7252833d5ed4b00aa9604b563529dd5e11de9c23615de2dcdf91eb87b52"+dependencies = [+ "async-compression",+ "crc32fast",+ "futures-lite 2.6.1",+ "pin-project",+ "thiserror 1.0.69",+]++[[package]]+name = "atomic"+version = "0.5.3"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "c59bdb34bc650a32731b31bd8f0829cc15d24a708ee31559e0bb34f2bc320cba"++[[package]]+name = "atomic-waker"+version = "1.1.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "1505bd5d3d116872e7271a6d4e16d81d0c8570876c8de68093a09ac269d8aac0"++[[package]]+name = "autocfg"+version = "1.5.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "f2032f911046de80f0a198e0901378627c33f59ea0ac00e363d481118bd70a53"++[[package]]+name = "av-scenechange"+version = "0.14.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "0f321d77c20e19b92c39e7471cf986812cbb46659d2af674adc4331ef3f18394"+dependencies = [+ "aligned",+ "anyhow",+ "arg_enum_proc_macro",+ "arrayvec",+ "log",+ "num-rational",+ "num-traits",+ "pastey",+ "rayon",+ "thiserror 2.0.20",+ "v_frame",+ "y4m",+]++[[package]]+name = "av1-grain"+version = "0.2.5"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "8cfddb07216410377231960af4fcab838eaa12e013417781b78bd95ee22077f8"+dependencies = [+ "anyhow",+ "arrayvec",+ "log",+ "nom 8.0.0",+ "num-rational",+ "v_frame",+]++[[package]]+name = "avif-serialize"+version = "0.8.9"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "e7178fe5f7d460b13895ebb9dcb28a3a6216d2df2574a0806cb51b555d297f38"+dependencies = [+ "arrayvec",+]++[[package]]+name = "base62"+version = "2.2.4"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "cd637ac531c60eb7fbc4684dc061c2d7d90d73d758181aa02eeff0464b9eee4b"++[[package]]+name = "base64"+version = "0.22.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "72b3254f16251a8381aa12e40e3c4d2f0199f8c6508fbecb9d91f575e0fbb8c6"++[[package]]+name = "bindgen"+version = "0.71.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "5f58bf3d7db68cfbac37cfc485a8d711e87e064c3d0fe0435b92f7a407f9d6b3"+dependencies = [+ "bitflags 2.13.1",+ "cexpr",+ "clang-sys",+ "itertools 0.13.0",+ "log",+ "prettyplease",+ "proc-macro2",+ "quote",+ "regex",+ "rustc-hash 2.1.3",+ "shlex 1.3.0",+ "syn 2.0.119",+]++[[package]]+name = "bit-set"+version = "0.8.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "08807e080ed7f9d5433fa9b275196cfc35414f66a0c79d864dc51a0d825231a3"+dependencies = [+ "bit-vec",+]++[[package]]+name = "bit-vec"+version = "0.8.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "5e764a1d40d510daf35e07be9eb06e75770908c27d411ee6c92109c9840eaaf7"++[[package]]+name = "bit_field"+version = "0.10.3"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "1e4b40c7323adcfc0a41c4b88143ed58346ff65a288fc144329c5c45e05d70c6"++[[package]]+name = "bitflags"+version = "1.3.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "bef38d45163c2f1dde094a7dfd33ccf595c92905c8f8f4fdc18d06fb1037718a"++[[package]]+name = "bitflags"+version = "2.13.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "b588b76d00fde79687d7646a9b5bdf3cc0f655e0bbd080335a95d7e96f3587da"++[[package]]+name = "bitstream-io"+version = "4.10.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "7eff00be299a18769011411c9def0d827e8f2d7bf0c3dbf53633147a8867fd1f"+dependencies = [+ "no_std_io2",+]++[[package]]+name = "blade-graphics"+version = "0.7.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "e71cfb73b98eb9f58ee84048aa1bdf4e7497fd20c141b57523499fa066b48fed"+dependencies = [+ "ash",+ "ash-window",+ "bitflags 2.13.1",+ "bytemuck",+ "codespan-reporting",+ "glow",+ "gpu-alloc",+ "gpu-alloc-ash",+ "hidden-trait",+ "js-sys",+ "khronos-egl",+ "libloading",+ "log",+ "mint",+ "naga",+ "objc2",+ "objc2-app-kit",+ "objc2-core-foundation",+ "objc2-foundation",+ "objc2-metal",+ "objc2-quartz-core",+ "objc2-ui-kit",+ "once_cell",+ "raw-window-handle",+ "slab",+ "wasm-bindgen",+ "web-sys",+]++[[package]]+name = "blade-macros"+version = "0.3.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "27142319e2f4c264581067eaccb9f80acccdde60d8b4bf57cc50cd3152f109ca"+dependencies = [+ "proc-macro2",+ "quote",+ "syn 2.0.119",+]++[[package]]+name = "blade-util"+version = "0.3.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "3a6be3a82c001ba7a17b6f8e413ede5d1004e6047213f8efaf0ffc15b5c4904c"+dependencies = [+ "blade-graphics",+ "bytemuck",+ "log",+ "profiling",+]++[[package]]+name = "block"+version = "0.1.6"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "0d8c1fef690941d3e7788d328517591fecc684c084084702d6ff1641e993699a"++[[package]]+name = "block-buffer"+version = "0.10.4"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "3078c7629b62d3f0439517fa394996acacc5cbc91c5a20d8c658e77abd503a71"+dependencies = [+ "generic-array",+]++[[package]]+name = "block-buffer"+version = "0.12.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "d2f6c7dbe95a6ed67ad9f18e57daf93a2f034c524b99fd2b76d18fdfeb6660aa"+dependencies = [+ "hybrid-array",+]++[[package]]+name = "block-padding"+version = "0.3.3"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "a8894febbff9f758034a5b8e12d87918f56dfc64a8e1fe757d65e29041538d93"+dependencies = [+ "generic-array",+]++[[package]]+name = "block2"+version = "0.6.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "cdeb9d870516001442e364c5220d3574d2da8dc765554b4a617230d33fa58ef5"+dependencies = [+ "objc2",+]++[[package]]+name = "blocking"+version = "1.6.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "e83f8d02be6967315521be875afa792a316e28d57b5a2d401897e2a7921b7f21"+dependencies = [+ "async-channel 2.5.0",+ "async-task",+ "futures-io",+ "futures-lite 2.6.1",+ "piper",+]++[[package]]+name = "bstr"+version = "1.13.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "6bb31b46c14244e20ee9984b11bf5c992b91fb6939fea616e3512c8baecdbe5f"+dependencies = [+ "memchr",+ "serde_core",+]++[[package]]+name = "built"+version = "0.8.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "5c0e531d93d39c34eef561e929e8a7f86d77a5af08aac4f6d6e39976c51858e9"++[[package]]+name = "bumpalo"+version = "3.20.3"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "72f5acc6cb2ba439de613abc23857ec3d78374d8ed5ac84e9d11336e87da8649"++[[package]]+name = "bytemuck"+version = "1.25.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "95832e849adfb21180ccb6826a99da14e5d266ae5c2e668e1602cf234f153797"+dependencies = [+ "bytemuck_derive",+]++[[package]]+name = "bytemuck_derive"+version = "1.12.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "fc0e56a716f1e132ff6bf4bdac1c944a3fcdc1cae65f70a4a2a1ac3b401d2d1f"+dependencies = [+ "proc-macro2",+ "quote",+ "syn 3.0.3",+]++[[package]]+name = "byteorder"+version = "1.5.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "1fd0f2584146f6f2ef48085050886acf353beff7305ebd1ae69500e27c67f64b"++[[package]]+name = "byteorder-lite"+version = "0.1.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "8f1fe948ff07f4bd06c30984e69f5b4899c516a3ef74f34df92a2df2ab535495"++[[package]]+name = "bytes"+version = "1.12.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "fc652a48c352aef3ea3aed32080501cf3ef6ed5da78602a020c991775b0aff04"++[[package]]+name = "calloop"+version = "0.13.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "b99da2f8558ca23c71f4fd15dc57c906239752dd27ff3c00a1d56b685b7cbfec"+dependencies = [+ "bitflags 2.13.1",+ "log",+ "polling",+ "rustix 0.38.44",+ "slab",+ "thiserror 1.0.69",+]++[[package]]+name = "calloop-wayland-source"+version = "0.3.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "95a66a987056935f7efce4ab5668920b5d0dac4a7c99991a67395f13702ddd20"+dependencies = [+ "calloop",+ "rustix 0.38.44",+ "wayland-backend",+ "wayland-client",+]++[[package]]+name = "cbc"+version = "0.1.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "26b52a9543ae338f279b96b0b9fed9c8093744685043739079ce85cd58f289a6"+dependencies = [+ "cipher",+]++[[package]]+name = "cbindgen"+version = "0.28.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "eadd868a2ce9ca38de7eeafdcec9c7065ef89b42b32f0839278d55f35c54d1ff"+dependencies = [+ "heck 0.4.1",+ "indexmap",+ "log",+ "proc-macro2",+ "quote",+ "serde",+ "serde_json",+ "syn 2.0.119",+ "tempfile",+ "toml 0.8.23",+]++[[package]]+name = "cc"+version = "1.2.67"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "e17dd265a7d0f31ef544e1b20e03add05d3b45b491b633b10d67145d2acc1a38"+dependencies = [+ "find-msvc-tools",+ "jobserver",+ "libc",+ "shlex 2.0.1",+]++[[package]]+name = "cexpr"+version = "0.6.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "6fac387a98bb7c37292057cffc56d62ecb629900026402633ae9160df93a8766"+dependencies = [+ "nom 7.1.3",+]++[[package]]+name = "cfg-if"+version = "1.0.4"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "9330f8b2ff13f34540b44e946ef35111825727b38d33286ef986142615121801"++[[package]]+name = "cfg_aliases"+version = "0.2.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "f079e83a288787bcd14a6aea84cee5c87a67c5a3e660c30f557a3d24761b3527"++[[package]]+name = "cgl"+version = "0.3.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "0ced0551234e87afee12411d535648dd89d2e7f34c78b753395567aff3d447ff"+dependencies = [+ "libc",+]++[[package]]+name = "chacha20"+version = "0.10.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "d524456ba66e72eb8b115ff89e01e497f8e6d11d78b70b1aa13c0fbd97540a81"+dependencies = [+ "cfg-if",+ "cpufeatures 0.3.0",+ "rand_core 0.10.1",+]++[[package]]+name = "chrono"+version = "0.4.45"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "1aa79e62e7697b8e29b513a68abacf485adcd1fe8284a4316c5ae868e6633327"+dependencies = [+ "iana-time-zone",+ "js-sys",+ "num-traits",+ "serde",+ "wasm-bindgen",+ "windows-link 0.2.1",+]++[[package]]+name = "cipher"+version = "0.4.4"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "773f3b9af64447d2ce9850330c473515014aa235e6a783b02db81ff39e4a3dad"+dependencies = [+ "crypto-common 0.1.7",+ "inout",+ "zeroize",+]++[[package]]+name = "clang-sys"+version = "1.9.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "157a8ba7b480713b56f4c09fd13fc3e0a22a5dfab8097ba61cbc5feef950788a"+dependencies = [+ "glob",+ "libc",+ "libloading",+]++[[package]]+name = "cocoa"+version = "0.25.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "f6140449f97a6e97f9511815c5632d84c8aacf8ac271ad77c559218161a1373c"+dependencies = [+ "bitflags 1.3.2",+ "block",+ "cocoa-foundation 0.1.2",+ "core-foundation 0.9.4",+ "core-graphics 0.23.2",+ "foreign-types",+ "libc",+ "objc",+]++[[package]]+name = "cocoa"+version = "0.26.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "f79398230a6e2c08f5c9760610eb6924b52aa9e7950a619602baba59dcbbdbb2"+dependencies = [+ "bitflags 2.13.1",+ "block",+ "cocoa-foundation 0.2.0",+ "core-foundation 0.10.0",+ "core-graphics 0.24.0",+ "foreign-types",+ "libc",+ "objc",+]++[[package]]+name = "cocoa-foundation"+version = "0.1.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "8c6234cbb2e4c785b456c0644748b1ac416dd045799740356f8363dfe00c93f7"+dependencies = [+ "bitflags 1.3.2",+ "block",+ "core-foundation 0.9.4",+ "core-graphics-types 0.1.3",+ "libc",+ "objc",+]++[[package]]+name = "cocoa-foundation"+version = "0.2.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "e14045fb83be07b5acf1c0884b2180461635b433455fa35d1cd6f17f1450679d"+dependencies = [+ "bitflags 2.13.1",+ "block",+ "core-foundation 0.10.0",+ "core-graphics-types 0.2.0",+ "libc",+ "objc",+]++[[package]]+name = "codespan-reporting"+version = "0.12.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "fe6d2e5af09e8c8ad56c969f2157a3d4238cebc7c55f0a517728c38f7b200f81"+dependencies = [+ "serde",+ "termcolor",+ "unicode-width",+]++[[package]]+name = "color_quant"+version = "1.1.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "3d7b894f5411737b7867f4827955924d7c254fc9f4d91a6aad6b097804b1018b"++[[package]]+name = "command-fds"+version = "0.3.3"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "1b60b5124979fccd9addd89d8b97a1d6eebb4950694520c75ddd722535ea443f"+dependencies = [+ "nix 0.31.3",+ "thiserror 2.0.20",+]++[[package]]+name = "compression-codecs"+version = "0.4.38"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "ce2548391e9c1929c21bf6aa2680af86fe4c1b33e6cea9ac1cfeec0bd11218cf"+dependencies = [+ "compression-core",+ "deflate64",+ "flate2",+ "memchr",+]++[[package]]+name = "compression-core"+version = "0.4.32"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "cc14f565cf027a105f7a44ccf9e5b424348421a1d8952a8fc9d499d313107789"++[[package]]+name = "concurrent-queue"+version = "2.5.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "4ca0197aee26d1ae37445ee532fefce43251d24cc7c166799f4d46817f1d3973"+dependencies = [+ "crossbeam-utils",+]++[[package]]+name = "const-oid"+version = "0.10.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "a6ef517f0926dd24a1582492c791b6a4818a4d94e789a334894aa15b0d12f55c"++[[package]]+name = "const-random"+version = "0.1.18"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "87e00182fe74b066627d63b85fd550ac2998d4b0bd86bfed477a0ae4c7c71359"+dependencies = [+ "const-random-macro",+]++[[package]]+name = "const-random-macro"+version = "0.1.16"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "f9d839f2a20b0aee515dc581a6172f2321f96cab76c1a38a4c584a194955390e"+dependencies = [+ "getrandom 0.2.17",+ "once_cell",+ "tiny-keccak",+]++[[package]]+name = "convert_case"+version = "0.4.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "6245d59a3e82a7fc217c5828a6692dbc6dfb63a0c8c90495621f7b9d79704a0e"++[[package]]+name = "core-foundation"+version = "0.9.4"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "91e195e091a93c46f7102ec7818a2aa394e1e1771c3ab4825963fa03e45afb8f"+dependencies = [+ "core-foundation-sys",+ "libc",+]++[[package]]+name = "core-foundation"+version = "0.10.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "b55271e5c8c478ad3f38ad24ef34923091e0548492a266d19b3c0b4d82574c63"+dependencies = [+ "core-foundation-sys",+ "libc",+]++[[package]]+name = "core-foundation-sys"+version = "0.8.7"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "773648b94d0e5d620f64f280777445740e61fe701025087ec8b57f45c791888b"++[[package]]+name = "core-graphics"+version = "0.23.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "c07782be35f9e1140080c6b96f0d44b739e2278479f64e02fdab4e32dfd8b081"+dependencies = [+ "bitflags 1.3.2",+ "core-foundation 0.9.4",+ "core-graphics-types 0.1.3",+ "foreign-types",+ "libc",+]++[[package]]+name = "core-graphics"+version = "0.24.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "fa95a34622365fa5bbf40b20b75dba8dfa8c94c734aea8ac9a5ca38af14316f1"+dependencies = [+ "bitflags 2.13.1",+ "core-foundation 0.10.0",+ "core-graphics-types 0.2.0",+ "foreign-types",+ "libc",+]++[[package]]+name = "core-graphics-helmer-fork"+version = "0.24.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "32eb7c354ae9f6d437a6039099ce7ecd049337a8109b23d73e48e8ffba8e9cd5"+dependencies = [+ "bitflags 2.13.1",+ "core-foundation 0.9.4",+ "core-graphics-types 0.1.3",+ "foreign-types",+ "libc",+]++[[package]]+name = "core-graphics-types"+version = "0.1.3"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "45390e6114f68f718cc7a830514a96f903cccd70d02a8f6d9f643ac4ba45afaf"+dependencies = [+ "bitflags 1.3.2",+ "core-foundation 0.9.4",+ "libc",+]++[[package]]+name = "core-graphics-types"+version = "0.2.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "3d44a101f213f6c4cdc1853d4b78aef6db6bdfa3468798cc1d9912f4735013eb"+dependencies = [+ "bitflags 2.13.1",+ "core-foundation 0.10.0",+ "libc",+]++[[package]]+name = "core-graphics2"+version = "0.4.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "7e4583956b9806b69f73fcb23aee05eb3620efc282972f08f6a6db7504f8334d"+dependencies = [+ "bitflags 2.13.1",+ "block",+ "cfg-if",+ "core-foundation 0.10.0",+ "libc",+]++[[package]]+name = "core-text"+version = "21.0.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "a593227b66cbd4007b2a050dfdd9e1d1318311409c8d600dc82ba1b15ca9c130"+dependencies = [+ "core-foundation 0.10.0",+ "core-graphics 0.24.0",+ "foreign-types",+ "libc",+]++[[package]]+name = "core-video"+version = "0.4.3"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "d45e71d5be22206bed53c3c3cb99315fc4c3d31b8963808c6bc4538168c4f8ef"+dependencies = [+ "block",+ "core-foundation 0.10.0",+ "core-graphics2",+ "io-surface",+ "libc",+ "metal",+]++[[package]]+name = "core_maths"+version = "0.1.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "77745e017f5edba1a9c1d854f6f3a52dac8a12dd5af5d2f54aecf61e43d80d30"+dependencies = [+ "libm",+]++[[package]]+name = "cosmic-text"+version = "0.14.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "da46a9d5a8905cc538a4a5bceb6a4510de7a51049c5588c0114efce102bcbbe8"+dependencies = [+ "bitflags 2.13.1",+ "fontdb 0.16.2",+ "log",+ "rangemap",+ "rustc-hash 1.1.0",+ "rustybuzz 0.14.1",+ "self_cell",+ "smol_str",+ "swash",+ "sys-locale",+ "ttf-parser 0.21.1",+ "unicode-bidi",+ "unicode-linebreak",+ "unicode-script",+ "unicode-segmentation",+]++[[package]]+name = "cpufeatures"+version = "0.2.17"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "59ed5838eebb26a2bb2e58f6d5b5316989ae9d08bab10e0e6d103e656d1b0280"+dependencies = [+ "libc",+]++[[package]]+name = "cpufeatures"+version = "0.3.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "8b2a41393f66f16b0823bb79094d54ac5fbd34ab292ddafb9a0456ac9f87d201"+dependencies = [+ "libc",+]++[[package]]+name = "crc32fast"+version = "1.5.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "9481c1c90cbf2ac953f07c8d4a58aa3945c425b7185c9154d67a65e4230da511"+dependencies = [+ "cfg-if",+]++[[package]]+name = "crossbeam-deque"+version = "0.8.7"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "5181e0de7b61eb03a81e347d6dd8797bae9da5146707b51077e2d71a54ec0ceb"+dependencies = [+ "crossbeam-epoch",+ "crossbeam-utils",+]++[[package]]+name = "crossbeam-epoch"+version = "0.9.20"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "2d6914041f254d6e9176c01941b21115dcfb7089e55135a35411081bd106ef3f"+dependencies = [+ "crossbeam-utils",+]++[[package]]+name = "crossbeam-queue"+version = "0.3.13"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "803d13fb3b09d88be9f4dbc29062c66b19bf7170867ceb746d2a8689bf6c7a26"+dependencies = [+ "crossbeam-utils",+]++[[package]]+name = "crossbeam-utils"+version = "0.8.22"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "61803da095bee82a81bb1a452ecc25d3b2f1416d1897eb86430c6159ef717c17"++[[package]]+name = "crunchy"+version = "0.2.4"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "460fbee9c2c2f33933d720630a6a0bac33ba7053db5344fac858d4b8952d77d5"++[[package]]+name = "crypto-common"+version = "0.1.7"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "78c8292055d1c1df0cce5d180393dc8cce0abec0a7102adb6c7b1eef6016d60a"+dependencies = [+ "generic-array",+ "rand_core 0.6.4",+ "typenum",+]++[[package]]+name = "crypto-common"+version = "0.2.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "ce6e4c961d6cd6c9a86db418387425e8bdeaf05b3c8bc1411e6dca4c252f1453"+dependencies = [+ "hybrid-array",+]++[[package]]+name = "ctor"+version = "0.4.3"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "ec09e802f5081de6157da9a75701d6c713d8dc3ba52571fd4bd25f412644e8a6"+dependencies = [+ "ctor-proc-macro",+ "dtor",+]++[[package]]+name = "ctor-proc-macro"+version = "0.0.6"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "e2931af7e13dc045d8e9d26afccc6fa115d64e115c9c84b1166288b46f6782c2"++[[package]]+name = "data-url"+version = "0.3.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "be1e0bca6c3637f992fc1cc7cbc52a78c1ef6db076dbf1059c4323d6a2048376"++[[package]]+name = "deflate64"+version = "0.1.12"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "ac6b926516df9c60bfa16e107b21086399f8285a44ca9711344b9e553c5146e2"++[[package]]+name = "derive_more"+version = "0.99.20"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "6edb4b64a43d977b8e99788fe3a04d483834fba1215a7e02caa415b626497f7f"+dependencies = [+ "convert_case",+ "proc-macro2",+ "quote",+ "rustc_version",+ "syn 2.0.119",+]++[[package]]+name = "digest"+version = "0.10.7"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "9ed9a281f7bc9b7576e61468ba615a66a5c8cfdff42420a70aa82701a3b1e292"+dependencies = [+ "block-buffer 0.10.4",+ "crypto-common 0.1.7",+ "subtle",+]++[[package]]+name = "digest"+version = "0.11.3"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "f1dd6dbb5841937940781866fa1281a1ff7bd3bf827091440879f9994983d5c2"+dependencies = [+ "block-buffer 0.12.1",+ "const-oid",+ "crypto-common 0.2.2",+]++[[package]]+name = "dirs"+version = "4.0.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "ca3aa72a6f96ea37bbc5aa912f6788242832f75369bdfdadcb0e38423f100059"+dependencies = [+ "dirs-sys 0.3.7",+]++[[package]]+name = "dirs"+version = "5.0.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "44c45a9d03d6676652bcb5e724c7e988de1acad23a711b5217ab9cbecbec2225"+dependencies = [+ "dirs-sys 0.4.1",+]++[[package]]+name = "dirs-sys"+version = "0.3.7"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "1b1d1d91c932ef41c0f2663aa8b0ca0342d444d842c06914aa0a7e352d0bada6"+dependencies = [+ "libc",+ "redox_users",+ "winapi",+]++[[package]]+name = "dirs-sys"+version = "0.4.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "520f05a5cbd335fae5a99ff7a6ab8627577660ee5cfd6a94a6a929b52ff0321c"+dependencies = [+ "libc",+ "option-ext",+ "redox_users",+ "windows-sys 0.48.0",+]++[[package]]+name = "dispatch"+version = "0.2.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "bd0c93bb4b0c6d9b77f4435b0ae98c24d17f1c45b2ff844c6151a07256ca923b"++[[package]]+name = "dispatch2"+version = "0.3.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "1e0e367e4e7da84520dedcac1901e4da967309406d1e51017ae1abfb97adbd38"+dependencies = [+ "bitflags 2.13.1",+ "objc2",+]++[[package]]+name = "displaydoc"+version = "0.2.7"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "c6232dd377dcc64799954cbd3a9bb882e9cdc1308ccd87b1c098f1fb2eaf82a8"+dependencies = [+ "proc-macro2",+ "quote",+ "syn 3.0.3",+]++[[package]]+name = "dlib"+version = "0.5.3"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "ab8ecd87370524b461f8557c119c405552c396ed91fc0a8eec68679eab26f94a"+dependencies = [+ "libloading",+]++[[package]]+name = "downcast-rs"+version = "1.2.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "75b325c5dbd37f80359721ad39aca5a29fb04c89279657cffdda8736d0c0b9d2"++[[package]]+name = "dtor"+version = "0.0.6"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "97cbdf2ad6846025e8e25df05171abfb30e3ababa12ee0a0e44b9bbe570633a8"+dependencies = [+ "dtor-proc-macro",+]++[[package]]+name = "dtor-proc-macro"+version = "0.0.5"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "7454e41ff9012c00d53cf7f475c5e3afa3b91b7c90568495495e8d9bf47a1055"++[[package]]+name = "dunce"+version = "1.0.5"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "92773504d58c093f6de2459af4af33faa518c13451eb8f2b5698ed3d36e7c813"++[[package]]+name = "dwrote"+version = "0.11.5"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "9e1b35532432acc8b19ceed096e35dfa088d3ea037fe4f3c085f1f97f33b4d02"+dependencies = [+ "lazy_static",+ "libc",+ "winapi",+ "wio",+]++[[package]]+name = "dyn-clone"+version = "1.0.20"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "d0881ea181b1df73ff77ffaaf9c7544ecc11e82fba9b5f27b262a3c73a332555"++[[package]]+name = "either"+version = "1.17.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "9e5e8f6c15a24b9a3ee5efec809ccd006d3b30e8b3bb63c39af737c7f87daa1d"++[[package]]+name = "embed-resource"+version = "3.0.11"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "fbfdaacccebec3b28e4866b8973543c7647797db5ada1bdab552e48fe665fbbd"+dependencies = [+ "cc",+ "memchr",+ "rustc_version",+ "toml 1.1.4+spec-1.1.0",+ "vswhom",+ "winreg",+]++[[package]]+name = "encoding_rs"+version = "0.8.35"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "75030f3c4f45dafd7586dd6780965a8c7e8e285a5ecb86713e63a79c5b2766f3"+dependencies = [+ "cfg-if",+]++[[package]]+name = "endi"+version = "1.1.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "66b7e2430c6dff6a955451e2cfc438f09cea1965a9d6f87f7e3b90decc014099"++[[package]]+name = "enum-iterator"+version = "2.3.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "a4549325971814bda7a44061bf3fe7e487d447cba01e4220a4b454d630d7a016"+dependencies = [+ "enum-iterator-derive",+]++[[package]]+name = "enum-iterator-derive"+version = "1.5.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "685adfa4d6f3d765a26bc5dbc936577de9abf756c1feeb3089b01dd395034842"+dependencies = [+ "proc-macro2",+ "quote",+ "syn 2.0.119",+]++[[package]]+name = "enumflags2"+version = "0.7.12"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "1027f7680c853e056ebcec683615fb6fbbc07dbaa13b4d5d9442b146ded4ecef"+dependencies = [+ "enumflags2_derive",+ "serde",+]++[[package]]+name = "enumflags2_derive"+version = "0.7.12"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "67c78a4d8fdf9953a5c9d458f9efe940fd97a0cab0941c075a813ac594733827"+dependencies = [+ "proc-macro2",+ "quote",+ "syn 2.0.119",+]++[[package]]+name = "equator"+version = "0.4.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "4711b213838dfee0117e3be6ac926007d7f433d7bbe33595975d4190cb07e6fc"+dependencies = [+ "equator-macro",+]++[[package]]+name = "equator-macro"+version = "0.4.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "44f23cf4b44bfce11a86ace86f8a73ffdec849c9fd00a386a53d278bd9e81fb3"+dependencies = [+ "proc-macro2",+ "quote",+ "syn 2.0.119",+]++[[package]]+name = "equivalent"+version = "1.0.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "877a4ace8713b0bcf2a4e7eec82529c029f1d0619886d18145fea96c3ffe5c0f"++[[package]]+name = "erased-serde"+version = "0.4.10"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "d2add8a07dd6a8d93ff627029c51de145e12686fbc36ecb298ac22e74cf02dec"+dependencies = [+ "serde",+ "serde_core",+ "typeid",+]++[[package]]+name = "errno"+version = "0.3.14"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "39cab71617ae0d63f51a36d69f866391735b51691dbda63cf6f96d042b63efeb"+dependencies = [+ "libc",+ "windows-sys 0.61.2",+]++[[package]]+name = "etagere"+version = "0.2.15"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "fc89bf99e5dc15954a60f707c1e09d7540e5cd9af85fa75caa0b510bc08c5342"+dependencies = [+ "euclid",+ "svg_fmt",+]++[[package]]+name = "euclid"+version = "0.22.14"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "f1a05365e3b1c6d1650318537c7460c6923f1abdd272ad6842baa2b509957a06"+dependencies = [+ "num-traits",+]++[[package]]+name = "event-listener"+version = "2.5.3"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "0206175f82b8d6bf6652ff7d71a1e27fd2e4efde587fd368662814d6ec1d9ce0"++[[package]]+name = "event-listener"+version = "5.4.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "5a23add41df1562121a9393cb065eab5146a1242410f23a644851e90cfd669d2"+dependencies = [+ "parking",+ "pin-project-lite",+]++[[package]]+name = "event-listener-strategy"+version = "0.5.4"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "8be9f3dfaaffdae2972880079a491a1a8bb7cbed0b8dd7a347f668b4150a3b93"+dependencies = [+ "event-listener 5.4.2",+ "pin-project-lite",+]++[[package]]+name = "exr"+version = "1.74.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "711fe42c9964295e01ee3fba3f9fe0e1d24b98886950d68efe81b1c76e21adf3"+dependencies = [+ "bit_field",+ "half",+ "lebe",+ "miniz_oxide",+ "num-complex",+ "pulp",+ "rayon-core",+ "smallvec",+ "zune-inflate",+]++[[package]]+name = "fallible-iterator"+version = "0.3.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "2acce4a10f12dc2fb14a218589d4f1f62ef011b2d0cc4b3cb1bba8e94da14649"++[[package]]+name = "fallible-streaming-iterator"+version = "0.1.9"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "7360491ce676a36bf9bb3c56c1aa791658183a54d2744120f27285738d90465a"++[[package]]+name = "fastrand"+version = "1.9.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "e51093e27b0797c359783294ca4f0a911c270184cb10f85783b118614a1501be"+dependencies = [+ "instant",+]++[[package]]+name = "fastrand"+version = "2.5.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "da7c62ceae207dd37ea5b845da6a0696c799f85e97da1ab5b7910be3c1c80223"++[[package]]+name = "fax"+version = "0.2.7"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "caf1079563223d5d59d83c85886a56e586cfd5c1a26292e971a0fa266531ac5a"++[[package]]+name = "fdeflate"+version = "0.3.7"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "1e6853b52649d4ac5c0bd02320cddc5ba956bdb407c4b75a2c6b75bf51500f8c"+dependencies = [+ "simd-adler32",+]++[[package]]+name = "filedescriptor"+version = "0.8.3"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "e40758ed24c9b2eeb76c35fb0aebc66c626084edd827e07e1552279814c6682d"+dependencies = [+ "libc",+ "thiserror 1.0.69",+ "winapi",+]++[[package]]+name = "filetime"+version = "0.2.29"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "5c287a33c7f0a620c38e641e7f60827713987b3c0f26e8ddc9462cc69cf75759"+dependencies = [+ "cfg-if",+ "libc",+]++[[package]]+name = "find-msvc-tools"+version = "0.1.10"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "26b73573e6edcd2af0cdf47bd6cb58f0b3839491263c314eaad1ccf24430e1de"++[[package]]+name = "flate2"+version = "1.1.9"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "843fba2746e448b37e26a819579957415c8cef339bf08564fe8b7ddbd959573c"+dependencies = [+ "crc32fast",+ "miniz_oxide",+]++[[package]]+name = "float-cmp"+version = "0.9.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "98de4bbd547a563b716d8dfa9aad1cb19bfab00f4fa09a6a4ed21dbcf44ce9c4"++[[package]]+name = "float-ord"+version = "0.3.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "8ce81f49ae8a0482e4c55ea62ebbd7e5a686af544c00b9d090bba3ff9be97b3d"++[[package]]+name = "float_next_after"+version = "1.0.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "8bf7cc16383c4b8d58b9905a8509f02926ce3058053c056376248d958c9df1e8"++[[package]]+name = "fluent-uri"+version = "0.1.4"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "17c704e9dbe1ddd863da1e6ff3567795087b1eb201ce80d8fa81162e1516500d"+dependencies = [+ "bitflags 1.3.2",+]++[[package]]+name = "flume"+version = "0.11.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "da0e4dd2a88388a1f4ccc7c9ce104604dab68d9f408dc34cd45823d5a9069095"+dependencies = [+ "futures-core",+ "futures-sink",+ "nanorand",+ "spin",+]++[[package]]+name = "fnv"+version = "1.0.7"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "3f9eec918d3f24069decb9af1554cad7c880e2da24a9afd88aca000531ab82c1"++[[package]]+name = "foldhash"+version = "0.1.5"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "d9c4f5dac5e15c24eb999c26181a6ca40b39fe946cbe4c263c7209467bc83af2"++[[package]]+name = "font-types"+version = "0.12.3"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "75382bc7392ef10aad10935f92fc3db36d2d4dad0e5d96d8d65e04f89a07ec39"+dependencies = [+ "bytemuck",+]++[[package]]+name = "fontconfig-parser"+version = "0.5.8"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "bbc773e24e02d4ddd8395fd30dc147524273a83e54e0f312d986ea30de5f5646"+dependencies = [+ "roxmltree",+]++[[package]]+name = "fontdb"+version = "0.16.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "b0299020c3ef3f60f526a4f64ab4a3d4ce116b1acbf24cdd22da0068e5d81dc3"+dependencies = [+ "fontconfig-parser",+ "log",+ "memmap2",+ "slotmap",+ "tinyvec",+ "ttf-parser 0.20.0",+]++[[package]]+name = "fontdb"+version = "0.23.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "457e789b3d1202543297a350643cf459f836cade38934e7a4cf6a39e7cde2905"+dependencies = [+ "fontconfig-parser",+ "log",+ "memmap2",+ "slotmap",+ "tinyvec",+ "ttf-parser 0.25.1",+]++[[package]]+name = "foreign-types"+version = "0.5.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "d737d9aa519fb7b749cbc3b962edcf310a8dd1f4b67c91c4f83975dbdd17d965"+dependencies = [+ "foreign-types-macros",+ "foreign-types-shared",+]++[[package]]+name = "foreign-types-macros"+version = "0.2.4"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "ea5190182e6915eb873ddbc16e23b711b6eb1f9c00a0d0a3a91b5f6228475225"+dependencies = [+ "proc-macro2",+ "quote",+ "syn 3.0.3",+]++[[package]]+name = "foreign-types-shared"+version = "0.3.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "aa9a19cbb55df58761df49b23516a86d432839add4af60fc256da840f66ed35b"++[[package]]+name = "form_urlencoded"+version = "1.2.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "cb4cb245038516f5f85277875cdaa4f7d2c9a0fa0468de06ed190163b1581fcf"+dependencies = [+ "percent-encoding",+]++[[package]]+name = "freetype-sys"+version = "0.20.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "0e7edc5b9669349acfda99533e9e0bcf26a51862ab43b08ee7745c55d28eb134"+dependencies = [+ "cc",+ "libc",+ "pkg-config",+]++[[package]]+name = "fsevent-sys"+version = "4.1.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "76ee7a02da4d231650c7cea31349b889be2f45ddb3ef3032d2ec8185f6313fd2"+dependencies = [+ "libc",+]++[[package]]+name = "futf"+version = "0.1.5"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "df420e2e84819663797d1ec6544b13c5be84629e7bb00dc960d6917db2987843"+dependencies = [+ "mac",+ "new_debug_unreachable",+]++[[package]]+name = "futures"+version = "0.3.34"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "9a31d2a3fbaaeb2af2368bbdd904aa8e812d3c04a1ee10d3171f52d556e5d0a3"+dependencies = [+ "futures-channel",+ "futures-core",+ "futures-executor",+ "futures-io",+ "futures-sink",+ "futures-task",+ "futures-util",+]++[[package]]+name = "futures-channel"+version = "0.3.34"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "b1f9e3d69d39e4862ffed03ed071a76f9a13ba1d9109d355b0f0aa6b15e393c4"+dependencies = [+ "futures-core",+ "futures-sink",+]++[[package]]+name = "futures-core"+version = "0.3.34"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "92d699e522242e69e3003b94ecc1f960f3a5e015aa7c5d7486e65ad01dd94f5e"++[[package]]+name = "futures-executor"+version = "0.3.34"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "031b47cf1a3c6cc8bc2fc76cd437f521619387907d469316e7c0bc278f1f5432"+dependencies = [+ "futures-core",+ "futures-task",+ "futures-util",+]++[[package]]+name = "futures-io"+version = "0.3.34"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "53c0fa8157de1303bfffdaa1cc2a673bfffb60102f76b0ef4441659124373fed"++[[package]]+name = "futures-lite"+version = "1.13.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "49a9d51ce47660b1e808d3c990b4709f2f415d928835a17dfd16991515c46bce"+dependencies = [+ "fastrand 1.9.0",+ "futures-core",+ "futures-io",+ "memchr",+ "parking",+ "pin-project-lite",+ "waker-fn",+]++[[package]]+name = "futures-lite"+version = "2.6.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "f78e10609fe0e0b3f4157ffab1876319b5b0db102a2c60dc4626306dc46b44ad"+dependencies = [+ "fastrand 2.5.0",+ "futures-core",+ "futures-io",+ "parking",+ "pin-project-lite",+]++[[package]]+name = "futures-macro"+version = "0.3.34"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "9fb9654ba8355388abeb8dcb4fc62f511300867002afc858860463bdd9fe0c44"+dependencies = [+ "proc-macro2",+ "quote",+ "syn 3.0.3",+]++[[package]]+name = "futures-sink"+version = "0.3.34"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "1944426bf7d03f1d14f708785e4b33efd750b36d48a157b836b3efc15ede8e1d"++[[package]]+name = "futures-task"+version = "0.3.34"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "cd417de3d1d015fc3bfd2b1ea46dfc7bab72ef86f1cc7cc9c78e728b34a6d1fd"++[[package]]+name = "futures-util"+version = "0.3.34"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "0d50a92467f8ba5dd6e3ee5d4bd04d73ab2e4e1c44474a0674821dfce14b79bc"+dependencies = [+ "futures-channel",+ "futures-core",+ "futures-io",+ "futures-macro",+ "futures-sink",+ "futures-task",+ "memchr",+ "pin-project-lite",+ "slab",+]++[[package]]+name = "generic-array"+version = "0.14.7"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "85649ca51fd72272d7821adaf274ad91c288277713d9c18820d8499a7ff69e9a"+dependencies = [+ "typenum",+ "version_check",+]++[[package]]+name = "gethostname"+version = "1.1.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "1bd49230192a3797a9a4d6abe9b3eed6f7fa4c8a8a4947977c6f80025f92cbd8"+dependencies = [+ "rustix 1.1.4",+ "windows-link 0.2.1",+]++[[package]]+name = "getrandom"+version = "0.2.17"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "ff2abc00be7fca6ebc474524697ae276ad847ad0a6b3faa4bcb027e9a4614ad0"+dependencies = [+ "cfg-if",+ "js-sys",+ "libc",+ "wasi",+ "wasm-bindgen",+]++[[package]]+name = "getrandom"+version = "0.3.4"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "899def5c37c4fd7b2664648c28120ecec138e4d395b459e5ca34f9cce2dd77fd"+dependencies = [+ "cfg-if",+ "libc",+ "r-efi 5.3.0",+ "wasip2",+]++[[package]]+name = "getrandom"+version = "0.4.3"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "300e883d756b2e4ec94e02791f39b04b522276138852cfc41d9fb7e904106099"+dependencies = [+ "cfg-if",+ "js-sys",+ "libc",+ "r-efi 6.0.0",+ "rand_core 0.10.1",+ "wasm-bindgen",+]++[[package]]+name = "gif"+version = "0.14.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "ee8cfcc411d9adbbaba82fb72661cc1bcca13e8bba98b364e62b2dba8f960159"+dependencies = [+ "color_quant",+ "weezl",+]++[[package]]+name = "glob"+version = "0.3.4"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "e4eba85ea1d0a966a983acd07deee566e67395d2d96b6fb39e62b5a833f1eb0b"++[[package]]+name = "globset"+version = "0.4.20"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "07c34a9410465b45bd9787443bc7370f37735bad04b0f0cd57ff1a3186c98988"+dependencies = [+ "aho-corasick",+ "bstr",+ "log",+ "regex-automata",+ "regex-syntax",+]++[[package]]+name = "globwalk"+version = "0.8.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "93e3af942408868f6934a7b85134a3230832b9977cf66125df2f9edcfce4ddcc"+dependencies = [+ "bitflags 1.3.2",+ "ignore",+ "walkdir",+]++[[package]]+name = "gloo-timers"+version = "0.3.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "bbb143cf96099802033e0d4f4963b19fd2e0b728bcf076cd9cf7f6634f092994"+dependencies = [+ "futures-channel",+ "futures-core",+ "js-sys",+ "wasm-bindgen",+]++[[package]]+name = "glow"+version = "0.16.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "c5e5ea60d70410161c8bf5da3fdfeaa1c72ed2c15f8bbb9d19fe3a4fad085f08"+dependencies = [+ "js-sys",+ "slotmap",+ "wasm-bindgen",+ "web-sys",+]++[[package]]+name = "gpu-alloc"+version = "0.6.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "45cf04b2726f02df5508c6de726acdc90cdf97ac771a9a0ffd8ba10a6e696bf9"+dependencies = [+ "bitflags 2.13.1",+ "gpu-alloc-types",+]++[[package]]+name = "gpu-alloc-ash"+version = "0.7.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "643756f08ef6def813c776199e4766596395a4c6530373c9a4374a64de2f53a1"+dependencies = [+ "ash",+ "gpu-alloc-types",+ "tinyvec",+]++[[package]]+name = "gpu-alloc-types"+version = "0.3.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "b2bbed164dd10ed526c2e4fe3e721ca4a71c61730e5aafac6844b417b3227058"+dependencies = [+ "bitflags 2.13.1",+]++[[package]]+name = "gpui"+version = "0.2.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "979b45cfa6ec723b6f42330915a1b3769b930d02b2d505f9697f8ca602bee707"+dependencies = [+ "anyhow",+ "as-raw-xcb-connection",+ "ashpd 0.11.1",+ "async-task",+ "bindgen",+ "blade-graphics",+ "blade-macros",+ "blade-util",+ "block",+ "bytemuck",+ "calloop",+ "calloop-wayland-source",+ "cbindgen",+ "cocoa 0.26.0",+ "cocoa-foundation 0.2.0",+ "core-foundation 0.10.0",+ "core-foundation-sys",+ "core-graphics 0.24.0",+ "core-text",+ "core-video",+ "cosmic-text",+ "ctor",+ "derive_more",+ "embed-resource",+ "etagere",+ "filedescriptor",+ "flume",+ "foreign-types",+ "futures",+ "gpui-macros",+ "gpui_collections",+ "gpui_http_client",+ "gpui_media",+ "gpui_refineable",+ "gpui_semantic_version",+ "gpui_sum_tree",+ "gpui_util",+ "gpui_util_macros",+ "image",+ "inventory",+ "itertools 0.14.0",+ "libc",+ "log",+ "lyon",+ "metal",+ "naga",+ "num_cpus",+ "objc",+ "oo7",+ "open",+ "parking",+ "parking_lot",+ "pathfinder_geometry",+ "pin-project",+ "postage",+ "profiling",+ "rand 0.9.5",+ "raw-window-handle",+ "resvg",+ "schemars",+ "seahash",+ "serde",+ "serde_json",+ "slotmap",+ "smallvec",+ "smol",+ "stacksafe",+ "strum 0.27.2",+ "taffy",+ "thiserror 2.0.20",+ "usvg",+ "uuid",+ "waker-fn",+ "wayland-backend",+ "wayland-client",+ "wayland-cursor",+ "wayland-protocols 0.31.2",+ "wayland-protocols-plasma",+ "windows 0.61.3",+ "windows-core 0.61.2",+ "windows-numerics",+ "windows-registry 0.5.3",+ "x11-clipboard",+ "x11rb",+ "xkbcommon",+ "zed-font-kit",+ "zed-scap",+ "zed-xim",+]++[[package]]+name = "gpui-component"+version = "0.5.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "d021d46b4088d3d93a57ccdf443da85695a77272108caca2f6fe5369f584966a"+dependencies = [+ "aho-corasick",+ "anyhow",+ "chrono",+ "core-text",+ "enum-iterator",+ "gpui",+ "gpui-component-macros",+ "gpui-macros",+ "html5ever",+ "itertools 0.13.0",+ "lsp-types",+ "markdown",+ "markup5ever_rcdom",+ "notify",+ "num-traits",+ "once_cell",+ "paste",+ "regex",+ "ropey",+ "rust-i18n",+ "schemars",+ "serde",+ "serde_json",+ "serde_repr",+ "smallvec",+ "smol",+ "tracing",+ "tree-sitter",+ "tree-sitter-bash",+ "tree-sitter-c",+ "tree-sitter-c-sharp",+ "tree-sitter-cmake",+ "tree-sitter-cpp",+ "tree-sitter-css",+ "tree-sitter-diff",+ "tree-sitter-elixir",+ "tree-sitter-embedded-template",+ "tree-sitter-go",+ "tree-sitter-graphql",+ "tree-sitter-html",+ "tree-sitter-java",+ "tree-sitter-javascript",+ "tree-sitter-jsdoc",+ "tree-sitter-json",+ "tree-sitter-make",+ "tree-sitter-md",+ "tree-sitter-proto",+ "tree-sitter-python",+ "tree-sitter-ruby",+ "tree-sitter-rust",+ "tree-sitter-scala",+ "tree-sitter-sequel",+ "tree-sitter-swift",+ "tree-sitter-toml-ng",+ "tree-sitter-typescript",+ "tree-sitter-yaml",+ "tree-sitter-zig",+ "unicode-segmentation",+ "uuid",+ "zed-sum-tree",+]++[[package]]+name = "gpui-component-macros"+version = "0.5.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "86fbc2d84bf91717b171320e6adc600d91ccb3ed259448f3b006787633c1c615"+dependencies = [+ "proc-macro2",+ "quote",+ "syn 2.0.119",+]++[[package]]+name = "gpui-macros"+version = "0.2.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "bcb02dd63a2859714ac7b6b476937617c3c744157af1b49f7c904023a79039be"+dependencies = [+ "heck 0.5.0",+ "proc-macro2",+ "quote",+ "syn 2.0.119",+]++[[package]]+name = "gpui_collections"+version = "0.2.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "ae39dc6d3d201be97e4bc08d96dbef2bc5b5c3d5734e05786e8cc3043342351c"+dependencies = [+ "indexmap",+ "rustc-hash 2.1.3",+]++[[package]]+name = "gpui_derive_refineable"+version = "0.2.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "644de174341a87b3478bd65b66bca38af868bcf2b2e865700523734f83cfc664"+dependencies = [+ "proc-macro2",+ "quote",+ "syn 2.0.119",+]++[[package]]+name = "gpui_http_client"+version = "0.2.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "23822b0a6d2c5e6a42507980a0ab3848610ea908942c8ef98187f646f690335e"+dependencies = [+ "anyhow",+ "async-compression",+ "async-fs",+ "bytes",+ "derive_more",+ "futures",+ "gpui_util",+ "http",+ "http-body",+ "log",+ "parking_lot",+ "serde",+ "serde_json",+ "sha2 0.10.9",+ "tempfile",+ "url",+ "zed-async-tar",+ "zed-reqwest",+]++[[package]]+name = "gpui_media"+version = "0.2.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "05cb8912ae17371725132d2b7eec6797a255accc95d58ee5c1134b529810f14b"+dependencies = [+ "anyhow",+ "bindgen",+ "core-foundation 0.10.0",+ "core-video",+ "ctor",+ "foreign-types",+ "metal",+ "objc",+]++[[package]]+name = "gpui_perf"+version = "0.2.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "f40a0961dcf598955130e867f4b731150a20546427b41b1a63767c1037a86d77"+dependencies = [+ "gpui_collections",+ "serde",+ "serde_json",+]++[[package]]+name = "gpui_refineable"+version = "0.2.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "258cb099254e9468181aee5614410fba61db4ae115fc1d51b4a0b985f60d6641"+dependencies = [+ "gpui_derive_refineable",+]++[[package]]+name = "gpui_semantic_version"+version = "0.2.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "201e45eff7b695528fb3af6560a534943fbc2db5323d755b9d198bd743948e35"+dependencies = [+ "anyhow",+ "serde",+]++[[package]]+name = "gpui_sum_tree"+version = "0.2.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "e4f3bedd573fafafa13d1200b356c588cf094fb2786e3684bb3f5ea59b549fa9"+dependencies = [+ "arrayvec",+ "log",+ "rayon",+]++[[package]]+name = "gpui_util"+version = "0.2.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "68faea25903ae524de9af83990b9aa51bcbc8dd085929ac0aea7fd41905e05c3"+dependencies = [+ "anyhow",+ "async-fs",+ "async_zip",+ "command-fds",+ "dirs 4.0.0",+ "dunce",+ "futures",+ "futures-lite 1.13.0",+ "globset",+ "gpui_collections",+ "itertools 0.14.0",+ "libc",+ "log",+ "nix 0.29.0",+ "regex",+ "rust-embed",+ "schemars",+ "serde",+ "serde_json",+ "serde_json_lenient",+ "shlex 1.3.0",+ "smol",+ "take-until",+ "tempfile",+ "tendril",+ "unicase",+ "walkdir",+ "which",+]++[[package]]+name = "gpui_util_macros"+version = "0.2.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "2c28f65ef47fb97e21e82fd4dd75ccc2506eda010c846dc8054015ea234f1a22"+dependencies = [+ "gpui_perf",+ "quote",+ "syn 2.0.119",+]++[[package]]+name = "grid"+version = "0.18.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "12101ecc8225ea6d675bc70263074eab6169079621c2186fe0c66590b2df9681"++[[package]]+name = "h2"+version = "0.4.15"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "6cb093c84e8bd9b188d4c4a8cb6579fc016968d14c99882163cd3ff402a4f155"+dependencies = [+ "atomic-waker",+ "bytes",+ "fnv",+ "futures-core",+ "futures-sink",+ "http",+ "indexmap",+ "slab",+ "tokio",+ "tokio-util",+ "tracing",+]++[[package]]+name = "half"+version = "2.7.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "6ea2d84b969582b4b1864a92dc5d27cd2b77b622a8d79306834f1be5ba20d84b"+dependencies = [+ "cfg-if",+ "crunchy",+ "num-traits",+ "zerocopy",+]++[[package]]+name = "hashbrown"+version = "0.14.5"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "e5274423e17b7c9fc20b6e7e208532f9b19825d82dfd615708b70edd83df41f1"+dependencies = [+ "ahash",+]++[[package]]+name = "hashbrown"+version = "0.15.5"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "9229cfe53dfd69f0609a49f65461bd93001ea1ef889cd5529dd176593f5338a1"+dependencies = [+ "foldhash",+]++[[package]]+name = "hashbrown"+version = "0.17.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "ed5909b6e89a2db4456e54cd5f673791d7eca6732202bbf2a9cc504fe2f9b84a"++[[package]]+name = "hashlink"+version = "0.9.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "6ba4ff7128dee98c7dc9794b6a411377e1404dba1c97deb8d1a55297bd25d8af"+dependencies = [+ "hashbrown 0.14.5",+]++[[package]]+name = "heck"+version = "0.4.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "95505c38b4572b2d910cecb0281560f54b440a19336cbbcb27bf6ce6adc6f5a8"++[[package]]+name = "heck"+version = "0.5.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "2304e00983f87ffb38b55b444b5e3b60a884b5d30c0fca7d82fe33449bbe55ea"++[[package]]+name = "hermit-abi"+version = "0.5.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "fc0fef456e4baa96da950455cd02c081ca953b141298e41db3fc7e36b1da849c"++[[package]]+name = "hex"+version = "0.4.3"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "7f24254aa9a54b5c858eaee2f5bccdb46aaf0e486a595ed5fd8f86ba55232a70"++[[package]]+name = "hexf-parse"+version = "0.2.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "dfa686283ad6dd069f105e5ab091b04c62850d3e4cf5d67debad1933f55023df"++[[package]]+name = "hidden-trait"+version = "0.1.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "68ed9e850438ac849bec07e7d09fbe9309cbd396a5988c30b010580ce08860df"+dependencies = [+ "proc-macro2",+ "quote",+ "syn 1.0.109",+]++[[package]]+name = "hkdf"+version = "0.12.4"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "7b5f8eb2ad728638ea2c7d47a21db23b7b58a72ed6a38256b8a1849f15fbbdf7"+dependencies = [+ "hmac",+]++[[package]]+name = "hmac"+version = "0.12.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "6c49c37c09c17a53d937dfbb742eb3a961d65a994e6bcdcf37e7399d0cc8ab5e"+dependencies = [+ "digest 0.10.7",+]++[[package]]+name = "home"+version = "0.5.12"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "cc627f471c528ff0c4a49e1d5e60450c8f6461dd6d10ba9dcd3a61d3dff7728d"+dependencies = [+ "windows-sys 0.61.2",+]++[[package]]+name = "html5ever"+version = "0.27.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "c13771afe0e6e846f1e67d038d4cb29998a6779f93c809212e4e9c32efd244d4"+dependencies = [+ "log",+ "mac",+ "markup5ever",+ "proc-macro2",+ "quote",+ "syn 2.0.119",+]++[[package]]+name = "http"+version = "1.5.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "918d3568bebf352712bc2ef3d46a8bcf1a75b373be6539de198e9105cbbf9ce0"+dependencies = [+ "bytes",+ "itoa",+]++[[package]]+name = "http-body"+version = "1.1.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "ca2a8f2913ee65f60facd6a5905613afaa448497a0230cc41ce022d93290bc2c"+dependencies = [+ "bytes",+ "http",+]++[[package]]+name = "http-body-util"+version = "0.1.5"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "23169fe34a5fbcdd3f3862e78fb9b6fccd5f02a6dc6f732547005d45631ce71c"+dependencies = [+ "bytes",+ "futures-core",+ "http",+ "http-body",+ "pin-project-lite",+]++[[package]]+name = "httparse"+version = "1.10.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "6dbf3de79e51f3d586ab4cb9d5c3e2c14aa28ed23d180cf89b4df0454a69cc87"++[[package]]+name = "hybrid-array"+version = "0.4.14"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "707114b52a152fa7bdb290cd7cd5912d9467273b6d74e21b8d81aca1f8533f6b"+dependencies = [+ "typenum",+]++[[package]]+name = "hyper"+version = "1.11.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "d22053281f852e11534f5198498373cbb59295120a20771d90f7ed1897490a72"+dependencies = [+ "atomic-waker",+ "bytes",+ "futures-channel",+ "futures-core",+ "h2",+ "http",+ "http-body",+ "httparse",+ "itoa",+ "pin-project-lite",+ "smallvec",+ "tokio",+ "want",+]++[[package]]+name = "hyper-rustls"+version = "0.27.9"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "33ca68d021ef39cf6463ab54c1d0f5daf03377b70561305bb89a8f83aab66e0f"+dependencies = [+ "http",+ "hyper",+ "hyper-util",+ "rustls",+ "rustls-native-certs",+ "tokio",+ "tokio-rustls",+ "tower-service",+]++[[package]]+name = "hyper-util"+version = "0.1.20"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "96547c2556ec9d12fb1578c4eaf448b04993e7fb79cbaad930a656880a6bdfa0"+dependencies = [+ "bytes",+ "futures-channel",+ "futures-util",+ "http",+ "http-body",+ "hyper",+ "libc",+ "pin-project-lite",+ "socket2",+ "tokio",+ "tower-service",+ "tracing",+]++[[package]]+name = "iana-time-zone"+version = "0.1.65"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "e31bc9ad994ba00e440a8aa5c9ef0ec67d5cb5e5cb0cc7f8b744a35b389cc470"+dependencies = [+ "android_system_properties",+ "core-foundation-sys",+ "iana-time-zone-haiku",+ "js-sys",+ "log",+ "wasm-bindgen",+ "windows-core 0.62.2",+]++[[package]]+name = "iana-time-zone-haiku"+version = "0.1.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "f31827a206f56af32e590ba56d5d2d085f558508192593743f16b2306495269f"+dependencies = [+ "cc",+]++[[package]]+name = "icu_collections"+version = "2.3.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "fa68d21081c4a05d5a901a1c62add574c77048b6a1c67be3b50ce0b60d4ca513"+dependencies = [+ "displaydoc",+ "potential_utf",+ "utf8_iter",+ "yoke",+ "zerofrom",+ "zerovec",+]++[[package]]+name = "icu_locale_core"+version = "2.3.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "d56e28588da92eee5c3201a6eff33fabdd49b62269c8938d4ff050ce4d900deb"+dependencies = [+ "displaydoc",+ "litemap",+ "tinystr",+ "writeable",+ "zerovec",+]++[[package]]+name = "icu_normalizer"+version = "2.3.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "12f9cf5f235641ed274641dd81c3f28d870e276763d0797aeeab72317b1c646f"+dependencies = [+ "icu_collections",+ "icu_normalizer_data",+ "icu_properties",+ "icu_provider",+ "smallvec",+ "zerovec",+]++[[package]]+name = "icu_normalizer_data"+version = "2.3.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "1563da1ed3e0b3bf3d74c9b85917ac9c56464d2f57242270c09c9e752f8021a0"++[[package]]+name = "icu_properties"+version = "2.3.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "7e7ca276ad3145661a65914e6daf131ca5120cd3dcee8f8f3214b8875184a148"+dependencies = [+ "displaydoc",+ "icu_collections",+ "icu_locale_core",+ "icu_properties_data",+ "icu_provider",+ "zerotrie",+ "zerovec",+]++[[package]]+name = "icu_properties_data"+version = "2.3.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "e590f038c1464a96894fd6d10127e90a8be4509f56ff7ecef851b15cee0b7caa"++[[package]]+name = "icu_provider"+version = "2.3.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "92a7ed671a6aad807a8651a2e1782a6598fda9ce5185dd8158549e95a91c6428"+dependencies = [+ "displaydoc",+ "icu_locale_core",+ "writeable",+ "yoke",+ "zerofrom",+ "zerotrie",+ "zerovec",+]++[[package]]+name = "idna"+version = "1.1.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "3b0875f23caa03898994f6ddc501886a45c7d3d62d04d2d90788d47be1b1e4de"+dependencies = [+ "idna_adapter",+ "smallvec",+ "utf8_iter",+]++[[package]]+name = "idna_adapter"+version = "1.2.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "cb68373c0d6620ef8105e855e7745e18b0d00d3bdb07fb532e434244cdb9a714"+dependencies = [+ "icu_normalizer",+ "icu_properties",+]++[[package]]+name = "ignore"+version = "0.4.33"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "00b69833ed729dc5aa7d19541d96d6cf8e9137194207a04916d658e43168402f"+dependencies = [+ "crossbeam-deque",+ "globset",+ "log",+ "memchr",+ "regex-automata",+ "same-file",+ "walkdir",+ "winapi-util",+]++[[package]]+name = "image"+version = "0.25.10"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "85ab80394333c02fe689eaf900ab500fbd0c2213da414687ebf995a65d5a6104"+dependencies = [+ "bytemuck",+ "byteorder-lite",+ "color_quant",+ "exr",+ "gif",+ "image-webp",+ "moxcms",+ "num-traits",+ "png 0.18.1",+ "qoi",+ "ravif",+ "rayon",+ "rgb",+ "tiff",+ "zune-core",+ "zune-jpeg",+]++[[package]]+name = "image-webp"+version = "0.2.4"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "525e9ff3e1a4be2fbea1fdf0e98686a6d98b4d8f937e1bf7402245af1909e8c3"+dependencies = [+ "byteorder-lite",+ "quick-error",+]++[[package]]+name = "imagesize"+version = "0.13.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "edcd27d72f2f071c64249075f42e205ff93c9a4c5f6c6da53e79ed9f9832c285"++[[package]]+name = "imgref"+version = "1.12.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "89194689a993ab15268672e99e7b0e19da2da3268ac682e8f02d29d4d1434cd7"++[[package]]+name = "indexmap"+version = "2.14.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "d466e9454f08e4a911e14806c24e16fba1b4c121d1ea474396f396069cf949d9"+dependencies = [+ "equivalent",+ "hashbrown 0.17.1",+ "serde",+ "serde_core",+]++[[package]]+name = "inotify"+version = "0.10.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "fdd168d97690d0b8c412d6b6c10360277f4d7ee495c5d0d5d5fe0854923255cc"+dependencies = [+ "bitflags 1.3.2",+ "inotify-sys",+ "libc",+]++[[package]]+name = "inotify-sys"+version = "0.1.8"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "c033f80b2c113cdf91ab7a33faa9cbc014726dcad99880c8609af2a370edf37d"+dependencies = [+ "libc",+]++[[package]]+name = "inout"+version = "0.1.4"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "879f10e63c20629ecabbb64a8010319738c66a5cd0c29b02d63d272b03751d01"+dependencies = [+ "block-padding",+ "generic-array",+]++[[package]]+name = "instant"+version = "0.1.13"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "e0242819d153cba4b4b05a5a8f2a7e9bbf97b6055b2a002b395c96b5ff3c0222"+dependencies = [+ "cfg-if",+]++[[package]]+name = "interpolate_name"+version = "0.2.4"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "c34819042dc3d3971c46c2190835914dfbe0c3c13f61449b2997f4e9722dfa60"+dependencies = [+ "proc-macro2",+ "quote",+ "syn 2.0.119",+]++[[package]]+name = "inventory"+version = "0.3.24"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "a4f0c30c76f2f4ccee3fe55a2435f691ca00c0e4bd87abe4f4a851b1d4dac39b"+dependencies = [+ "rustversion",+]++[[package]]+name = "io-surface"+version = "0.16.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "554b8c5d64ec09a3a520fe58e4d48a73e00ff32899cdcbe32a4877afd4968b8e"+dependencies = [+ "cgl",+ "core-foundation 0.10.0",+ "core-foundation-sys",+ "leaky-cow",+]++[[package]]+name = "ipnet"+version = "2.12.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "6a756c3fac73139e83f14c2d742155dd2b78d3ee56597b419a0579b7bdd6dd78"++[[package]]+name = "is-docker"+version = "0.2.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "928bae27f42bc99b60d9ac7334e3a21d10ad8f1835a4e12ec3ec0464765ed1b3"+dependencies = [+ "once_cell",+]++[[package]]+name = "is-wsl"+version = "0.4.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "173609498df190136aa7dea1a91db051746d339e18476eed5ca40521f02d7aa5"+dependencies = [+ "is-docker",+ "once_cell",+]++[[package]]+name = "itertools"+version = "0.11.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "b1c173a5686ce8bfa551b3563d0c2170bf24ca44da99c7ca4bfdab5418c3fe57"+dependencies = [+ "either",+]++[[package]]+name = "itertools"+version = "0.13.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "413ee7dfc52ee1a4949ceeb7dbc8a33f2d6c088194d9f922fb8318faf1f01186"+dependencies = [+ "either",+]++[[package]]+name = "itertools"+version = "0.14.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "2b192c782037fadd9cfa75548310488aabdbf3d2da73885b31bd0abd03351285"+dependencies = [+ "either",+]++[[package]]+name = "itoa"+version = "1.0.18"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "8f42a60cbdf9a97f5d2305f08a87dc4e09308d1276d28c869c684d7777685682"++[[package]]+name = "jobserver"+version = "0.1.35"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "1c00acbd29eabad4a2392fa0e921c874934dbbf4194312ad20f04a0ed67a3cb3"+dependencies = [+ "getrandom 0.4.3",+ "libc",+]++[[package]]+name = "js-sys"+version = "0.3.104"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "0e0c1080212aad755ea003d18543e8768dd432c48819efd73a7bf1e39b7a5a3a"+dependencies = [+ "cfg-if",+ "futures-util",+ "wasm-bindgen",+]++[[package]]+name = "khronos-egl"+version = "6.0.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "6aae1df220ece3c0ada96b8153459b67eebe9ae9212258bb0134ae60416fdf76"+dependencies = [+ "libc",+ "libloading",+]++[[package]]+name = "kqueue"+version = "1.2.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "8d763e5b24120b4ddf50de6c92308156765aabfbbccebf401da7cff2d70a41ea"+dependencies = [+ "kqueue-sys",+ "libc",+]++[[package]]+name = "kqueue-sys"+version = "1.1.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "07293a4e297ac234359b510362495713f75ea345d5307140414f20c69ffeb087"+dependencies = [+ "bitflags 2.13.1",+ "libc",+]++[[package]]+name = "kurbo"+version = "0.11.3"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "c62026ae44756f8a599ba21140f350303d4f08dcdcc71b5ad9c9bb8128c13c62"+dependencies = [+ "arrayvec",+ "euclid",+ "smallvec",+]++[[package]]+name = "kv-log-macro"+version = "1.0.7"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "0de8b303297635ad57c9f5059fd9cee7a47f8e8daa09df0fcd07dd39fb22977f"+dependencies = [+ "log",+]++[[package]]+name = "lazy_static"+version = "1.5.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "bbd2bcb4c963f2ddae06a2efc7e9f3591312473c50c6685e1f298068316e66fe"+dependencies = [+ "spin",+]++[[package]]+name = "leak"+version = "0.1.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "bd100e01f1154f2908dfa7d02219aeab25d0b9c7fa955164192e3245255a0c73"++[[package]]+name = "leaky-cow"+version = "0.1.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "40a8225d44241fd324a8af2806ba635fc7c8a7e9a7de4d5cf3ef54e71f5926fc"+dependencies = [+ "leak",+]++[[package]]+name = "lebe"+version = "0.5.3"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "7a79a3332a6609480d7d0c9eab957bca6b455b91bb84e66d19f5ff66294b85b8"++[[package]]+name = "libc"+version = "0.2.189"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "3eaf3ede3fee6db1a4c2ee091bf8a8b4dccdc6d17f656fb07896ee72867612f2"++[[package]]+name = "libfuzzer-sys"+version = "0.4.13"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "a9fd2f41a1cba099f79a0b6b6c35656cf7c03351a7bae8ff0f28f25270f929d2"+dependencies = [+ "arbitrary",+ "cc",+]++[[package]]+name = "libloading"+version = "0.8.9"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "d7c4b02199fee7c5d21a5ae7d8cfa79a6ef5bb2fc834d6e9058e89c825efdc55"+dependencies = [+ "cfg-if",+ "windows-link 0.2.1",+]++[[package]]+name = "libm"+version = "0.2.16"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "b6d2cec3eae94f9f509c767b45932f1ada8350c4bdb85af2fcab4a3c14807981"++[[package]]+name = "libredox"+version = "0.1.19"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "2026a5056764a10b2bf5d56488cba40da507f5493a6a429340e2004d9ed085fa"+dependencies = [+ "libc",+]++[[package]]+name = "libsqlite3-sys"+version = "0.30.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "2e99fb7a497b1e3339bc746195567ed8d3e24945ecd636e3619d20b9de9e9149"+dependencies = [+ "cc",+ "pkg-config",+ "vcpkg",+]++[[package]]+name = "linux-raw-sys"+version = "0.4.15"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "d26c52dbd32dccf2d10cac7725f8eae5296885fb5703b261f7d0a0739ec807ab"++[[package]]+name = "linux-raw-sys"+version = "0.12.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "32a66949e030da00e8c7d4434b251670a91556f4144941d37452769c25d58a53"++[[package]]+name = "litemap"+version = "0.8.3"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "47d9d19d1d6efa0109d2f65ff4c85cddd50bd572e5a00127ab10987290bcefae"++[[package]]+name = "lock_api"+version = "0.4.14"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "224399e74b87b5f3557511d98dff8b14089b3dadafcab6bb93eab67d3aace965"+dependencies = [+ "scopeguard",+]++[[package]]+name = "log"+version = "0.4.33"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "0ceec5bc11778974d1bcb055b18002eba7f4b3518b6a0081b3af5f21666da9ad"+dependencies = [+ "serde_core",+ "value-bag",+]++[[package]]+name = "loop9"+version = "0.1.5"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "0fae87c125b03c1d2c0150c90365d7d6bcc53fb73a9acaef207d2d065860f062"+dependencies = [+ "imgref",+]++[[package]]+name = "lru-slab"+version = "0.1.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "112b39cec0b298b6c1999fee3e31427f74f676e4cb9879ed1a121b43661a4154"++[[package]]+name = "lsp-types"+version = "0.97.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "53353550a17c04ac46c585feb189c2db82154fc84b79c7a66c96c2c644f66071"+dependencies = [+ "bitflags 1.3.2",+ "fluent-uri",+ "serde",+ "serde_json",+ "serde_repr",+]++[[package]]+name = "lyon"+version = "1.0.19"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "bd0578bdecb7d6d88987b8b2b1e3a4e2f81df9d0ece1078623324a567904e7b7"+dependencies = [+ "lyon_algorithms",+ "lyon_tessellation",+]++[[package]]+name = "lyon_algorithms"+version = "1.0.20"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "8575c0d003ae459399623c4def180c63b77f343b1a7fee64f249b349e7699a31"+dependencies = [+ "lyon_path",+ "num-traits",+]++[[package]]+name = "lyon_geom"+version = "1.0.19"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "4336502e29e32af93cf2dad2214ed6003c17ceb5bd499df77b1de663b9042b92"+dependencies = [+ "arrayvec",+ "euclid",+ "num-traits",+]++[[package]]+name = "lyon_path"+version = "1.0.19"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "5c463f9c428b7fc5ec885dcd39ce4aa61e29111d0e33483f6f98c74e89d8621e"+dependencies = [+ "lyon_geom",+ "num-traits",+]++[[package]]+name = "lyon_tessellation"+version = "1.0.20"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "8e43b7e44161571868f5c931d12583592c223c5583eef86b08aa02b7048a3552"+dependencies = [+ "float_next_after",+ "lyon_path",+ "num-traits",+]++[[package]]+name = "mac"+version = "0.1.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "c41e0c4fef86961ac6d6f8a82609f55f31b05e4fce149ac5710e439df7619ba4"++[[package]]+name = "malloc_buf"+version = "0.0.6"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "62bb907fe88d54d8d9ce32a3cceab4218ed2f6b7d35617cafe9adf84e43919cb"+dependencies = [+ "libc",+]++[[package]]+name = "markdown"+version = "1.0.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "a5cab8f2cadc416a82d2e783a1946388b31654d391d1c7d92cc1f03e295b1deb"+dependencies = [+ "unicode-id",+]++[[package]]+name = "markup5ever"+version = "0.12.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "16ce3abbeba692c8b8441d036ef91aea6df8da2c6b6e21c7e14d3c18e526be45"+dependencies = [+ "log",+ "phf",+ "phf_codegen",+ "string_cache",+ "string_cache_codegen",+ "tendril",+]++[[package]]+name = "markup5ever_rcdom"+version = "0.3.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "edaa21ab3701bfee5099ade5f7e1f84553fd19228cf332f13cd6e964bf59be18"+dependencies = [+ "html5ever",+ "markup5ever",+ "tendril",+ "xml5ever",+]++[[package]]+name = "maybe-rayon"+version = "0.1.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "8ea1f30cedd69f0a2954655f7188c6a834246d2bcf1e315e2ac40c4b24dc9519"+dependencies = [+ "cfg-if",+ "rayon",+]++[[package]]+name = "md-5"+version = "0.10.6"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "d89e7ee0cfbedfc4da3340218492196241d89eefb6dab27de5df917a6d2e78cf"+dependencies = [+ "cfg-if",+ "digest 0.10.7",+]++[[package]]+name = "memchr"+version = "2.8.3"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "cf8baf1c55e62ffcace7a9f06f4bd9cd3f0c4beb022d3b367256b91b87513d98"++[[package]]+name = "memmap2"+version = "0.9.11"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "d1219ed1b7f229ee7104d281dd01d6802fe28bb6e95d292942c4daacdeb798c0"+dependencies = [+ "libc",+]++[[package]]+name = "memoffset"+version = "0.9.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "488016bfae457b036d996092f6cb448677611ce4449e970ceaf42695203f218a"+dependencies = [+ "autocfg",+]++[[package]]+name = "metal"+version = "0.29.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "7ecfd3296f8c56b7c1f6fbac3c71cefa9d78ce009850c45000015f206dc7fa21"+dependencies = [+ "bitflags 2.13.1",+ "block",+ "core-graphics-types 0.1.3",+ "foreign-types",+ "log",+ "objc",+ "paste",+]++[[package]]+name = "mime"+version = "0.3.17"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "6877bb514081ee2a7ff5ef9de3281f14a4dd4bceac4c09388074a6b5df8a139a"++[[package]]+name = "mime_guess"+version = "2.0.5"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "f7c44f8e672c00fe5308fa235f821cb4198414e1c77935c1ab6948d3fd78550e"+dependencies = [+ "mime",+ "unicase",+]++[[package]]+name = "minimal-lexical"+version = "0.2.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "68354c5c6bd36d73ff3feceb05efa59b6acb7626617f4962be322a825e61f79a"++[[package]]+name = "miniz_oxide"+version = "0.8.9"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "1fa76a2c86f704bdb222d66965fb3d63269ce38518b83cb0575fca855ebb6316"+dependencies = [+ "adler2",+ "simd-adler32",+]++[[package]]+name = "mint"+version = "0.5.9"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "e53debba6bda7a793e5f99b8dacf19e626084f525f7829104ba9898f367d85ff"++[[package]]+name = "mio"+version = "1.2.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "30d65c71f1ce40ab09135ce117d742b9f8a19ff91a41a8b57ed50bc2de59c427"+dependencies = [+ "libc",+ "log",+ "wasi",+ "windows-sys 0.61.2",+]++[[package]]+name = "moxcms"+version = "0.8.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "bb85c154ba489f01b25c0d36ae69a87e4a1c73a72631fc6c0eb6dde34a73e44b"+dependencies = [+ "num-traits",+ "pxfm",+]++[[package]]+name = "naga"+version = "25.0.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "2b977c445f26e49757f9aca3631c3b8b836942cb278d69a92e7b80d3b24da632"+dependencies = [+ "arrayvec",+ "bit-set",+ "bitflags 2.13.1",+ "cfg_aliases",+ "codespan-reporting",+ "half",+ "hashbrown 0.15.5",+ "hexf-parse",+ "indexmap",+ "log",+ "num-traits",+ "once_cell",+ "rustc-hash 1.1.0",+ "spirv",+ "strum 0.26.3",+ "thiserror 2.0.20",+ "unicode-ident",+]++[[package]]+name = "nanorand"+version = "0.7.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "6a51313c5820b0b02bd422f4b44776fbf47961755c74ce64afc73bfad10226c3"+dependencies = [+ "getrandom 0.2.17",+]++[[package]]+name = "new_debug_unreachable"+version = "1.0.6"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "650eef8c711430f1a879fdd01d4745a7deea475becfb90269c06775983bbf086"++[[package]]+name = "nix"+version = "0.29.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "71e2746dc3a24dd78b3cfcb7be93368c6de9963d30f43a6a73998a9cf4b17b46"+dependencies = [+ "bitflags 2.13.1",+ "cfg-if",+ "cfg_aliases",+ "libc",+]++[[package]]+name = "nix"+version = "0.31.3"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "cf20d2fde8ff38632c426f1165ed7436270b44f199fc55284c38276f9db47c3d"+dependencies = [+ "bitflags 2.13.1",+ "cfg-if",+ "cfg_aliases",+ "libc",+]++[[package]]+name = "no_std_io2"+version = "0.9.4"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "418abd1b6d34fbf6cae440dc874771b0525a604428704c76e48b29a5e67b8003"+dependencies = [+ "memchr",+]++[[package]]+name = "nom"+version = "7.1.3"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "d273983c5a657a70a3e8f2a01329822f3b8c8172b73826411a55751e404a0a4a"+dependencies = [+ "memchr",+ "minimal-lexical",+]++[[package]]+name = "nom"+version = "8.0.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "df9761775871bdef83bee530e60050f7e54b1105350d6884eb0fb4f46c2f9405"+dependencies = [+ "memchr",+]++[[package]]+name = "noop_proc_macro"+version = "0.3.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "0676bb32a98c1a483ce53e500a81ad9c3d5b3f7c920c28c24e9cb0980d0b5bc8"++[[package]]+name = "normpath"+version = "1.5.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "b9985ef7269fa99f3b12437bb698381da2428743ab90f20393f399fa14cab21a"+dependencies = [+ "windows-sys 0.61.2",+]++[[package]]+name = "notify"+version = "7.0.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "c533b4c39709f9ba5005d8002048266593c1cfaf3c5f0739d5b8ab0c6c504009"+dependencies = [+ "bitflags 2.13.1",+ "filetime",+ "fsevent-sys",+ "inotify",+ "kqueue",+ "libc",+ "log",+ "mio",+ "notify-types",+ "walkdir",+ "windows-sys 0.52.0",+]++[[package]]+name = "notify-types"+version = "1.0.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "585d3cb5e12e01aed9e8a1f70d5c6b5e86fe2a6e48fc8cd0b3e0b8df6f6eb174"+dependencies = [+ "instant",+]++[[package]]+name = "ntapi"+version = "0.4.3"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "c3b335231dfd352ffb0f8017f3b6027a4917f7df785ea2143d8af2adc66980ae"+dependencies = [+ "winapi",+]++[[package]]+name = "num"+version = "0.4.3"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "35bd024e8b2ff75562e5f34e7f4905839deb4b22955ef5e73d2fea1b9813cb23"+dependencies = [+ "num-bigint",+ "num-complex",+ "num-integer",+ "num-iter",+ "num-rational",+ "num-traits",+]++[[package]]+name = "num-bigint"+version = "0.4.8"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "c89e69e7e0f03bea5ef08013795c25018e101932225a656383bd384495ecc367"+dependencies = [+ "num-integer",+ "num-traits",+]++[[package]]+name = "num-bigint-dig"+version = "0.8.6"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "e661dda6640fad38e827a6d4a310ff4763082116fe217f279885c97f511bb0b7"+dependencies = [+ "lazy_static",+ "libm",+ "num-integer",+ "num-iter",+ "num-traits",+ "rand 0.8.7",+ "serde",+ "smallvec",+ "zeroize",+]++[[package]]+name = "num-complex"+version = "0.4.6"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "73f88a1307638156682bada9d7604135552957b7818057dcef22705b4d509495"+dependencies = [+ "bytemuck",+ "num-traits",+]++[[package]]+name = "num-derive"+version = "0.4.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "ed3955f1a9c7c0c15e092f9c887db08b1fc683305fdf6eb6684f22555355e202"+dependencies = [+ "proc-macro2",+ "quote",+ "syn 2.0.119",+]++[[package]]+name = "num-integer"+version = "0.1.47"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "7ce2d95d4b3734dc35aa2f45e1aa22cd416814592a4f9d9205e11affd5b8e10b"+dependencies = [+ "num-traits",+]++[[package]]+name = "num-iter"+version = "0.1.46"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "c92800bd69a1eac91786bcfe9da64a897eb72911b8dc3095decbd07429e8048b"+dependencies = [+ "num-integer",+ "num-traits",+]++[[package]]+name = "num-rational"+version = "0.4.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "f83d14da390562dca69fc84082e73e548e1ad308d24accdedd2720017cb37824"+dependencies = [+ "num-bigint",+ "num-integer",+ "num-traits",+]++[[package]]+name = "num-traits"+version = "0.2.19"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "071dfc062690e90b734c0b2273ce72ad0ffa95f0c74596bc250dcfd960262841"+dependencies = [+ "autocfg",+ "libm",+]++[[package]]+name = "num_cpus"+version = "1.17.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "91df4bbde75afed763b708b7eee1e8e7651e02d97f6d5dd763e89367e957b23b"+dependencies = [+ "hermit-abi",+ "libc",+]++[[package]]+name = "objc"+version = "0.2.7"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "915b1b472bc21c53464d6c8461c9d3af805ba1ef837e1cac254428f4a77177b1"+dependencies = [+ "malloc_buf",+ "objc_exception",+]++[[package]]+name = "objc-foundation"+version = "0.1.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "1add1b659e36c9607c7aab864a76c7a4c2760cd0cd2e120f3fb8b952c7e22bf9"+dependencies = [+ "block",+ "objc",+ "objc_id",+]++[[package]]+name = "objc2"+version = "0.6.4"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "3a12a8ed07aefc768292f076dc3ac8c48f3781c8f2d5851dd3d98950e8c5a89f"+dependencies = [+ "objc2-encode",+]++[[package]]+name = "objc2-app-kit"+version = "0.3.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "d49e936b501e5c5bf01fda3a9452ff86dc3ea98ad5f283e1455153142d97518c"+dependencies = [+ "bitflags 2.13.1",+ "objc2",+ "objc2-core-foundation",+ "objc2-foundation",+ "objc2-quartz-core",+]++[[package]]+name = "objc2-core-foundation"+version = "0.3.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "2a180dd8642fa45cdb7dd721cd4c11b1cadd4929ce112ebd8b9f5803cc79d536"+dependencies = [+ "bitflags 2.13.1",+ "dispatch2",+ "objc2",+]++[[package]]+name = "objc2-encode"+version = "4.1.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "ef25abbcd74fb2609453eb695bd2f860d389e457f67dc17cafc8b8cbc89d0c33"++[[package]]+name = "objc2-foundation"+version = "0.3.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "e3e0adef53c21f888deb4fa59fc59f7eb17404926ee8a6f59f5df0fd7f9f3272"+dependencies = [+ "bitflags 2.13.1",+ "objc2",+ "objc2-core-foundation",+]++[[package]]+name = "objc2-metal"+version = "0.3.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "a0125f776a10d00af4152d74616409f0d4a2053a6f57fa5b7d6aa2854ac04794"+dependencies = [+ "bitflags 2.13.1",+ "block2",+ "objc2",+ "objc2-foundation",+]++[[package]]+name = "objc2-quartz-core"+version = "0.3.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "96c1358452b371bf9f104e21ec536d37a650eb10f7ee379fff67d2e08d537f1f"+dependencies = [+ "bitflags 2.13.1",+ "objc2",+ "objc2-core-foundation",+ "objc2-foundation",+ "objc2-metal",+]++[[package]]+name = "objc2-ui-kit"+version = "0.3.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "d87d638e33c06f577498cbcc50491496a3ed4246998a7fbba7ccb98b1e7eab22"+dependencies = [+ "bitflags 2.13.1",+ "objc2",+ "objc2-core-foundation",+ "objc2-foundation",+ "objc2-quartz-core",+]++[[package]]+name = "objc_exception"+version = "0.1.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "ad970fb455818ad6cba4c122ad012fae53ae8b4795f86378bce65e4f6bab2ca4"+dependencies = [+ "cc",+]++[[package]]+name = "objc_id"+version = "0.1.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "c92d4ddb4bd7b50d730c215ff871754d0da6b2178849f8a2a2ab69712d0c073b"+dependencies = [+ "objc",+]++[[package]]+name = "object"+version = "0.39.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "2e5a6c098c7a3b6547378093f5cc30bc54fd361ce711e05293a5cc589562739b"+dependencies = [+ "memchr",+]++[[package]]+name = "once_cell"+version = "1.21.4"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "9f7c3e4beb33f85d45ae3e3a1792185706c8e16d043238c593331cc7cd313b50"++[[package]]+name = "oo7"+version = "0.5.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "e3299dd401feaf1d45afd8fd1c0586f10fcfb22f244bb9afa942cec73503b89d"+dependencies = [+ "aes",+ "ashpd 0.12.3",+ "async-fs",+ "async-io",+ "async-lock",+ "blocking",+ "cbc",+ "cipher",+ "digest 0.10.7",+ "endi",+ "futures-lite 2.6.1",+ "futures-util",+ "getrandom 0.3.4",+ "hkdf",+ "hmac",+ "md-5",+ "num",+ "num-bigint-dig",+ "pbkdf2",+ "rand 0.9.5",+ "serde",+ "sha2 0.10.9",+ "subtle",+ "zbus",+ "zbus_macros",+ "zeroize",+ "zvariant",+]++[[package]]+name = "open"+version = "5.4.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "f9cfef937e9c486488c7e3d949ae31c0f1d06bdacd75b99c086cb35356e30408"+dependencies = [+ "is-wsl",+ "libc",+]++[[package]]+name = "openssl-probe"+version = "0.2.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "7c87def4c32ab89d880effc9e097653c8da5d6ef28e6b539d313baaacfbafcbe"++[[package]]+name = "option-ext"+version = "0.2.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "04744f49eae99ab78e0d5c0b603ab218f515ea8cfe5a456d7629ad883a3b6e7d"++[[package]]+name = "ordered-stream"+version = "0.2.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "9aa2b01e1d916879f73a53d01d1d6cee68adbb31d6d9177a8cfce093cced1d50"+dependencies = [+ "futures-core",+ "pin-project-lite",+]++[[package]]+name = "parking"+version = "2.2.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "f38d5652c16fde515bb1ecef450ab0f6a219d619a7274976324d5e377f7dceba"++[[package]]+name = "parking_lot"+version = "0.12.5"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "93857453250e3077bd71ff98b6a65ea6621a19bb0f559a85248955ac12c45a1a"+dependencies = [+ "lock_api",+ "parking_lot_core",+]++[[package]]+name = "parking_lot_core"+version = "0.9.12"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "2621685985a2ebf1c516881c026032ac7deafcda1a2c9b7850dc81e3dfcb64c1"+dependencies = [+ "cfg-if",+ "libc",+ "redox_syscall 0.5.18",+ "smallvec",+ "windows-link 0.2.1",+]++[[package]]+name = "paste"+version = "1.0.15"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "57c0d7b74b563b49d38dae00a0c37d4d6de9b432382b2892f0574ddcae73fd0a"++[[package]]+name = "pastey"+version = "0.1.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "35fb2e5f958ec131621fdd531e9fc186ed768cbe395337403ae56c17a74c68ec"++[[package]]+name = "pathfinder_geometry"+version = "0.5.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "0b7b7e7b4ea703700ce73ebf128e1450eb69c3a8329199ffbfb9b2a0418e5ad3"+dependencies = [+ "log",+ "pathfinder_simd",+]++[[package]]+name = "pathfinder_simd"+version = "0.5.6"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "4500030c302e4af1d423f36f3b958d1aecb6c04184356ed5a833bf6b60435777"+dependencies = [+ "rustc_version",+]++[[package]]+name = "pbkdf2"+version = "0.12.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "f8ed6a7761f76e3b9f92dfb0a60a6a6477c61024b775147ff0973a02653abaf2"+dependencies = [+ "digest 0.10.7",+ "hmac",+]++[[package]]+name = "percent-encoding"+version = "2.3.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "9b4f627cb1b25917193a259e49bdad08f671f8d9708acfd5fe0a8c1455d87220"++[[package]]+name = "phf"+version = "0.11.3"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "1fd6780a80ae0c52cc120a26a1a42c1ae51b247a253e4e06113d23d2c2edd078"+dependencies = [+ "phf_shared",+]++[[package]]+name = "phf_codegen"+version = "0.11.3"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "aef8048c789fa5e851558d709946d6d79a8ff88c0440c587967f8e94bfb1216a"+dependencies = [+ "phf_generator",+ "phf_shared",+]++[[package]]+name = "phf_generator"+version = "0.11.3"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "3c80231409c20246a13fddb31776fb942c38553c51e871f8cbd687a4cfb5843d"+dependencies = [+ "phf_shared",+ "rand 0.8.7",+]++[[package]]+name = "phf_shared"+version = "0.11.3"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "67eabc2ef2a60eb7faa00097bd1ffdb5bd28e62bf39990626a582201b7a754e5"+dependencies = [+ "siphasher",+]++[[package]]+name = "pico-args"+version = "0.5.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "5be167a7af36ee22fe3115051bc51f6e6c7054c9348e28deb4f49bd6f705a315"++[[package]]+name = "pin-project"+version = "1.1.13"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "2466b2336ed02bcdca6b294417127b90ec92038d1d5c4fbeac971a922e0e0924"+dependencies = [+ "pin-project-internal",+]++[[package]]+name = "pin-project-internal"+version = "1.1.13"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "c96395f0a926bc13b1c17622aaddda1ecb55d49c8f1bf9777e4d877800a43f8b"+dependencies = [+ "proc-macro2",+ "quote",+ "syn 2.0.119",+]++[[package]]+name = "pin-project-lite"+version = "0.2.17"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "a89322df9ebe1c1578d689c92318e070967d1042b512afbe49518723f4e6d5cd"++[[package]]+name = "pin-utils"+version = "0.1.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "8b870d8c151b6f2fb93e84a13146138f05d02ed11c7e7c54f8826aaaf7c9f184"++[[package]]+name = "piper"+version = "0.2.5"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "c835479a4443ded371d6c535cbfd8d31ad92c5d23ae9770a61bc155e4992a3c1"+dependencies = [+ "atomic-waker",+ "fastrand 2.5.0",+ "futures-io",+]++[[package]]+name = "pkg-config"+version = "0.3.33"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "19f132c84eca552bf34cab8ec81f1c1dcc229b811638f9d283dceabe58c5569e"++[[package]]+name = "png"+version = "0.17.16"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "82151a2fc869e011c153adc57cf2789ccb8d9906ce52c0b39a6b5697749d7526"+dependencies = [+ "bitflags 1.3.2",+ "crc32fast",+ "fdeflate",+ "flate2",+ "miniz_oxide",+]++[[package]]+name = "png"+version = "0.18.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "60769b8b31b2a9f263dae2776c37b1b28ae246943cf719eb6946a1db05128a61"+dependencies = [+ "bitflags 2.13.1",+ "crc32fast",+ "fdeflate",+ "flate2",+ "miniz_oxide",+]++[[package]]+name = "polling"+version = "3.11.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "5d0e4f59085d47d8241c88ead0f274e8a0cb551f3625263c05eb8dd897c34218"+dependencies = [+ "cfg-if",+ "concurrent-queue",+ "hermit-abi",+ "pin-project-lite",+ "rustix 1.1.4",+ "windows-sys 0.61.2",+]++[[package]]+name = "pollster"+version = "0.2.5"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "5da3b0203fd7ee5720aa0b5e790b591aa5d3f41c3ed2c34a3a393382198af2f7"++[[package]]+name = "postage"+version = "0.5.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "af3fb618632874fb76937c2361a7f22afd393c982a2165595407edc75b06d3c1"+dependencies = [+ "atomic",+ "crossbeam-queue",+ "futures",+ "log",+ "parking_lot",+ "pin-project",+ "pollster",+ "static_assertions",+ "thiserror 1.0.69",+]++[[package]]+name = "potential_utf"+version = "0.1.6"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "d83eb9bc6d8e5cf568e7a1101d60ee05e81ed50ea106026f3d18deeb046d7661"+dependencies = [+ "zerovec",+]++[[package]]+name = "ppv-lite86"+version = "0.2.21"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "85eae3c4ed2f50dcfe72643da4befc30deadb458a9b590d720cde2f2b1e97da9"+dependencies = [+ "zerocopy",+]++[[package]]+name = "precomputed-hash"+version = "0.1.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "925383efa346730478fb4838dbe9137d2a47675ad789c546d150a6e1dd4ab31c"++[[package]]+name = "prettyplease"+version = "0.2.37"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "479ca8adacdd7ce8f1fb39ce9ecccbfe93a3f1344b3d0d97f20bc0196208f62b"+dependencies = [+ "proc-macro2",+ "syn 2.0.119",+]++[[package]]+name = "proc-macro-crate"+version = "3.5.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "e67ba7e9b2b56446f1d419b1d807906278ffa1a658a8a5d8a39dcb1f5a78614f"+dependencies = [+ "toml_edit 0.25.13+spec-1.1.0",+]++[[package]]+name = "proc-macro-error-attr2"+version = "2.0.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "96de42df36bb9bba5542fe9f1a054b8cc87e172759a1868aa05c1f3acc89dfc5"+dependencies = [+ "proc-macro2",+ "quote",+]++[[package]]+name = "proc-macro-error2"+version = "2.0.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "11ec05c52be0a07b08061f7dd003e7d7092e0472bc731b4af7bb1ef876109802"+dependencies = [+ "proc-macro-error-attr2",+ "proc-macro2",+ "quote",+ "syn 2.0.119",+]++[[package]]+name = "proc-macro2"+version = "1.0.107"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "985e7ec9bb745e6ce6535b544d84d6cd6f7ad8bd711c398938ae983b91a766d9"+dependencies = [+ "unicode-ident",+]++[[package]]+name = "profiling"+version = "1.0.18"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "3d595e54a326bc53c1c197b32d295e14b169e3cfeaa8dc82b529f947fba6bcf5"+dependencies = [+ "profiling-procmacros",+]++[[package]]+name = "profiling-procmacros"+version = "1.0.18"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "4488a4a36b9a4ba6b9334a32a39971f77c1436ec82c38707bce707699cc3bbcb"+dependencies = [+ "quote",+ "syn 2.0.119",+]++[[package]]+name = "psm"+version = "0.1.32"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "4dcd034599e63b970727f70d79e02d62390a4a84f7c6b827c27c46d5ac3fa622"+dependencies = [+ "ar_archive_writer",+ "cc",+]++[[package]]+name = "pulp"+version = "0.22.3"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "046aa45b989642ec2e4717c8e72d677b13edd831a4d3b6cf37d9a3e54912496a"+dependencies = [+ "bytemuck",+ "cfg-if",+ "libm",+ "num-complex",+ "paste",+ "pulp-wasm-simd-flag",+ "raw-cpuid",+ "reborrow",+ "version_check",+]++[[package]]+name = "pulp-wasm-simd-flag"+version = "0.1.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "1d8f70e07b9c3962945a74e59ca1c511bba65b6419468acc217c457d93f3c740"++[[package]]+name = "pxfm"+version = "0.1.30"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "d55d956fa96f5ec02be2e13af0e20391a5aa83d6a074e3ad368959d0fab299ea"++[[package]]+name = "qoi"+version = "0.4.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "7f6d64c71eb498fe9eae14ce4ec935c555749aef511cca85b5568910d6e48001"+dependencies = [+ "bytemuck",+]++[[package]]+name = "quick-error"+version = "2.0.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "a993555f31e5a609f617c12db6250dedcac1b0a85076912c436e6fc9b2c8e6a3"++[[package]]+name = "quick-xml"+version = "0.41.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "e660451e55124f798a69a5af3f49ccfbefbd41910eefd25caf2393e1f3473ec1"+dependencies = [+ "memchr",+]++[[package]]+name = "quinn"+version = "0.11.11"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "0c1a41e437b6bbd489372cd4971de128e85c855f56c57f283d20ff016cf7c0a8"+dependencies = [+ "bytes",+ "cfg_aliases",+ "pin-project-lite",+ "quinn-proto",+ "quinn-udp",+ "rustc-hash 2.1.3",+ "rustls",+ "socket2",+ "thiserror 2.0.20",+ "tokio",+ "tracing",+ "web-time",+]++[[package]]+name = "quinn-proto"+version = "0.11.16"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "2f4bfc015262b9df63c8845072ce59068853ff5872180c2ce2f13038b970e560"+dependencies = [+ "bytes",+ "getrandom 0.4.3",+ "lru-slab",+ "rand 0.10.2",+ "rand_pcg",+ "ring",+ "rustc-hash 2.1.3",+ "rustls",+ "rustls-pki-types",+ "slab",+ "thiserror 2.0.20",+ "tinyvec",+ "tracing",+ "web-time",+]++[[package]]+name = "quinn-udp"+version = "0.5.15"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "35a133f956daabe89a61a685c2649f13d82d5aa4bd5d12d1277e1072a21c0694"+dependencies = [+ "cfg_aliases",+ "libc",+ "once_cell",+ "socket2",+ "tracing",+ "windows-sys 0.61.2",+]++[[package]]+name = "quote"+version = "1.0.47"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "1fbf4db142a473a8d80c26bbf18454ed458bf8d26c8219c331daecfdbd079001"+dependencies = [+ "proc-macro2",+]++[[package]]+name = "r-efi"+version = "5.3.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "69cdb34c158ceb288df11e18b4bd39de994f6657d83847bdffdbd7f346754b0f"++[[package]]+name = "r-efi"+version = "6.0.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "f8dcc9c7d52a811697d2151c701e0d08956f92b0e24136cf4cf27b57a6a0d9bf"++[[package]]+name = "rand"+version = "0.8.7"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "22f6172bdec972074665ed81ed53b71da00bfc44b65a753cfde883ec4c702a1a"+dependencies = [+ "libc",+ "rand_chacha 0.3.1",+ "rand_core 0.6.4",+]++[[package]]+name = "rand"+version = "0.9.5"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "b9ef1d0d795eb7d84685bca4f72f3649f064e6641543d3a8c415898726a57b41"+dependencies = [+ "rand_chacha 0.9.0",+ "rand_core 0.9.5",+]++[[package]]+name = "rand"+version = "0.10.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "c7f5fa3a058cd35567ef9bfa5e75732bee0f9e4c55fa90477bef2dfcdbc4be80"+dependencies = [+ "chacha20",+ "getrandom 0.4.3",+ "rand_core 0.10.1",+]++[[package]]+name = "rand_chacha"+version = "0.3.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "e6c10a63a0fa32252be49d21e7709d4d4baf8d231c2dbce1eaa8141b9b127d88"+dependencies = [+ "ppv-lite86",+ "rand_core 0.6.4",+]++[[package]]+name = "rand_chacha"+version = "0.9.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "d3022b5f1df60f26e1ffddd6c66e8aa15de382ae63b3a0c1bfc0e4d3e3f325cb"+dependencies = [+ "ppv-lite86",+ "rand_core 0.9.5",+]++[[package]]+name = "rand_core"+version = "0.6.4"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "ec0be4795e2f6a28069bec0b5ff3e2ac9bafc99e6a9a7dc3547996c5c816922c"+dependencies = [+ "getrandom 0.2.17",+]++[[package]]+name = "rand_core"+version = "0.9.5"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "76afc826de14238e6e8c374ddcc1fa19e374fd8dd986b0d2af0d02377261d83c"+dependencies = [+ "getrandom 0.3.4",+]++[[package]]+name = "rand_core"+version = "0.10.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "63b8176103e19a2643978565ca18b50549f6101881c443590420e4dc998a3c69"++[[package]]+name = "rand_pcg"+version = "0.10.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "caa0f4137e1c0a72f4c651489402276c8e8e1cf081f3b0ba156d2cbeef09e86a"+dependencies = [+ "rand_core 0.10.1",+]++[[package]]+name = "rangemap"+version = "1.8.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "a611d15b50743feb4c76b7d03edcb0e64f399c26961e4efe6975bc398be6aa3d"++[[package]]+name = "rav1e"+version = "0.8.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "43b6dd56e85d9483277cde964fd1bdb0428de4fec5ebba7540995639a21cb32b"+dependencies = [+ "aligned-vec",+ "arbitrary",+ "arg_enum_proc_macro",+ "arrayvec",+ "av-scenechange",+ "av1-grain",+ "bitstream-io",+ "built",+ "cfg-if",+ "interpolate_name",+ "itertools 0.14.0",+ "libc",+ "libfuzzer-sys",+ "log",+ "maybe-rayon",+ "new_debug_unreachable",+ "noop_proc_macro",+ "num-derive",+ "num-traits",+ "paste",+ "profiling",+ "rand 0.9.5",+ "rand_chacha 0.9.0",+ "simd_helpers",+ "thiserror 2.0.20",+ "v_frame",+ "wasm-bindgen",+]++[[package]]+name = "ravif"+version = "0.13.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "e52310197d971b0f5be7fe6b57530dcd27beb35c1b013f29d66c1ad73fbbcc45"+dependencies = [+ "avif-serialize",+ "imgref",+ "loop9",+ "quick-error",+ "rav1e",+ "rayon",+ "rgb",+]++[[package]]+name = "raw-cpuid"+version = "11.6.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "498cd0dc59d73224351ee52a95fee0f1a617a2eae0e7d9d720cc622c73a54186"+dependencies = [+ "bitflags 2.13.1",+]++[[package]]+name = "raw-window-handle"+version = "0.6.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "20675572f6f24e9e76ef639bc5552774ed45f1c30e2951e1e99c59888861c539"++[[package]]+name = "raw-window-metal"+version = "0.4.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "76e8caa82e31bb98fee12fa8f051c94a6aa36b07cddb03f0d4fc558988360ff1"+dependencies = [+ "cocoa 0.25.0",+ "core-graphics 0.23.2",+ "objc",+ "raw-window-handle",+]++[[package]]+name = "rayon"+version = "1.12.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "fb39b166781f92d482534ef4b4b1b2568f42613b53e5b6c160e24cfbfa30926d"+dependencies = [+ "either",+ "rayon-core",+]++[[package]]+name = "rayon-core"+version = "1.13.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "22e18b0f0062d30d4230b2e85ff77fdfe4326feb054b9783a3460d8435c8ab91"+dependencies = [+ "crossbeam-deque",+ "crossbeam-utils",+]++[[package]]+name = "read-fonts"+version = "0.41.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "046a7d674daf459825b32f5062056d6882db0d2f5a479fbd76ccfc870ac18709"+dependencies = [+ "bytemuck",+ "font-types",+ "once_cell",+]++[[package]]+name = "reborrow"+version = "0.5.5"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "03251193000f4bd3b042892be858ee50e8b3719f2b08e5833ac4353724632430"++[[package]]+name = "redox_syscall"+version = "0.2.16"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "fb5a58c1855b4b6819d59012155603f0b22ad30cad752600aadfcb695265519a"+dependencies = [+ "bitflags 1.3.2",+]++[[package]]+name = "redox_syscall"+version = "0.5.18"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "ed2bf2547551a7053d6fdfafda3f938979645c44812fbfcda098faae3f1a362d"+dependencies = [+ "bitflags 2.13.1",+]++[[package]]+name = "redox_users"+version = "0.4.6"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "ba009ff324d1fc1b900bd1fdb31564febe58a8ccc8a6fdbb93b543d33b13ca43"+dependencies = [+ "getrandom 0.2.17",+ "libredox",+ "thiserror 1.0.69",+]++[[package]]+name = "ref-cast"+version = "1.0.26"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "216e8f773d7923bcba9ceb86a86c93cabb3903a11872fc3f138c49630e50b96d"+dependencies = [+ "ref-cast-impl",+]++[[package]]+name = "ref-cast-impl"+version = "1.0.26"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "2c9283685feec7d69af75fb0e858d5e7378f33fe4fc699383b2916ab9273e03c"+dependencies = [+ "proc-macro2",+ "quote",+ "syn 3.0.3",+]++[[package]]+name = "regex"+version = "1.13.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "f020237b6c8eed93db2e2cb53c00c60a8e1bc73da7d073199a1180401450218d"+dependencies = [+ "aho-corasick",+ "memchr",+ "regex-automata",+ "regex-syntax",+]++[[package]]+name = "regex-automata"+version = "0.4.18"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "ad8553b9b26413251cbf30e620595c7a41b3887f03da04579c0e6b0d6a06b4b2"+dependencies = [+ "aho-corasick",+ "memchr",+ "regex-syntax",+]++[[package]]+name = "regex-syntax"+version = "0.8.11"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "d6f6ff9a378485b298a5286656da665ba74413d36db0979633275d2e708145d4"++[[package]]+name = "resvg"+version = "0.45.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "a8928798c0a55e03c9ca6c4c6846f76377427d2c1e1f7e6de3c06ae57942df43"+dependencies = [+ "log",+ "pico-args",+ "rgb",+ "svgtypes",+ "tiny-skia",+ "usvg",+]++[[package]]+name = "rgb"+version = "0.8.53"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "47b34b781b31e5d73e9fbc8689c70551fd1ade9a19e3e28cfec8580a79290cc4"+dependencies = [+ "bytemuck",+]++[[package]]+name = "ring"+version = "0.17.14"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "a4689e6c2294d81e88dc6261c768b63bc4fcdb852be6d1352498b114f61383b7"+dependencies = [+ "cc",+ "cfg-if",+ "getrandom 0.2.17",+ "libc",+ "untrusted",+ "windows-sys 0.52.0",+]++[[package]]+name = "ropey"+version = "2.0.0-beta.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "4045a00dc327d084a2bbf126976e14125b54f23bd30511d45b842eba76c52d74"+dependencies = [+ "str_indices",+]++[[package]]+name = "roxmltree"+version = "0.20.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "6c20b6793b5c2fa6553b250154b78d6d0db37e72700ae35fad9387a46f487c97"++[[package]]+name = "rusqlite"+version = "0.32.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "7753b721174eb8ff87a9a0e799e2d7bc3749323e773db92e0984debb00019d6e"+dependencies = [+ "bitflags 2.13.1",+ "fallible-iterator",+ "fallible-streaming-iterator",+ "hashlink",+ "libsqlite3-sys",+ "smallvec",+]++[[package]]+name = "rust-embed"+version = "8.12.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "e9e7760e252aaba7b09f4be00e36476cf585bdb68a53552ac954cdf504ab4bc9"+dependencies = [+ "rust-embed-impl",+ "rust-embed-utils",+ "walkdir",+]++[[package]]+name = "rust-embed-impl"+version = "8.12.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "3bcfc4d6f53af43755f7a723e4b6b8794fcce052a178dd8c6c1dadc5f5343097"+dependencies = [+ "mime_guess",+ "proc-macro2",+ "quote",+ "rust-embed-utils",+ "syn 2.0.119",+ "walkdir",+]++[[package]]+name = "rust-embed-utils"+version = "8.12.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "42ffa149f6aa81b58a5b3011d01a857c4ed12c7a732d2c51947a4c7c692185f0"+dependencies = [+ "globset",+ "sha2 0.11.0",+ "walkdir",+]++[[package]]+name = "rust-i18n"+version = "3.1.5"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "fda2551fdfaf6cc5ee283adc15e157047b92ae6535cf80f6d4962d05717dc332"+dependencies = [+ "globwalk",+ "once_cell",+ "regex",+ "rust-i18n-macro",+ "rust-i18n-support",+ "smallvec",+]++[[package]]+name = "rust-i18n-macro"+version = "3.1.5"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "22baf7d7f56656d23ebe24f6bb57a5d40d2bce2a5f1c503e692b5b2fa450f965"+dependencies = [+ "glob",+ "once_cell",+ "proc-macro2",+ "quote",+ "rust-i18n-support",+ "serde",+ "serde_json",+ "serde_yaml",+ "syn 2.0.119",+]++[[package]]+name = "rust-i18n-support"+version = "3.1.5"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "940ed4f52bba4c0152056d771e563b7133ad9607d4384af016a134b58d758f19"+dependencies = [+ "arc-swap",+ "base62",+ "globwalk",+ "itertools 0.11.0",+ "lazy_static",+ "normpath",+ "once_cell",+ "proc-macro2",+ "regex",+ "serde",+ "serde_json",+ "serde_yaml",+ "siphasher",+ "toml 0.8.23",+ "triomphe",+]++[[package]]+name = "rustc-hash"+version = "1.1.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "08d43f7aa6b08d49f382cde6a7982047c3426db949b1424bc4b7ec9ae12c6ce2"++[[package]]+name = "rustc-hash"+version = "2.1.3"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "6b1e7f9a428571be2dc5bc0505c13fb6bf936822b894ec87abf8a08a4e51742d"++[[package]]+name = "rustc_version"+version = "0.4.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "cfcb3a22ef46e85b45de6ee7e79d063319ebb6594faafcf1c225ea92ab6e9b92"+dependencies = [+ "semver",+]++[[package]]+name = "rustix"+version = "0.38.44"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "fdb5bc1ae2baa591800df16c9ca78619bf65c0488b41b96ccec5d11220d8c154"+dependencies = [+ "bitflags 2.13.1",+ "errno",+ "libc",+ "linux-raw-sys 0.4.15",+ "windows-sys 0.59.0",+]++[[package]]+name = "rustix"+version = "1.1.4"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "b6fe4565b9518b83ef4f91bb47ce29620ca828bd32cb7e408f0062e9930ba190"+dependencies = [+ "bitflags 2.13.1",+ "errno",+ "libc",+ "linux-raw-sys 0.12.1",+ "windows-sys 0.61.2",+]++[[package]]+name = "rustls"+version = "0.23.43"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "0283386ce02abc0151e1761d08802dfe86c173b0b494af5cbc086574e453da06"+dependencies = [+ "once_cell",+ "ring",+ "rustls-pki-types",+ "rustls-webpki",+ "subtle",+ "zeroize",+]++[[package]]+name = "rustls-native-certs"+version = "0.8.4"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "dab5152771c58876a2146916e53e35057e1a4dfa2b9df0f0305b07f611fdea4d"+dependencies = [+ "openssl-probe",+ "rustls-pki-types",+ "schannel",+ "security-framework",+]++[[package]]+name = "rustls-pemfile"+version = "2.2.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "dce314e5fee3f39953d46bb63bb8a46d40c2f8fb7cc5a3b6cab2bde9721d6e50"+dependencies = [+ "rustls-pki-types",+]++[[package]]+name = "rustls-pki-types"+version = "1.15.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "2f4925028c7eb5d1fcdaf196971378ed9d2c1c4efc7dc5d011256f76c99c0a96"+dependencies = [+ "web-time",+ "zeroize",+]++[[package]]+name = "rustls-webpki"+version = "0.103.14"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "0527518605e68109d875e248ea259b6758801cf165e4b2c2733ae3b51f12535a"+dependencies = [+ "ring",+ "rustls-pki-types",+ "untrusted",+]++[[package]]+name = "rustversion"+version = "1.0.23"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "cf54715a573b99ac80df0bc206da022bcd442c974952c7b9720069370852e21f"++[[package]]+name = "rustybuzz"+version = "0.14.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "cfb9cf8877777222e4a3bc7eb247e398b56baba500c38c1c46842431adc8b55c"+dependencies = [+ "bitflags 2.13.1",+ "bytemuck",+ "libm",+ "smallvec",+ "ttf-parser 0.21.1",+ "unicode-bidi-mirroring 0.2.0",+ "unicode-ccc 0.2.0",+ "unicode-properties",+ "unicode-script",+]++[[package]]+name = "rustybuzz"+version = "0.20.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "fd3c7c96f8a08ee34eff8857b11b49b07d71d1c3f4e88f8a88d4c9e9f90b1702"+dependencies = [+ "bitflags 2.13.1",+ "bytemuck",+ "core_maths",+ "log",+ "smallvec",+ "ttf-parser 0.25.1",+ "unicode-bidi-mirroring 0.4.0",+ "unicode-ccc 0.4.0",+ "unicode-properties",+ "unicode-script",+]++[[package]]+name = "ryu"+version = "1.0.23"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "9774ba4a74de5f7b1c1451ed6cd5285a32eddb5cccb8cc655a4e50009e06477f"++[[package]]+name = "same-file"+version = "1.0.6"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "93fc1dc3aaa9bfed95e02e6eadabb4baf7e3078b0bd1b4d7b6b0b68378900502"+dependencies = [+ "winapi-util",+]++[[package]]+name = "schannel"+version = "0.1.29"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "91c1b7e4904c873ef0710c1f407dde2e6287de2bebc1bbbf7d430bb7cbffd939"+dependencies = [+ "windows-sys 0.61.2",+]++[[package]]+name = "schemars"+version = "1.2.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "687274d293b6cdc6e73e0fee520bf2049650090d7164f87672d212a3c530cf4a"+dependencies = [+ "dyn-clone",+ "indexmap",+ "ref-cast",+ "schemars_derive",+ "serde",+ "serde_json",+]++[[package]]+name = "schemars_derive"+version = "1.2.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "d98c67716b46af2f0b8cf752abc930f6f9aecfbf671ecfb531db8a31dbe4e2ba"+dependencies = [+ "proc-macro2",+ "quote",+ "serde_derive_internals",+ "syn 3.0.3",+]++[[package]]+name = "scoped-tls"+version = "1.0.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "e1cf6437eb19a8f4a6cc0f7dca544973b0b78843adbfeb3683d1a94a0024a294"++[[package]]+name = "scopeguard"+version = "1.2.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "94143f37725109f92c262ed2cf5e59bce7498c01bcc1502d7b9afe439a4e9f49"++[[package]]+name = "screencapturekit"+version = "0.2.8"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "1a5eeeb57ac94960cfe5ff4c402be6585ae4c8d29a2cf41b276048c2e849d64e"+dependencies = [+ "screencapturekit-sys",+]++[[package]]+name = "screencapturekit-sys"+version = "0.2.8"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "22411b57f7d49e7fe08025198813ee6fd65e1ee5eff4ebc7880c12c82bde4c60"+dependencies = [+ "block",+ "dispatch",+ "objc",+ "objc-foundation",+ "objc_id",+ "once_cell",+]++[[package]]+name = "seahash"+version = "4.1.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "1c107b6f4780854c8b126e228ea8869f4d7b71260f962fefb57b996b8959ba6b"++[[package]]+name = "security-framework"+version = "3.7.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "b7f4bc775c73d9a02cde8bf7b2ec4c9d12743edf609006c7facc23998404cd1d"+dependencies = [+ "bitflags 2.13.1",+ "core-foundation 0.10.0",+ "core-foundation-sys",+ "libc",+ "security-framework-sys",+]++[[package]]+name = "security-framework-sys"+version = "2.17.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "6ce2691df843ecc5d231c0b14ece2acc3efb62c0a398c7e1d875f3983ce020e3"+dependencies = [+ "core-foundation-sys",+ "libc",+]++[[package]]+name = "self_cell"+version = "1.3.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "2ab42ca02749e120097e328d91d415325bdf43b1c72c4c8badf37375fe40a813"++[[package]]+name = "semver"+version = "1.0.28"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "8a7852d02fc848982e0c167ef163aaff9cd91dc640ba85e263cb1ce46fae51cd"++[[package]]+name = "serde"+version = "1.0.229"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "4148590afebada386688f18773da617792bf2ef03ffc1e4cbd2b1d45b023e0ba"+dependencies = [+ "serde_core",+ "serde_derive",+]++[[package]]+name = "serde_core"+version = "1.0.229"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "67dca2c9c51e58a4791a4b1ed58308b39c64224d349a935ab5039aa360942a48"+dependencies = [+ "serde_derive",+]++[[package]]+name = "serde_derive"+version = "1.0.229"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "e7a5d71263a5a7d47b41f6b3f06ba276f10cc18b0931f1799f710578e2309348"+dependencies = [+ "proc-macro2",+ "quote",+ "syn 3.0.3",+]++[[package]]+name = "serde_derive_internals"+version = "0.30.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "f852137cce035d6a4df67ccce505ff6b3e9fd3a10e3e52b24dc71e650bb1a9bd"+dependencies = [+ "proc-macro2",+ "quote",+ "syn 3.0.3",+]++[[package]]+name = "serde_fmt"+version = "1.1.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "6e497af288b3b95d067a23a4f749f2861121ffcb2f6d8379310dcda040c345ed"+dependencies = [+ "serde_core",+]++[[package]]+name = "serde_json"+version = "1.0.151"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "c841b55ecdae098c80dcae9cf767f6f8a0c2cdb3416bbef72181df4d0fe73f14"+dependencies = [+ "indexmap",+ "itoa",+ "memchr",+ "serde",+ "serde_core",+ "zmij",+]++[[package]]+name = "serde_json_lenient"+version = "0.2.4"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "0e033097bf0d2b59a62b42c18ebbb797503839b26afdda2c4e1415cb6c813540"+dependencies = [+ "indexmap",+ "itoa",+ "memchr",+ "ryu",+ "serde",+]++[[package]]+name = "serde_repr"+version = "0.1.21"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "8d3b1629de253c70a0508c3899572da79ca359fdab27c7920ff00406df418906"+dependencies = [+ "proc-macro2",+ "quote",+ "syn 3.0.3",+]++[[package]]+name = "serde_spanned"+version = "0.6.9"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "bf41e0cfaf7226dca15e8197172c295a782857fcb97fad1808a166870dee75a3"+dependencies = [+ "serde",+]++[[package]]+name = "serde_spanned"+version = "1.1.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "6662b5879511e06e8999a8a235d848113e942c9124f211511b16466ee2995f26"+dependencies = [+ "serde_core",+]++[[package]]+name = "serde_urlencoded"+version = "0.7.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "d3491c14715ca2294c4d6a88f15e84739788c1d030eed8c110436aafdaa2f3fd"+dependencies = [+ "form_urlencoded",+ "itoa",+ "ryu",+ "serde",+]++[[package]]+name = "serde_yaml"+version = "0.9.34+deprecated"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "6a8b1a1a2ebf674015cc02edccce75287f1a0130d394307b36743c2f5d504b47"+dependencies = [+ "indexmap",+ "itoa",+ "ryu",+ "serde",+ "unsafe-libyaml",+]++[[package]]+name = "sha1_smol"+version = "1.0.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "bbfa15b3dddfee50a0fff136974b3e1bde555604ba463834a7eb7deb6417705d"++[[package]]+name = "sha2"+version = "0.10.9"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "a7507d819769d01a365ab707794a4084392c824f54a7a6a7862f8c3d0892b283"+dependencies = [+ "cfg-if",+ "cpufeatures 0.2.17",+ "digest 0.10.7",+]++[[package]]+name = "sha2"+version = "0.11.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "446ba717509524cb3f22f17ecc096f10f4822d76ab5c0b9822c5f9c284e825f4"+dependencies = [+ "cfg-if",+ "cpufeatures 0.3.0",+ "digest 0.11.3",+]++[[package]]+name = "shlex"+version = "1.3.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "0fda2ff0d084019ba4d7c6f371c95d8fd75ce3524c3cb8fb653a3023f6323e64"++[[package]]+name = "shlex"+version = "2.0.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "f8fadd59c855ef2080decdef8ff161eb6661b86933c9d82e5ba29dc602a55aba"++[[package]]+name = "signal-hook-registry"+version = "1.4.8"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "c4db69cba1110affc0e9f7bcd48bbf87b3f4fc7c61fc9155afd4c469eb3d6c1b"+dependencies = [+ "errno",+ "libc",+]++[[package]]+name = "simd-adler32"+version = "0.3.10"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "3a219298ac11a56ea9a6d2120044824d6f01aeb034955e7af7bc16858527deea"++[[package]]+name = "simd_helpers"+version = "0.1.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "95890f873bec569a0362c235787f3aca6e1e887302ba4840839bcc6459c42da6"+dependencies = [+ "quote",+]++[[package]]+name = "simplecss"+version = "0.2.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "7a9c6883ca9c3c7c90e888de77b7a5c849c779d25d74a1269b0218b14e8b136c"+dependencies = [+ "log",+]++[[package]]+name = "siphasher"+version = "1.0.3"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "8ee5873ec9cce0195efcb7a4e9507a04cd49aec9c83d0389df45b1ef7ba2e649"++[[package]]+name = "skrifa"+version = "0.44.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "819ab7d62b1d3e72d9d9dea5650bac30424f9111364bb94928dbf5ecad1baa68"+dependencies = [+ "bytemuck",+ "read-fonts",+]++[[package]]+name = "slab"+version = "0.4.12"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "0c790de23124f9ab44544d7ac05d60440adc586479ce501c1d6d7da3cd8c9cf5"++[[package]]+name = "slotmap"+version = "1.1.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "bdd58c3c93c3d278ca835519292445cb4b0d4dc59ccfdf7ceadaab3f8aeb4038"+dependencies = [+ "version_check",+]++[[package]]+name = "smallvec"+version = "1.15.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "8ed6a63f02c8539c91a8685a86f4099661ba3da017932f6ebbea6de3f0fa7c90"++[[package]]+name = "smol"+version = "2.0.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "a33bd3e260892199c3ccfc487c88b2da2265080acb316cd920da72fdfd7c599f"+dependencies = [+ "async-channel 2.5.0",+ "async-executor",+ "async-fs",+ "async-io",+ "async-lock",+ "async-net",+ "async-process",+ "blocking",+ "futures-lite 2.6.1",+]++[[package]]+name = "smol_str"+version = "0.2.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "dd538fb6910ac1099850255cf94a94df6551fbdd602454387d0adb2d1ca6dead"++[[package]]+name = "socket2"+version = "0.6.5"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "c3d1e2c7f27f8d4cb10542a02c49005dbd6e93095799d6f3be745fae9f8fedd4"+dependencies = [+ "libc",+ "windows-sys 0.61.2",+]++[[package]]+name = "spin"+version = "0.9.9"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "3763264f6b73151db08c50ff20d7d8a0b8796e021cdea7ceedad07b80155fa0e"+dependencies = [+ "lock_api",+]++[[package]]+name = "spirv"+version = "0.3.0+sdk-1.3.268.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "eda41003dc44290527a59b13432d4a0379379fa074b70174882adfbdfd917844"+dependencies = [+ "bitflags 2.13.1",+]++[[package]]+name = "stable_deref_trait"+version = "1.2.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "6ce2be8dc25455e1f91df71bfa12ad37d7af1092ae736f3a6cd0e37bc7810596"++[[package]]+name = "stacker"+version = "0.1.25"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "707f49d46706bacf8a2b00d51dace3f9de527c13eec3778f570c411f89e69967"+dependencies = [+ "cc",+ "cfg-if",+ "libc",+ "psm",+ "windows-sys 0.61.2",+]++[[package]]+name = "stacksafe"+version = "0.1.4"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "1d9c1172965d317e87ddb6d364a040d958b40a1db82b6ef97da26253a8b3d090"+dependencies = [+ "stacker",+ "stacksafe-macro",+]++[[package]]+name = "stacksafe-macro"+version = "0.1.4"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "172175341049678163e979d9107ca3508046d4d2a7c6682bee46ac541b17db69"+dependencies = [+ "proc-macro-error2",+ "quote",+ "syn 2.0.119",+]++[[package]]+name = "static_assertions"+version = "1.1.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "a2eb9349b6444b326872e140eb1cf5e7c522154d69e7a0ffb0fb81c06b37543f"++[[package]]+name = "str_indices"+version = "0.4.4"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "d08889ec5408683408db66ad89e0e1f93dff55c73a4ccc71c427d5b277ee47e6"++[[package]]+name = "streaming-iterator"+version = "0.1.9"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "2b2231b7c3057d5e4ad0156fb3dc807d900806020c5ffa3ee6ff2c8c76fb8520"++[[package]]+name = "strict-num"+version = "0.1.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "6637bab7722d379c8b41ba849228d680cc12d0a45ba1fa2b48f2a30577a06731"+dependencies = [+ "float-cmp",+]++[[package]]+name = "string_cache"+version = "0.8.9"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "bf776ba3fa74f83bf4b63c3dcbbf82173db2632ed8452cb2d891d33f459de70f"+dependencies = [+ "new_debug_unreachable",+ "parking_lot",+ "phf_shared",+ "precomputed-hash",+ "serde",+]++[[package]]+name = "string_cache_codegen"+version = "0.5.4"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "c711928715f1fe0fe509c53b43e993a9a557babc2d0a3567d0a3006f1ac931a0"+dependencies = [+ "phf_generator",+ "phf_shared",+ "proc-macro2",+ "quote",+]++[[package]]+name = "strum"+version = "0.26.3"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "8fec0f0aef304996cf250b31b5a10dee7980c85da9d759361292b8bca5a18f06"+dependencies = [+ "strum_macros 0.26.4",+]++[[package]]+name = "strum"+version = "0.27.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "af23d6f6c1a224baef9d3f61e287d2761385a5b88fdab4eb4c6f11aeb54c4bcf"+dependencies = [+ "strum_macros 0.27.2",+]++[[package]]+name = "strum_macros"+version = "0.26.4"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "4c6bee85a5a24955dc440386795aa378cd9cf82acd5f764469152d2270e581be"+dependencies = [+ "heck 0.5.0",+ "proc-macro2",+ "quote",+ "rustversion",+ "syn 2.0.119",+]++[[package]]+name = "strum_macros"+version = "0.27.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "7695ce3845ea4b33927c055a39dc438a45b059f7c1b3d91d38d10355fb8cbca7"+dependencies = [+ "heck 0.5.0",+ "proc-macro2",+ "quote",+ "syn 2.0.119",+]++[[package]]+name = "subtle"+version = "2.6.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "13c2bddecc57b384dee18652358fb23172facb8a2c51ccc10d74c157bdea3292"++[[package]]+name = "sval"+version = "2.21.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "ec4a2a7d92fa86fcc6222e4c3845f8486cff899d9db32480b26c91a5dbf2e22d"++[[package]]+name = "sval_buffer"+version = "2.21.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "f4324db9ac500c609d659b752edf9c8abbf2233f8afd61a503fd6f88ed625032"+dependencies = [+ "sval",+ "sval_ref",+ "zerocopy",+]++[[package]]+name = "sval_dynamic"+version = "2.21.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "4046add0eecf55e680b9e207edf5fc7737b18a1d950db363d97e7f1b2d7c629c"+dependencies = [+ "sval",+]++[[package]]+name = "sval_fmt"+version = "2.21.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "911a3486b5984a0a4f25edefcf2c2dba23654c29f63e75493b671d338bf24243"+dependencies = [+ "itoa",+ "ryu",+ "sval",+]++[[package]]+name = "sval_json"+version = "2.21.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "da53aae7c737b5b5f1be4bcb0ff20e057bf6b2ee4e9d025560075c5830d09f95"+dependencies = [+ "itoa",+ "ryu",+ "sval",+]++[[package]]+name = "sval_nested"+version = "2.21.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "df24df43cbdc4bb8c9f5ed19d0d57dc8f60a1a4259cdce52d597fe774ad3a71f"+dependencies = [+ "sval",+ "sval_buffer",+ "sval_ref",+]++[[package]]+name = "sval_ref"+version = "2.21.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "2bebc17f0f1fad060e57b778728d41ef87627e9111a6365d7463472cb58fc1b3"+dependencies = [+ "sval",+]++[[package]]+name = "sval_serde"+version = "2.21.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "9f26fe3f6a68b40e6c8d654ea48c00e4316272fddf68c80493714c1b034ae70b"+dependencies = [+ "serde_core",+ "sval",+ "sval_nested",+]++[[package]]+name = "svg_fmt"+version = "0.4.5"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "0193cc4331cfd2f3d2011ef287590868599a2f33c3e69bc22c1a3d3acf9e02fb"++[[package]]+name = "svgtypes"+version = "0.15.3"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "68c7541fff44b35860c1a7a47a7cadf3e4a304c457b58f9870d9706ece028afc"+dependencies = [+ "kurbo",+ "siphasher",+]++[[package]]+name = "swash"+version = "0.2.10"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "6c2499c2d826531388872b2268718aed907a39bd785ab0dcfe57fab26283f92e"+dependencies = [+ "skrifa",+ "yazi",+ "zeno",+]++[[package]]+name = "syn"+version = "1.0.109"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "72b64191b275b66ffe2469e8af2c1cfe3bafa67b529ead792a6d0160888b4237"+dependencies = [+ "proc-macro2",+ "quote",+ "unicode-ident",+]++[[package]]+name = "syn"+version = "2.0.119"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "872831b642d1a07999a962a351ed35b955ea2cfc8f3862091e2a240a84f17297"+dependencies = [+ "proc-macro2",+ "quote",+ "unicode-ident",+]++[[package]]+name = "syn"+version = "3.0.3"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "53e9bae58849f64dfa4f5d5ae372c8341f7305f82a3868709269343628b659a3"+dependencies = [+ "proc-macro2",+ "quote",+ "unicode-ident",+]++[[package]]+name = "sync_wrapper"+version = "1.0.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "0bf256ce5efdfa370213c1dabab5935a12e49f2c58d15e9eac2870d3b4f27263"+dependencies = [+ "futures-core",+]++[[package]]+name = "synstructure"+version = "0.13.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "728a70f3dbaf5bab7f0c4b1ac8d7ae5ea60a4b5549c8a5914361c99147a709d2"+dependencies = [+ "proc-macro2",+ "quote",+ "syn 2.0.119",+]++[[package]]+name = "sys-locale"+version = "0.3.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "8eab9a99a024a169fe8a903cf9d4a3b3601109bcc13bd9e3c6fff259138626c4"+dependencies = [+ "libc",+]++[[package]]+name = "sysinfo"+version = "0.31.4"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "355dbe4f8799b304b05e1b0f05fc59b2a18d36645cf169607da45bde2f69a1be"+dependencies = [+ "core-foundation-sys",+ "libc",+ "memchr",+ "ntapi",+ "rayon",+ "windows 0.57.0",+]++[[package]]+name = "system-configuration"+version = "0.6.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "3c879d448e9d986b661742763247d3693ed13609438cf3d006f51f5368a5ba6b"+dependencies = [+ "bitflags 2.13.1",+ "core-foundation 0.9.4",+ "system-configuration-sys",+]++[[package]]+name = "system-configuration-sys"+version = "0.6.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "8e1d1b10ced5ca923a1fcb8d03e96b8d3268065d724548c0211415ff6ac6bac4"+dependencies = [+ "core-foundation-sys",+ "libc",+]++[[package]]+name = "taffy"+version = "0.9.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "a13e5d13f79d558b5d353a98072ca8ca0e99da429467804de959aa8c83c9a004"+dependencies = [+ "arrayvec",+ "grid",+ "serde",+ "slotmap",+]++[[package]]+name = "take-until"+version = "0.2.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "8bdb6fa0dfa67b38c1e66b7041ba9dcf23b99d8121907cd31c807a332f7a0bbb"++[[package]]+name = "tao-core-video-sys"+version = "0.2.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "271450eb289cb4d8d0720c6ce70c72c8c858c93dd61fc625881616752e6b98f6"+dependencies = [+ "cfg-if",+ "core-foundation-sys",+ "libc",+ "objc",+]++[[package]]+name = "tempfile"+version = "3.27.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "32497e9a4c7b38532efcdebeef879707aa9f794296a4f0244f6f69e9bc8574bd"+dependencies = [+ "fastrand 2.5.0",+ "getrandom 0.4.3",+ "once_cell",+ "rustix 1.1.4",+ "windows-sys 0.61.2",+]++[[package]]+name = "tendril"+version = "0.4.3"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "d24a120c5fc464a3458240ee02c299ebcb9d67b5249c8848b09d639dca8d7bb0"+dependencies = [+ "futf",+ "mac",+ "utf-8",+]++[[package]]+name = "termcolor"+version = "1.4.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "06794f8f6c5c898b3275aebefa6b8a1cb24cd2c6c79397ab15774837a0bc5755"+dependencies = [+ "winapi-util",+]++[[package]]+name = "thiserror"+version = "1.0.69"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "b6aaf5339b578ea85b50e080feb250a3e8ae8cfcdff9a461c9ec2904bc923f52"+dependencies = [+ "thiserror-impl 1.0.69",+]++[[package]]+name = "thiserror"+version = "2.0.20"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "ec86235f5fcc2a73650310756d2ac5b138a5780bbbdfae3eeccec992c435ba4f"+dependencies = [+ "thiserror-impl 2.0.20",+]++[[package]]+name = "thiserror-impl"+version = "1.0.69"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "4fee6c4efc90059e10f81e6d42c60a18f76588c3d74cb83a0b242a2b6c7504c1"+dependencies = [+ "proc-macro2",+ "quote",+ "syn 2.0.119",+]++[[package]]+name = "thiserror-impl"+version = "2.0.20"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "bc04cd3e1236dd4a98afca4569f2deb3f120e5422a4023be2cb683f8486292af"+dependencies = [+ "proc-macro2",+ "quote",+ "syn 3.0.3",+]++[[package]]+name = "tiff"+version = "0.11.3"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "b63feaf3343d35b6ca4d50483f94843803b0f51634937cc2ec519fc32232bc52"+dependencies = [+ "fax",+ "flate2",+ "half",+ "quick-error",+ "weezl",+ "zune-jpeg",+]++[[package]]+name = "tiny-keccak"+version = "2.0.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "2c9d3793400a45f954c52e73d068316d76b6f4e36977e3fcebb13a2721e80237"+dependencies = [+ "crunchy",+]++[[package]]+name = "tiny-skia"+version = "0.11.4"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "83d13394d44dae3207b52a326c0c85a8bf87f1541f23b0d143811088497b09ab"+dependencies = [+ "arrayref",+ "arrayvec",+ "bytemuck",+ "cfg-if",+ "log",+ "png 0.17.16",+ "tiny-skia-path",+]++[[package]]+name = "tiny-skia-path"+version = "0.11.4"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "9c9e7fc0c2e86a30b117d0462aa261b72b7a99b7ebd7deb3a14ceda95c5bdc93"+dependencies = [+ "arrayref",+ "bytemuck",+ "strict-num",+]++[[package]]+name = "tinystr"+version = "0.8.4"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "b1e27c91459209c2986af3dcf603a5a74a4368754ce37414f59acc971167f643"+dependencies = [+ "displaydoc",+ "zerovec",+]++[[package]]+name = "tinyvec"+version = "1.12.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "bb4ebadaa0af04fab11ae01eb5f9fdb5f9c5b875506e210e71c07873528baa7f"+dependencies = [+ "tinyvec_macros",+]++[[package]]+name = "tinyvec_macros"+version = "0.1.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "1f3ccbac311fea05f86f61904b462b55fb3df8837a366dfc601a0161d0532f20"++[[package]]+name = "tokio"+version = "1.53.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "202caea871b69668250d242070849eb495be178ed697a3e98aebce5bc81a0bed"+dependencies = [+ "bytes",+ "libc",+ "mio",+ "pin-project-lite",+ "socket2",+ "windows-sys 0.61.2",+]++[[package]]+name = "tokio-rustls"+version = "0.26.4"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "1729aa945f29d91ba541258c8df89027d5792d85a8841fb65e8bf0f4ede4ef61"+dependencies = [+ "rustls",+ "tokio",+]++[[package]]+name = "tokio-socks"+version = "0.5.3"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "a7e2948f60dbe26b35f2c7fb74ac2854c1fddded0fe9d7548fcc674a246f7615"+dependencies = [+ "either",+ "futures-util",+ "thiserror 1.0.69",+ "tokio",+]++[[package]]+name = "tokio-util"+version = "0.7.19"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "494815d09bf52b5548659851081238f0ca39ff638363907596da739561c62c52"+dependencies = [+ "bytes",+ "futures-core",+ "futures-sink",+ "libc",+ "pin-project-lite",+ "tokio",+]++[[package]]+name = "toml"+version = "0.8.23"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "dc1beb996b9d83529a9e75c17a1686767d148d70663143c7854d8b4a09ced362"+dependencies = [+ "serde",+ "serde_spanned 0.6.9",+ "toml_datetime 0.6.11",+ "toml_edit 0.22.27",+]++[[package]]+name = "toml"+version = "1.1.4+spec-1.1.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "3aace63f4bbcdfc2c965b059de67119c89c4017a70d633be6c104910f67056f5"+dependencies = [+ "indexmap",+ "serde_core",+ "serde_spanned 1.1.1",+ "toml_datetime 1.1.1+spec-1.1.0",+ "toml_parser",+ "toml_writer",+ "winnow 1.0.4",+]++[[package]]+name = "toml_datetime"+version = "0.6.11"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "22cddaf88f4fbc13c51aebbf5f8eceb5c7c5a9da2ac40a13519eb5b0a0e8f11c"+dependencies = [+ "serde",+]++[[package]]+name = "toml_datetime"+version = "1.1.1+spec-1.1.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "3165f65f62e28e0115a00b2ebdd37eb6f3b641855f9d636d3cd4103767159ad7"+dependencies = [+ "serde_core",+]++[[package]]+name = "toml_edit"+version = "0.22.27"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "41fe8c660ae4257887cf66394862d21dbca4a6ddd26f04a3560410406a2f819a"+dependencies = [+ "indexmap",+ "serde",+ "serde_spanned 0.6.9",+ "toml_datetime 0.6.11",+ "toml_write",+ "winnow 0.7.15",+]++[[package]]+name = "toml_edit"+version = "0.25.13+spec-1.1.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "6975367e4d2ef766d86af01ffad14b622fecc8d4357a998fbc4deb6e9bacaf9b"+dependencies = [+ "indexmap",+ "toml_datetime 1.1.1+spec-1.1.0",+ "toml_parser",+ "winnow 1.0.4",+]++[[package]]+name = "toml_parser"+version = "1.1.3+spec-1.1.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "1d38ac1cf9b95face32296c0a3ede1fdc270627c9d9c02a7274dd6d960dc4d56"+dependencies = [+ "winnow 1.0.4",+]++[[package]]+name = "toml_write"+version = "0.1.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "5d99f8c9a7727884afe522e9bd5edbfc91a3312b36a77b5fb8926e4c31a41801"++[[package]]+name = "toml_writer"+version = "1.1.2+spec-1.1.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "7d56353a2a665ad0f41a421187180aab746c8c325620617ad883a99a1cbe66d2"++[[package]]+name = "tower"+version = "0.5.3"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "ebe5ef63511595f1344e2d5cfa636d973292adc0eec1f0ad45fae9f0851ab1d4"+dependencies = [+ "futures-core",+ "futures-util",+ "pin-project-lite",+ "sync_wrapper",+ "tokio",+ "tower-layer",+ "tower-service",+]++[[package]]+name = "tower-layer"+version = "0.3.3"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "121c2a6cda46980bb0fcd1647ffaf6cd3fc79a013de288782836f6df9c48780e"++[[package]]+name = "tower-service"+version = "0.3.3"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "8df9b6e13f2d32c91b9bd719c00d1958837bc7dec474d94952798cc8e69eeec3"++[[package]]+name = "tracing"+version = "0.1.44"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "63e71662fa4b2a2c3a26f570f037eb95bb1f85397f3cd8076caed2f026a6d100"+dependencies = [+ "pin-project-lite",+ "tracing-attributes",+ "tracing-core",+]++[[package]]+name = "tracing-attributes"+version = "0.1.31"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "7490cfa5ec963746568740651ac6781f701c9c5ea257c58e057f3ba8cf69e8da"+dependencies = [+ "proc-macro2",+ "quote",+ "syn 2.0.119",+]++[[package]]+name = "tracing-core"+version = "0.1.36"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "db97caf9d906fbde555dd62fa95ddba9eecfd14cb388e4f491a66d74cd5fb79a"+dependencies = [+ "once_cell",+]++[[package]]+name = "tree-sitter"+version = "0.25.10"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "78f873475d258561b06f1c595d93308a7ed124d9977cb26b148c2084a4a3cc87"+dependencies = [+ "cc",+ "regex",+ "regex-syntax",+ "serde_json",+ "streaming-iterator",+ "tree-sitter-language",+]++[[package]]+name = "tree-sitter-bash"+version = "0.23.3"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "329a4d48623ac337d42b1df84e81a1c9dbb2946907c102ca72db158c1964a52e"+dependencies = [+ "cc",+ "tree-sitter-language",+]++[[package]]+name = "tree-sitter-c"+version = "0.24.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "a9b2eb57a55fed6b00812912e730b7a275cf4fe98bfd6a5d76263d4438371728"+dependencies = [+ "cc",+ "tree-sitter-language",+]++[[package]]+name = "tree-sitter-c-sharp"+version = "0.23.5"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "c1aac67f1ad71de1d6d39708d34811081c26dfa495658de6c14c34200849357c"+dependencies = [+ "cc",+ "tree-sitter-language",+]++[[package]]+name = "tree-sitter-cmake"+version = "0.7.4"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "164e0c4f4236ec5ceff14824a5528615cf462e100467e49826442ff57d327061"+dependencies = [+ "cc",+ "tree-sitter-language",+]++[[package]]+name = "tree-sitter-cpp"+version = "0.23.4"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "df2196ea9d47b4ab4a31b9297eaa5a5d19a0b121dceb9f118f6790ad0ab94743"+dependencies = [+ "cc",+ "tree-sitter-language",+]++[[package]]+name = "tree-sitter-css"+version = "0.23.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "5ad6489794d41350d12a7fbe520e5199f688618f43aace5443980d1ddcf1b29e"+dependencies = [+ "cc",+ "tree-sitter-language",+]++[[package]]+name = "tree-sitter-diff"+version = "0.1.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "dfe1e5ca280a65dfe5ba4205c1bcc84edf486464fed315db53dee6da9a335889"+dependencies = [+ "cc",+ "tree-sitter-language",+]++[[package]]+name = "tree-sitter-elixir"+version = "0.3.5"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "66dd064a762ed95bfc29857fa3cb7403bb1e5cb88112de0f6341b7e47284ba40"+dependencies = [+ "cc",+ "tree-sitter-language",+]++[[package]]+name = "tree-sitter-embedded-template"+version = "0.23.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "790063ef14e5b67556abc0b3be0ed863fb41d65ee791cf8c0b20eb42a1fa46af"+dependencies = [+ "cc",+ "tree-sitter-language",+]++[[package]]+name = "tree-sitter-go"+version = "0.23.4"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "b13d476345220dbe600147dd444165c5791bf85ef53e28acbedd46112ee18431"+dependencies = [+ "cc",+ "tree-sitter-language",+]++[[package]]+name = "tree-sitter-graphql"+version = "0.1.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "efedc4cac157161cc23a0adc4553a2cedc908e1cd754b6cd033a919bb81ce5d6"+dependencies = [+ "cc",+ "tree-sitter-language",+]++[[package]]+name = "tree-sitter-html"+version = "0.23.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "261b708e5d92061ede329babaaa427b819329a9d427a1d710abb0f67bbef63ee"+dependencies = [+ "cc",+ "tree-sitter-language",+]++[[package]]+name = "tree-sitter-java"+version = "0.23.5"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "0aa6cbcdc8c679b214e616fd3300da67da0e492e066df01bcf5a5921a71e90d6"+dependencies = [+ "cc",+ "tree-sitter-language",+]++[[package]]+name = "tree-sitter-javascript"+version = "0.23.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "bf40bf599e0416c16c125c3cec10ee5ddc7d1bb8b0c60fa5c4de249ad34dc1b1"+dependencies = [+ "cc",+ "tree-sitter-language",+]++[[package]]+name = "tree-sitter-jsdoc"+version = "0.23.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "a3862dfcb1038fc5e7812d7df14190afdeb7e1415288fd5f51f58395f8cb0faf"+dependencies = [+ "cc",+ "tree-sitter-language",+]++[[package]]+name = "tree-sitter-json"+version = "0.24.8"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "4d727acca406c0020cffc6cf35516764f36c8e3dc4408e5ebe2cb35a947ec471"+dependencies = [+ "cc",+ "tree-sitter-language",+]++[[package]]+name = "tree-sitter-language"+version = "0.1.7"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "009994f150cc0cd50ff54917d5bc8bffe8cad10ca10d81c34da2ec421ae61782"++[[package]]+name = "tree-sitter-make"+version = "1.1.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "c5998dc7cbcbdab19fae8aefef982bf2d6544513d8d2e69cc44aec4c63810104"+dependencies = [+ "cc",+ "tree-sitter-language",+]++[[package]]+name = "tree-sitter-md"+version = "0.5.3"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "2efd398be546456c814598ee56c0f51769a77241511b4a58077815d120afa882"+dependencies = [+ "cc",+ "tree-sitter-language",+]++[[package]]+name = "tree-sitter-proto"+version = "0.2.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "8e4360b434b5980fc397137ef29e1988619fef4159ac86fa7ac5777d459d3924"+dependencies = [+ "cc",+ "tree-sitter-language",+]++[[package]]+name = "tree-sitter-python"+version = "0.23.6"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "3d065aaa27f3aaceaf60c1f0e0ac09e1cb9eb8ed28e7bcdaa52129cffc7f4b04"+dependencies = [+ "cc",+ "tree-sitter-language",+]++[[package]]+name = "tree-sitter-ruby"+version = "0.23.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "be0484ea4ef6bb9c575b4fdabde7e31340a8d2dbc7d52b321ac83da703249f95"+dependencies = [+ "cc",+ "tree-sitter-language",+]++[[package]]+name = "tree-sitter-rust"+version = "0.24.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "439e577dbe07423ec2582ac62c7531120dbfccfa6e5f92406f93dd271a120e45"+dependencies = [+ "cc",+ "tree-sitter-language",+]++[[package]]+name = "tree-sitter-scala"+version = "0.23.4"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "efde5e68b4736e9eac17bfa296c6f104a26bffab363b365eb898c40a63c15d2f"+dependencies = [+ "cc",+ "tree-sitter-language",+]++[[package]]+name = "tree-sitter-sequel"+version = "0.3.11"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "9d198ad3c319c02e43c21efa1ec796b837afcb96ffaef1a40c1978fbdcec7d17"+dependencies = [+ "cc",+ "tree-sitter-language",+]++[[package]]+name = "tree-sitter-swift"+version = "0.7.3"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "fe36052155b9dd69ca82b3b8f1b4ccfb2d867125ac1a4db1dd7331829242668c"+dependencies = [+ "cc",+ "tree-sitter-language",+]++[[package]]+name = "tree-sitter-toml-ng"+version = "0.7.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "e9adc2c898ae49730e857d75be403da3f92bb81d8e37a2f918a08dd10de5ebb1"+dependencies = [+ "cc",+ "tree-sitter-language",+]++[[package]]+name = "tree-sitter-typescript"+version = "0.23.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "6c5f76ed8d947a75cc446d5fccd8b602ebf0cde64ccf2ffa434d873d7a575eff"+dependencies = [+ "cc",+ "tree-sitter-language",+]++[[package]]+name = "tree-sitter-yaml"+version = "0.7.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "53c223db85f05e34794f065454843b0668ebc15d240ada63e2b5939f43ce7c97"+dependencies = [+ "cc",+ "tree-sitter-language",+]++[[package]]+name = "tree-sitter-zig"+version = "1.1.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "ab11fc124851b0db4dd5e55983bbd9631192e93238389dcd44521715e5d53e28"+dependencies = [+ "cc",+ "tree-sitter-language",+]++[[package]]+name = "triomphe"+version = "0.1.16"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "b40688ea6389c8171614b25491f71d4a27946e0c7ce2da1c6de27e25abf1a0ae"+dependencies = [+ "arc-swap",+ "serde",+ "stable_deref_trait",+]++[[package]]+name = "try-lock"+version = "0.2.5"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "e421abadd41a4225275504ea4d6566923418b7f05506fbc9c0fe86ba7396114b"++[[package]]+name = "ttf-parser"+version = "0.20.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "17f77d76d837a7830fe1d4f12b7b4ba4192c1888001c7164257e4bc6d21d96b4"++[[package]]+name = "ttf-parser"+version = "0.21.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "2c591d83f69777866b9126b24c6dd9a18351f177e49d625920d19f989fd31cf8"++[[package]]+name = "ttf-parser"+version = "0.25.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "d2df906b07856748fa3f6e0ad0cbaa047052d4a7dd609e231c4f72cee8c36f31"+dependencies = [+ "core_maths",+]++[[package]]+name = "typeid"+version = "1.0.3"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "bc7d623258602320d5c55d1bc22793b57daff0ec7efc270ea7d55ce1d5f5471c"++[[package]]+name = "typenum"+version = "1.20.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "b6f5e870be6c3b371b77fe0ee0bafb859fa4964b4404c27de1d380043c4dda20"++[[package]]+name = "uds_windows"+version = "1.2.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "f2f6fb2847f6742cd76af783a2a2c49e9375d0a111c7bef6f71cd9e738c72d6e"+dependencies = [+ "memoffset",+ "tempfile",+ "windows-sys 0.61.2",+]++[[package]]+name = "unicase"+version = "2.9.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "dbc4bc3a9f746d862c45cb89d705aa10f187bb96c76001afab07a0d35ce60142"++[[package]]+name = "unicode-bidi"+version = "0.3.18"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "5c1cb5db39152898a79168971543b1cb5020dff7fe43c8dc468b0885f5e29df5"++[[package]]+name = "unicode-bidi-mirroring"+version = "0.2.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "23cb788ffebc92c5948d0e997106233eeb1d8b9512f93f41651f52b6c5f5af86"++[[package]]+name = "unicode-bidi-mirroring"+version = "0.4.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "5dfa6e8c60bb66d49db113e0125ee8711b7647b5579dc7f5f19c42357ed039fe"++[[package]]+name = "unicode-ccc"+version = "0.2.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "1df77b101bcc4ea3d78dafc5ad7e4f58ceffe0b2b16bf446aeb50b6cb4157656"++[[package]]+name = "unicode-ccc"+version = "0.4.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "ce61d488bcdc9bc8b5d1772c404828b17fc481c0a582b5581e95fb233aef503e"++[[package]]+name = "unicode-id"+version = "0.3.6"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "70ba288e709927c043cbe476718d37be306be53fb1fafecd0dbe36d072be2580"++[[package]]+name = "unicode-ident"+version = "1.0.24"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "e6e4313cd5fcd3dad5cafa179702e2b244f760991f45397d14d4ebf38247da75"++[[package]]+name = "unicode-linebreak"+version = "0.1.5"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "3b09c83c3c29d37506a3e260c08c03743a6bb66a9cd432c6934ab501a190571f"++[[package]]+name = "unicode-properties"+version = "0.1.4"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "7df058c713841ad818f1dc5d3fd88063241cc61f49f5fbea4b951e8cf5a8d71d"++[[package]]+name = "unicode-script"+version = "0.5.8"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "383ad40bb927465ec0ce7720e033cb4ca06912855fc35db31b5755d0de75b1ee"++[[package]]+name = "unicode-segmentation"+version = "1.13.3"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "c6f5d3c3b1bf09027a88a6bc961fc00497d651009560b5463668dc81b0fa87a8"++[[package]]+name = "unicode-vo"+version = "0.1.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "b1d386ff53b415b7fe27b50bb44679e2cc4660272694b7b6f3326d8480823a94"++[[package]]+name = "unicode-width"+version = "0.2.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "b4ac048d71ede7ee76d585517add45da530660ef4390e49b098733c6e897f254"++[[package]]+name = "unsafe-libyaml"+version = "0.2.11"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "673aac59facbab8a9007c7f6108d11f63b603f7cabff99fabf650fea5c32b861"++[[package]]+name = "untrusted"+version = "0.9.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "8ecb6da28b8a351d773b68d5825ac39017e680750f980f3a1a85cd8dd28a47c1"++[[package]]+name = "url"+version = "2.5.8"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "ff67a8a4397373c3ef660812acab3268222035010ab8680ec4215f38ba3d0eed"+dependencies = [+ "form_urlencoded",+ "idna",+ "percent-encoding",+ "serde",+ "serde_derive",+]++[[package]]+name = "usvg"+version = "0.45.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "80be9b06fbae3b8b303400ab20778c80bbaf338f563afe567cf3c9eea17b47ef"+dependencies = [+ "base64",+ "data-url",+ "flate2",+ "fontdb 0.23.0",+ "imagesize",+ "kurbo",+ "log",+ "pico-args",+ "roxmltree",+ "rustybuzz 0.20.1",+ "simplecss",+ "siphasher",+ "strict-num",+ "svgtypes",+ "tiny-skia-path",+ "unicode-bidi",+ "unicode-script",+ "unicode-vo",+ "xmlwriter",+]++[[package]]+name = "utf-8"+version = "0.7.6"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "09cc8ee72d2a9becf2f2febe0205bbed8fc6615b7cb429ad062dc7b7ddd036a9"++[[package]]+name = "utf8_iter"+version = "1.0.4"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "b6c140620e7ffbb22c2dee59cafe6084a59b5ffc27a8859a5f0d494b5d52b6be"++[[package]]+name = "uuid"+version = "1.24.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "bf3923a6f5c4c6382e0b653c4117f48d631ea17f38ed86e2a828e6f7412f5239"+dependencies = [+ "getrandom 0.4.3",+ "js-sys",+ "serde_core",+ "sha1_smol",+ "wasm-bindgen",+]++[[package]]+name = "v_frame"+version = "0.3.9"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "666b7727c8875d6ab5db9533418d7c764233ac9c0cff1d469aec8fa127597be2"+dependencies = [+ "aligned-vec",+ "num-traits",+ "wasm-bindgen",+]++[[package]]+name = "value-bag"+version = "1.13.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "068e763e8279de7ab94b6afebded2cb701678af094feb1c12ccb061b4783c1be"+dependencies = [+ "value-bag-serde1",+ "value-bag-sval2",+]++[[package]]+name = "value-bag-serde1"+version = "1.13.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "417d6197dd0ee696783d6be4276ac6ea74b985e00024c85ccfb37aff4f2bed82"+dependencies = [+ "erased-serde",+ "serde_core",+ "serde_fmt",+]++[[package]]+name = "value-bag-sval2"+version = "1.13.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "c61f7251ecde2c9ed431bbe0659853e7991753447447bbf1ae59d8b31c578d4e"+dependencies = [+ "sval",+ "sval_buffer",+ "sval_dynamic",+ "sval_fmt",+ "sval_json",+ "sval_ref",+ "sval_serde",+]++[[package]]+name = "vcpkg"+version = "0.2.15"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "accd4ea62f7bb7a82fe23066fb0957d48ef677f6eeb8215f372f52e48bb32426"++[[package]]+name = "version_check"+version = "0.9.5"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "0b928f33d975fc6ad9f86c8f283853ad26bdd5b10b7f1542aa2fa15e2289105a"++[[package]]+name = "vswhom"+version = "0.1.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "be979b7f07507105799e854203b470ff7c78a1639e330a58f183b5fea574608b"+dependencies = [+ "libc",+ "vswhom-sys",+]++[[package]]+name = "vswhom-sys"+version = "0.1.3"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "fb067e4cbd1ff067d1df46c9194b5de0e98efd2810bbc95c5d5e5f25a3231150"+dependencies = [+ "cc",+ "libc",+]++[[package]]+name = "wake"+version = "0.1.0"+dependencies = [+ "anyhow",+ "chrono",+ "dirs 5.0.1",+ "futures",+ "gpui",+ "gpui-component",+ "serde",+ "serde_json",+ "wake-core",+]++[[package]]+name = "wake-core"+version = "0.1.0"+dependencies = [+ "anyhow",+ "chrono",+ "dirs 5.0.1",+ "notify",+ "rusqlite",+ "serde",+ "serde_json",+ "walkdir",+]++[[package]]+name = "waker-fn"+version = "1.2.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "317211a0dc0ceedd78fb2ca9a44aed3d7b9b26f81870d485c07122b4350673b7"++[[package]]+name = "walkdir"+version = "2.5.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "29790946404f91d9c5d06f9874efddea1dc06c5efe94541a7d6863108e3a5e4b"+dependencies = [+ "same-file",+ "winapi-util",+]++[[package]]+name = "want"+version = "0.3.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "bfa7760aed19e106de2c7c0b581b509f2f25d3dacaf737cb82ac61bc6d760b0e"+dependencies = [+ "try-lock",+]++[[package]]+name = "wasi"+version = "0.11.1+wasi-snapshot-preview1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "ccf3ec651a847eb01de73ccad15eb7d99f80485de043efb2f370cd654f4ea44b"++[[package]]+name = "wasip2"+version = "1.0.4+wasi-0.2.12"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "b67efb37e106e55ce722a510d6b5f9c17f083e5fc79afc2badeb12cc313d9487"+dependencies = [+ "wit-bindgen",+]++[[package]]+name = "wasm-bindgen"+version = "0.2.127"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "1b70935747edd64d89de3efa29d73789b806c15798f8e7dca4d8ac356b50ce70"+dependencies = [+ "cfg-if",+ "once_cell",+ "rustversion",+ "wasm-bindgen-macro",+ "wasm-bindgen-shared",+]++[[package]]+name = "wasm-bindgen-futures"+version = "0.4.77"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "6b7777d5cc23d0e91404e53ce2d5e8ec7acae3026b16233dba62cd3246457950"+dependencies = [+ "js-sys",+ "wasm-bindgen",+]++[[package]]+name = "wasm-bindgen-macro"+version = "0.2.127"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "77775f8f3f7217702089053b94958f8f54061a3f663417df76e19cbdcca29bc1"+dependencies = [+ "quote",+ "wasm-bindgen-macro-support",+]++[[package]]+name = "wasm-bindgen-macro-support"+version = "0.2.127"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "e11d33f857dc2fb11b8bc75aee111aa9cbeb12cd9f25efd3d4c2a3dd4e235284"+dependencies = [+ "bumpalo",+ "proc-macro2",+ "quote",+ "syn 2.0.119",+ "wasm-bindgen-shared",+]++[[package]]+name = "wasm-bindgen-shared"+version = "0.2.127"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "7ef64dbcc55df09c7e5a46182d181c2cfa3e925f3da937ea764728b4bbb9dcbf"+dependencies = [+ "unicode-ident",+]++[[package]]+name = "wasm-streams"+version = "0.4.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "15053d8d85c7eccdbefef60f06769760a563c7f0a9d6902a13d35c7800b0ad65"+dependencies = [+ "futures-util",+ "js-sys",+ "wasm-bindgen",+ "wasm-bindgen-futures",+ "web-sys",+]++[[package]]+name = "wayland-backend"+version = "0.3.16"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "016ccf01d1c58b6f8999612813e17c9b2390f7d70671428869913310f83f54b8"+dependencies = [+ "cc",+ "downcast-rs",+ "rustix 1.1.4",+ "scoped-tls",+ "smallvec",+ "wayland-sys",+]++[[package]]+name = "wayland-client"+version = "0.31.15"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "e3c36a0f861ad76d0901f2800b46321410d9f73f2ea88aac0650d86c32688073"+dependencies = [+ "bitflags 2.13.1",+ "rustix 1.1.4",+ "wayland-backend",+ "wayland-scanner",+]++[[package]]+name = "wayland-cursor"+version = "0.31.14"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "4a52d18780be9b1314328a3de5f930b73d2200112e3849ca6cb11822793fb34d"+dependencies = [+ "rustix 1.1.4",+ "wayland-client",+ "xcursor",+]++[[package]]+name = "wayland-protocols"+version = "0.31.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "8f81f365b8b4a97f422ac0e8737c438024b5951734506b0e1d775c73030561f4"+dependencies = [+ "bitflags 2.13.1",+ "wayland-backend",+ "wayland-client",+ "wayland-scanner",+]++[[package]]+name = "wayland-protocols"+version = "0.32.13"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "23d0c813de3daa2ed6520af85a3bd49b0e722a3078506899aa9686fea58dc4b6"+dependencies = [+ "bitflags 2.13.1",+ "wayland-backend",+ "wayland-client",+ "wayland-scanner",+]++[[package]]+name = "wayland-protocols-plasma"+version = "0.2.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "23803551115ff9ea9bce586860c5c5a971e360825a0309264102a9495a5ff479"+dependencies = [+ "bitflags 2.13.1",+ "wayland-backend",+ "wayland-client",+ "wayland-protocols 0.31.2",+ "wayland-scanner",+]++[[package]]+name = "wayland-scanner"+version = "0.31.11"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "338e30461b3a2b67d70eb30a6d89f8e0c93a833e07d2ae89085cd070c4a00ac0"+dependencies = [+ "proc-macro2",+ "quick-xml",+ "quote",+]++[[package]]+name = "wayland-sys"+version = "0.31.11"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "d8eab23fefc9e41f8e841df4a9c707e8a8c4ed26e944ef69297184de2785e3be"+dependencies = [+ "dlib",+ "log",+ "once_cell",+ "pkg-config",+]++[[package]]+name = "web-sys"+version = "0.3.104"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "c435338968042f4f59a557f690a253676d47ce13ceb55d70100e7facf6620a30"+dependencies = [+ "js-sys",+ "wasm-bindgen",+]++[[package]]+name = "web-time"+version = "1.1.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "5a6580f308b1fad9207618087a65c04e7a10bc77e02c8e84e9b00dd4b12fa0bb"+dependencies = [+ "js-sys",+ "wasm-bindgen",+]++[[package]]+name = "weezl"+version = "0.1.12"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "a28ac98ddc8b9274cb41bb4d9d4d5c425b6020c50c46f25559911905610b4a88"++[[package]]+name = "which"+version = "6.0.3"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "b4ee928febd44d98f2f459a4a79bd4d928591333a494a10a868418ac1b39cf1f"+dependencies = [+ "either",+ "home",+ "rustix 0.38.44",+ "winsafe",+]++[[package]]+name = "winapi"+version = "0.3.9"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "5c839a674fcd7a98952e593242ea400abe93992746761e38641405d28b00f419"+dependencies = [+ "winapi-i686-pc-windows-gnu",+ "winapi-x86_64-pc-windows-gnu",+]++[[package]]+name = "winapi-i686-pc-windows-gnu"+version = "0.4.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "ac3b87c63620426dd9b991e5ce0329eff545bccbbb34f3be09ff6fb6ab51b7b6"++[[package]]+name = "winapi-util"+version = "0.1.11"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "c2a7b1c03c876122aa43f3020e6c3c3ee5c05081c9a00739faf7503aeba10d22"+dependencies = [+ "windows-sys 0.61.2",+]++[[package]]+name = "winapi-x86_64-pc-windows-gnu"+version = "0.4.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "712e227841d057c1ee1cd2fb22fa7e5a5461ae8e48fa2ca79ec42cfc1931183f"++[[package]]+name = "windows"+version = "0.57.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "12342cb4d8e3b046f3d80effd474a7a02447231330ef77d71daa6fbc40681143"+dependencies = [+ "windows-core 0.57.0",+ "windows-targets 0.52.6",+]++[[package]]+name = "windows"+version = "0.61.3"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "9babd3a767a4c1aef6900409f85f5d53ce2544ccdfaa86dad48c91782c6d6893"+dependencies = [+ "windows-collections",+ "windows-core 0.61.2",+ "windows-future",+ "windows-link 0.1.3",+ "windows-numerics",+]++[[package]]+name = "windows-capture"+version = "1.5.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "3a4df73e95feddb9ec1a7e9c2ca6323b8c97d5eeeff78d28f1eccdf19c882b24"+dependencies = [+ "parking_lot",+ "rayon",+ "thiserror 2.0.20",+ "windows 0.61.3",+ "windows-future",+]++[[package]]+name = "windows-collections"+version = "0.2.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "3beeceb5e5cfd9eb1d76b381630e82c4241ccd0d27f1a39ed41b2760b255c5e8"+dependencies = [+ "windows-core 0.61.2",+]++[[package]]+name = "windows-core"+version = "0.57.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "d2ed2439a290666cd67ecce2b0ffaad89c2a56b976b736e6ece670297897832d"+dependencies = [+ "windows-implement 0.57.0",+ "windows-interface 0.57.0",+ "windows-result 0.1.2",+ "windows-targets 0.52.6",+]++[[package]]+name = "windows-core"+version = "0.61.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "c0fdd3ddb90610c7638aa2b3a3ab2904fb9e5cdbecc643ddb3647212781c4ae3"+dependencies = [+ "windows-implement 0.60.2",+ "windows-interface 0.59.3",+ "windows-link 0.1.3",+ "windows-result 0.3.4",+ "windows-strings 0.4.2",+]++[[package]]+name = "windows-core"+version = "0.62.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "b8e83a14d34d0623b51dce9581199302a221863196a1dde71a7663a4c2be9deb"+dependencies = [+ "windows-implement 0.60.2",+ "windows-interface 0.59.3",+ "windows-link 0.2.1",+ "windows-result 0.4.1",+ "windows-strings 0.5.1",+]++[[package]]+name = "windows-future"+version = "0.2.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "fc6a41e98427b19fe4b73c550f060b59fa592d7d686537eebf9385621bfbad8e"+dependencies = [+ "windows-core 0.61.2",+ "windows-link 0.1.3",+ "windows-threading",+]++[[package]]+name = "windows-implement"+version = "0.57.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "9107ddc059d5b6fbfbffdfa7a7fe3e22a226def0b2608f72e9d552763d3e1ad7"+dependencies = [+ "proc-macro2",+ "quote",+ "syn 2.0.119",+]++[[package]]+name = "windows-implement"+version = "0.60.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "053e2e040ab57b9dc951b72c264860db7eb3b0200ba345b4e4c3b14f67855ddf"+dependencies = [+ "proc-macro2",+ "quote",+ "syn 2.0.119",+]++[[package]]+name = "windows-interface"+version = "0.57.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "29bee4b38ea3cde66011baa44dba677c432a78593e202392d1e9070cf2a7fca7"+dependencies = [+ "proc-macro2",+ "quote",+ "syn 2.0.119",+]++[[package]]+name = "windows-interface"+version = "0.59.3"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "3f316c4a2570ba26bbec722032c4099d8c8bc095efccdc15688708623367e358"+dependencies = [+ "proc-macro2",+ "quote",+ "syn 2.0.119",+]++[[package]]+name = "windows-link"+version = "0.1.3"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "5e6ad25900d524eaabdbbb96d20b4311e1e7ae1699af4fb28c17ae66c80d798a"++[[package]]+name = "windows-link"+version = "0.2.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "f0805222e57f7521d6a62e36fa9163bc891acd422f971defe97d64e70d0a4fe5"++[[package]]+name = "windows-numerics"+version = "0.2.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "9150af68066c4c5c07ddc0ce30421554771e528bde427614c61038bc2c92c2b1"+dependencies = [+ "windows-core 0.61.2",+ "windows-link 0.1.3",+]++[[package]]+name = "windows-registry"+version = "0.4.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "4286ad90ddb45071efd1a66dfa43eb02dd0dfbae1545ad6cc3c51cf34d7e8ba3"+dependencies = [+ "windows-result 0.3.4",+ "windows-strings 0.3.1",+ "windows-targets 0.53.5",+]++[[package]]+name = "windows-registry"+version = "0.5.3"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "5b8a9ed28765efc97bbc954883f4e6796c33a06546ebafacbabee9696967499e"+dependencies = [+ "windows-link 0.1.3",+ "windows-result 0.3.4",+ "windows-strings 0.4.2",+]++[[package]]+name = "windows-result"+version = "0.1.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "5e383302e8ec8515204254685643de10811af0ed97ea37210dc26fb0032647f8"+dependencies = [+ "windows-targets 0.52.6",+]++[[package]]+name = "windows-result"+version = "0.3.4"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "56f42bd332cc6c8eac5af113fc0c1fd6a8fd2aa08a0119358686e5160d0586c6"+dependencies = [+ "windows-link 0.1.3",+]++[[package]]+name = "windows-result"+version = "0.4.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "7781fa89eaf60850ac3d2da7af8e5242a5ea78d1a11c49bf2910bb5a73853eb5"+dependencies = [+ "windows-link 0.2.1",+]++[[package]]+name = "windows-strings"+version = "0.3.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "87fa48cc5d406560701792be122a10132491cff9d0aeb23583cc2dcafc847319"+dependencies = [+ "windows-link 0.1.3",+]++[[package]]+name = "windows-strings"+version = "0.4.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "56e6c93f3a0c3b36176cb1327a4958a0353d5d166c2a35cb268ace15e91d3b57"+dependencies = [+ "windows-link 0.1.3",+]++[[package]]+name = "windows-strings"+version = "0.5.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "7837d08f69c77cf6b07689544538e017c1bfcf57e34b4c0ff58e6c2cd3b37091"+dependencies = [+ "windows-link 0.2.1",+]++[[package]]+name = "windows-sys"+version = "0.48.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "677d2418bec65e3338edb076e806bc1ec15693c5d0104683f2efe857f61056a9"+dependencies = [+ "windows-targets 0.48.5",+]++[[package]]+name = "windows-sys"+version = "0.52.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "282be5f36a8ce781fad8c8ae18fa3f9beff57ec1b52cb3de0789201425d9a33d"+dependencies = [+ "windows-targets 0.52.6",+]++[[package]]+name = "windows-sys"+version = "0.59.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "1e38bc4d79ed67fd075bcc251a1c39b32a1776bbe92e5bef1f0bf1f8c531853b"+dependencies = [+ "windows-targets 0.52.6",+]++[[package]]+name = "windows-sys"+version = "0.61.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "ae137229bcbd6cdf0f7b80a31df61766145077ddf49416a728b02cb3921ff3fc"+dependencies = [+ "windows-link 0.2.1",+]++[[package]]+name = "windows-targets"+version = "0.48.5"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "9a2fa6e2155d7247be68c096456083145c183cbbbc2764150dda45a87197940c"+dependencies = [+ "windows_aarch64_gnullvm 0.48.5",+ "windows_aarch64_msvc 0.48.5",+ "windows_i686_gnu 0.48.5",+ "windows_i686_msvc 0.48.5",+ "windows_x86_64_gnu 0.48.5",+ "windows_x86_64_gnullvm 0.48.5",+ "windows_x86_64_msvc 0.48.5",+]++[[package]]+name = "windows-targets"+version = "0.52.6"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "9b724f72796e036ab90c1021d4780d4d3d648aca59e491e6b98e725b84e99973"+dependencies = [+ "windows_aarch64_gnullvm 0.52.6",+ "windows_aarch64_msvc 0.52.6",+ "windows_i686_gnu 0.52.6",+ "windows_i686_gnullvm 0.52.6",+ "windows_i686_msvc 0.52.6",+ "windows_x86_64_gnu 0.52.6",+ "windows_x86_64_gnullvm 0.52.6",+ "windows_x86_64_msvc 0.52.6",+]++[[package]]+name = "windows-targets"+version = "0.53.5"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "4945f9f551b88e0d65f3db0bc25c33b8acea4d9e41163edf90dcd0b19f9069f3"+dependencies = [+ "windows-link 0.2.1",+ "windows_aarch64_gnullvm 0.53.1",+ "windows_aarch64_msvc 0.53.1",+ "windows_i686_gnu 0.53.1",+ "windows_i686_gnullvm 0.53.1",+ "windows_i686_msvc 0.53.1",+ "windows_x86_64_gnu 0.53.1",+ "windows_x86_64_gnullvm 0.53.1",+ "windows_x86_64_msvc 0.53.1",+]++[[package]]+name = "windows-threading"+version = "0.1.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "b66463ad2e0ea3bbf808b7f1d371311c80e115c0b71d60efc142cafbcfb057a6"+dependencies = [+ "windows-link 0.1.3",+]++[[package]]+name = "windows_aarch64_gnullvm"+version = "0.48.5"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "2b38e32f0abccf9987a4e3079dfb67dcd799fb61361e53e2882c3cbaf0d905d8"++[[package]]+name = "windows_aarch64_gnullvm"+version = "0.52.6"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "32a4622180e7a0ec044bb555404c800bc9fd9ec262ec147edd5989ccd0c02cd3"++[[package]]+name = "windows_aarch64_gnullvm"+version = "0.53.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "a9d8416fa8b42f5c947f8482c43e7d89e73a173cead56d044f6a56104a6d1b53"++[[package]]+name = "windows_aarch64_msvc"+version = "0.48.5"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "dc35310971f3b2dbbf3f0690a219f40e2d9afcf64f9ab7cc1be722937c26b4bc"++[[package]]+name = "windows_aarch64_msvc"+version = "0.52.6"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "09ec2a7bb152e2252b53fa7803150007879548bc709c039df7627cabbd05d469"++[[package]]+name = "windows_aarch64_msvc"+version = "0.53.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "b9d782e804c2f632e395708e99a94275910eb9100b2114651e04744e9b125006"++[[package]]+name = "windows_i686_gnu"+version = "0.48.5"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "a75915e7def60c94dcef72200b9a8e58e5091744960da64ec734a6c6e9b3743e"++[[package]]+name = "windows_i686_gnu"+version = "0.52.6"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "8e9b5ad5ab802e97eb8e295ac6720e509ee4c243f69d781394014ebfe8bbfa0b"++[[package]]+name = "windows_i686_gnu"+version = "0.53.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "960e6da069d81e09becb0ca57a65220ddff016ff2d6af6a223cf372a506593a3"++[[package]]+name = "windows_i686_gnullvm"+version = "0.52.6"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "0eee52d38c090b3caa76c563b86c3a4bd71ef1a819287c19d586d7334ae8ed66"++[[package]]+name = "windows_i686_gnullvm"+version = "0.53.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "fa7359d10048f68ab8b09fa71c3daccfb0e9b559aed648a8f95469c27057180c"++[[package]]+name = "windows_i686_msvc"+version = "0.48.5"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "8f55c233f70c4b27f66c523580f78f1004e8b5a8b659e05a4eb49d4166cca406"++[[package]]+name = "windows_i686_msvc"+version = "0.52.6"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "240948bc05c5e7c6dabba28bf89d89ffce3e303022809e73deaefe4f6ec56c66"++[[package]]+name = "windows_i686_msvc"+version = "0.53.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "1e7ac75179f18232fe9c285163565a57ef8d3c89254a30685b57d83a38d326c2"++[[package]]+name = "windows_x86_64_gnu"+version = "0.48.5"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "53d40abd2583d23e4718fddf1ebec84dbff8381c07cae67ff7768bbf19c6718e"++[[package]]+name = "windows_x86_64_gnu"+version = "0.52.6"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "147a5c80aabfbf0c7d901cb5895d1de30ef2907eb21fbbab29ca94c5b08b1a78"++[[package]]+name = "windows_x86_64_gnu"+version = "0.53.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "9c3842cdd74a865a8066ab39c8a7a473c0778a3f29370b5fd6b4b9aa7df4a499"++[[package]]+name = "windows_x86_64_gnullvm"+version = "0.48.5"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "0b7b52767868a23d5bab768e390dc5f5c55825b6d30b86c844ff2dc7414044cc"++[[package]]+name = "windows_x86_64_gnullvm"+version = "0.52.6"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "24d5b23dc417412679681396f2b49f3de8c1473deb516bd34410872eff51ed0d"++[[package]]+name = "windows_x86_64_gnullvm"+version = "0.53.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "0ffa179e2d07eee8ad8f57493436566c7cc30ac536a3379fdf008f47f6bb7ae1"++[[package]]+name = "windows_x86_64_msvc"+version = "0.48.5"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "ed94fce61571a4006852b7389a063ab983c02eb1bb37b47f8272ce92d06d9538"++[[package]]+name = "windows_x86_64_msvc"+version = "0.52.6"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "589f6da84c646204747d1270a2a5661ea66ed1cced2631d546fdfb155959f9ec"++[[package]]+name = "windows_x86_64_msvc"+version = "0.53.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "d6bbff5f0aada427a1e5a6da5f1f98158182f26556f345ac9e04d36d0ebed650"++[[package]]+name = "winnow"+version = "0.7.15"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "df79d97927682d2fd8adb29682d1140b343be4ac0f08fd68b7765d9c059d3945"+dependencies = [+ "memchr",+]++[[package]]+name = "winnow"+version = "1.0.4"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "23b97319f7b8343df12cc98938e5c3eb436064524c8d2b4e30a1d3a36eecdf81"+dependencies = [+ "memchr",+]++[[package]]+name = "winreg"+version = "0.55.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "cb5a765337c50e9ec252c2069be9bf91c7df47afb103b642ba3a53bf8101be97"+dependencies = [+ "cfg-if",+ "windows-sys 0.59.0",+]++[[package]]+name = "winsafe"+version = "0.0.19"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "d135d17ab770252ad95e9a872d365cf3090e3be864a34ab46f48555993efc904"++[[package]]+name = "wio"+version = "0.2.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "5d129932f4644ac2396cb456385cbf9e63b5b30c6e8dc4820bdca4eb082037a5"+dependencies = [+ "winapi",+]++[[package]]+name = "wit-bindgen"+version = "0.57.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "1ebf944e87a7c253233ad6766e082e3cd714b5d03812acc24c318f549614536e"++[[package]]+name = "workspace-hack"+version = "0.1.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "beffa227304dbaea3ad6a06ac674f9bc83a3dec3b7f63eeb442de37e7cb6bb01"++[[package]]+name = "writeable"+version = "0.6.4"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "3ad82d2a33cdc9674dc7465672f271e096168fcdbe0f799d9e6db8c5892679dc"++[[package]]+name = "x11"+version = "2.21.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "502da5464ccd04011667b11c435cb992822c2c0dbde1770c988480d312a0db2e"+dependencies = [+ "libc",+ "pkg-config",+]++[[package]]+name = "x11-clipboard"+version = "0.9.3"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "662d74b3d77e396b8e5beb00b9cad6a9eccf40b2ef68cc858784b14c41d535a3"+dependencies = [+ "libc",+ "x11rb",+]++[[package]]+name = "x11rb"+version = "0.13.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "9993aa5be5a26815fe2c3eacfc1fde061fc1a1f094bf1ad2a18bf9c495dd7414"+dependencies = [+ "as-raw-xcb-connection",+ "gethostname",+ "libc",+ "rustix 1.1.4",+ "x11rb-protocol",+ "xcursor",+]++[[package]]+name = "x11rb-protocol"+version = "0.13.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "ea6fc2961e4ef194dcbfe56bb845534d0dc8098940c7e5c012a258bfec6701bd"++[[package]]+name = "xattr"+version = "0.2.3"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "6d1526bbe5aaeb5eb06885f4d987bcdfa5e23187055de9b83fe00156a821fabc"+dependencies = [+ "libc",+]++[[package]]+name = "xcb"+version = "1.7.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "a6c2ad15e0e922856ee89afe862b8992334bbe7953adad56cd1199358cb30566"+dependencies = [+ "bitflags 2.13.1",+ "libc",+ "quick-xml",+ "x11",+]++[[package]]+name = "xcursor"+version = "0.3.11"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "163b33ed8786455e2fa5d72f554057ce3f3182425434f756cd39c99839d88e23"++[[package]]+name = "xim-ctext"+version = "0.3.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "2ac61a7062c40f3c37b6e82eeeef835d5cc7824b632a72784a89b3963c33284c"+dependencies = [+ "encoding_rs",+]++[[package]]+name = "xim-parser"+version = "0.2.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "5dcee45f89572d5a65180af3a84e7ddb24f5ea690a6d3aa9de231281544dd7b7"+dependencies = [+ "bitflags 2.13.1",+]++[[package]]+name = "xkbcommon"+version = "0.8.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "8d66ca9352cbd4eecbbc40871d8a11b4ac8107cfc528a6e14d7c19c69d0e1ac9"+dependencies = [+ "as-raw-xcb-connection",+ "libc",+ "memmap2",+ "xkeysym",+]++[[package]]+name = "xkeysym"+version = "0.2.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "b9cc00251562a284751c9973bace760d86c0276c471b4be569fe6b068ee97a56"++[[package]]+name = "xml5ever"+version = "0.18.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "9bbb26405d8e919bc1547a5aa9abc95cbfa438f04844f5fdd9dc7596b748bf69"+dependencies = [+ "log",+ "mac",+ "markup5ever",+]++[[package]]+name = "xmlwriter"+version = "0.1.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "ec7a2a501ed189703dba8b08142f057e887dfc4b2cc4db2d343ac6376ba3e0b9"++[[package]]+name = "y4m"+version = "0.8.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "7a5a4b21e1a62b67a2970e6831bc091d7b87e119e7f9791aef9702e3bef04448"++[[package]]+name = "yazi"+version = "0.2.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "e01738255b5a16e78bbb83e7fbba0a1e7dd506905cfc53f4622d89015a03fbb5"++[[package]]+name = "yeslogic-fontconfig-sys"+version = "6.0.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "1d8b8abf912b9a29ff112e1671c97c33636903d13a69712037190e6805af4f76"+dependencies = [+ "dlib",+ "once_cell",+ "pkg-config",+]++[[package]]+name = "yoke"+version = "0.8.3"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "709fe23a0424b6a435d82152b1bd3fdfb0833487d5fa90d05d42762a9891fef5"+dependencies = [+ "stable_deref_trait",+ "yoke-derive",+ "zerofrom",+]++[[package]]+name = "yoke-derive"+version = "0.8.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "de844c262c8848816172cef550288e7dc6c7b7814b4ee56b3e1553f275f1858e"+dependencies = [+ "proc-macro2",+ "quote",+ "syn 2.0.119",+ "synstructure",+]++[[package]]+name = "zbus"+version = "5.19.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "5db4be7c075cb421e4b7ee645541604239bd243ba7c357511f4ff3a74b555907"+dependencies = [+ "async-broadcast",+ "async-executor",+ "async-io",+ "async-lock",+ "async-process",+ "async-recursion",+ "async-task",+ "async-trait",+ "blocking",+ "enumflags2",+ "event-listener 5.4.2",+ "futures-core",+ "futures-lite 2.6.1",+ "hex",+ "libc",+ "ordered-stream",+ "rustix 1.1.4",+ "serde",+ "serde_repr",+ "tracing",+ "uds_windows",+ "uuid",+ "windows-sys 0.61.2",+ "winnow 1.0.4",+ "zbus_macros",+ "zbus_names",+ "zvariant",+]++[[package]]+name = "zbus_macros"+version = "5.19.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "2990635d09ade6df1868f72f8cac69a876a90981e8bd3c40b1be413f8dc88f40"+dependencies = [+ "proc-macro-crate",+ "proc-macro2",+ "quote",+ "syn 3.0.3",+ "zbus_names",+ "zvariant",+ "zvariant_utils",+]++[[package]]+name = "zbus_names"+version = "4.3.4"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "d8bf88b4a3ff53e883001e0e0115b297a9d53c31b9c1edd2bfdd853e3428624e"+dependencies = [+ "serde",+ "winnow 1.0.4",+ "zvariant",+]++[[package]]+name = "zcheapstr"+version = "1.1.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "d1afec51604565183aeb5c54c20aeab286120d4e4460f7f76e3e8bb8c0d99473"+dependencies = [+ "serde",+]++[[package]]+name = "zed-async-tar"+version = "0.5.0-zed"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "6cf4b5f655e29700e473cb1acd914ab112b37b62f96f7e642d5fc6a0c02eb881"+dependencies = [+ "async-std",+ "filetime",+ "libc",+ "pin-project",+ "redox_syscall 0.2.16",+ "xattr",+]++[[package]]+name = "zed-font-kit"+version = "0.14.1-zed"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "a3898e450f36f852edda72e3f985c34426042c4951790b23b107f93394f9bff5"+dependencies = [+ "bitflags 2.13.1",+ "byteorder",+ "core-foundation 0.10.0",+ "core-graphics 0.24.0",+ "core-text",+ "dirs 5.0.1",+ "dwrote",+ "float-ord",+ "freetype-sys",+ "lazy_static",+ "libc",+ "log",+ "pathfinder_geometry",+ "pathfinder_simd",+ "walkdir",+ "winapi",+ "yeslogic-fontconfig-sys",+]++[[package]]+name = "zed-reqwest"+version = "0.12.15-zed"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "ac2d05756ff48539950c3282ad7acf3817ad3f08797c205ad1c34a2ce03b9970"+dependencies = [+ "base64",+ "bytes",+ "encoding_rs",+ "futures-core",+ "futures-util",+ "h2",+ "http",+ "http-body",+ "http-body-util",+ "hyper",+ "hyper-rustls",+ "hyper-util",+ "ipnet",+ "js-sys",+ "log",+ "mime",+ "mime_guess",+ "once_cell",+ "percent-encoding",+ "pin-project-lite",+ "quinn",+ "rustls",+ "rustls-native-certs",+ "rustls-pemfile",+ "rustls-pki-types",+ "serde",+ "serde_json",+ "serde_urlencoded",+ "sync_wrapper",+ "system-configuration",+ "tokio",+ "tokio-rustls",+ "tokio-socks",+ "tokio-util",+ "tower",+ "tower-service",+ "url",+ "wasm-bindgen",+ "wasm-bindgen-futures",+ "wasm-streams",+ "web-sys",+ "windows-registry 0.4.0",+]++[[package]]+name = "zed-scap"+version = "0.0.8-zed"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "b6b338d705ae33a43ca00287c11129303a7a0aa57b101b72a1c08c863f698ac8"+dependencies = [+ "anyhow",+ "cocoa 0.25.0",+ "core-graphics-helmer-fork",+ "log",+ "objc",+ "rand 0.8.7",+ "screencapturekit",+ "screencapturekit-sys",+ "sysinfo",+ "tao-core-video-sys",+ "windows 0.61.3",+ "windows-capture",+ "x11",+ "xcb",+]++[[package]]+name = "zed-sum-tree"+version = "0.2.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "d490156d0d7311855564d6e1d6dccab992405a0c0e15e1c8ef18920c02177e35"+dependencies = [+ "arrayvec",+ "log",+ "rayon",+ "workspace-hack",+]++[[package]]+name = "zed-xim"+version = "0.4.0-zed"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "0c0b46ed118eba34d9ba53d94ddc0b665e0e06a2cf874cfa2dd5dec278148642"+dependencies = [+ "ahash",+ "hashbrown 0.14.5",+ "log",+ "x11rb",+ "xim-ctext",+ "xim-parser",+]++[[package]]+name = "zeno"+version = "0.3.3"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "6df3dc4292935e51816d896edcd52aa30bc297907c26167fec31e2b0c6a32524"++[[package]]+name = "zerocopy"+version = "0.8.56"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "556764e583adb45a9f8d413c2a147fa7e8d821e48e12b14fd560b607998b75eb"+dependencies = [+ "zerocopy-derive",+]++[[package]]+name = "zerocopy-derive"+version = "0.8.56"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "f2ab42fc20575779bd240faa45f94a74256f755c0fa9e89f0ede20d91d0cdfc1"+dependencies = [+ "proc-macro2",+ "quote",+ "syn 2.0.119",+]++[[package]]+name = "zerofrom"+version = "0.1.8"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "0ec05a11813ea801ff6d75110ad09cd0824ddba17dfe17128ea0d5f68e6c5272"+dependencies = [+ "zerofrom-derive",+]++[[package]]+name = "zerofrom-derive"+version = "0.1.7"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "11532158c46691caf0f2593ea8358fed6bbf68a0315e80aae9bd41fbade684a1"+dependencies = [+ "proc-macro2",+ "quote",+ "syn 2.0.119",+ "synstructure",+]++[[package]]+name = "zeroize"+version = "1.9.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "e13c156562582aa81c60cb29407084cdb54c4164760106ab78e6c5b0858cf64e"+dependencies = [+ "zeroize_derive",+]++[[package]]+name = "zeroize_derive"+version = "1.5.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "3c50655cbb0fe3fc43170059e702f1ce5e19b84cec58dc87b037a09935c2f328"+dependencies = [+ "proc-macro2",+ "quote",+ "syn 2.0.119",+]++[[package]]+name = "zerotrie"+version = "0.2.5"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "4ea269c3bd32f0a32c321907a2ae912ba6f4649bb0fc764a15627e99a7095a3f"+dependencies = [+ "displaydoc",+ "yoke",+ "zerofrom",+]++[[package]]+name = "zerovec"+version = "0.11.7"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "94b5c6b5976d66c1d703c4fd17d3f5e43c8cedaacf604961b171adc7130896d8"+dependencies = [+ "yoke",+ "zerofrom",+ "zerovec-derive",+]++[[package]]+name = "zerovec-derive"+version = "0.11.4"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "47402523226a02bfe5230160dc3ccc089aa6f6f19e7fcbb4e6f824bbb1b4aa62"+dependencies = [+ "proc-macro2",+ "quote",+ "syn 3.0.3",+]++[[package]]+name = "zmij"+version = "1.0.23"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "29666d0abbfad1e3dc4dcf6144730dd3a3ab225bbbdac83319345b1b44ccfc1b"++[[package]]+name = "zune-core"+version = "0.5.3"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "d56377fd46368984a170bc5aac5567e52ca5da874caa60bea39fcbca78fb658b"++[[package]]+name = "zune-inflate"+version = "0.2.54"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "73ab332fe2f6680068f3582b16a24f90ad7096d5d39b974d1c0aff0125116f02"+dependencies = [+ "simd-adler32",+]++[[package]]+name = "zune-jpeg"+version = "0.5.15"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "27bc9d5b815bc103f142aa054f561d9187d191692ec7c2d1e2b4737f8dbd7296"+dependencies = [+ "zune-core",+]++[[package]]+name = "zvariant"+version = "5.14.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "b5e28c25bd8bb8da5a1f3e7065d0c156b9ee9a7973adf78b0e35eaefdf3b1b5c"+dependencies = [+ "endi",+ "enumflags2",+ "serde",+ "url",+ "winnow 1.0.4",+ "zcheapstr",+ "zvariant_derive",+ "zvariant_utils",+]++[[package]]+name = "zvariant_derive"+version = "5.14.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "d496a145685283b67e232bd9e47377f6b60ad9d51e3601b23867f77c42477f96"+dependencies = [+ "proc-macro-crate",+ "proc-macro2",+ "quote",+ "syn 3.0.3",+ "zvariant_utils",+]++[[package]]+name = "zvariant_utils"+version = "4.0.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "629d80ece222cad20fe0e8741be493c4ab166acf3b85341bdc2cdbcfd8f3c2d6"+dependencies = [+ "proc-macro2",+ "quote",+ "serde",+ "syn 3.0.3",+ "winnow 1.0.4",+]diff --git a/Cargo.toml b/Cargo.tomlnew file mode 100644index 0000000..ac74117--- /dev/null+++ b/Cargo.toml@@ -0,0 +1,25 @@+[workspace]+resolver = "2"+members = ["crates/wake-core", "crates/wake"]++[workspace.package]+version = "0.1.0"+edition = "2021"+license = "MIT"++[workspace.dependencies]+anyhow = "1"+serde = { version = "1", features = ["derive"] }+serde_json = "1"+rusqlite = { version = "0.32", features = ["bundled"] }+dirs = "5"+walkdir = "2"+notify = "7"+chrono = { version = "0.4", features = ["serde"] }++[profile.dev]+# gpui 依赖树巨大,dev 依赖开优化让 UI 不卡+opt-level = 1++[profile.dev.package."*"]+opt-level = 2diff --git a/DESIGN.md b/DESIGN.mdnew file mode 100644index 0000000..2f96e52--- /dev/null+++ b/DESIGN.md@@ -0,0 +1,220 @@+---+name: Wake+description: 本地 Coding Agent 会话资料库的 macOS 桌面设计系统+---++# Wake Design System++> 代码是唯一真相:`crates/wake/src/theme.rs` 定义主题,`workbench.rs` 定义界面结构,`detail.rs` 定义对话正文。修改视觉后同步本文。++## 设计命题++Wake 的目标不是展示技术感,而是让用户在几秒内重新找到并继续一段对话。界面采用 macOS 原生资料库心智:左侧导航与全局搜索,中间扫读会话,右侧阅读内容;全文搜索作为贯穿整个资料库的命令级能力。++视觉遵循现代 macOS Liquid Glass 的层级原则:++- 先用稳定的窗口拖拽区、来源列表、工具栏、菜单和键盘路径建立结构。+- 用自适应材质色差表达层级,避免给每个区域加边框。+- 常驻界面不使用投影;阴影只留给搜索面板、菜单、确认框和通知。+- 系统蓝只表达主操作、选择和焦点;Agent 身份只由品牌图标表达(`AgentId::brand_icon(dark)`,侧栏 18px、列表/搜索/详情 15px;单色素材按深浅模式取白版或 `-light` 深墨版)。+- 详情阅读面是内容主角,应用框架主动退后。++浅色是银白和暖灰,深色是石墨和暖黑。禁止滑向黑底霓虹、终端面板或仪表盘卡片墙。++## 信息架构++窗口使用稳定的三栏选择模型,不做 iOS 式逐页推进:++1. **资料库侧栏**:全部会话、收藏、智能体和项目。+2. **会话流**:当前范围的会话,按更新时间扫读和筛选。+3. **阅读区**:当前会话的身份、主操作、元信息和完整正文。++选择状态显式且稳定。收藏、置顶、导出、显示原文件和删除都围绕当前会话发生;设置若增加,应使用独立场景,不作为侧栏目的地。++## 窗口与布局++| 项目 | 规格 |+|---|---|+| 默认窗口 | 1180 × 760,居中(14" 屏约占 78% × 77%) |+| 最小窗口 | 940 × 620 |+| 窗口顶部 | 不设全宽标题栏;交通灯与拖拽区收在侧栏顶部 |+| 资料库侧栏 | 224px 固定宽度 |+| 会话流 | 336px 固定宽度 |+| 阅读区 | 剩余宽度,`min_w(0)` |+| 阅读卡 | 阅读区内边距 `SPACE_MD` 12px,卡内 20 × 16,12px 圆角 |++窗口不绘制全宽标题栏。侧栏承接交通灯、窗口拖拽区和唯一的全文搜索入口;会话流与阅读区直接延伸到窗口顶部。侧栏、会话流、阅读区分别使用 `sidebar`、`list`、`background` 材质,以色差分区,不画竖向分隔线。++## 颜色++所有颜色必须来自 `theme.rs` 的语义 token(含 MODEL_BADGE_BG/STAR_YELLOW 两个专用常量);其他 UI 文件禁止颜色字面量。Agent 品牌资产只能来自 `AgentId::brand_icon(dark)`(内嵌 PNG 路径,定义在 `wake-core/src/models.rs`),加新 agent 时一处改完。++### 主要材质++| token | 浅色 | 深色 | 用途 |+|---|---:|---:|---|+| `title_bar` | `#EDEDEA` | `#1B1B1A` | 侧栏顶部窗口拖拽区 |+| `sidebar` | `#EDEDEA` | `#1B1B1A` | 资料库侧栏 |+| `list` | `#F7F7F5` | `#20201F` | 会话流 |+| `background` | `#F1F1EF` | `#242422` | 阅读区外层 |+| `popover` | `#FDFDFC` | `#2C2C2A` | 阅读卡、对话框、菜单 |+| `muted` | `#E8E8E5` | `#323230` | 图标底、角标、静默面 |+| `secondary` | `#E8E8E5` | `#30302E` | 次级按钮、快捷键标签 |++### 文字与交互++| token | 浅色 | 深色 | 用途 |+|---|---:|---:|---|+| `foreground` | `#1D1D1F` | `#F0EFED` | 正文与标题 |+| `muted_foreground` | `#686761` | `#A9A8A2` | 元信息与说明 |+| `primary` | `#0A84FF` | `#4C8DFF` | 主操作、焦点、激活状态 |+| `list_hover` | `#EDEDEA` | `#2A2A28` | 会话 hover |+| `list_active` | `#E3EBF6` | `#303B4C` | 当前会话 |+| `sidebar_accent` | `#DEDEDA` | `#343432` | 当前资料库范围 |+| `danger` | `#E5484D` | `#FF6B60` | 删除与错误 |+| `success` | `#2F9E63` | `#56C789` | 刷新完成 |++主色 tint 必须有语义。不得为了“更活泼”给图标、面板或 Agent 名称随意上色。++## 字体与字阶(六档硬规范)++字体使用 `.AppleSystemUIFont`,等宽内容使用 Menlo。主题基准 14px。++**所有 UI 字号必须引用 `crates/wake/src/ui.rs` 的 FONT_* 常量**——禁止裸 `px` 数字,禁止 `text_sm` 等 rem 工具类(rem 被 Root 钉在 14px,`text_sm` 实渲 12.25px 这类幽灵值是层级失控的根源)。++| 档位 | 常量 | 值 | 字重 | 用途 |+|---|---|---|---|---|+| Title | `FONT_TITLE` | 22px | Semibold | 中栏上下文大标题 |+| Heading | `FONT_HEADING` | 16px | Semibold | 详情页会话标题、空态主标题 |+| Msg user | `FONT_MSG_USER` | 13.5px | Regular | 对话区用户气泡正文 |+| Msg body | `FONT_MSG_BODY` | 13px | Regular | 对话区助手正文 |+| Msg thinking | `FONT_MSG_THINKING` | 11.5px | Italic | 对话区 thinking 摘要 |+| Body | `FONT_BODY` | 14px | Regular(列表/搜索结果标题 Medium) | 导航行、**侧栏组头**、列表标题、按钮、输入、对话框正文 |+| Caption | `FONT_CAPTION` | 12px | Regular | 列表副行、元信息、占位、空态提示、路径 chip、侧栏子级行 |+| Label | `FONT_LABEL` | 11px | Regular | 计数、快捷键徽标、状态栏、会话行与详情头元信息 |++**颜色三级制**:`foreground`(主文字)/`muted_foreground`(全部辅助文字)/`primary`(强调与激活)。不引入第四种文字灰;不在 muted 色上叠 opacity。++**间距刻度(4px 网格)**:`SPACE_XS/SM/MD/LG/XL/XXL` = 4/8/12/16/20/24,定义在 `ui.rs`。新代码引用常量或显式 `px()`;**对齐敏感处禁用 rem 间距类**——`p_2p5` 实为 8.75px、`p_3` 实为 10.5px(rem=14 折算),均不在网格上,是对齐失真的来源。存量 rem 类逐步迁移。++**侧栏中轴(x = 26.75)**:traffic lights 定位 (20,11),红灯实测直径 13.5px,中心即 **26.75**。侧栏所有行首元素的**视觉中心**压在这条竖线上,而非左缘对齐:++| 元素 | 常量 | 值 | 推导 |+|---|---|---:|---|+| 容器内边距 | `SIDEBAR_EDGE` | 10 | 行 hover/选中胶囊的左右留白 |+| 行首槽位 | `LEAD_BOX` | 18 | 最大前导元素(品牌图)尺寸,槽内**居中** |+| 行左内边距 | `LEAD_INSET` | 7.75 | 26.75 − 9(槽位半宽) − 10 |+| 组头左内边距 | `GROUP_HEAD_INSET` | 12.125 | 由首字母字形中心反推(Body 常规下 A 宽 8.25、P 宽 7.25,两者中心恰好重合) |+| 标题左内边距 | `TITLE_INSET` | 9 | 由 "Wake" 的 W 反推(Heading semibold,W 宽 14.25、左承距 0.5) |+| 分组项缩进 | `SUB_INDENT` | 12 | 分组项行首中心落在 38.75,表达从属 |++三条硬约束:++1. **中心对齐与左缘对齐是同一个自由度,只能满足一个。** 选了中心,18px 品牌图的左缘就落在 17.75,比红灯左缘还靠左 2.25——这是预期结果,不是错位。同理分组项一旦缩进就不再压轴。+2. **`GROUP_HEAD_INSET` / `TITLE_INSET` 不是间距,是从字形宽度反推的值**,组头或标题的字号、字重一改立即失效,必须重新实测字形再算(11px semibold 时需 13.25/13.0,Body 常规时变成 12.125)。+3. **2x 屏光栅化步长是 0.5px,别往小数点后继续调。** 实测 `GROUP_HEAD_INSET` 取 12.125 落位 −0.125,改成 12.25 反而跳到 +0.375——两者落进不同物理像素。全部元素落在 ±0.375 以内即为达标。++**行高两级**(侧栏纵向层级的来源):主导航 `ROW_HEIGHT` 32px + Body 14,分组展开项 `ROW_HEIGHT_SUB` 26px + Caption 12。圆角均 8px。++UI 语言英文;会话正文保持原语言。元信息分隔符固定为前后带空格的 ` · `。++## 组件规范++### 窗口顶部++不设置横跨三栏的自定义 header。系统交通灯保留在侧栏顶部,其所在拖拽区与侧栏使用完全相同的材质和颜色;会话流与阅读区不为标题栏预留另一条色带。++### 资料库侧栏++- 顶部是唯一的全文搜索入口,文案 "Search sessions",右侧显示 `⌘K`,右侧并排 refresh 按钮;Search/All Sessions/Starred 固定不随滚动。+- 搜索行必须有防溢出结构:标签文字 `flex_1 + min_w_0 + truncate`,图标与 `⌘K` 徽标显式 `flex_shrink_0`。裸文字子元素的最小宽度被内容锁死,侧栏一窄就会把 refresh 按钮挤出边界裁掉。+- **行分两级**(侧栏纵向层级的来源,不得拉平):主导航 All Sessions/Starred 32px 行高 + Body 14;分组展开项(agent/项目)26px 行高 + Caption 12 + 整行右移 `SUB_INDENT` 12px 表达从属。+- **每行必须有行首元素**,由 `RowLead` 枚举强制(`Icon` 或 `Brand` 两态,无 `None`):主导航用 Lucide 单线图标,agent 行用品牌 PNG,项目行用 `folder.svg`。槽位定宽 `LEAD_BOX` 管右侧文字起点统一,槽内居中管中轴对齐。+- 线条图标比实心品牌图视觉轻,同档里给小一号:分组项 Lucide 14 / 品牌图 18,主导航 Lucide 15。+- 行内容 = 行首元素 + 标题 + 计数;计数一律 Label 档 muted。+- 组头 "Agents"/"Projects" 用 Body 档常规字重 + muted 色(与主导航同字号同字重,仅靠颜色和"无行首图标"区分——加粗会让组头压过它统辖的行),带 13px chevron 可折叠。+- 底部状态栏"常态沉默":仅刷新中或监听不可用时出现,顶部 hairline 分隔;文案须可 truncate,窄侧栏放不下长句(故为 "Live updates off" 而非带操作建议的整句)。+- 不把项目包装成卡片,不堆叠分支、时间或重复图标。项目行不加彩色标识——同一图标重复十几次不传递信息。++### 会话流++- 顶部由 22px 上下文标题、会话总数角标和无边框系统输入组成。+- 会话行使用 Body 14 标题与 Label 11 元信息,共两行;行内 `SPACE_SM` 上下内边距 + `SPACE_XS` 两行间距,单行约 50px。+- 第二行固定为:品牌图标 15px → 项目名 badge(muted 底 4px 圆角)→ 弹性空隙 → 相对时间。+- 分支、消息数、token 和归档状态不在列表重复展示,移入详情元信息。+- 收藏和置顶允许以 11px 系统蓝图标出现在标题尾部。+- 当前行使用低饱和蓝材质,不额外描边。+- 会话流不重复提供全文搜索入口;列表内输入只筛选当前范围。++### 详情头部++层级从上到下为:++1. 品牌图标 15px、Agent 名、项目名 badge、git 分支(Label 档 muted)。+2. 22px 会话标题与操作区。+3. 项目路径、分支、消息数和 token。++“在终端继续”是唯一主按钮。收藏、置顶保留为独立图标按钮;导出、Finder 和删除进入“更多”菜单。按钮圆角固定 6px,危险操作在菜单中用分组隔开并继续走确认框。++### 阅读卡++正文位于 `popover` 材质的 12px 圆角阅读卡中,外层使用 `background`。正文 15px,可选择、可滚动,代码继续使用 tree-sitter 高亮。++对话角色标题不使用 emoji(界面语言英文):++- 用户显示 "You"。+- 助手显示具体 Agent 名称,如 "Codex" 或 "Claude Code"。+- 思考显示 "Thinking · …"。+- 工具调用显示 "Tool · 名称";失败追加 " · failed"。++emoji 不再承担界面或正文结构图标职责。++### 空态++详情空态是 360px 宽的阅读材质面:58px 图标圆面、Heading 16 主句和 Caption 12 说明,内边距 `SPACE_XXL`。++空态标题**陈述状态**,不喊口号("No session selected",而非 "Find that conversation" 这类无指代对象的祈使句);说明只留一句、给一个可执行动作并直接点名快捷键("Pick one from the list, or press ⌘K to search.")。空态不重复放搜索按钮。会话列表无结果同构("No matching sessions" + 清空筛选或更换条件),尺寸更紧凑。++### 全文搜索++- 面板宽 680px,距窗口顶部 72px。+- 大尺寸无外框搜索输入置顶。+- 未输入与无结果状态高 250px;结果列表高 460px。+- 结果行使用品牌图标、标题、项目与时间、单行片段。+- 搜索始终覆盖全部会话;页脚左侧显示“搜索范围:全部会话”,右侧显示 `↑↓`、`↩`、`esc` 键盘路径。+- 指针回调中不得同步派发新的键盘事件。需要关闭旧浮层或转移输入焦点时,应通过对应组件 API 或延迟到下一事件周期处理,避免在 AppKit `mouseUp` 路径里重入 GPUI 事件分发;打开搜索面板前必须让 Root 先保存原焦点,关闭后 `⌘K` 才能继续生效。++## 图标、形状与层次++- UI chrome 只使用内嵌 Lucide 单线 SVG,不使用 Unicode 或 emoji 图标;Agent 身份用内嵌品牌 PNG,经 `img()` 渲染并**保持原色**(不得用 `text_color` 着色,选中态也不变色)。+- 品牌 PNG 登记在 `assets.rs` 的 `brands!` 宏,文件名 = `AgentId::as_str()`,路径含 `.png`。入库前须裁掉透明边并保持正方形;带白色/彩色底的 app-icon 风格图必须先抠底,否则在侧栏材质上会露出白方块。+- 品牌图标侧栏分组项 18px、内容区(列表/搜索/详情)15px;Lucide 行内图标 13–15px;主操作与工具栏图标 14–16px;空态图标 22–26px。+- 面板圆角 12px,列表与侧栏选择 8px,按钮固定 6px,快捷键标签 5px。+- 常驻界面零投影、零渐变、无装饰性描边。菜单、命令面板、确认框和通知由组件库提供浮层阴影。+- 相邻的自定义材质只用一套 token 和圆角语言,避免每个按钮各自模拟玻璃。++## 可访问性与桌面交互++- 不依赖颜色单独传达 Agent 或状态;品牌点/品牌图标旁必须出现 Agent 名称。+- 所有主要操作必须同时有指针和键盘路径;全文搜索为 `⌘K`,全量刷新为 `⌘R`。+- 控件使用 tooltip;菜单项使用“动词 + 对象”的完整英文标签(如 "Refresh Sessions")。+- 双模式使用同一语义结构,只有 token 值变化。+- 最小窗口宽度必须保证标题、主操作和更多菜单不互相挤压。++## 实现守则++- 先改标准结构和控件,再添加自定义材质面。+- 颜色只改 `theme.rs`;图标必须登记到 `assets.rs`,路径包含后缀(`.svg` / `.png`,漏后缀 = 静默空白)。+- 所有交互元素先设置 `.id()` 再绑定点击或滚动行为。+- `Root::render_dialog_layer` 与 `Root::render_notification_layer` 必须保留。+- 对原始 Agent 数据目录继续只读;任何视觉改造不得破坏刷新、搜索跳转、恢复或删除语义。+- 术语统一:用户可见文案一律说 **Refresh** 与 **Session**,不出现 scan / rescan / rebuild / index(这些只保留在数据层内部命名中)。++## 验收++```bash+cargo build -p wake+scripts/build_and_run.sh --verify+```++视觉验收至少覆盖:空态、选中会话、详情阅读、更多菜单、`⌘K` 搜索,以及系统浅色和深色模式。diff --git a/LICENSE b/LICENSEnew file mode 100644index 0000000..77ad15a--- /dev/null+++ b/LICENSE@@ -0,0 +1,21 @@+MIT License++Copyright (c) 2026 Corey Chiu++Permission is hereby granted, free of charge, to any person obtaining a copy+of this software and associated documentation files (the "Software"), to deal+in the Software without restriction, including without limitation the rights+to use, copy, modify, merge, publish, distribute, sublicense, and/or sell+copies of the Software, and to permit persons to whom the Software is+furnished to do so, subject to the following conditions:++The above copyright notice and this permission notice shall be included in all+copies or substantial portions of the Software.++THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR+IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,+FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE+AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER+LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,+OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE+SOFTWARE.diff --git a/PRODUCT.md b/PRODUCT.mdnew file mode 100644index 0000000..a1821ae--- /dev/null+++ b/PRODUCT.md@@ -0,0 +1,54 @@+# Product++<!-- impeccable:product-schema 1 -->++## Platform++macos(原生桌面,Rust + GPUI;非 web)++## Stack++Rust + gpui 0.2 + gpui-component 0.5(用户既定,workspace: crates/wake-core 数据层 + crates/wake UI)++## Users++Corey 本人(独立开发者,主力工具 Claude Code 与 Codex,中文为主)。计划开源后:同时使用多个 coding agent 的开发者。++## Product Purpose++把散落在本机各 coding agent 私有目录里的会话统一起来:浏览、全文搜索(中文+代码子串)、一键在终端恢复、收藏/导出/删除。成功 = 想找任何一段历史对话时,几秒内定位到并能继续它。++## Positioning++唯一以"本地文件为唯一事实源"的多 agent 会话管理器:全程只读原始数据、零网络请求、索引可随时重建;竞品要么单一 agent 要么云端。++## Operating Context++日常开发中随手唤起(常驻后台索引);与终端、编辑器并排使用;深浅色环境都会出现(跟随系统)。数据规模:本机 265 会话/约 800MB JSONL,实时增量。++## Capabilities and Constraints++已实现:Claude Code + Codex adapter、FTS5 trigram 搜索(<3 码点 LIKE 降级)、详情页整篇 markdown 渲染(tree-sitter 高亮)、恢复/收藏/置顶/导出/删除(废纸篓+墓碑)、文件监听增量。+约束:对 agent 数据目录只读;绝不写 Codex 的 SQLite;不读凭证;GPUI 无 SF Symbols(图标用 lucide SVG 自备);详情页当前不支持逐消息定位(整篇 markdown 方案的已知取舍)。+已支持七家 agent:Claude Code、Codex、Copilot CLI、Cursor(CLI transcripts)、OpenCode、Kiro、Gemini CLI(2026-08-17 P1 五家落地;Cursor IDE chats 正文加密不做,Windsurf/Trae 加密、Amp/Factory/Warp 云端无本地数据)。+待做:搜索跳转定位。++## Brand Commitments++名称 Wake(2026-08-14 由 Vibex 更名;取「船迹」——agent 驶过的痕迹,兼「唤醒」恢复会话之意)。界面语言英文(2026-08-14 由中文切换,用户反馈中文 UI 词汇观感生硬)。视觉基准(用户 2026-08-14 确认):现代 macOS 原生规范,工艺对标 Things / Bear(优雅轻盈的原生感);外观跟随系统(浅+深双模式)。agent 品牌色作为功能性识别色保留(Claude 橙 #D97757、Codex 绿 #12A06B 等,见 models.rs)。++## Evidence on Hand++真实本机数据即演示数据(265 个会话)。无需虚构内容。++## Product Principles++- 本地优先,只读别家数据,一切可重建+- 找回一段对话的速度是唯一北极星+- 原生质感优先于个性表达(Operate 工具,克制)+- 中文内容(会话正文)的排版与混排质量是一等公民;UI 语言为英文+- 开源可读:代码与设计决策都要经得起外人看++## Accessibility & Inclusion++跟随系统深浅色;文字对比按 HIG;不依赖纯色区分状态(色点旁始终有文字)。diff --git a/README.md b/README.mdnew file mode 100644index 0000000..d579ce9--- /dev/null+++ b/README.md@@ -0,0 +1,79 @@+# Wake++A native macOS app that gathers every coding-agent session on your machine into one place — browse, full-text search, and resume any conversation in seconds. Built with **Rust + GPUI** (gpui 0.2 + gpui-component 0.5).++Your agent history is scattered across `~/.claude`, `~/.codex`, and five other private directories. Wake reads them all, read-only, and gives you one fast window into it. Everything stays local: no network requests, ever.++## Features++- **Unified browsing** — all sessions grouped by agent / project, live file watching for incremental updates+- **Full-text search** (⌘K) — SQLite FTS5 trigram index; handles CJK text and code substrings (like `useEffect(`) equally well; jumps straight to the matched message in the transcript+- **Transcript view** — per-message rendering with user/assistant bubbles, collapsible tool-call clusters, thinking summaries, tree-sitter code highlighting (30+ languages)+- **One-click resume** — reopens the session in Terminal/iTerm at the original project directory (`claude --resume`, `codex resume`, …)+- **Manage** — star/pin (stored in Wake's own DB, original files untouched), export to Markdown, delete (system Trash + tombstone so deleted sessions stay deleted)++## Supported agents++| Agent | Data source |+|---|---|+| Claude Code | `~/.claude/projects/**/*.jsonl` |+| Codex CLI | `~/.codex/sessions` + `state_5.sqlite` (read-only) |+| Copilot CLI | `~/.copilot/session-store.db` |+| Cursor (CLI transcripts) | `~/.cursor/projects/**/agent-transcripts` |+| OpenCode | `~/.local/share/opencode/opencode.db` |+| Kiro | `~/.kiro/sessions/cli` |+| Gemini CLI | `~/.gemini/tmp/**/chats` |++Cursor IDE chats, Windsurf, and Trae encrypt their local data; Amp, Factory, and Warp keep sessions in the cloud — none of those are supported.++## Privacy stance++- Agent data directories are opened **read-only**; Wake never writes to another tool's files or databases+- Credential files (`auth.json` and friends) are never read+- Zero network requests — Wake never constructs or calls an HTTP client (GPUI's dependency tree bundles one; Wake doesn't reach for it)+- Wake's own index lives at `~/Library/Application Support/wake/wake.db` and can be rebuilt from scratch at any time (stars/pins live in a separate table and survive rebuilds)++## Performance++On the author's machine (282 sessions, ~800 MB of JSONL): full index ~4 s, subsequent launches are instant (mtime-based incremental scan), search results in under 1 ms.++## Install++Build from source (requires a Rust toolchain):++```bash+git clone https://github.com/iAmCorey/Wake && cd Wake+scripts/make-app.sh # builds dist/Wake.app (icon + Info.plist, ad-hoc signed)+open dist/Wake.app+```++The app is ad-hoc signed, so if you download a prebuilt copy instead of building it yourself, macOS Gatekeeper will block the first launch — right-click the app and choose *Open*, or run `xattr -d com.apple.quarantine Wake.app`.++## Development++```bash+cargo run -p wake # run in dev mode+cargo run -p wake-core --bin scan # data-layer smoke test: scan and print stats+cargo run -p wake-core --bin scan -- --search "useEffect(" # search smoke test+WAKE_THEME=dark cargo run -p wake # force dark/light (defaults to system)+```++## Architecture++```+crates/+├── wake-core # pure data layer, no UI dependencies+│ ├── adapters/ # claude / codex / copilot / cursor / opencode / kiro / gemini+│ │ # (AgentAdapter trait — add an adapter, get the whole UI for free)+│ ├── scanner.rs # single-pass scan: meta + FTS in one go, mtime incremental+│ ├── watcher.rs # notify-based file watching → per-file incremental updates+│ ├── db.rs # rusqlite (WAL): sessions / messages / messages_fts / user_data / tombstones+│ └── services/ # terminal resume (AppleScript) / export / trash+└── wake # GPUI app (three-pane workbench + ⌘K palette)+```++Design notes live in [DESIGN.md](DESIGN.md), product decisions in [PRODUCT.md](PRODUCT.md).++## License++[MIT](LICENSE). Brand icons are from [lobe-icons](https://github.com/lobehub/lobe-icons) (MIT); agent names and logos belong to their respective owners.diff --git a/crates/wake-core/Cargo.toml b/crates/wake-core/Cargo.tomlnew file mode 100644index 0000000..9d66628--- /dev/null+++ b/crates/wake-core/Cargo.toml@@ -0,0 +1,19 @@+[package]+name = "wake-core"+version.workspace = true+edition.workspace = true+license.workspace = true++[dependencies]+anyhow.workspace = true+serde.workspace = true+serde_json.workspace = true+rusqlite.workspace = true+dirs.workspace = true+walkdir.workspace = true+notify.workspace = true+chrono.workspace = true++[[bin]]+name = "scan"+path = "src/bin/scan.rs"diff --git a/crates/wake-core/src/adapters/claude.rs b/crates/wake-core/src/adapters/claude.rsnew file mode 100644index 0000000..efad4c8--- /dev/null+++ b/crates/wake-core/src/adapters/claude.rs@@ -0,0 +1,577 @@+use super::parse_utils::*;+use super::{units_from_messages, AgentAdapter};+use crate::models::*;+use anyhow::Result;+use serde_json::Value;+use std::collections::HashMap;+use std::fs;+use std::io::{BufRead, BufReader};+use std::path::{Path, PathBuf};++/// Claude JSONL 已知的非消息行类型,静默跳过(不计 unknown)+const KNOWN_SKIP_TYPES: &[&str] = &[+ "queue-operation",+ "mode",+ "last-prompt",+ "permission-mode",+ "file-history-snapshot",+ "file-history-delta",+ "pr-link",+ "frame-link",+ "attachment",+ "summary",+];++pub struct ClaudeAdapter {+ root: PathBuf,+}++impl ClaudeAdapter {+ pub fn new() -> Self {+ let root = dirs::home_dir()+ .unwrap_or_default()+ .join(".claude")+ .join("projects");+ Self { root }+ }+}++struct ParseResult {+ messages: Vec<TranscriptMessage>,+ title: String,+ cwd: String,+ git_branch: Option<String>,+ model: Option<String>,+ tokens_used: i64,+ created_at: i64,+ updated_at: i64,+ unknown_lines: u32,+}++#[derive(Default)]+struct PendingAssistant {+ msg_id: Option<String>,+ text: Vec<String>,+ thinking: Vec<String>,+ tool_calls: Vec<ToolCallView>,+ timestamp: Option<i64>,+ model: Option<String>,+}++fn flush_assistant(+ pending: &mut Option<PendingAssistant>,+ messages: &mut Vec<TranscriptMessage>,+ tool_index: &mut HashMap<String, (usize, usize)>,+) {+ let Some(p) = pending.take() else { return };+ let text = p.text.join("\n\n");+ if text.is_empty() && p.thinking.is_empty() && p.tool_calls.is_empty() {+ return;+ }+ let (clipped, truncated) = clip(&text, MAX_MSG_TEXT);+ let thinking = if p.thinking.is_empty() {+ None+ } else {+ Some(clip(&p.thinking.join("\n\n"), MAX_TOOL_IO).0)+ };+ // tool_result 出现在后续 user 行,此刻登记 tool_use id → 消息内的真实位置+ let msg_idx = messages.len();+ for (ti, tc) in p.tool_calls.iter().enumerate() {+ if !tc.id.is_empty() {+ tool_index.insert(tc.id.clone(), (msg_idx, ti));+ }+ }+ messages.push(TranscriptMessage {+ seq: 0,+ role: Role::Assistant,+ kind: MessageKind::Text,+ text: clipped,+ truncated,+ tool_calls: p.tool_calls,+ thinking,+ timestamp: p.timestamp,+ model: p.model,+ });+}++fn parse_claude_jsonl(path: &Path, include_sidechain: bool) -> Result<ParseResult> {+ let file = fs::File::open(path)?;+ let reader = BufReader::with_capacity(1 << 20, file);++ let mut messages: Vec<TranscriptMessage> = Vec::new();+ // tool_use id → (消息占位:回填时按 id 在已 flush 消息与 pending 中查)+ let mut tool_index: HashMap<String, (usize, usize)> = HashMap::new();+ let mut custom_title = String::new();+ let mut fallback_title = String::new();+ let mut cwd = String::new();+ let mut git_branch: Option<String> = None;+ let mut model: Option<String> = None;+ let mut tokens_used: i64 = 0;+ let mut created_at: i64 = 0;+ let mut updated_at: i64 = 0;+ let mut unknown_lines: u32 = 0;+ let mut pending: Option<PendingAssistant> = None;++ for line in reader.lines() {+ let line = match line {+ Ok(l) => l,+ Err(_) => {+ unknown_lines += 1;+ continue;+ }+ };+ if line.trim().is_empty() {+ continue;+ }+ let row: Value = match serde_json::from_str(&line) {+ Ok(v) => v,+ Err(_) => {+ unknown_lines += 1;+ continue;+ }+ };+ let typ = row.get("type").and_then(|v| v.as_str()).unwrap_or("");++ if typ == "custom-title" {+ if let Some(t) = row.get("customTitle").and_then(|v| v.as_str()) {+ if !t.trim().is_empty() {+ custom_title = t.trim().to_string();+ }+ }+ continue;+ }+ if typ != "user" && typ != "assistant" && typ != "system" {+ if typ.is_empty() || !KNOWN_SKIP_TYPES.contains(&typ) {+ unknown_lines += 1;+ }+ continue;+ }++ // ---- 消息行公共信封 ----+ if cwd.is_empty() {+ if let Some(c) = row.get("cwd").and_then(|v| v.as_str()) {+ cwd = c.to_string();+ }+ }+ if let Some(b) = row.get("gitBranch").and_then(|v| v.as_str()) {+ if !b.is_empty() {+ git_branch = Some(b.to_string());+ }+ }+ let ts = row.get("timestamp").map(to_epoch_ms).unwrap_or(0);+ if ts > 0 {+ if created_at == 0 {+ created_at = ts;+ }+ if ts > updated_at {+ updated_at = ts;+ }+ }+ if row.get("isSidechain").and_then(|v| v.as_bool()) == Some(true) && !include_sidechain {+ continue;+ }++ let message = row.get("message");++ if typ == "system" {+ flush_assistant(&mut pending, &mut messages, &mut tool_index);+ let subtype = row.get("subtype").and_then(|v| v.as_str());+ if subtype == Some("compact_boundary") {+ messages.push(mk_msg(Role::System, MessageKind::CompactSummary, "── Context compacted ──", ts));+ } else if let Some(content) = row.get("content").and_then(|v| v.as_str()) {+ if !content.is_empty() {+ let (text, truncated) = clip(content, MAX_TOOL_IO);+ messages.push(TranscriptMessage {+ seq: 0,+ role: Role::System,+ kind: MessageKind::Meta,+ text,+ truncated,+ tool_calls: Vec::new(),+ thinking: None,+ timestamp: ts_opt(ts),+ model: None,+ });+ }+ }+ continue;+ }++ if typ == "user" {+ flush_assistant(&mut pending, &mut messages, &mut tool_index);+ let Some(message) = message else { continue };+ let content = message.get("content");+ let mut parts: Vec<String> = Vec::new();+ let mut had_tool_result = false;++ match content {+ Some(Value::String(s)) => parts.push(s.clone()),+ Some(Value::Array(blocks)) => {+ for b in blocks {+ match b.get("type").and_then(|v| v.as_str()) {+ Some("text") => {+ if let Some(t) = b.get("text").and_then(|v| v.as_str()) {+ parts.push(t.to_string());+ }+ }+ Some("tool_result") => {+ had_tool_result = true;+ let id = b.get("tool_use_id").and_then(|v| v.as_str()).unwrap_or("");+ if let Some(&(mi, ti)) = tool_index.get(id) {+ let out = stringify_tool_result(b.get("content"));+ let target = &mut messages[mi].tool_calls[ti];+ target.output = Some(clip(&out, MAX_TOOL_IO).0);+ if b.get("is_error").and_then(|v| v.as_bool()) == Some(true) {+ target.is_error = true;+ }+ }+ }+ Some("image") => parts.push("[image]".to_string()),+ _ => {}+ }+ }+ }+ _ => {}+ }++ let text = parts.join("\n\n").trim().to_string();+ if text.is_empty() {+ let _ = had_tool_result;+ continue;+ }++ let is_meta = row.get("isMeta").and_then(|v| v.as_bool()) == Some(true);+ let is_compact = row.get("isCompactSummary").and_then(|v| v.as_bool()) == Some(true);+ let kind = if is_compact {+ MessageKind::CompactSummary+ } else if is_meta || is_injected_user_content(&text) {+ MessageKind::Meta+ } else {+ MessageKind::Text+ };+ if kind == MessageKind::Text && fallback_title.is_empty() {+ fallback_title = clean_title_candidate(&text);+ }+ let (clipped, truncated) = clip(&text, MAX_MSG_TEXT);+ messages.push(TranscriptMessage {+ seq: 0,+ role: Role::User,+ kind,+ text: clipped,+ truncated,+ tool_calls: Vec::new(),+ thinking: None,+ timestamp: ts_opt(ts),+ model: None,+ });+ continue;+ }++ // ---- assistant ----+ let Some(message) = message else { continue };+ let msg_id = message.get("id").and_then(|v| v.as_str()).map(String::from);+ let need_new = match (&pending, &msg_id) {+ (None, _) => true,+ (Some(p), Some(mid)) => p.msg_id.as_deref().is_some_and(|pid| pid != mid),+ (Some(_), None) => false,+ };+ if need_new {+ flush_assistant(&mut pending, &mut messages, &mut tool_index);+ pending = Some(PendingAssistant {+ msg_id: msg_id.clone(),+ timestamp: ts_opt(ts),+ ..Default::default()+ });+ }+ let p = pending.as_mut().unwrap();+ if p.msg_id.is_none() {+ p.msg_id = msg_id;+ }+ // "<synthetic>" = 系统合成消息(中断提示等)的占位 model,不是真实模型+ if let Some(m) = message.get("model").and_then(|v| v.as_str()) {+ if !m.is_empty() && m != "<synthetic>" {+ p.model = Some(m.to_string());+ model = Some(m.to_string());+ }+ }+ if let Some(usage) = message.get("usage") {+ tokens_used += usage.get("input_tokens").and_then(|v| v.as_i64()).unwrap_or(0)+ + usage.get("output_tokens").and_then(|v| v.as_i64()).unwrap_or(0)+ + usage+ .get("cache_creation_input_tokens")+ .and_then(|v| v.as_i64())+ .unwrap_or(0);+ }+ match message.get("content") {+ Some(Value::Array(blocks)) => {+ for b in blocks {+ match b.get("type").and_then(|v| v.as_str()) {+ Some("text") => {+ if let Some(t) = b.get("text").and_then(|v| v.as_str()) {+ if !t.trim().is_empty() {+ p.text.push(t.to_string());+ }+ }+ }+ Some("thinking") => {+ if let Some(t) = b.get("thinking").and_then(|v| v.as_str()) {+ if !t.trim().is_empty() {+ p.thinking.push(t.to_string());+ }+ }+ }+ Some("tool_use") => {+ let id = b.get("id").and_then(|v| v.as_str()).unwrap_or("").to_string();+ let input = b.get("input").cloned().unwrap_or(Value::Null);+ let name = b.get("name").and_then(|v| v.as_str()).unwrap_or("tool");+ p.tool_calls.push(tool_call_view(id, name, &input, None, false));+ }+ _ => {}+ }+ }+ }+ Some(Value::String(s)) if !s.trim().is_empty() => p.text.push(s.clone()),+ _ => {}+ }+ }+ flush_assistant(&mut pending, &mut messages, &mut tool_index);+ assign_seq(&mut messages);++ Ok(ParseResult {+ title: if !custom_title.is_empty() {+ custom_title+ } else if !fallback_title.is_empty() {+ fallback_title+ } else {+ UNTITLED.to_string()+ },+ messages,+ cwd,+ git_branch,+ model,+ tokens_used,+ created_at,+ updated_at,+ unknown_lines,+ })+}++fn ts_opt(ts: i64) -> Option<i64> {+ if ts > 0 {+ Some(ts)+ } else {+ None+ }+}++fn mk_msg(role: Role, kind: MessageKind, text: &str, ts: i64) -> TranscriptMessage {+ TranscriptMessage {+ seq: 0,+ role,+ kind,+ text: text.to_string(),+ truncated: false,+ tool_calls: Vec::new(),+ thinking: None,+ timestamp: ts_opt(ts),+ model: None,+ }+}++fn stringify_tool_result(content: Option<&Value>) -> String {+ match content {+ Some(Value::String(s)) => s.clone(),+ Some(Value::Array(arr)) => arr+ .iter()+ .filter_map(|c| match c.get("type").and_then(|v| v.as_str()) {+ Some("text") => c.get("text").and_then(|v| v.as_str()).map(String::from),+ Some("image") => Some("[image]".to_string()),+ _ => None,+ })+ .collect::<Vec<_>>()+ .join("\n"),+ Some(v @ Value::Object(_)) => serde_json::to_string(v).unwrap_or_default(),+ _ => String::new(),+ }+}++fn build_meta(r: &SessionFileRef, p: &ParseResult) -> SessionMeta {+ let project_name = project_name_of(&p.cwd);+ SessionMeta {+ key: format!("claude-code:{}", r.native_id),+ id: r.native_id.clone(),+ agent: AgentId::ClaudeCode,+ title: p.title.clone(),+ project_path: p.cwd.clone(),+ project_name,+ file_path: r.file_path.clone(),+ created_at: if p.created_at > 0 { p.created_at } else { r.mtime_ms },+ updated_at: if p.updated_at > 0 { p.updated_at } else { r.mtime_ms },+ message_count: p+ .messages+ .iter()+ .filter(|m| m.kind == MessageKind::Text)+ .count() as i64,+ size_bytes: r.size,+ git_branch: p.git_branch.clone(),+ model: p.model.clone(),+ tokens_used: if p.tokens_used > 0 { Some(p.tokens_used) } else { None },+ archived: false,+ source: None,+ favorite: false,+ pinned: false,+ }+}++fn subagents_dir(r: &SessionFileRef) -> PathBuf {+ Path::new(&r.file_path)+ .parent()+ .unwrap_or(Path::new("."))+ .join(&r.native_id)+ .join("subagents")+}++fn list_sidechains(r: &SessionFileRef) -> Vec<SidechainInfo> {+ let dir = subagents_dir(r);+ let Ok(entries) = fs::read_dir(&dir) else {+ return Vec::new();+ };+ let mut out = Vec::new();+ for entry in entries.flatten() {+ let name = entry.file_name().to_string_lossy().to_string();+ if !name.ends_with(".jsonl") {+ continue;+ }+ let id = name.trim_end_matches(".jsonl").to_string();+ let mut info = SidechainInfo {+ id: id.clone(),+ agent_type: None,+ description: None,+ tool_use_id: None,+ };+ if let Ok(meta_raw) = fs::read_to_string(dir.join(format!("{id}.meta.json"))) {+ if let Ok(meta) = serde_json::from_str::<Value>(&meta_raw) {+ info.agent_type = meta.get("agentType").and_then(|v| v.as_str()).map(String::from);+ info.description = meta.get("description").and_then(|v| v.as_str()).map(String::from);+ info.tool_use_id = meta.get("toolUseId").and_then(|v| v.as_str()).map(String::from);+ }+ }+ out.push(info);+ }+ out+}++impl AgentAdapter for ClaudeAdapter {+ fn agent(&self) -> AgentId {+ AgentId::ClaudeCode+ }++ fn detect(&self) -> bool {+ self.root.is_dir()+ }++ fn list_session_files(&self) -> Result<Vec<SessionFileRef>> {+ let mut refs = Vec::new();+ let Ok(projects) = fs::read_dir(&self.root) else {+ return Ok(refs);+ };+ for project in projects.flatten() {+ let Ok(entries) = fs::read_dir(project.path()) else {+ continue;+ };+ for entry in entries.flatten() {+ let path = entry.path();+ let name = entry.file_name().to_string_lossy().to_string();+ if !name.ends_with(".jsonl") {+ continue;+ }+ let Ok(meta) = entry.metadata() else { continue };+ if !meta.is_file() || meta.len() == 0 {+ continue;+ }+ refs.push(SessionFileRef {+ agent: AgentId::ClaudeCode,+ native_id: name.trim_end_matches(".jsonl").to_string(),+ file_path: path.to_string_lossy().to_string(),+ mtime_ms: mtime_ms(&meta),+ size: meta.len() as i64,+ });+ }+ }+ Ok(refs)+ }++ fn parse_session(&self, r: &SessionFileRef) -> Result<ParsedSession> {+ let parsed = parse_claude_jsonl(Path::new(&r.file_path), false)?;+ let meta = build_meta(r, &parsed);+ let units = units_from_messages(&parsed.messages);+ Ok(ParsedSession {+ meta,+ units,+ unknown_line_count: parsed.unknown_lines,+ })+ }++ fn parse_transcript(&self, r: &SessionFileRef) -> Result<ParsedTranscript> {+ let parsed = parse_claude_jsonl(Path::new(&r.file_path), false)?;+ let sidechains = list_sidechains(r);+ let mut mainline = parsed.messages.clone();+ // 把 sidechain 挂到主线对应 Task tool call+ let by_tool_use: HashMap<&str, &SidechainInfo> = sidechains+ .iter()+ .filter_map(|s| s.tool_use_id.as_deref().map(|t| (t, s)))+ .collect();+ for m in &mut mainline {+ for tc in &mut m.tool_calls {+ if let Some(sc) = by_tool_use.get(tc.id.as_str()) {+ tc.sidechain_ref = Some(sc.id.clone());+ }+ }+ }+ Ok(ParsedTranscript {+ meta: build_meta(r, &parsed),+ mainline,+ sidechains,+ unknown_line_count: parsed.unknown_lines,+ })+ }++ fn load_sidechain(&self, r: &SessionFileRef, sidechain_id: &str) -> Result<Vec<TranscriptMessage>> {+ let file = subagents_dir(r).join(format!("{sidechain_id}.jsonl"));+ if !file.is_file() {+ return Ok(Vec::new());+ }+ let parsed = parse_claude_jsonl(&file, true)?;+ Ok(parsed.messages)+ }++ fn file_ref(&self, path: &Path) -> Option<SessionFileRef> {+ let p = path.to_string_lossy();+ // subagents 转录与 memory 边车不是主会话+ if p.contains("/subagents/") || p.contains("/memory/") {+ return None;+ }+ default_file_ref(self.agent(), path)+ }++ fn session_paths(&self, meta: &SessionMeta) -> Vec<String> {+ let mut v = vec![meta.file_path.clone()];+ // <projects>/<dir>/<id>/ 边车目录(subagents 等)随会话一并删+ if let Some(dir) = Path::new(&meta.file_path).parent() {+ let sidecar = dir.join(&meta.id);+ if sidecar.is_dir() {+ v.push(sidecar.to_string_lossy().to_string());+ }+ }+ v+ }++ fn watch_paths(&self) -> Vec<PathBuf> {+ if self.detect() {+ vec![self.root.clone()]+ } else {+ Vec::new()+ }+ }+}+diff --git a/crates/wake-core/src/adapters/codex.rs b/crates/wake-core/src/adapters/codex.rsnew file mode 100644index 0000000..c81ad2d--- /dev/null+++ b/crates/wake-core/src/adapters/codex.rs@@ -0,0 +1,559 @@+use super::parse_utils::*;+use super::sqlite_ro::open_sqlite_ro;+use super::{units_from_messages, AgentAdapter};+use crate::models::*;+use anyhow::Result;+use rusqlite::Connection;+use serde_json::Value;+use std::collections::HashMap;+use std::fs;+use std::io::{BufRead, BufReader};+use std::path::{Path, PathBuf};++pub struct CodexAdapter {+ sessions_dir: PathBuf,+ archived_dir: PathBuf,+ state_db: PathBuf,+}++impl CodexAdapter {+ pub fn new() -> Self {+ let root = dirs::home_dir().unwrap_or_default().join(".codex");+ Self {+ sessions_dir: root.join("sessions"),+ archived_dir: root.join("archived_sessions"),+ state_db: root.join("state_5.sqlite"),+ }+ }+}++#[derive(Debug)]+struct ThreadRow {+ id: String,+ rollout_path: String,+ cwd: String,+ title: String,+ name: Option<String>,+ tokens_used: Option<i64>,+ archived: bool,+ git_branch: Option<String>,+ model: Option<String>,+ source: Option<String>,+ created_at_ms: Option<i64>,+ updated_at_ms: Option<i64>,+}++/// 只读读取 Codex state DB(三级梯度统一走 sqlite_ro,绝不写、绝不 immutable=1)+fn read_threads(state_db: &Path) -> Option<Vec<ThreadRow>> {+ let query = |conn: &Connection| -> rusqlite::Result<Vec<ThreadRow>> {+ let mut stmt = conn.prepare(+ "SELECT id, rollout_path, cwd, title, name, tokens_used, archived,+ git_branch, model, source, created_at_ms, updated_at_ms+ FROM threads",+ )?;+ let rows = stmt.query_map([], |r| {+ Ok(ThreadRow {+ id: r.get(0)?,+ rollout_path: r.get(1)?,+ cwd: r.get(2)?,+ title: r.get(3)?,+ name: r.get(4)?,+ tokens_used: r.get(5)?,+ archived: r.get::<_, i64>(6)? == 1,+ git_branch: r.get(7)?,+ model: r.get(8)?,+ source: r.get(9)?,+ created_at_ms: r.get(10)?,+ updated_at_ms: r.get(11)?,+ })+ })?;+ rows.collect()+ };+ let ro = open_sqlite_ro(state_db, "codex")?;+ query(&ro.conn).ok()+}++struct CodexParse {+ messages: Vec<TranscriptMessage>,+ cwd: String,+ git_branch: Option<String>,+ model: Option<String>,+ /// rollout 首行 originator 的友好名。state DB 的 source 列会把+ /// Codex Desktop 与 IDE 扩展都归为 "vscode",originator 才分得开。+ source: Option<String>,+ tokens_used: i64,+ created_at: i64,+ updated_at: i64,+ unknown_lines: u32,+}++fn friendly_source(originator: &str) -> Option<String> {+ Some(match originator {+ "codex_cli_rs" | "codex-tui" => "CLI".to_string(),+ "codex_exec" => "exec".to_string(),+ "codex_vscode" => "IDE extension".to_string(),+ "codex_work_desktop" => "Codex Desktop".to_string(),+ "" => return None,+ other => other.to_string(), // "Codex Desktop"、"Claude Code" 等原样+ })+}++fn parse_rollout(path: &Path) -> Result<CodexParse> {+ let file = fs::File::open(path)?;+ let reader = BufReader::with_capacity(1 << 20, file);++ let mut messages: Vec<TranscriptMessage> = Vec::new();+ let mut event_fallback: Vec<TranscriptMessage> = Vec::new();+ let mut tool_index: HashMap<String, (usize, usize)> = HashMap::new();+ let mut cwd = String::new();+ let mut git_branch: Option<String> = None;+ let mut model: Option<String> = None;+ let mut source: Option<String> = None;+ let mut tokens_used: i64 = 0;+ let mut created_at: i64 = 0;+ let mut updated_at: i64 = 0;+ let mut unknown_lines: u32 = 0;+ let mut saw_session_meta = false;++ for line in reader.lines() {+ let Ok(line) = line else {+ unknown_lines += 1;+ continue;+ };+ if line.trim().is_empty() {+ continue;+ }+ let row: Value = match serde_json::from_str(&line) {+ Ok(v) => v,+ Err(_) => {+ unknown_lines += 1;+ continue;+ }+ };+ let ts = row.get("timestamp").map(to_epoch_ms).unwrap_or(0);+ if ts > 0 {+ if created_at == 0 {+ created_at = ts;+ }+ if ts > updated_at {+ updated_at = ts;+ }+ }+ let typ = row.get("type").and_then(|v| v.as_str()).unwrap_or("");+ let Some(payload) = row.get("payload") else {+ if typ != "compacted" && typ != "world_state" {+ unknown_lines += 1;+ }+ continue;+ };++ match typ {+ "session_meta" => {+ if !saw_session_meta {+ saw_session_meta = true;+ if let Some(c) = payload.get("cwd").and_then(|v| v.as_str()) {+ cwd = c.to_string();+ }+ if let Some(o) = payload.get("originator").and_then(|v| v.as_str()) {+ source = friendly_source(o);+ }+ if let Some(b) = payload+ .get("git")+ .and_then(|g| g.get("branch"))+ .and_then(|v| v.as_str())+ {+ git_branch = Some(b.to_string());+ }+ }+ }+ "turn_context" => {+ if cwd.is_empty() {+ if let Some(c) = payload.get("cwd").and_then(|v| v.as_str()) {+ cwd = c.to_string();+ }+ }+ if let Some(m) = payload.get("model").and_then(|v| v.as_str()) {+ model = Some(m.to_string());+ }+ }+ "response_item" => {+ let pt = payload.get("type").and_then(|v| v.as_str()).unwrap_or("");+ match pt {+ "message" => {+ let role = payload.get("role").and_then(|v| v.as_str()).unwrap_or("");+ let mut parts: Vec<String> = Vec::new();+ match payload.get("content") {+ Some(Value::Array(blocks)) => {+ for b in blocks {+ if matches!(+ b.get("type").and_then(|v| v.as_str()),+ Some("input_text") | Some("output_text") | Some("text")+ ) {+ if let Some(t) = b.get("text").and_then(|v| v.as_str()) {+ parts.push(t.to_string());+ }+ }+ }+ }+ Some(Value::String(s)) => parts.push(s.clone()),+ _ => {}+ }+ let text = parts.join("\n\n").trim().to_string();+ if text.is_empty() {+ continue;+ }+ match role {+ "user" => {+ messages.push(mk_msg(Role::User, user_kind(&text), &text, ts))+ }+ "assistant" => {+ messages.push(mk_msg(Role::Assistant, MessageKind::Text, &text, ts))+ }+ _ => messages.push(mk_msg(Role::System, MessageKind::Meta, &text, ts)),+ }+ }+ "reasoning" => {+ // encrypted_content 丢弃,只取明文 summary+ let mut parts: Vec<String> = Vec::new();+ if let Some(Value::Array(summary)) = payload.get("summary") {+ for s in summary {+ if let Some(t) = s.get("text").and_then(|v| v.as_str()) {+ parts.push(t.to_string());+ }+ }+ }+ if !parts.is_empty() {+ let thinking = clip(&parts.join("\n\n"), MAX_TOOL_IO).0;+ match messages.last_mut() {+ Some(last)+ if last.role == Role::Assistant+ && last.text.is_empty()+ && last.thinking.is_none() =>+ {+ last.thinking = Some(thinking);+ }+ _ => {+ let mut m = mk_msg(Role::Assistant, MessageKind::Text, "", ts);+ m.thinking = Some(thinking);+ messages.push(m);+ }+ }+ }+ }+ "function_call" | "custom_tool_call" | "local_shell_call" => {+ let call_id = payload+ .get("call_id")+ .or_else(|| payload.get("id"))+ .and_then(|v| v.as_str())+ .unwrap_or("")+ .to_string();+ let name = payload+ .get("name")+ .and_then(|v| v.as_str())+ .unwrap_or("exec")+ .to_string();+ let raw_input = payload+ .get("arguments")+ .and_then(|v| v.as_str())+ .or_else(|| payload.get("input").and_then(|v| v.as_str()))+ .map(String::from)+ .unwrap_or_else(|| {+ payload+ .get("action")+ .map(|a| serde_json::to_string(a).unwrap_or_default())+ .unwrap_or_default()+ });+ let preview_source: Value = serde_json::from_str(&raw_input)+ .unwrap_or(Value::String(raw_input.clone()));+ let call = ToolCallView {+ id: call_id.clone(),+ name,+ input_preview: make_preview(&preview_source),+ input: if raw_input.is_empty() {+ None+ } else {+ Some(clip(&raw_input, MAX_TOOL_IO).0)+ },+ output: None,+ is_error: false,+ sidechain_ref: None,+ };+ let need_host = !matches!(+ messages.last(),+ Some(m) if m.role == Role::Assistant && m.kind == MessageKind::Text+ );+ if need_host {+ messages.push(mk_msg(Role::Assistant, MessageKind::Text, "", ts));+ }+ let mi = messages.len() - 1;+ let host = &mut messages[mi];+ host.tool_calls.push(call);+ if !call_id.is_empty() {+ tool_index.insert(call_id, (mi, host.tool_calls.len() - 1));+ }+ }+ "function_call_output" | "custom_tool_call_output" => {+ let call_id = payload.get("call_id").and_then(|v| v.as_str()).unwrap_or("");+ if let Some(&(mi, ti)) = tool_index.get(call_id) {+ let out_text = match payload.get("output") {+ Some(Value::String(s)) => s.clone(),+ Some(o @ Value::Object(_)) => o+ .get("content")+ .and_then(|v| v.as_str())+ .map(String::from)+ .unwrap_or_else(|| serde_json::to_string(o).unwrap_or_default()),+ _ => String::new(),+ };+ messages[mi].tool_calls[ti].output = Some(clip(&out_text, MAX_TOOL_IO).0);+ }+ }+ _ => {}+ }+ }+ "event_msg" => {+ let pt = payload.get("type").and_then(|v| v.as_str()).unwrap_or("");+ match pt {+ "token_count" => {+ if let Some(total) = payload+ .get("info")+ .and_then(|i| i.get("total_token_usage"))+ .and_then(|u| u.get("total_tokens"))+ .and_then(|v| v.as_i64())+ {+ tokens_used = total;+ }+ }+ "user_message" => {+ if let Some(m) = payload.get("message").and_then(|v| v.as_str()) {+ if !m.trim().is_empty() {+ event_fallback.push(mk_msg(Role::User, user_kind(m), m.trim(), ts));+ }+ }+ }+ "agent_message" => {+ if let Some(m) = payload.get("message").and_then(|v| v.as_str()) {+ if !m.trim().is_empty() {+ event_fallback+ .push(mk_msg(Role::Assistant, MessageKind::Text, m.trim(), ts));+ }+ }+ }+ _ => {}+ }+ }+ "compacted" => {+ messages.push(mk_msg(Role::System, MessageKind::CompactSummary, "── Context compacted ──", ts));+ }+ "world_state" => {}+ _ => unknown_lines += 1,+ }+ }++ // response_item 完全缺席的会话退回 event_msg 流+ let has_real = messages.iter().any(|m| m.kind == MessageKind::Text && !m.text.is_empty());+ let mut final_messages = if has_real {+ messages+ } else if !event_fallback.is_empty() {+ event_fallback+ } else {+ messages+ };+ assign_seq(&mut final_messages);++ Ok(CodexParse {+ messages: final_messages,+ cwd,+ git_branch,+ model,+ source,+ tokens_used,+ created_at,+ updated_at,+ unknown_lines,+ })+}++fn mk_msg(role: Role, kind: MessageKind, text: &str, ts: i64) -> TranscriptMessage {+ let (clipped, truncated) = clip(text, MAX_MSG_TEXT);+ TranscriptMessage {+ seq: 0,+ role,+ kind,+ text: clipped,+ truncated,+ tool_calls: Vec::new(),+ thinking: None,+ timestamp: if ts > 0 { Some(ts) } else { None },+ model: None,+ }+}++/// rollout-2026-08-14T11-47-18-<uuid>.jsonl → uuid+pub(crate) fn rollout_native_id(stem: &str) -> String {+ if let Some(rest) = stem.strip_prefix("rollout-") {+ // 跳过 "YYYY-MM-DDTHH-MM-SS-" 前缀(19 字符 + 尾随 '-')+ if rest.len() > 20 && rest.as_bytes()[10] == b'T' {+ return rest[20..].to_string();+ }+ }+ stem.to_string()+}++fn build_meta(r: &SessionFileRef, p: &CodexParse, archived_dir: &Path) -> SessionMeta {+ let title = title_from_messages(&p.messages).unwrap_or_else(|| UNTITLED.to_string());+ let project_name = project_name_of(&p.cwd);+ SessionMeta {+ key: format!("codex:{}", r.native_id),+ id: r.native_id.clone(),+ agent: AgentId::Codex,+ title,+ project_path: p.cwd.clone(),+ project_name,+ file_path: r.file_path.clone(),+ created_at: if p.created_at > 0 { p.created_at } else { r.mtime_ms },+ updated_at: if p.updated_at > 0 { p.updated_at } else { r.mtime_ms },+ message_count: p+ .messages+ .iter()+ .filter(|m| m.kind == MessageKind::Text)+ .count() as i64,+ size_bytes: r.size,+ git_branch: p.git_branch.clone(),+ model: p.model.clone(),+ tokens_used: if p.tokens_used > 0 { Some(p.tokens_used) } else { None },+ archived: r.file_path.starts_with(&archived_dir.to_string_lossy().to_string()),+ source: p.source.clone(),+ favorite: false,+ pinned: false,+ }+}++impl AgentAdapter for CodexAdapter {+ fn agent(&self) -> AgentId {+ AgentId::Codex+ }++ fn detect(&self) -> bool {+ self.sessions_dir.is_dir() || self.archived_dir.is_dir()+ }++ fn list_session_files(&self) -> Result<Vec<SessionFileRef>> {+ let mut refs = list_jsonl_refs(&self.sessions_dir, AgentId::Codex, rollout_native_id);+ refs.extend(list_jsonl_refs(&self.archived_dir, AgentId::Codex, rollout_native_id));+ Ok(refs)+ }++ fn quick_meta(&self, refs: &[SessionFileRef]) -> Option<HashMap<String, SessionMeta>> {+ let rows = read_threads(&self.state_db)?;+ let by_path: HashMap<&str, &ThreadRow> =+ rows.iter().map(|r| (r.rollout_path.as_str(), r)).collect();+ let mut out = HashMap::new();+ for r in refs {+ let Some(row) = by_path.get(r.file_path.as_str()) else {+ continue;+ };+ let title = row+ .name+ .as_deref()+ .filter(|n| !n.trim().is_empty())+ .map(String::from)+ .or_else(|| {+ // Codex 自家 state DB 会把注入文本存进 title,同样要过滤+ if is_injected_user_content(&row.title) {+ return None;+ }+ let t = clean_title_candidate(&row.title);+ if t.is_empty() {+ None+ } else {+ Some(t)+ }+ })+ .unwrap_or_else(|| UNTITLED.to_string());+ let project_name = project_name_of(&row.cwd);+ out.insert(+ r.file_path.clone(),+ SessionMeta {+ key: format!("codex:{}", row.id),+ id: row.id.clone(),+ agent: AgentId::Codex,+ title,+ project_path: row.cwd.clone(),+ project_name,+ file_path: r.file_path.clone(),+ created_at: row.created_at_ms.unwrap_or(r.mtime_ms),+ updated_at: row.updated_at_ms.unwrap_or(r.mtime_ms),+ message_count: 0,+ size_bytes: r.size,+ git_branch: row.git_branch.clone(),+ model: row.model.clone(),+ tokens_used: row.tokens_used,+ archived: row.archived,+ source: row.source.clone(),+ favorite: false,+ pinned: false,+ },+ );+ }+ Some(out)+ }++ fn file_ref(&self, path: &Path) -> Option<SessionFileRef> {+ let mut r = default_file_ref(self.agent(), path)?;+ r.native_id = rollout_native_id(&r.native_id);+ Some(r)+ }++ fn merge_quick_meta(&self, mut parsed: SessionMeta, quick: &SessionMeta) -> SessionMeta {+ // state DB 的 title/name 是用户在 Codex 里手动命名,优先于首条消息推导;+ // UNTITLED 守卫防止占位符覆盖真实标题。key/id 以 state 的线程 id 为准。+ if !quick.title.is_empty() && quick.title != UNTITLED {+ parsed.title = quick.title.clone();+ }+ parsed.key = quick.key.clone();+ parsed.id = quick.id.clone();+ // source 相反:parsed 的 originator 比 state 的粗分类精确,quick 只兜底+ if parsed.source.is_none() {+ parsed.source = quick.source.clone();+ }+ if parsed.model.is_none() {+ parsed.model = quick.model.clone();+ }+ if parsed.tokens_used.is_none() {+ parsed.tokens_used = quick.tokens_used;+ }+ parsed+ }++ fn parse_session(&self, r: &SessionFileRef) -> Result<ParsedSession> {+ let parsed = parse_rollout(Path::new(&r.file_path))?;+ let meta = build_meta(r, &parsed, &self.archived_dir);+ let units = units_from_messages(&parsed.messages);+ Ok(ParsedSession {+ meta,+ units,+ unknown_line_count: parsed.unknown_lines,+ })+ }++ fn parse_transcript(&self, r: &SessionFileRef) -> Result<ParsedTranscript> {+ let parsed = parse_rollout(Path::new(&r.file_path))?;+ Ok(ParsedTranscript {+ meta: build_meta(r, &parsed, &self.archived_dir),+ mainline: parsed.messages,+ sidechains: Vec::new(),+ unknown_line_count: parsed.unknown_lines,+ })+ }++ fn watch_paths(&self) -> Vec<PathBuf> {+ let mut v = Vec::new();+ if self.sessions_dir.is_dir() {+ v.push(self.sessions_dir.clone());+ }+ if self.archived_dir.is_dir() {+ v.push(self.archived_dir.clone());+ }+ v+ }+}diff --git a/crates/wake-core/src/adapters/copilot.rs b/crates/wake-core/src/adapters/copilot.rsnew file mode 100644index 0000000..e24e6b1--- /dev/null+++ b/crates/wake-core/src/adapters/copilot.rs@@ -0,0 +1,238 @@+use super::parse_utils::*;+use super::sqlite_ro::{open_sqlite_ro, virtual_path};+use super::{units_from_messages, AgentAdapter};+use crate::models::*;+use anyhow::{anyhow, Result};+use std::collections::HashMap;+use std::path::PathBuf;+use std::sync::Mutex;++/// Copilot CLI:`~/.copilot/session-store.db` 全明文 SQLite。+/// sessions(id,cwd,branch,summary) + turns(user_message,assistant_response)。+/// 无每会话文件,SessionFileRef 用虚拟路径,mtime 取行内 updated_at、+/// size 取 turns 正文总长,二者共同构成增量扫描的 dirty 判断。+pub struct CopilotAdapter {+ db: PathBuf,+ /// rows() 的全表聚合较贵,按 db mtime 缓存一轮扫描内的重复调用+ /// (list_session_files 与 quick_meta 各调一次)+ rows_cache: Mutex<Option<(i64, Vec<CopilotRow>)>>,+}++impl CopilotAdapter {+ pub fn new() -> Self {+ Self {+ db: dirs::home_dir()+ .unwrap_or_default()+ .join(".copilot")+ .join("session-store.db"),+ rows_cache: Mutex::new(None),+ }+ }++ fn db_mtime(&self) -> i64 {+ std::fs::metadata(&self.db).map(|m| mtime_ms(&m)).unwrap_or(0)+ }++ fn rows(&self) -> Option<Vec<CopilotRow>> {+ let mtime = self.db_mtime();+ {+ let cache = self.rows_cache.lock().unwrap();+ if let Some((t, rows)) = cache.as_ref() {+ if *t == mtime {+ return Some(rows.clone());+ }+ }+ }+ let ro = open_sqlite_ro(&self.db, "copilot")?;+ let mut stmt = ro+ .conn+ .prepare(+ "SELECT s.id, s.cwd, s.branch, s.summary, s.created_at, s.updated_at,+ COALESCE(SUM(LENGTH(COALESCE(t.user_message,'')) + LENGTH(COALESCE(t.assistant_response,''))), 0),+ COUNT(t.id)+ FROM sessions s LEFT JOIN turns t ON t.session_id = s.id+ GROUP BY s.id",+ )+ .ok()?;+ let rows = stmt+ .query_map([], |r| {+ Ok(CopilotRow {+ id: r.get(0)?,+ cwd: r.get::<_, Option<String>>(1)?.unwrap_or_default(),+ branch: r.get(2)?,+ summary: r.get::<_, Option<String>>(3)?.unwrap_or_default(),+ created_ms: sqlite_dt_ms(&r.get::<_, Option<String>>(4)?.unwrap_or_default()),+ updated_ms: sqlite_dt_ms(&r.get::<_, Option<String>>(5)?.unwrap_or_default()),+ content_len: r.get(6)?,+ turn_count: r.get(7)?,+ })+ })+ .ok()?+ .collect::<rusqlite::Result<Vec<_>>>()+ .ok()?;+ *self.rows_cache.lock().unwrap() = Some((mtime, rows.clone()));+ Some(rows)+ }++ fn build_meta(&self, r: &SessionFileRef, row: &CopilotRow, message_count: i64) -> SessionMeta {+ let title = clean_title_candidate(&row.summary);+ SessionMeta {+ key: format!("copilot:{}", row.id),+ id: row.id.clone(),+ agent: AgentId::Copilot,+ title: if title.is_empty() { UNTITLED.to_string() } else { title },+ project_path: row.cwd.clone(),+ project_name: project_name_of(&row.cwd),+ file_path: r.file_path.clone(),+ created_at: if row.created_ms > 0 { row.created_ms } else { r.mtime_ms },+ updated_at: if row.updated_ms > 0 { row.updated_ms } else { r.mtime_ms },+ message_count,+ size_bytes: r.size,+ git_branch: row.branch.clone().filter(|b| !b.is_empty()),+ model: None,+ tokens_used: None,+ archived: false,+ source: None,+ favorite: false,+ pinned: false,+ }+ }++ /// 单会话解析:一次连接,会话行与 turns 都只查本会话(不做全表聚合)+ fn parse(&self, r: &SessionFileRef) -> Result<(SessionMeta, Vec<TranscriptMessage>)> {+ let ro = open_sqlite_ro(&self.db, "copilot")+ .ok_or_else(|| anyhow!("cannot open copilot store"))?;+ let row = ro+ .conn+ .query_row(+ "SELECT s.id, s.cwd, s.branch, s.summary, s.created_at, s.updated_at,+ COALESCE(SUM(LENGTH(COALESCE(t.user_message,'')) + LENGTH(COALESCE(t.assistant_response,''))), 0),+ COUNT(t.id)+ FROM sessions s LEFT JOIN turns t ON t.session_id = s.id+ WHERE s.id = ?1 GROUP BY s.id",+ [&r.native_id],+ |x| {+ Ok(CopilotRow {+ id: x.get(0)?,+ cwd: x.get::<_, Option<String>>(1)?.unwrap_or_default(),+ branch: x.get(2)?,+ summary: x.get::<_, Option<String>>(3)?.unwrap_or_default(),+ created_ms: sqlite_dt_ms(&x.get::<_, Option<String>>(4)?.unwrap_or_default()),+ updated_ms: sqlite_dt_ms(&x.get::<_, Option<String>>(5)?.unwrap_or_default()),+ content_len: x.get(6)?,+ turn_count: x.get(7)?,+ })+ },+ )+ .map_err(|_| anyhow!("copilot session {} not in store", r.native_id))?;++ let mut stmt = ro.conn.prepare(+ "SELECT user_message, assistant_response, timestamp+ FROM turns WHERE session_id = ?1 ORDER BY turn_index",+ )?;+ let turns = stmt.query_map([&r.native_id], |t| {+ Ok((+ t.get::<_, Option<String>>(0)?,+ t.get::<_, Option<String>>(1)?,+ t.get::<_, Option<String>>(2)?,+ ))+ })?;++ let mut messages: Vec<TranscriptMessage> = Vec::new();+ for turn in turns.flatten() {+ let ts = sqlite_dt_ms(&turn.2.unwrap_or_default());+ if let Some(u) = turn.0.filter(|s| !s.trim().is_empty()) {+ messages.push(text_msg(Role::User, &u, ts));+ }+ if let Some(a) = turn.1.filter(|s| !s.trim().is_empty()) {+ messages.push(text_msg(Role::Assistant, &a, ts));+ }+ }+ assign_seq(&mut messages);+ let count = messages.iter().filter(|m| m.kind == MessageKind::Text).count() as i64;+ let mut meta = self.build_meta(r, &row, count);+ // summary 缺失时回退首条用户消息+ if meta.title == UNTITLED {+ if let Some(t) = title_from_messages(&messages) {+ meta.title = t;+ }+ }+ Ok((meta, messages))+ }+}++#[derive(Clone)]+struct CopilotRow {+ id: String,+ cwd: String,+ branch: Option<String>,+ summary: String,+ created_ms: i64,+ updated_ms: i64,+ content_len: i64,+ turn_count: i64,+}++impl AgentAdapter for CopilotAdapter {+ fn agent(&self) -> AgentId {+ AgentId::Copilot+ }++ fn detect(&self) -> bool {+ self.db.is_file()+ }++ fn list_session_files(&self) -> Result<Vec<SessionFileRef>> {+ let Some(rows) = self.rows() else {+ return Ok(Vec::new());+ };+ Ok(rows+ .into_iter()+ .filter(|row| row.turn_count > 0)+ .map(|row| SessionFileRef {+ agent: AgentId::Copilot,+ native_id: row.id.clone(),+ file_path: virtual_path(&self.db, &row.id),+ mtime_ms: row.updated_ms,+ size: row.content_len,+ })+ .collect())+ }++ fn quick_meta(&self, refs: &[SessionFileRef]) -> Option<HashMap<String, SessionMeta>> {+ let rows = self.rows()?;+ let by_id: HashMap<&str, &CopilotRow> = rows.iter().map(|r| (r.id.as_str(), r)).collect();+ let mut out = HashMap::new();+ for r in refs {+ if let Some(row) = by_id.get(r.native_id.as_str()) {+ out.insert(r.file_path.clone(), self.build_meta(r, row, 0));+ }+ }+ Some(out)+ }++ fn parse_session(&self, r: &SessionFileRef) -> Result<ParsedSession> {+ let (meta, messages) = self.parse(r)?;+ let units = units_from_messages(&messages);+ Ok(ParsedSession {+ meta,+ units,+ unknown_line_count: 0,+ })+ }++ fn parse_transcript(&self, r: &SessionFileRef) -> Result<ParsedTranscript> {+ let (meta, messages) = self.parse(r)?;+ Ok(ParsedTranscript {+ meta,+ mainline: messages,+ sidechains: Vec::new(),+ unknown_line_count: 0,+ })+ }++ fn watch_paths(&self) -> Vec<PathBuf> {+ // SQLite 库变更 watcher 不追踪(只认 .jsonl),依赖手动/启动时刷新+ Vec::new()+ }+}diff --git a/crates/wake-core/src/adapters/cursor.rs b/crates/wake-core/src/adapters/cursor.rsnew file mode 100644index 0000000..242ef80--- /dev/null+++ b/crates/wake-core/src/adapters/cursor.rs@@ -0,0 +1,382 @@+use super::parse_utils::*;+use super::{units_from_messages, AgentAdapter};+use crate::models::*;+use anyhow::Result;+use serde_json::Value;+use std::fs;+use std::io::{BufRead, BufReader};+use std::path::{Path, PathBuf};++/// Cursor CLI:`~/.cursor/projects/<slug>/agent-transcripts/<uuid>/<uuid>.jsonl` 明文。+/// 行结构 {role, message:{content:[{type:text|tool_use}]}} + {type:"turn_ended"}。+/// user 正文包在 <timestamp>/<user_query> 壳里;transcript 不含 cwd,+/// 从有损 slug 目录名 DFS 反推真实路径。IDE chats(store.db 加密)不做。+pub struct CursorAdapter {+ root: PathBuf,+}++impl CursorAdapter {+ pub fn new() -> Self {+ Self {+ root: dirs::home_dir()+ .unwrap_or_default()+ .join(".cursor")+ .join("projects"),+ }+ }+}++/// "Users-corey-Github-image-translate" → "/Users/corey/Github/image-translate"。+/// '-' 既可能是路径分隔也可能是目录名字符,按磁盘真实存在的目录 DFS(优先短段);+/// 项目目录已删时回退直译。+fn decode_slug(slug: &str) -> String {+ let parts: Vec<&str> = slug.split('-').collect();+ fn dfs(base: PathBuf, parts: &[&str]) -> Option<PathBuf> {+ if parts.is_empty() {+ return Some(base);+ }+ let mut seg = String::new();+ for i in 0..parts.len() {+ if i > 0 {+ seg.push('-');+ }+ seg.push_str(parts[i]);+ let cand = base.join(&seg);+ if cand.is_dir() {+ if let Some(hit) = dfs(cand, &parts[i + 1..]) {+ return Some(hit);+ }+ }+ }+ None+ }+ dfs(PathBuf::from("/"), &parts)+ .map(|p| p.to_string_lossy().to_string())+ .unwrap_or_else(|| format!("/{}", slug.replace('-', "/")))+}++/// "Thursday, Jul 23, 2026, 4:00 PM (UTC+8)" → epoch ms,解析失败 = 0+fn cursor_ts_ms(s: &str) -> i64 {+ (|| -> Option<i64> {+ let (dt_part, tz_part) = s.rsplit_once(" (")?;+ let naive =+ chrono::NaiveDateTime::parse_from_str(dt_part.trim(), "%A, %b %d, %Y, %I:%M %p").ok()?;+ let off = tz_part.trim_end_matches(')').strip_prefix("UTC")?;+ let (sign, rest) = match off.as_bytes().first()? {+ b'+' => (1i32, &off[1..]),+ b'-' => (-1i32, &off[1..]),+ _ => (1i32, off),+ };+ let secs = match rest.split_once(':') {+ Some((h, m)) => h.parse::<i32>().ok()? * 3600 + m.parse::<i32>().ok()? * 60,+ None => rest.parse::<i32>().ok()? * 3600,+ };+ let offset = chrono::FixedOffset::east_opt(sign * secs)?;+ use chrono::TimeZone;+ Some(offset.from_local_datetime(&naive).single()?.timestamp_millis())+ })()+ .unwrap_or(0)+}++struct CursorParse {+ messages: Vec<TranscriptMessage>,+ created_at: i64,+ updated_at: i64,+ unknown_lines: u32,+}++#[derive(Default)]+struct PendingAssistant {+ text: Vec<String>,+ tool_calls: Vec<ToolCallView>,+ timestamp: Option<i64>,+}++fn flush_assistant(pending: &mut Option<PendingAssistant>, messages: &mut Vec<TranscriptMessage>) {+ let Some(p) = pending.take() else { return };+ let text = p.text.join("\n\n");+ if text.is_empty() && p.tool_calls.is_empty() {+ return;+ }+ let (clipped, truncated) = clip(&text, MAX_MSG_TEXT);+ messages.push(TranscriptMessage {+ seq: 0,+ role: Role::Assistant,+ kind: MessageKind::Text,+ text: clipped,+ truncated,+ tool_calls: p.tool_calls,+ thinking: None,+ timestamp: p.timestamp,+ model: None,+ });+}++fn parse_cursor_jsonl(path: &Path) -> Result<CursorParse> {+ let file = fs::File::open(path)?;+ let reader = BufReader::with_capacity(1 << 20, file);++ let mut messages: Vec<TranscriptMessage> = Vec::new();+ let mut pending: Option<PendingAssistant> = None;+ let mut created_at = 0i64;+ let mut updated_at = 0i64;+ let mut unknown_lines = 0u32;++ for line in reader.lines() {+ let Ok(line) = line else {+ unknown_lines += 1;+ continue;+ };+ if line.trim().is_empty() {+ continue;+ }+ let row: Value = match serde_json::from_str(&line) {+ Ok(v) => v,+ Err(_) => {+ unknown_lines += 1;+ continue;+ }+ };+ let Some(role) = row.get("role").and_then(|v| v.as_str()) else {+ match row.get("type").and_then(|v| v.as_str()) {+ Some("turn_ended") => flush_assistant(&mut pending, &mut messages),+ _ => unknown_lines += 1,+ }+ continue;+ };+ let blocks = row+ .get("message")+ .and_then(|m| m.get("content"))+ .and_then(|c| c.as_array())+ .cloned()+ .unwrap_or_default();++ match role {+ "user" => {+ flush_assistant(&mut pending, &mut messages);+ let mut parts: Vec<String> = Vec::new();+ let mut ts = 0i64;+ for b in &blocks {+ if b.get("type").and_then(|v| v.as_str()) != Some("text") {+ continue;+ }+ let Some(raw) = b.get("text").and_then(|v| v.as_str()) else {+ continue;+ };+ if let Some(t) = extract_tag(raw, "timestamp") {+ let parsed = cursor_ts_ms(&t);+ if parsed > 0 {+ ts = parsed;+ }+ }+ // 真实输入在 <user_query> 壳内;没有壳的行(注入上下文等)原样保留+ let body = extract_tag(raw, "user_query").unwrap_or_else(|| raw.to_string());+ if !body.trim().is_empty() {+ parts.push(body.trim().to_string());+ }+ }+ let text = parts.join("\n\n");+ if text.trim().is_empty() {+ continue;+ }+ if ts > 0 {+ if created_at == 0 {+ created_at = ts;+ }+ updated_at = updated_at.max(ts);+ }+ messages.push(text_msg(Role::User, &text, ts));+ }+ "assistant" => {+ // Cursor 逐块落行且无消息 id,连续 assistant 行并成一条,turn_ended/user 处 flush+ let p = pending.get_or_insert_with(PendingAssistant::default);+ for b in &blocks {+ match b.get("type").and_then(|v| v.as_str()) {+ Some("text") => {+ if let Some(t) = b.get("text").and_then(|v| v.as_str()) {+ if !t.trim().is_empty() {+ p.text.push(t.to_string());+ }+ }+ }+ Some("tool_use") => {+ let input = b.get("input").cloned().unwrap_or(Value::Null);+ let name = b.get("name").and_then(|v| v.as_str()).unwrap_or("tool");+ // transcript 不落盘工具结果,output 恒 None+ p.tool_calls.push(tool_call_view(String::new(), name, &input, None, false));+ }+ _ => {}+ }+ }+ }+ _ => unknown_lines += 1,+ }+ }+ flush_assistant(&mut pending, &mut messages);+ assign_seq(&mut messages);+ Ok(CursorParse {+ messages,+ created_at,+ updated_at,+ unknown_lines,+ })+}++fn subagents_dir(r: &SessionFileRef) -> PathBuf {+ Path::new(&r.file_path)+ .parent()+ .unwrap_or(Path::new("."))+ .join("subagents")+}++fn build_meta(r: &SessionFileRef, p: &CursorParse) -> SessionMeta {+ // …/projects/<slug>/agent-transcripts/<uuid>/<uuid>.jsonl → slug+ let cwd = Path::new(&r.file_path)+ .ancestors()+ .nth(3)+ .and_then(|d| d.file_name())+ .map(|s| decode_slug(&s.to_string_lossy()))+ .unwrap_or_default();+ let title = title_from_messages(&p.messages).unwrap_or_else(|| UNTITLED.to_string());+ SessionMeta {+ key: format!("cursor:{}", r.native_id),+ id: r.native_id.clone(),+ agent: AgentId::Cursor,+ title,+ project_path: cwd.clone(),+ project_name: project_name_of(&cwd),+ file_path: r.file_path.clone(),+ created_at: if p.created_at > 0 { p.created_at } else { r.mtime_ms },+ updated_at: if p.updated_at > 0 { p.updated_at } else { r.mtime_ms },+ message_count: p+ .messages+ .iter()+ .filter(|m| m.kind == MessageKind::Text)+ .count() as i64,+ size_bytes: r.size,+ git_branch: None,+ model: None,+ tokens_used: None,+ archived: false,+ source: None,+ favorite: false,+ pinned: false,+ }+}++impl AgentAdapter for CursorAdapter {+ fn agent(&self) -> AgentId {+ AgentId::Cursor+ }++ fn detect(&self) -> bool {+ self.root.is_dir()+ }++ fn list_session_files(&self) -> Result<Vec<SessionFileRef>> {+ let mut refs = Vec::new();+ let Ok(projects) = fs::read_dir(&self.root) else {+ return Ok(refs);+ };+ for project in projects.flatten() {+ let transcripts = project.path().join("agent-transcripts");+ let Ok(sessions) = fs::read_dir(&transcripts) else {+ continue;+ };+ for session in sessions.flatten() {+ let Ok(entries) = fs::read_dir(session.path()) else {+ continue;+ };+ for entry in entries.flatten() {+ let name = entry.file_name().to_string_lossy().to_string();+ if !name.ends_with(".jsonl") {+ continue;+ }+ let Ok(meta) = entry.metadata() else { continue };+ if !meta.is_file() || meta.len() == 0 {+ continue;+ }+ refs.push(SessionFileRef {+ agent: AgentId::Cursor,+ native_id: name.trim_end_matches(".jsonl").to_string(),+ file_path: entry.path().to_string_lossy().to_string(),+ mtime_ms: mtime_ms(&meta),+ size: meta.len() as i64,+ });+ }+ }+ }+ Ok(refs)+ }++ fn file_ref(&self, path: &Path) -> Option<SessionFileRef> {+ // 只认 transcript 主文件;subagents 转录不是独立会话+ let p = path.to_string_lossy();+ if !p.contains("/agent-transcripts/") || p.contains("/subagents/") {+ return None;+ }+ default_file_ref(self.agent(), path)+ }++ fn session_paths(&self, meta: &SessionMeta) -> Vec<String> {+ // 会话是 <uuid>/ 整个目录(含 subagents/),删除时整目录进废纸篓+ Path::new(&meta.file_path)+ .parent()+ .map(|d| vec![d.to_string_lossy().to_string()])+ .unwrap_or_else(|| vec![meta.file_path.clone()])+ }++ fn parse_session(&self, r: &SessionFileRef) -> Result<ParsedSession> {+ let parsed = parse_cursor_jsonl(Path::new(&r.file_path))?;+ let meta = build_meta(r, &parsed);+ let units = units_from_messages(&parsed.messages);+ Ok(ParsedSession {+ meta,+ units,+ unknown_line_count: parsed.unknown_lines,+ })+ }++ fn parse_transcript(&self, r: &SessionFileRef) -> Result<ParsedTranscript> {+ let parsed = parse_cursor_jsonl(Path::new(&r.file_path))?;+ // subagents/ 子目录与 Claude 同构,但无 meta 边车、主线 Task 调用无 id,+ // 挂不上具体 tool_use——仅列出供导出携带+ let mut sidechains = Vec::new();+ let dir = subagents_dir(r);+ if let Ok(entries) = fs::read_dir(&dir) {+ for entry in entries.flatten() {+ let name = entry.file_name().to_string_lossy().to_string();+ if let Some(id) = name.strip_suffix(".jsonl") {+ sidechains.push(SidechainInfo {+ id: id.to_string(),+ agent_type: None,+ description: None,+ tool_use_id: None,+ });+ }+ }+ }+ Ok(ParsedTranscript {+ meta: build_meta(r, &parsed),+ mainline: parsed.messages,+ sidechains,+ unknown_line_count: parsed.unknown_lines,+ })+ }++ fn load_sidechain(&self, r: &SessionFileRef, sidechain_id: &str) -> Result<Vec<TranscriptMessage>> {+ let file = subagents_dir(r).join(format!("{sidechain_id}.jsonl"));+ if !file.is_file() {+ return Ok(Vec::new());+ }+ Ok(parse_cursor_jsonl(&file)?.messages)+ }++ fn watch_paths(&self) -> Vec<PathBuf> {+ if self.detect() {+ vec![self.root.clone()]+ } else {+ Vec::new()+ }+ }+}diff --git a/crates/wake-core/src/adapters/gemini.rs b/crates/wake-core/src/adapters/gemini.rsnew file mode 100644index 0000000..6119fa4--- /dev/null+++ b/crates/wake-core/src/adapters/gemini.rs@@ -0,0 +1,282 @@+use super::parse_utils::*;+use super::{units_from_messages, AgentAdapter};+use crate::models::*;+use anyhow::Result;+use serde_json::Value;+use std::collections::HashMap;+use std::fs;+use std::io::{BufRead, BufReader};+use std::path::{Path, PathBuf};++/// Gemini CLI:`~/.gemini/tmp/<slug>/chats/session-*.jsonl`。+/// 首行 header({sessionId,startTime,lastUpdated}),后续 {$set:{messages:[…]}}+/// **覆盖式**快照——重放到最后一条 $set 为准,不能按行追加。+/// cwd 靠 `~/.gemini/projects.json` 的 路径→slug 映射反查;无原生标题。+pub struct GeminiAdapter {+ root: PathBuf,+ projects_json: PathBuf,+ /// slug → 项目路径映射,按 projects.json mtime 缓存(全量刷新时逐会话调用)+ slug_cache: std::sync::Mutex<Option<(i64, HashMap<String, String>)>>,+}++impl GeminiAdapter {+ pub fn new() -> Self {+ let home = dirs::home_dir().unwrap_or_default().join(".gemini");+ Self {+ root: home.join("tmp"),+ projects_json: home.join("projects.json"),+ slug_cache: std::sync::Mutex::new(None),+ }+ }++ /// slug → 项目真实路径+ fn slug_map(&self) -> HashMap<String, String> {+ let mtime = fs::metadata(&self.projects_json).map(|m| mtime_ms(&m)).unwrap_or(0);+ {+ let cache = self.slug_cache.lock().unwrap();+ if let Some((t, map)) = cache.as_ref() {+ if *t == mtime {+ return map.clone();+ }+ }+ }+ let mut out = HashMap::new();+ if let Ok(raw) = fs::read_to_string(&self.projects_json) {+ if let Ok(v) = serde_json::from_str::<Value>(&raw) {+ if let Some(Value::Object(map)) = v.get("projects") {+ for (path, slug) in map {+ if let Some(s) = slug.as_str() {+ out.insert(s.to_string(), path.clone());+ }+ }+ }+ }+ }+ *self.slug_cache.lock().unwrap() = Some((mtime, out.clone()));+ out+ }+}++struct GeminiParse {+ session_id: Option<String>,+ messages: Vec<TranscriptMessage>,+ created_at: i64,+ updated_at: i64,+ unknown_lines: u32,+}++fn parse_gemini_jsonl(path: &Path) -> Result<GeminiParse> {+ let file = fs::File::open(path)?;+ let reader = BufReader::with_capacity(1 << 20, file);++ let mut session_id: Option<String> = None;+ let mut created_at = 0i64;+ let mut updated_at = 0i64;+ let mut unknown = 0u32;+ let mut last_set: Option<Value> = None;++ for line in reader.lines() {+ let Ok(line) = line else {+ unknown += 1;+ continue;+ };+ if line.trim().is_empty() {+ continue;+ }+ let Ok(row) = serde_json::from_str::<Value>(&line) else {+ unknown += 1;+ continue;+ };+ if let Some(set) = row.get("$set") {+ if set.get("messages").and_then(|m| m.as_array()).is_some() {+ last_set = Some(set.clone());+ }+ continue;+ }+ if let Some(id) = row.get("sessionId").and_then(|v| v.as_str()) {+ session_id = Some(id.to_string());+ if let Some(t) = row.get("startTime").and_then(|v| v.as_str()) {+ created_at = iso_ms(t);+ }+ if let Some(t) = row.get("lastUpdated").and_then(|v| v.as_str()) {+ updated_at = iso_ms(t);+ }+ continue;+ }+ unknown += 1;+ }++ let mut messages: Vec<TranscriptMessage> = Vec::new();+ if let Some(set) = last_set {+ if let Some(arr) = set.get("messages").and_then(|m| m.as_array()) {+ for m in arr {+ let role = match m.get("type").and_then(|v| v.as_str()) {+ Some("user") => Role::User,+ Some(_) => Role::Assistant,+ None => {+ unknown += 1;+ continue;+ }+ };+ let mut parts: Vec<String> = Vec::new();+ if let Some(Value::Array(blocks)) = m.get("content") {+ for b in blocks {+ if let Some(t) = b.get("text").and_then(|v| v.as_str()) {+ if !t.trim().is_empty() {+ parts.push(t.trim().to_string());+ }+ }+ }+ }+ let text = parts.join("\n\n");+ if text.is_empty() {+ continue;+ }+ let ts = m+ .get("timestamp")+ .and_then(|v| v.as_str())+ .map(iso_ms)+ .unwrap_or(0);+ if ts > 0 {+ if created_at == 0 {+ created_at = ts;+ }+ updated_at = updated_at.max(ts);+ }+ messages.push(text_msg(role, &text, ts));+ }+ }+ }+ assign_seq(&mut messages);+ Ok(GeminiParse {+ session_id,+ messages,+ created_at,+ updated_at,+ unknown_lines: unknown,+ })+}++fn build_meta(r: &SessionFileRef, p: &GeminiParse, cwd: &str) -> SessionMeta {+ let native = p.session_id.clone().unwrap_or_else(|| r.native_id.clone());+ let title = title_from_messages(&p.messages).unwrap_or_else(|| UNTITLED.to_string());+ SessionMeta {+ key: format!("gemini:{native}"),+ id: native,+ agent: AgentId::Gemini,+ title,+ project_path: cwd.to_string(),+ project_name: project_name_of(cwd),+ file_path: r.file_path.clone(),+ created_at: if p.created_at > 0 { p.created_at } else { r.mtime_ms },+ updated_at: if p.updated_at > 0 { p.updated_at } else { r.mtime_ms },+ message_count: p+ .messages+ .iter()+ .filter(|m| m.kind == MessageKind::Text)+ .count() as i64,+ size_bytes: r.size,+ git_branch: None,+ model: None,+ tokens_used: None,+ archived: false,+ source: None,+ favorite: false,+ pinned: false,+ }+}++/// …/tmp/<slug>/chats/session-*.jsonl → slug+fn slug_of(path: &Path) -> Option<String> {+ path.ancestors()+ .nth(2)+ .and_then(|d| d.file_name())+ .map(|s| s.to_string_lossy().to_string())+}++impl GeminiAdapter {+ fn cwd_for(&self, r: &SessionFileRef) -> String {+ slug_of(Path::new(&r.file_path))+ .and_then(|slug| self.slug_map().get(&slug).cloned())+ .unwrap_or_default()+ }+}++impl AgentAdapter for GeminiAdapter {+ fn agent(&self) -> AgentId {+ AgentId::Gemini+ }++ fn detect(&self) -> bool {+ self.root.is_dir()+ }++ fn list_session_files(&self) -> Result<Vec<SessionFileRef>> {+ let mut refs = Vec::new();+ let Ok(slugs) = fs::read_dir(&self.root) else {+ return Ok(refs);+ };+ for slug in slugs.flatten() {+ let chats = slug.path().join("chats");+ let Ok(entries) = fs::read_dir(&chats) else {+ continue;+ };+ for entry in entries.flatten() {+ let name = entry.file_name().to_string_lossy().to_string();+ if !name.starts_with("session-") || !name.ends_with(".jsonl") {+ continue;+ }+ let Ok(meta) = entry.metadata() else { continue };+ if !meta.is_file() || meta.len() == 0 {+ continue;+ }+ refs.push(SessionFileRef {+ agent: AgentId::Gemini,+ native_id: name.trim_end_matches(".jsonl").to_string(),+ file_path: entry.path().to_string_lossy().to_string(),+ mtime_ms: mtime_ms(&meta),+ size: meta.len() as i64,+ });+ }+ }+ Ok(refs)+ }++ fn file_ref(&self, path: &Path) -> Option<SessionFileRef> {+ // 只认 chats/session-*.jsonl(tmp 下其他 jsonl 不是会话)+ let name = path.file_name()?.to_string_lossy().to_string();+ if !name.starts_with("session-") || !path.to_string_lossy().contains("/chats/") {+ return None;+ }+ default_file_ref(self.agent(), path)+ }++ fn parse_session(&self, r: &SessionFileRef) -> Result<ParsedSession> {+ let parsed = parse_gemini_jsonl(Path::new(&r.file_path))?;+ let meta = build_meta(r, &parsed, &self.cwd_for(r));+ let units = units_from_messages(&parsed.messages);+ Ok(ParsedSession {+ meta,+ units,+ unknown_line_count: parsed.unknown_lines,+ })+ }++ fn parse_transcript(&self, r: &SessionFileRef) -> Result<ParsedTranscript> {+ let parsed = parse_gemini_jsonl(Path::new(&r.file_path))?;+ Ok(ParsedTranscript {+ meta: build_meta(r, &parsed, &self.cwd_for(r)),+ mainline: parsed.messages,+ sidechains: Vec::new(),+ unknown_line_count: parsed.unknown_lines,+ })+ }++ fn watch_paths(&self) -> Vec<PathBuf> {+ if self.detect() {+ vec![self.root.clone()]+ } else {+ Vec::new()+ }+ }+}diff --git a/crates/wake-core/src/adapters/kiro.rs b/crates/wake-core/src/adapters/kiro.rsnew file mode 100644index 0000000..184f494--- /dev/null+++ b/crates/wake-core/src/adapters/kiro.rs@@ -0,0 +1,194 @@+use super::parse_utils::*;+use super::{units_from_messages, AgentAdapter};+use crate::models::*;+use anyhow::Result;+use serde_json::Value;+use std::fs;+use std::io::{BufRead, BufReader};+use std::path::{Path, PathBuf};++/// Kiro CLI:`~/.kiro/sessions/cli/<uuid>.{jsonl,json,history}` 三件套。+/// .json 边车含 cwd/title/时间;.jsonl 行 {kind:Prompt|AssistantMessage,+/// data:{content:[{kind:text,data}],meta:{timestamp:unix秒}}};.history 忽略。+pub struct KiroAdapter {+ root: PathBuf,+}++impl KiroAdapter {+ pub fn new() -> Self {+ Self {+ root: dirs::home_dir()+ .unwrap_or_default()+ .join(".kiro")+ .join("sessions")+ .join("cli"),+ }+ }+}++struct Sidecar {+ cwd: String,+ title: String,+ created_ms: i64,+ updated_ms: i64,+}++fn read_sidecar(jsonl_path: &Path) -> Sidecar {+ let mut side = Sidecar {+ cwd: String::new(),+ title: String::new(),+ created_ms: 0,+ updated_ms: 0,+ };+ let json_path = jsonl_path.with_extension("json");+ if let Ok(raw) = fs::read_to_string(&json_path) {+ if let Ok(v) = serde_json::from_str::<Value>(&raw) {+ if let Some(c) = v.get("cwd").and_then(|x| x.as_str()) {+ side.cwd = c.to_string();+ }+ if let Some(t) = v.get("title").and_then(|x| x.as_str()) {+ side.title = t.to_string();+ }+ if let Some(t) = v.get("created_at").and_then(|x| x.as_str()) {+ side.created_ms = iso_ms(t);+ }+ if let Some(t) = v.get("updated_at").and_then(|x| x.as_str()) {+ side.updated_ms = iso_ms(t);+ }+ }+ }+ side+}++fn parse_kiro_jsonl(path: &Path) -> Result<(Vec<TranscriptMessage>, u32)> {+ let file = fs::File::open(path)?;+ let reader = BufReader::with_capacity(1 << 20, file);+ let mut messages: Vec<TranscriptMessage> = Vec::new();+ let mut unknown = 0u32;++ for line in reader.lines() {+ let Ok(line) = line else {+ unknown += 1;+ continue;+ };+ if line.trim().is_empty() {+ continue;+ }+ let Ok(row) = serde_json::from_str::<Value>(&line) else {+ unknown += 1;+ continue;+ };+ let role = match row.get("kind").and_then(|v| v.as_str()) {+ Some("Prompt") => Role::User,+ Some("AssistantMessage") => Role::Assistant,+ _ => {+ unknown += 1;+ continue;+ }+ };+ let Some(data) = row.get("data") else {+ unknown += 1;+ continue;+ };+ let mut parts: Vec<String> = Vec::new();+ if let Some(Value::Array(blocks)) = data.get("content") {+ for b in blocks {+ if b.get("kind").and_then(|v| v.as_str()) == Some("text") {+ if let Some(t) = b.get("data").and_then(|v| v.as_str()) {+ if !t.trim().is_empty() {+ parts.push(t.trim().to_string());+ }+ }+ }+ }+ }+ let text = parts.join("\n\n");+ if text.is_empty() {+ continue;+ }+ let ts_sec = data+ .get("meta")+ .and_then(|m| m.get("timestamp"))+ .and_then(|v| v.as_i64())+ .unwrap_or(0);+ messages.push(text_msg(role, &text, ts_sec * 1000));+ }+ assign_seq(&mut messages);+ Ok((messages, unknown))+}++fn build_meta(r: &SessionFileRef, side: &Sidecar, messages: &[TranscriptMessage]) -> SessionMeta {+ let title = Some(clean_title_candidate(&side.title))+ .filter(|t| !t.is_empty())+ .or_else(|| title_from_messages(messages))+ .unwrap_or_else(|| UNTITLED.to_string());+ let msg_ts_max = messages.iter().filter_map(|m| m.timestamp).max().unwrap_or(0);+ SessionMeta {+ key: format!("kiro:{}", r.native_id),+ id: r.native_id.clone(),+ agent: AgentId::Kiro,+ title,+ project_path: side.cwd.clone(),+ project_name: project_name_of(&side.cwd),+ file_path: r.file_path.clone(),+ created_at: if side.created_ms > 0 { side.created_ms } else { r.mtime_ms },+ updated_at: match side.updated_ms.max(msg_ts_max) {+ t if t > 0 => t,+ _ => r.mtime_ms,+ },+ message_count: messages.iter().filter(|m| m.kind == MessageKind::Text).count() as i64,+ size_bytes: r.size,+ git_branch: None,+ model: None,+ tokens_used: None,+ archived: false,+ source: None,+ favorite: false,+ pinned: false,+ }+}++impl AgentAdapter for KiroAdapter {+ fn agent(&self) -> AgentId {+ AgentId::Kiro+ }++ fn detect(&self) -> bool {+ self.root.is_dir()+ }++ fn list_session_files(&self) -> Result<Vec<SessionFileRef>> {+ Ok(list_jsonl_refs(&self.root, AgentId::Kiro, str::to_string))+ }++ fn parse_session(&self, r: &SessionFileRef) -> Result<ParsedSession> {+ let (messages, unknown) = parse_kiro_jsonl(Path::new(&r.file_path))?;+ let side = read_sidecar(Path::new(&r.file_path));+ let meta = build_meta(r, &side, &messages);+ let units = units_from_messages(&messages);+ Ok(ParsedSession {+ meta,+ units,+ unknown_line_count: unknown,+ })+ }++ fn parse_transcript(&self, r: &SessionFileRef) -> Result<ParsedTranscript> {+ let (messages, unknown) = parse_kiro_jsonl(Path::new(&r.file_path))?;+ let side = read_sidecar(Path::new(&r.file_path));+ Ok(ParsedTranscript {+ meta: build_meta(r, &side, &messages),+ mainline: messages,+ sidechains: Vec::new(),+ unknown_line_count: unknown,+ })+ }++ fn watch_paths(&self) -> Vec<PathBuf> {+ if self.detect() {+ vec![self.root.clone()]+ } else {+ Vec::new()+ }+ }+}diff --git a/crates/wake-core/src/adapters/mod.rs b/crates/wake-core/src/adapters/mod.rsnew file mode 100644index 0000000..51ab431--- /dev/null+++ b/crates/wake-core/src/adapters/mod.rs@@ -0,0 +1,102 @@+pub mod claude;+pub mod codex;+pub mod copilot;+pub mod cursor;+pub mod gemini;+pub mod kiro;+pub mod opencode;++pub(crate) mod parse_utils;+mod sqlite_ro;++use crate::models::*;+use anyhow::Result;+use std::path::Path;++/// agent 数据源适配器。列表扫描与详情解析共用同一核心解析器,+/// 保证 FTS 的 seq 与详情页消息序号一致(搜索跳转依赖)。+pub trait AgentAdapter: Send + Sync {+ fn agent(&self) -> AgentId;+ /// 数据根目录是否存在+ fn detect(&self) -> bool;+ /// 枚举全部会话文件(只 stat 不读内容)+ fn list_session_files(&self) -> Result<Vec<SessionFileRef>>;+ /// watcher 事件路径 → 本 adapter 的会话文件引用;None = 非会话文件+ /// (边车、子代理转录等)。默认:非空 .jsonl,stem 即 native_id。+ /// 各家的路径布局知识收敛在此,watcher 不再硬编码任何 agent 特例。+ fn file_ref(&self, path: &Path) -> Option<SessionFileRef> {+ parse_utils::default_file_ref(self.agent(), path)+ }+ /// 快路径:不解析文件直接给出 meta(Codex 走 state DB)。None = 无快路径+ fn quick_meta(&self, _refs: &[SessionFileRef]) -> Option<std::collections::HashMap<String, SessionMeta>> {+ None+ }+ /// quick 与 parsed 的合并策略:默认 parsed 为准、quick 补缺。+ /// Codex 覆写(state DB 的 title 是用户手动命名,优先级更高)。+ fn merge_quick_meta(&self, mut parsed: SessionMeta, quick: &SessionMeta) -> SessionMeta {+ if parsed.source.is_none() {+ parsed.source = quick.source.clone();+ }+ if parsed.model.is_none() {+ parsed.model = quick.model.clone();+ }+ if parsed.tokens_used.is_none() {+ parsed.tokens_used = quick.tokens_used;+ }+ parsed+ }+ /// 全解析:meta + FTS 单元+ fn parse_session(&self, r: &SessionFileRef) -> Result<ParsedSession>;+ /// 详情解析+ fn parse_transcript(&self, r: &SessionFileRef) -> Result<ParsedTranscript>;+ /// 加载 sidechain 消息(仅 Claude/Cursor subagents)+ fn load_sidechain(&self, _r: &SessionFileRef, _sidechain_id: &str) -> Result<Vec<TranscriptMessage>> {+ Ok(Vec::new())+ }+ /// 会话在磁盘上的全部归属路径(删除时一并 trash)。默认仅主文件;+ /// 有边车/目录布局的 adapter 覆写。+ fn session_paths(&self, meta: &SessionMeta) -> Vec<String> {+ vec![meta.file_path.clone()]+ }+ /// 文件监听根目录+ fn watch_paths(&self) -> Vec<std::path::PathBuf>;+}++pub fn create_adapters() -> Vec<Box<dyn AgentAdapter>> {+ let all: Vec<Box<dyn AgentAdapter>> = vec![+ Box::new(claude::ClaudeAdapter::new()),+ Box::new(codex::CodexAdapter::new()),+ Box::new(copilot::CopilotAdapter::new()),+ Box::new(cursor::CursorAdapter::new()),+ Box::new(opencode::OpencodeAdapter::new()),+ Box::new(kiro::KiroAdapter::new()),+ Box::new(gemini::GeminiAdapter::new()),+ ];+ all.into_iter().filter(|a| a.detect()).collect()+}++/// 从解析后的消息派生 FTS 单元(text + tool 名称/输入摘要)+pub(crate) fn units_from_messages(messages: &[TranscriptMessage]) -> Vec<IndexUnit> {+ messages+ .iter()+ .filter(|m| m.kind == MessageKind::Text)+ .filter_map(|m| {+ let mut parts = vec![m.text.clone()];+ for tc in &m.tool_calls {+ parts.push(format!("{} {}", tc.name, tc.input_preview));+ }+ let text = parse_utils::clip(&parts.join("\n"), MAX_MSG_TEXT).0;+ if text.trim().is_empty() {+ None+ } else {+ Some(IndexUnit {+ seq: m.seq,+ sidechain_id: None,+ role: m.role,+ timestamp: m.timestamp,+ text,+ })+ }+ })+ .collect()+}diff --git a/crates/wake-core/src/adapters/opencode.rs b/crates/wake-core/src/adapters/opencode.rsnew file mode 100644index 0000000..495f02f--- /dev/null+++ b/crates/wake-core/src/adapters/opencode.rs@@ -0,0 +1,313 @@+use super::parse_utils::*;+use super::sqlite_ro::{open_sqlite_ro, virtual_path, SqliteRo};+use super::{units_from_messages, AgentAdapter};+use crate::models::*;+use anyhow::{anyhow, Result};+use serde_json::Value;+use std::collections::HashMap;+use std::path::PathBuf;+use std::sync::Mutex;++/// OpenCode:`~/.local/share/opencode/opencode.db`。+/// session 表自带 title/directory/tokens;正文在 part 表+/// ({type:text|reasoning|tool},synthetic=注入),message 表只有角色与时间。+/// parent_id 非空的是子代理会话,不进列表。+pub struct OpencodeAdapter {+ db: PathBuf,+ /// rows() 带按会话相关子查询(全 part 表求和),按 db mtime 缓存一轮+ /// 扫描内的重复调用+ rows_cache: Mutex<Option<(i64, Vec<OcRow>)>>,+}++const ROW_SELECT: &str = "SELECT s.id, s.directory, s.title, s.time_created, s.time_updated,+ s.model, s.tokens_input + s.tokens_output + s.tokens_reasoning,+ s.time_archived,+ (SELECT COALESCE(SUM(LENGTH(p.data)), 0) FROM part p WHERE p.session_id = s.id)+ FROM session s";++fn row_from(r: &rusqlite::Row) -> rusqlite::Result<OcRow> {+ Ok(OcRow {+ id: r.get(0)?,+ directory: r.get::<_, Option<String>>(1)?.unwrap_or_default(),+ title: r.get::<_, Option<String>>(2)?.unwrap_or_default(),+ created_ms: r.get::<_, Option<i64>>(3)?.unwrap_or(0),+ updated_ms: r.get::<_, Option<i64>>(4)?.unwrap_or(0),+ model_json: r.get::<_, Option<String>>(5)?.unwrap_or_default(),+ tokens: r.get::<_, Option<i64>>(6)?.unwrap_or(0),+ archived: r.get::<_, Option<i64>>(7)?.is_some(),+ content_len: r.get(8)?,+ })+}++impl OpencodeAdapter {+ pub fn new() -> Self {+ Self {+ db: dirs::home_dir()+ .unwrap_or_default()+ .join(".local")+ .join("share")+ .join("opencode")+ .join("opencode.db"),+ rows_cache: Mutex::new(None),+ }+ }++ fn open(&self) -> Option<SqliteRo> {+ open_sqlite_ro(&self.db, "opencode")+ }++ fn rows(&self) -> Option<Vec<OcRow>> {+ let mtime = std::fs::metadata(&self.db).map(|m| mtime_ms(&m)).unwrap_or(0);+ {+ let cache = self.rows_cache.lock().unwrap();+ if let Some((t, rows)) = cache.as_ref() {+ if *t == mtime {+ return Some(rows.clone());+ }+ }+ }+ let ro = self.open()?;+ let mut stmt = ro+ .conn+ .prepare(&format!("{ROW_SELECT} WHERE s.parent_id IS NULL"))+ .ok()?;+ let rows = stmt+ .query_map([], |r| row_from(r))+ .ok()?+ .collect::<rusqlite::Result<Vec<_>>>()+ .ok()?;+ *self.rows_cache.lock().unwrap() = Some((mtime, rows.clone()));+ Some(rows)+ }++ fn build_meta(&self, r: &SessionFileRef, row: &OcRow, message_count: i64) -> SessionMeta {+ let title = clean_title_candidate(&row.title);+ let model = serde_json::from_str::<Value>(&row.model_json)+ .ok()+ .and_then(|m| m.get("id").and_then(|v| v.as_str()).map(String::from));+ SessionMeta {+ key: format!("opencode:{}", row.id),+ id: row.id.clone(),+ agent: AgentId::Opencode,+ title: if title.is_empty() { UNTITLED.to_string() } else { title },+ project_path: row.directory.clone(),+ project_name: project_name_of(&row.directory),+ file_path: r.file_path.clone(),+ created_at: if row.created_ms > 0 { row.created_ms } else { r.mtime_ms },+ updated_at: if row.updated_ms > 0 { row.updated_ms } else { r.mtime_ms },+ message_count,+ size_bytes: r.size,+ git_branch: None,+ model,+ tokens_used: if row.tokens > 0 { Some(row.tokens) } else { None },+ archived: row.archived,+ source: None,+ favorite: false,+ pinned: false,+ }+ }++ /// 单会话解析:一次连接,会话行与 message/part 都只查本会话+ fn parse(&self, r: &SessionFileRef) -> Result<(SessionMeta, Vec<TranscriptMessage>, u32)> {+ let ro = self.open().ok_or_else(|| anyhow!("cannot open opencode db"))?;+ let row = ro+ .conn+ .query_row(+ &format!("{ROW_SELECT} WHERE s.id = ?1"),+ [&r.native_id],+ |x| row_from(x),+ )+ .map_err(|_| anyhow!("opencode session {} not in db", r.native_id))?;++ // part 按 (message_id, id) 排序分组;id 前缀时间有序+ let mut parts_by_msg: HashMap<String, Vec<Value>> = HashMap::new();+ {+ let mut stmt = ro.conn.prepare(+ "SELECT message_id, data FROM part WHERE session_id = ?1 ORDER BY message_id, id",+ )?;+ let rows = stmt.query_map([&r.native_id], |p| {+ Ok((p.get::<_, String>(0)?, p.get::<_, String>(1)?))+ })?;+ for (mid, data) in rows.flatten() {+ if let Ok(v) = serde_json::from_str::<Value>(&data) {+ parts_by_msg.entry(mid).or_default().push(v);+ }+ }+ }++ let mut messages: Vec<TranscriptMessage> = Vec::new();+ let mut unknown = 0u32;+ let mut stmt = ro.conn.prepare(+ "SELECT id, data FROM message WHERE session_id = ?1 ORDER BY time_created, id",+ )?;+ let msg_rows = stmt.query_map([&r.native_id], |m| {+ Ok((m.get::<_, String>(0)?, m.get::<_, String>(1)?))+ })?;+ for (mid, data) in msg_rows.flatten() {+ let Ok(md) = serde_json::from_str::<Value>(&data) else {+ unknown += 1;+ continue;+ };+ let role = match md.get("role").and_then(|v| v.as_str()) {+ Some("user") => Role::User,+ Some("assistant") => Role::Assistant,+ _ => Role::System,+ };+ let ts = md+ .get("time")+ .and_then(|t| t.get("created"))+ .and_then(|v| v.as_i64())+ .unwrap_or(0);+ let mut text_parts: Vec<String> = Vec::new();+ let mut synthetic_parts: Vec<String> = Vec::new();+ let mut thinking_parts: Vec<String> = Vec::new();+ let mut tool_calls: Vec<ToolCallView> = Vec::new();+ for p in parts_by_msg.remove(&mid).unwrap_or_default() {+ match p.get("type").and_then(|v| v.as_str()) {+ Some("text") => {+ let t = p.get("text").and_then(|v| v.as_str()).unwrap_or("");+ if t.trim().is_empty() {+ continue;+ }+ if p.get("synthetic").and_then(|v| v.as_bool()) == Some(true) {+ synthetic_parts.push(t.trim().to_string());+ } else {+ text_parts.push(t.trim().to_string());+ }+ }+ Some("reasoning") => {+ if let Some(t) = p.get("text").and_then(|v| v.as_str()) {+ if !t.trim().is_empty() {+ thinking_parts.push(t.trim().to_string());+ }+ }+ }+ Some("tool") => {+ let state = p.get("state").cloned().unwrap_or(Value::Null);+ let input = state.get("input").cloned().unwrap_or(Value::Null);+ let output = match state.get("output") {+ Some(Value::String(s)) => Some(s.clone()),+ Some(v) if !v.is_null() => serde_json::to_string(v).ok(),+ _ => None,+ };+ tool_calls.push(tool_call_view(+ p.get("callID").and_then(|v| v.as_str()).unwrap_or("").to_string(),+ p.get("tool").and_then(|v| v.as_str()).unwrap_or("tool"),+ &input,+ output,+ state.get("status").and_then(|v| v.as_str()) == Some("error"),+ ));+ }+ Some("step-start") | Some("step-finish") | Some("snapshot")+ | Some("patch") | Some("file") => {}+ _ => unknown += 1,+ }+ }+ // 只有注入内容(editor_context 等)的消息归 Meta 折叠+ let (text, kind) = if text_parts.is_empty() && !synthetic_parts.is_empty() {+ (synthetic_parts.join("\n\n"), MessageKind::Meta)+ } else {+ (text_parts.join("\n\n"), MessageKind::Text)+ };+ if text.is_empty() && thinking_parts.is_empty() && tool_calls.is_empty() {+ continue;+ }+ let (clipped, truncated) = clip(&text, MAX_MSG_TEXT);+ messages.push(TranscriptMessage {+ seq: 0,+ role,+ kind,+ text: clipped,+ truncated,+ tool_calls,+ thinking: if thinking_parts.is_empty() {+ None+ } else {+ Some(clip(&thinking_parts.join("\n\n"), MAX_TOOL_IO).0)+ },+ timestamp: if ts > 0 { Some(ts) } else { None },+ model: None,+ });+ }+ assign_seq(&mut messages);+ let count = messages.iter().filter(|m| m.kind == MessageKind::Text).count() as i64;+ let meta = self.build_meta(r, &row, count);+ Ok((meta, messages, unknown))+ }+}++#[derive(Clone)]+struct OcRow {+ id: String,+ directory: String,+ title: String,+ created_ms: i64,+ updated_ms: i64,+ model_json: String,+ tokens: i64,+ archived: bool,+ content_len: i64,+}++impl AgentAdapter for OpencodeAdapter {+ fn agent(&self) -> AgentId {+ AgentId::Opencode+ }++ fn detect(&self) -> bool {+ self.db.is_file()+ }++ fn list_session_files(&self) -> Result<Vec<SessionFileRef>> {+ let Some(rows) = self.rows() else {+ return Ok(Vec::new());+ };+ Ok(rows+ .into_iter()+ .filter(|row| row.content_len > 0)+ .map(|row| SessionFileRef {+ agent: AgentId::Opencode,+ native_id: row.id.clone(),+ file_path: virtual_path(&self.db, &row.id),+ mtime_ms: row.updated_ms,+ size: row.content_len,+ })+ .collect())+ }++ fn quick_meta(&self, refs: &[SessionFileRef]) -> Option<HashMap<String, SessionMeta>> {+ let rows = self.rows()?;+ let by_id: HashMap<&str, &OcRow> = rows.iter().map(|r| (r.id.as_str(), r)).collect();+ let mut out = HashMap::new();+ for r in refs {+ if let Some(row) = by_id.get(r.native_id.as_str()) {+ out.insert(r.file_path.clone(), self.build_meta(r, row, 0));+ }+ }+ Some(out)+ }++ fn parse_session(&self, r: &SessionFileRef) -> Result<ParsedSession> {+ let (meta, messages, unknown) = self.parse(r)?;+ let units = units_from_messages(&messages);+ Ok(ParsedSession {+ meta,+ units,+ unknown_line_count: unknown,+ })+ }++ fn parse_transcript(&self, r: &SessionFileRef) -> Result<ParsedTranscript> {+ let (meta, messages, unknown) = self.parse(r)?;+ Ok(ParsedTranscript {+ meta,+ mainline: messages,+ sidechains: Vec::new(),+ unknown_line_count: unknown,+ })+ }++ fn watch_paths(&self) -> Vec<PathBuf> {+ Vec::new()+ }+}diff --git a/crates/wake-core/src/adapters/parse_utils.rs b/crates/wake-core/src/adapters/parse_utils.rsnew file mode 100644index 0000000..2c0a91e--- /dev/null+++ b/crates/wake-core/src/adapters/parse_utils.rs@@ -0,0 +1,325 @@+use crate::models::*;+use serde_json::Value;++/// 文件 mtime → epoch ms(七家 adapter 与 watcher 共用)+pub fn mtime_ms(meta: &std::fs::Metadata) -> i64 {+ meta.modified()+ .ok()+ .and_then(|t| t.duration_since(std::time::UNIX_EPOCH).ok())+ .map(|d| d.as_millis() as i64)+ .unwrap_or(0)+}++/// cwd → 项目显示名(路径末段;空/异常 = "Unknown project")+pub fn project_name_of(cwd: &str) -> String {+ if cwd.is_empty() {+ return "Unknown project".to_string();+ }+ std::path::Path::new(cwd)+ .file_name()+ .map(|s| s.to_string_lossy().to_string())+ .unwrap_or_else(|| "Unknown project".to_string())+}++/// user 消息的 kind:注入内容归 Meta 折叠+pub fn user_kind(text: &str) -> MessageKind {+ if is_injected_user_content(text) {+ MessageKind::Meta+ } else {+ MessageKind::Text+ }+}++/// 纯文本消息构造(clip + user 注入判定),多家 adapter 共用+pub fn text_msg(role: Role, text: &str, ts: i64) -> TranscriptMessage {+ let (clipped, truncated) = clip(text.trim(), MAX_MSG_TEXT);+ let kind = if role == Role::User { user_kind(text) } else { MessageKind::Text };+ TranscriptMessage {+ seq: 0,+ role,+ kind,+ text: clipped,+ truncated,+ tool_calls: Vec::new(),+ thinking: None,+ timestamp: if ts > 0 { Some(ts) } else { None },+ model: None,+ }+}++/// seq 回填——FTS seq 与详情页序号一致(跨文件不变量 1)的统一执行点,+/// 必须在消息序列定型后、入库/返回前调用+pub fn assign_seq(messages: &mut [TranscriptMessage]) {+ for (i, m) in messages.iter_mut().enumerate() {+ m.seq = i as i64;+ }+}++/// 标题推导:首条真实用户消息经清洗,七家共用的回退链+pub fn title_from_messages(messages: &[TranscriptMessage]) -> Option<String> {+ messages+ .iter()+ .find(|m| m.role == Role::User && m.kind == MessageKind::Text)+ .map(|m| clean_title_candidate(&m.text))+ .filter(|t| !t.is_empty())+}++/// `AgentAdapter::file_ref` 的默认实现:非空 .jsonl,stem 即 native_id。+/// 覆写方可在此结果上做路径过滤或 native_id 改写。+pub fn default_file_ref(agent: AgentId, path: &std::path::Path) -> Option<SessionFileRef> {+ let name = path.file_name()?.to_string_lossy().to_string();+ if name.starts_with('.') {+ return None;+ }+ let stem = name.strip_suffix(".jsonl")?;+ let meta = std::fs::metadata(path).ok()?;+ if !meta.is_file() || meta.len() == 0 {+ return None;+ }+ Some(SessionFileRef {+ agent,+ native_id: stem.to_string(),+ file_path: path.to_string_lossy().to_string(),+ mtime_ms: mtime_ms(&meta),+ size: meta.len() as i64,+ })+}++/// 递归枚举目录下非空 .jsonl 为 SessionFileRef;`native_id` 从文件 stem 提取+/// 会话 id(多数家恒等,codex 需剥 rollout 前缀)+pub fn list_jsonl_refs(+ dir: &std::path::Path,+ agent: AgentId,+ native_id: impl Fn(&str) -> String,+) -> Vec<SessionFileRef> {+ let mut refs = Vec::new();+ if !dir.is_dir() {+ return refs;+ }+ for entry in walkdir::WalkDir::new(dir).into_iter().flatten() {+ if !entry.file_type().is_file() {+ continue;+ }+ let name = entry.file_name().to_string_lossy().to_string();+ let Some(stem) = name.strip_suffix(".jsonl") else {+ continue;+ };+ let Ok(meta) = entry.metadata() else { continue };+ if meta.len() == 0 {+ continue;+ }+ refs.push(SessionFileRef {+ agent,+ native_id: native_id(stem),+ file_path: entry.path().to_string_lossy().to_string(),+ mtime_ms: mtime_ms(&meta),+ size: meta.len() as i64,+ });+ }+ refs+}++/// tool_use 块 → ToolCallView(preview + pretty-print input 三件套统一)+pub fn tool_call_view(+ id: String,+ name: &str,+ input: &Value,+ output: Option<String>,+ is_error: bool,+) -> ToolCallView {+ let input_json = if input.is_null() {+ String::new()+ } else {+ serde_json::to_string_pretty(input).unwrap_or_default()+ };+ ToolCallView {+ id,+ name: if name.is_empty() { "tool".to_string() } else { name.to_string() },+ input_preview: make_preview(input),+ input: if input_json.is_empty() { None } else { Some(clip(&input_json, MAX_TOOL_IO).0) },+ output: output.map(|o| clip(&o, MAX_TOOL_IO).0),+ is_error,+ sidechain_ref: None,+ }+}++/// 截断到 max 字符(按 char 边界),返回 (text, truncated)+pub fn clip(s: &str, max: usize) -> (String, bool) {+ if s.len() <= max {+ return (s.to_string(), false);+ }+ // 找不超过 max 的最大 char 边界+ let mut end = max;+ while end > 0 && !s.is_char_boundary(end) {+ end -= 1;+ }+ (format!("{}\n… (truncated)", &s[..end]), true)+}++/// RFC3339 字符串 → epoch ms,解析失败 = 0+pub fn iso_ms(s: &str) -> i64 {+ chrono::DateTime::parse_from_rfc3339(s)+ .map(|d| d.timestamp_millis())+ .unwrap_or(0)+}++/// SQLite `datetime('now')` 风格("2026-05-15 06:23:37" 或带 T/毫秒/Z)→ epoch ms(按 UTC)+pub fn sqlite_dt_ms(s: &str) -> i64 {+ let ms = iso_ms(s);+ if ms > 0 {+ return ms;+ }+ let t = s.replace(' ', "T");+ let with_z = if t.ends_with('Z') { t } else { format!("{t}Z") };+ iso_ms(&with_z)+}++/// ISO8601 字符串或 unix 秒/毫秒 → epoch ms+pub fn to_epoch_ms(v: &Value) -> i64 {+ match v {+ Value::Number(n) => {+ let f = n.as_f64().unwrap_or(0.0);+ if f > 1e12 {+ f as i64+ } else if f > 0.0 {+ (f * 1000.0) as i64+ } else {+ 0+ }+ }+ Value::String(s) => iso_ms(s),+ _ => 0,+ }+}++/// 清洗标题候选:剥 slash-command 壳与 system-reminder 等标签,压单行截断。空串=不可用+pub fn clean_title_candidate(raw: &str) -> String {+ let mut s = strip_tag_block(raw, "system-reminder");+ s = strip_tag_block(&s, "local-command-caveat");+ s = strip_tag_block(&s, "local-command-stdout");++ let args = extract_tag(&s, "command-args");+ let name = extract_tag(&s, "command-name");+ if args.is_some() || name.is_some() {+ s = args.filter(|a| !a.trim().is_empty()).or(name).unwrap_or_default();+ }+ // 去掉残余短标签+ let mut out = String::with_capacity(s.len());+ let mut chars = s.chars().peekable();+ while let Some(c) = chars.next() {+ if c == '<' {+ let mut tag = String::new();+ let mut closed = false;+ for c2 in chars.by_ref() {+ if c2 == '>' {+ closed = true;+ break;+ }+ if c2 == '\n' || tag.len() > 60 {+ break;+ }+ tag.push(c2);+ }+ if !closed {+ out.push('<');+ out.push_str(&tag);+ } else {+ out.push(' ');+ }+ } else {+ out.push(c);+ }+ }+ let compact = out.split_whitespace().collect::<Vec<_>>().join(" ");+ if compact.is_empty() {+ return String::new();+ }+ let chars: Vec<char> = compact.chars().collect();+ if chars.len() > MAX_TITLE {+ let mut t: String = chars[..MAX_TITLE].iter().collect();+ t.push('…');+ t+ } else {+ compact+ }+}++fn strip_tag_block(s: &str, tag: &str) -> String {+ let open = format!("<{tag}>");+ let close = format!("</{tag}>");+ let mut out = String::with_capacity(s.len());+ let mut rest = s;+ loop {+ match rest.find(&open) {+ None => {+ out.push_str(rest);+ return out;+ }+ Some(i) => {+ out.push_str(&rest[..i]);+ out.push(' ');+ match rest[i..].find(&close) {+ None => return out,+ Some(j) => rest = &rest[i + j + close.len()..],+ }+ }+ }+ }+}++pub(crate) fn extract_tag(s: &str, tag: &str) -> Option<String> {+ let open = format!("<{tag}>");+ let close = format!("</{tag}>");+ let i = s.find(&open)?;+ let j = s[i + open.len()..].find(&close)?;+ Some(s[i + open.len()..i + open.len() + j].to_string())+}++/// IDE/CLI 注入型"用户"消息:非用户手打,详情里应归 Meta 折叠,不参与标题推导。+pub fn is_injected_user_content(text: &str) -> bool {+ let t = text.trim_start();+ const PREFIXES: &[&str] = &[+ "<recommended_plugins",+ "<environment_context",+ "<user_instructions",+ "<permissions",+ "<workspace",+ "<system-",+ "<context ",+ "<session_context",+ "IMPORTANT: Do NOT read",+ "Caveat: The messages below",+ "# Files pasted by the user",+ ];+ if PREFIXES.iter().any(|p| t.starts_with(p)) {+ return true;+ }+ // Codex 的 skill 展开体:skill-name + SKILL.md 路径 + frontmatter(不带 $,+ // 用户手打的 "$skill" 引用是另一条独立消息,不受影响)+ t.contains("/.codex/plugins/") || (t.contains("/plugins/cache/") && t.contains("SKILL.md"))+}++/// tool 输入的单行摘要+pub fn make_preview(input: &Value) -> String {+ const MAX: usize = 200;+ let cand = if let Value::Object(obj) = input {+ ["command", "file_path", "path", "pattern", "query", "url", "description"]+ .iter()+ .find_map(|k| obj.get(*k).and_then(|v| v.as_str()).filter(|s| !s.trim().is_empty()))+ .map(|s| s.to_string())+ .or_else(|| serde_json::to_string(input).ok())+ } else if let Value::String(s) = input {+ Some(s.clone())+ } else {+ serde_json::to_string(input).ok()+ };+ let one = cand.unwrap_or_default().split_whitespace().collect::<Vec<_>>().join(" ");+ let chars: Vec<char> = one.chars().collect();+ if chars.len() > MAX {+ let mut t: String = chars[..MAX].iter().collect();+ t.push('…');+ t+ } else {+ one+ }+}diff --git a/crates/wake-core/src/adapters/sqlite_ro.rs b/crates/wake-core/src/adapters/sqlite_ro.rsnew file mode 100644index 0000000..fb996af--- /dev/null+++ b/crates/wake-core/src/adapters/sqlite_ro.rs@@ -0,0 +1,53 @@+use rusqlite::{Connection, OpenFlags};+use std::fs;+use std::path::{Path, PathBuf};++/// 只读打开的别家 SQLite 连接;若走了 copy 降级,临时目录随 drop 清理。+pub struct SqliteRo {+ pub conn: Connection,+ _tmp: Option<TempDirGuard>,+}++struct TempDirGuard(PathBuf);+impl Drop for TempDirGuard {+ fn drop(&mut self) {+ let _ = fs::remove_dir_all(&self.0);+ }+}++/// 只读读取别家 SQLite,与 codex.rs 同一约定:readonly 直开(探测查询验证可用)+/// → copy 三件套到临时目录 → 放弃。绝不写、绝不 immutable=1(WAL 并发写下不安全)。+pub fn open_sqlite_ro(db: &Path, tag: &str) -> Option<SqliteRo> {+ if !db.is_file() {+ return None;+ }+ if let Ok(conn) = Connection::open_with_flags(db, OpenFlags::SQLITE_OPEN_READ_ONLY) {+ let probe: rusqlite::Result<i64> =+ conn.query_row("SELECT count(*) FROM sqlite_master", [], |r| r.get(0));+ if probe.is_ok() {+ return Some(SqliteRo { conn, _tmp: None });+ }+ }+ let tmp = std::env::temp_dir().join(format!("wake-{tag}-{}", std::process::id()));+ fs::create_dir_all(&tmp).ok()?;+ let guard = TempDirGuard(tmp.clone());+ let db_copy = tmp.join("db.sqlite");+ fs::copy(db, &db_copy).ok()?;+ for suffix in ["-wal", "-shm"] {+ let src = PathBuf::from(format!("{}{suffix}", db.display()));+ if src.is_file() {+ let _ = fs::copy(&src, tmp.join(format!("db.sqlite{suffix}")));+ }+ }+ let conn = Connection::open_with_flags(&db_copy, OpenFlags::SQLITE_OPEN_READ_ONLY).ok()?;+ Some(SqliteRo {+ conn,+ _tmp: Some(guard),+ })+}++/// SQLite 型数据源没有每会话独立文件,用 `<db路径>#<会话id>` 作虚拟 file_path。+/// 该路径磁盘上不存在:trash 会自动跳过(仅 tombstone),watcher 不追踪。+pub fn virtual_path(db: &Path, id: &str) -> String {+ format!("{}#{id}", db.display())+}diff --git a/crates/wake-core/src/bin/scan.rs b/crates/wake-core/src/bin/scan.rsnew file mode 100644index 0000000..975cc82--- /dev/null+++ b/crates/wake-core/src/bin/scan.rs@@ -0,0 +1,86 @@+//! 数据层黄金对比 CLI:扫描全部会话入库并打印统计,+//! 与 Electron 版基准(claude 97 / codex 168 / messages 31871±)对照。+use anyhow::Result;+use std::sync::Arc;+use wake_core::adapters::create_adapters;+use wake_core::db::Store;+use wake_core::models::SessionFilter;+use wake_core::scanner::{run_scan, NullEvents, ScanEvents, ScanProgress};++struct StderrEvents;+impl ScanEvents for StderrEvents {+ fn on_progress(&self, p: &ScanProgress) {+ if p.total > 0 {+ eprint!("\rIndexing {}/{} ", p.done, p.total);+ }+ }+ fn on_sessions_changed(&self) {}+}++fn main() -> Result<()> {+ let args: Vec<String> = std::env::args().collect();+ let full = args.iter().any(|a| a == "--full");+ let db_path = if args.iter().any(|a| a == "--tmp") {+ std::env::temp_dir().join("wake-scan-test.db")+ } else {+ wake_core::db::default_db_path()+ };+ eprintln!("DB: {}", db_path.display());++ let store = Arc::new(Store::open(&db_path)?);+ let adapters = create_adapters();+ eprintln!(+ "adapters: {:?}",+ adapters.iter().map(|a| a.agent().as_str()).collect::<Vec<_>>()+ );++ let t0 = std::time::Instant::now();+ let events: Box<dyn ScanEvents> = if args.iter().any(|a| a == "--quiet") {+ Box::new(NullEvents)+ } else {+ Box::new(StderrEvents)+ };+ run_scan(&adapters, &store, events.as_ref(), full)?;+ eprintln!();+ println!("Scan took {:.1}s", t0.elapsed().as_secs_f64());++ for (agent, count) in store.agent_counts()? {+ println!("{agent}: {count} sessions");+ }+ let (sessions, total) = store.list_sessions(&SessionFilter {+ limit: 5,+ include_archived: true,+ ..Default::default()+ })?;+ println!("Total sessions (incl. archived): {total}");+ println!("Latest 5:");+ for s in sessions {+ println!(+ " [{}] {} — {} ({} msgs)",+ s.agent.as_str(),+ s.title.chars().take(30).collect::<String>(),+ s.project_name,+ s.message_count+ );+ }++ // 搜索冒烟+ if let Some(q) = args.iter().position(|a| a == "--search").map(|i| args.get(i + 1)).flatten() {+ let t1 = std::time::Instant::now();+ let (hits, degraded) = store.search(q, &[], None, 10)?;+ println!(+ "搜索 \"{q}\": {} hits, degraded={degraded}, {:.0}ms",+ hits.len(),+ t1.elapsed().as_secs_f64() * 1000.0+ );+ for h in hits.iter().take(3) {+ println!(+ " {} #{}: {}",+ h.session.title.chars().take(24).collect::<String>(),+ h.seq,+ h.snippet.chars().take(60).collect::<String>().replace('\n', " ")+ );+ }+ }+ Ok(())+}diff --git a/crates/wake-core/src/db.rs b/crates/wake-core/src/db.rsnew file mode 100644index 0000000..81369e8--- /dev/null+++ b/crates/wake-core/src/db.rs@@ -0,0 +1,636 @@+use crate::models::*;+use anyhow::{Context as _, Result};+use rusqlite::{params, Connection, OptionalExtension};+use std::collections::HashMap;+use std::path::Path;+use std::sync::Mutex;++const DDL: &str = r#"+CREATE TABLE IF NOT EXISTS schema_meta (key TEXT PRIMARY KEY, value TEXT);++CREATE TABLE IF NOT EXISTS sessions (+ key TEXT PRIMARY KEY,+ agent_id TEXT NOT NULL,+ native_id TEXT NOT NULL,+ title TEXT NOT NULL DEFAULT '',+ project_path TEXT NOT NULL DEFAULT '',+ project_name TEXT NOT NULL DEFAULT '',+ git_branch TEXT,+ created_at INTEGER DEFAULT 0,+ updated_at INTEGER DEFAULT 0,+ message_count INTEGER DEFAULT 0,+ tokens_used INTEGER,+ model TEXT,+ source TEXT,+ archived INTEGER DEFAULT 0,+ file_path TEXT NOT NULL UNIQUE,+ file_size INTEGER DEFAULT 0,+ file_mtime INTEGER DEFAULT 0,+ unknown_lines INTEGER DEFAULT 0+);+CREATE INDEX IF NOT EXISTS idx_sessions_updated ON sessions(updated_at DESC);+CREATE INDEX IF NOT EXISTS idx_sessions_agent ON sessions(agent_id, updated_at DESC);+CREATE INDEX IF NOT EXISTS idx_sessions_project ON sessions(project_path, updated_at DESC);++CREATE TABLE IF NOT EXISTS messages (+ id INTEGER PRIMARY KEY,+ session_key TEXT NOT NULL,+ sidechain_id TEXT,+ seq INTEGER NOT NULL,+ role TEXT, ts INTEGER,+ text TEXT NOT NULL+);+CREATE INDEX IF NOT EXISTS idx_messages_session ON messages(session_key);++CREATE VIRTUAL TABLE IF NOT EXISTS messages_fts USING fts5(+ text,+ content='messages', content_rowid='id',+ tokenize="trigram case_sensitive 0"+);++CREATE TABLE IF NOT EXISTS user_data (+ session_key TEXT PRIMARY KEY,+ favorite INTEGER DEFAULT 0,+ pinned INTEGER DEFAULT 0,+ updated_at INTEGER+);++CREATE TABLE IF NOT EXISTS tombstones (+ file_path TEXT PRIMARY KEY,+ deleted_at INTEGER+);+"#;++fn open_conn(path: &Path) -> Result<Connection> {+ if let Some(dir) = path.parent() {+ std::fs::create_dir_all(dir)?;+ }+ let conn = Connection::open(path)?;+ conn.pragma_update(None, "journal_mode", "WAL")?;+ conn.pragma_update(None, "synchronous", "NORMAL")?;+ conn.busy_timeout(std::time::Duration::from_millis(3000))?;+ conn.execute_batch(DDL)+ .context("failed to initialize SQLite schema")?;+ Ok(conn)+}++/// 打开索引库;打不开就把它连同 WAL/SHM 一起挪到 `.corrupt` 旁路再建一个空的。+/// 索引本来就能从磁盘全量重扫恢复,重建的真实损失只有 user_data(收藏/置顶)——+/// 而它远好过 GUI 无提示秒退。返回的 `Some(_)` 是给用户看的说明文案。+pub fn open_or_rebuild(path: &Path) -> Result<(Store, Option<String>)> {+ let first = match Store::open(path) {+ Ok(store) => return Ok((store, None)),+ Err(e) => e,+ };+ // 三件套一起挪:留下 WAL 或 SHM 任何一个,新库都会接着读旧日志+ let backup = std::path::PathBuf::from(format!("{}.corrupt", path.display()));+ let _ = std::fs::remove_file(&backup);+ let _ = std::fs::rename(path, &backup);+ for suffix in ["-wal", "-shm"] {+ let _ = std::fs::remove_file(format!("{}{suffix}", path.display()));+ }+ let store = Store::open(path)+ .with_context(|| format!("rebuild failed after: {first}"))?;+ Ok((+ store,+ Some(format!(+ "Index was damaged and has been rebuilt — stars and pins are gone. \+ The old file is kept at {}",+ backup.display()+ )),+ ))+}++/// 读写分连接(WAL 单写多读);Connection 非 Sync,各自套 Mutex+pub struct Store {+ write: Mutex<Connection>,+ read: Mutex<Connection>,+}++impl Store {+ pub fn open(path: &Path) -> Result<Self> {+ Ok(Self {+ write: Mutex::new(open_conn(path)?),+ read: Mutex::new(open_conn(path)?),+ })+ }++ // ---------- 写路径(扫描器/用户操作) ----------++ pub fn write_session(&self, meta: &SessionMeta, file_mtime: i64, units: &[IndexUnit]) -> Result<()> {+ let mut conn = self.write.lock().unwrap();+ let tx = conn.transaction()?;+ {+ // FTS external content 需要显式 delete 旧行+ let mut sel = tx.prepare_cached("SELECT id, text FROM messages WHERE session_key = ?1")?;+ let rows: Vec<(i64, String)> = sel+ .query_map(params![meta.key], |r| Ok((r.get(0)?, r.get(1)?)))?+ .collect::<rusqlite::Result<_>>()?;+ let mut fts_del =+ tx.prepare_cached("INSERT INTO messages_fts(messages_fts, rowid, text) VALUES ('delete', ?1, ?2)")?;+ for (id, text) in rows {+ fts_del.execute(params![id, text])?;+ }+ tx.execute("DELETE FROM messages WHERE session_key = ?1", params![meta.key])?;++ upsert_session(&tx, meta, file_mtime)?;++ let mut ins_msg = tx.prepare_cached(+ "INSERT INTO messages(session_key, sidechain_id, seq, role, ts, text) VALUES (?1,?2,?3,?4,?5,?6)",+ )?;+ let mut ins_fts =+ tx.prepare_cached("INSERT INTO messages_fts(rowid, text) VALUES (?1, ?2)")?;+ for u in units {+ ins_msg.execute(params![+ meta.key,+ u.sidechain_id,+ u.seq,+ u.role.as_str(),+ u.timestamp,+ u.text+ ])?;+ let rowid = tx.last_insert_rowid();+ ins_fts.execute(params![rowid, u.text])?;+ }+ }+ tx.commit()?;+ Ok(())+ }++ pub fn write_meta_only(&self, metas: &[(SessionMeta, i64)]) -> Result<()> {+ let mut conn = self.write.lock().unwrap();+ let tx = conn.transaction()?;+ for (meta, mtime) in metas {+ upsert_session(&tx, meta, *mtime)?;+ }+ tx.commit()?;+ Ok(())+ }++ pub fn remove_session(&self, key: &str, tombstone: bool) -> Result<()> {+ let mut conn = self.write.lock().unwrap();+ let tx = conn.transaction()?;+ {+ let file_path: Option<String> = tx+ .query_row("SELECT file_path FROM sessions WHERE key = ?1", params![key], |r| r.get(0))+ .optional()?;+ let mut sel = tx.prepare_cached("SELECT id, text FROM messages WHERE session_key = ?1")?;+ let rows: Vec<(i64, String)> = sel+ .query_map(params![key], |r| Ok((r.get(0)?, r.get(1)?)))?+ .collect::<rusqlite::Result<_>>()?;+ let mut fts_del =+ tx.prepare_cached("INSERT INTO messages_fts(messages_fts, rowid, text) VALUES ('delete', ?1, ?2)")?;+ for (id, text) in rows {+ fts_del.execute(params![id, text])?;+ }+ tx.execute("DELETE FROM messages WHERE session_key = ?1", params![key])?;+ tx.execute("DELETE FROM sessions WHERE key = ?1", params![key])?;+ if tombstone {+ if let Some(fp) = file_path {+ tx.execute(+ "INSERT OR REPLACE INTO tombstones(file_path, deleted_at) VALUES (?1, ?2)",+ params![fp, now_ms()],+ )?;+ }+ }+ }+ tx.commit()?;+ Ok(())+ }++ pub fn remove_by_path(&self, file_path: &str) -> Result<()> {+ let key: Option<String> = {+ let conn = self.read.lock().unwrap();+ conn.query_row(+ "SELECT key FROM sessions WHERE file_path = ?1",+ params![file_path],+ |r| r.get(0),+ )+ .optional()?+ };+ if let Some(k) = key {+ self.remove_session(&k, false)?;+ }+ Ok(())+ }++ pub fn set_user_data(&self, key: &str, favorite: Option<bool>, pinned: Option<bool>) -> Result<()> {+ let conn = self.write.lock().unwrap();+ conn.execute(+ "INSERT INTO user_data(session_key, favorite, pinned, updated_at)+ VALUES (?1, COALESCE(?2, 0), COALESCE(?3, 0), ?4)+ ON CONFLICT(session_key) DO UPDATE SET+ favorite = COALESCE(?2, user_data.favorite),+ pinned = COALESCE(?3, user_data.pinned),+ updated_at = excluded.updated_at",+ params![key, favorite.map(|v| v as i64), pinned.map(|v| v as i64), now_ms()],+ )?;+ Ok(())+ }++ pub fn rebuild_all(&self) -> Result<()> {+ let conn = self.write.lock().unwrap();+ conn.execute_batch(+ "DELETE FROM messages; DELETE FROM messages_fts; DELETE FROM sessions;",+ )?;+ Ok(())+ }++ // ---------- 读路径(UI 查询) ----------++ pub fn known_files(&self) -> Result<HashMap<String, (i64, i64, String)>> {+ let conn = self.read.lock().unwrap();+ let mut stmt = conn.prepare_cached("SELECT file_path, file_mtime, file_size, key FROM sessions")?;+ let rows = stmt.query_map([], |r| {+ Ok((r.get::<_, String>(0)?, (r.get(1)?, r.get(2)?, r.get(3)?)))+ })?;+ let mut map = HashMap::new();+ for row in rows {+ let (path, v) = row?;+ map.insert(path, v);+ }+ Ok(map)+ }++ pub fn is_tombstoned(&self, file_path: &str) -> bool {+ let conn = self.read.lock().unwrap();+ conn.query_row(+ "SELECT 1 FROM tombstones WHERE file_path = ?1",+ params![file_path],+ |_| Ok(()),+ )+ .optional()+ .map(|o| o.is_some())+ .unwrap_or(false)+ }++ pub fn list_sessions(&self, f: &SessionFilter) -> Result<(Vec<SessionMeta>, i64)> {+ let mut wheres: Vec<String> = Vec::new();+ let mut args: Vec<Box<dyn rusqlite::ToSql>> = Vec::new();++ if !f.agents.is_empty() {+ let ph = f.agents.iter().map(|_| "?").collect::<Vec<_>>().join(",");+ wheres.push(format!("s.agent_id IN ({ph})"));+ for a in &f.agents {+ args.push(Box::new(a.as_str().to_string()));+ }+ }+ if let Some(p) = &f.project_path {+ wheres.push("s.project_path = ?".into());+ args.push(Box::new(p.clone()));+ }+ if f.favorite_only {+ wheres.push("COALESCE(u.favorite, 0) = 1".into());+ }+ if !f.include_archived {+ wheres.push("s.archived = 0".into());+ }+ if let Some(q) = f.title_query.as_deref().filter(|q| !q.trim().is_empty()) {+ wheres.push("(s.title LIKE ? ESCAPE '\\' OR s.project_name LIKE ? ESCAPE '\\')".into());+ let like = format!("%{}%", escape_like(q.trim()));+ args.push(Box::new(like.clone()));+ args.push(Box::new(like));+ }+ let where_sql = if wheres.is_empty() {+ String::new()+ } else {+ format!("WHERE {}", wheres.join(" AND "))+ };+ let order_col = match f.sort {+ SortKey::Updated => "s.updated_at",+ SortKey::Created => "s.created_at",+ SortKey::Messages => "s.message_count",+ };+ let order_dir = if f.ascending { "ASC" } else { "DESC" };++ let conn = self.read.lock().unwrap();+ let total: i64 = conn.query_row(+ &format!(+ "SELECT COUNT(*) FROM sessions s LEFT JOIN user_data u ON u.session_key = s.key {where_sql}"+ ),+ rusqlite::params_from_iter(args.iter().map(|b| b.as_ref())),+ |r| r.get(0),+ )?;++ let sql = format!(+ "SELECT {SESSION_COLS} FROM sessions s LEFT JOIN user_data u ON u.session_key = s.key+ {where_sql}+ ORDER BY COALESCE(u.pinned,0) DESC, {order_col} {order_dir} LIMIT ? OFFSET ?"+ );+ let mut stmt = conn.prepare_cached(&sql)?;+ let limit = if f.limit > 0 { f.limit } else { 500 };+ args.push(Box::new(limit));+ args.push(Box::new(f.offset));+ let rows = stmt.query_map(+ rusqlite::params_from_iter(args.iter().map(|b| b.as_ref())),+ row_to_meta,+ )?;+ let mut out = Vec::new();+ for r in rows {+ out.push(r?);+ }+ Ok((out, total))+ }++ pub fn get_session(&self, key: &str) -> Result<Option<SessionMeta>> {+ let conn = self.read.lock().unwrap();+ let sql = format!(+ "SELECT {SESSION_COLS} FROM sessions s LEFT JOIN user_data u ON u.session_key = s.key WHERE s.key = ?1"+ );+ Ok(conn.query_row(&sql, params![key], row_to_meta).optional()?)+ }++ pub fn list_projects(&self) -> Result<Vec<ProjectInfo>> {+ let conn = self.read.lock().unwrap();+ let mut stmt = conn.prepare_cached(+ "SELECT project_path, project_name, COUNT(*), MAX(updated_at)+ FROM sessions WHERE archived = 0+ GROUP BY project_path ORDER BY MAX(updated_at) DESC",+ )?;+ let rows = stmt.query_map([], |r| {+ Ok(ProjectInfo {+ path: r.get(0)?,+ name: r.get(1)?,+ session_count: r.get(2)?,+ last_active: r.get(3)?,+ })+ })?;+ let mut out = Vec::new();+ for r in rows {+ out.push(r?);+ }+ Ok(out)+ }++ pub fn starred_count(&self) -> Result<i64> {+ let conn = self.read.lock().unwrap();+ Ok(conn.query_row(+ // archived 过滤与 agent_counts/list_projects 同口径,徽标数 = 点开后可见数+ "SELECT COUNT(*) FROM user_data u JOIN sessions s ON s.key = u.session_key WHERE u.favorite = 1 AND s.archived = 0",+ [],+ |r| r.get(0),+ )?)+ }++ pub fn agent_counts(&self) -> Result<HashMap<String, i64>> {+ let conn = self.read.lock().unwrap();+ let mut stmt =+ conn.prepare_cached("SELECT agent_id, COUNT(*) FROM sessions WHERE archived = 0 GROUP BY agent_id")?;+ let rows = stmt.query_map([], |r| Ok((r.get::<_, String>(0)?, r.get::<_, i64>(1)?)))?;+ let mut map = HashMap::new();+ for r in rows {+ let (k, v) = r?;+ map.insert(k, v);+ }+ Ok(map)+ }++ /// 全文搜索:trigram MATCH(每段 ≥3 码点)或 LIKE 降级。返回 (hits, degraded)+ pub fn search(+ &self,+ q: &str,+ agents: &[AgentId],+ project_path: Option<&str>,+ limit: i64,+ ) -> Result<(Vec<SearchHit>, bool)> {+ let segs: Vec<&str> = q.split_whitespace().filter(|s| !s.is_empty()).collect();+ if segs.is_empty() {+ return Ok((Vec::new(), false));+ }+ let degraded = segs.iter().any(|s| s.chars().count() < 3);++ let mut filter_sql = String::new();+ let mut filter_args: Vec<Box<dyn rusqlite::ToSql>> = Vec::new();+ if !agents.is_empty() {+ let ph = agents.iter().map(|_| "?").collect::<Vec<_>>().join(",");+ filter_sql.push_str(&format!(" AND s.agent_id IN ({ph})"));+ for a in agents {+ filter_args.push(Box::new(a.as_str().to_string()));+ }+ }+ if let Some(p) = project_path {+ filter_sql.push_str(" AND s.project_path = ?");+ filter_args.push(Box::new(p.to_string()));+ }++ let conn = self.read.lock().unwrap();+ let mut raw: Vec<(String, i64, Option<String>, String, Option<i64>, String)> = Vec::new();++ if !degraded {+ let match_expr = segs+ .iter()+ .map(|s| format!("\"{}\"", s.replace('"', "\"\"")))+ .collect::<Vec<_>>()+ .join(" AND ");+ let sql = format!(+ "SELECT m.session_key, m.seq, m.sidechain_id, m.role, m.ts,+ snippet(messages_fts, 0, ?, ?, '…', 16)+ FROM messages_fts+ JOIN messages m ON m.id = messages_fts.rowid+ JOIN sessions s ON s.key = m.session_key+ WHERE messages_fts MATCH ?{filter_sql}+ ORDER BY bm25(messages_fts) LIMIT ?"+ );+ let mut stmt = conn.prepare_cached(&sql)?;+ let mut all_args: Vec<Box<dyn rusqlite::ToSql>> = vec![+ Box::new(HL_OPEN.to_string()),+ Box::new(HL_CLOSE.to_string()),+ Box::new(match_expr),+ ];+ all_args.extend(filter_args);+ all_args.push(Box::new(limit));+ let rows = stmt.query_map(+ rusqlite::params_from_iter(all_args.iter().map(|b| b.as_ref())),+ |r| {+ Ok((+ r.get(0)?,+ r.get(1)?,+ r.get(2)?,+ r.get(3)?,+ r.get(4)?,+ r.get(5)?,+ ))+ },+ )?;+ for r in rows {+ raw.push(r?);+ }+ } else {+ let like_where = segs+ .iter()+ .map(|_| "m.text LIKE ? ESCAPE '\\'")+ .collect::<Vec<_>>()+ .join(" AND ");+ let sql = format!(+ "SELECT m.session_key, m.seq, m.sidechain_id, m.role, m.ts, m.text+ FROM messages m JOIN sessions s ON s.key = m.session_key+ WHERE {like_where}{filter_sql}+ ORDER BY m.ts DESC LIMIT ?"+ );+ let mut stmt = conn.prepare_cached(&sql)?;+ let mut all_args: Vec<Box<dyn rusqlite::ToSql>> = segs+ .iter()+ .map(|s| Box::new(format!("%{}%", escape_like(s))) as Box<dyn rusqlite::ToSql>)+ .collect();+ all_args.extend(filter_args);+ all_args.push(Box::new(limit));+ let rows = stmt.query_map(+ rusqlite::params_from_iter(all_args.iter().map(|b| b.as_ref())),+ |r| {+ Ok((+ r.get(0)?,+ r.get(1)?,+ r.get(2)?,+ r.get(3)?,+ r.get(4)?,+ r.get(5)?,+ ))+ },+ )?;+ for r in rows {+ let (k, seq, sc, role, ts, text): (String, i64, Option<String>, String, Option<i64>, String) = r?;+ raw.push((k, seq, sc, role, ts, make_like_snippet(&text, segs[0])));+ }+ }++ // 补齐 session meta+ let mut hits = Vec::new();+ let sql = format!(+ "SELECT {SESSION_COLS} FROM sessions s LEFT JOIN user_data u ON u.session_key = s.key WHERE s.key = ?1"+ );+ for (key, seq, sidechain_id, role, ts, snippet) in raw {+ if let Some(session) = conn.query_row(&sql, params![key], row_to_meta).optional()? {+ hits.push(SearchHit {+ session,+ seq,+ sidechain_id,+ role,+ snippet,+ timestamp: ts,+ });+ }+ }+ Ok((hits, degraded))+ }+}++const SESSION_COLS: &str = "s.key, s.agent_id, s.native_id, s.title, s.project_path, s.project_name,+ s.git_branch, s.created_at, s.updated_at, s.message_count, s.tokens_used, s.model, s.source,+ s.archived, s.file_path, s.file_size, COALESCE(u.favorite,0), COALESCE(u.pinned,0)";++fn row_to_meta(r: &rusqlite::Row<'_>) -> rusqlite::Result<SessionMeta> {+ let agent_str: String = r.get(1)?;+ Ok(SessionMeta {+ key: r.get(0)?,+ agent: AgentId::from_str(&agent_str).unwrap_or(AgentId::ClaudeCode),+ id: r.get(2)?,+ title: r.get(3)?,+ project_path: r.get(4)?,+ project_name: r.get(5)?,+ git_branch: r.get(6)?,+ created_at: r.get(7)?,+ updated_at: r.get(8)?,+ message_count: r.get(9)?,+ tokens_used: r.get(10)?,+ model: r.get(11)?,+ source: r.get(12)?,+ archived: r.get::<_, i64>(13)? == 1,+ file_path: r.get(14)?,+ size_bytes: r.get(15)?,+ favorite: r.get::<_, i64>(16)? == 1,+ pinned: r.get::<_, i64>(17)? == 1,+ })+}++fn upsert_session(tx: &rusqlite::Transaction<'_>, m: &SessionMeta, file_mtime: i64) -> Result<()> {+ tx.execute(+ "INSERT INTO sessions(key, agent_id, native_id, title, project_path, project_name,+ git_branch, created_at, updated_at, message_count, tokens_used, model, source,+ archived, file_path, file_size, file_mtime, unknown_lines)+ VALUES (?1,?2,?3,?4,?5,?6,?7,?8,?9,?10,?11,?12,?13,?14,?15,?16,?17,0)+ ON CONFLICT(key) DO UPDATE SET+ title=excluded.title, project_path=excluded.project_path,+ project_name=excluded.project_name, git_branch=excluded.git_branch,+ created_at=excluded.created_at, updated_at=excluded.updated_at,+ message_count=excluded.message_count, tokens_used=excluded.tokens_used,+ model=excluded.model, source=excluded.source, archived=excluded.archived,+ file_path=excluded.file_path, file_size=excluded.file_size,+ file_mtime=excluded.file_mtime",+ params![+ m.key,+ m.agent.as_str(),+ m.id,+ m.title,+ m.project_path,+ m.project_name,+ m.git_branch,+ m.created_at,+ m.updated_at,+ m.message_count,+ m.tokens_used,+ m.model,+ m.source,+ m.archived as i64,+ m.file_path,+ m.size_bytes,+ file_mtime,+ ],+ )?;+ Ok(())+}++fn escape_like(s: &str) -> String {+ s.replace('\\', "\\\\").replace('%', "\\%").replace('_', "\\_")+}++fn make_like_snippet(text: &str, first_seg: &str) -> String {+ let lower = text.to_lowercase();+ let seg_lower = first_seg.to_lowercase();+ let Some(byte_idx) = lower.find(&seg_lower) else {+ return text.chars().take(120).collect();+ };+ // 定位到字符边界安全的窗口+ let chars: Vec<char> = text.chars().collect();+ let char_idx = text[..byte_idx].chars().count();+ let seg_len = first_seg.chars().count();+ let start = char_idx.saturating_sub(40);+ let end = (char_idx + seg_len + 80).min(chars.len());+ let mut out = String::new();+ if start > 0 {+ out.push('…');+ }+ out.extend(&chars[start..char_idx]);+ out.push(HL_OPEN);+ out.extend(&chars[char_idx..(char_idx + seg_len).min(chars.len())]);+ out.push(HL_CLOSE);+ out.extend(&chars[(char_idx + seg_len).min(chars.len())..end]);+ if end < chars.len() {+ out.push('…');+ }+ out+}++pub fn now_ms() -> i64 {+ chrono::Utc::now().timestamp_millis()+}++/// 索引库路径:~/Library/Application Support/wake/wake.db+/// (从旧 vibex 路径一次性迁移,保留收藏等 user_data)+pub fn default_db_path() -> std::path::PathBuf {+ let data = dirs::data_dir().unwrap_or_else(|| std::path::PathBuf::from("."));+ let dir = data.join("wake");+ let db = dir.join("wake.db");+ if !db.exists() {+ let old_db = data.join("vibex").join("vibex-rs.db");+ if old_db.exists() {+ let _ = std::fs::create_dir_all(&dir);+ for suffix in ["", "-wal", "-shm"] {+ let src = data.join("vibex").join(format!("vibex-rs.db{suffix}"));+ if src.exists() {+ let _ = std::fs::copy(&src, dir.join(format!("wake.db{suffix}")));+ }+ }+ }+ }+ db+}diff --git a/crates/wake-core/src/lib.rs b/crates/wake-core/src/lib.rsnew file mode 100644index 0000000..704ba9c--- /dev/null+++ b/crates/wake-core/src/lib.rs@@ -0,0 +1,6 @@+pub mod adapters;+pub mod db;+pub mod models;+pub mod scanner;+pub mod services;+pub mod watcher;diff --git a/crates/wake-core/src/models.rs b/crates/wake-core/src/models.rsnew file mode 100644index 0000000..4c30b75--- /dev/null+++ b/crates/wake-core/src/models.rs@@ -0,0 +1,271 @@+use serde::{Deserialize, Serialize};++#[derive(Debug, Clone, Copy, PartialEq, Eq, Hash, Serialize, Deserialize)]+#[serde(rename_all = "kebab-case")]+pub enum AgentId {+ ClaudeCode,+ Codex,+ Copilot,+ Cursor,+ Opencode,+ Kiro,+ Gemini,+}++impl AgentId {+ pub fn as_str(&self) -> &'static str {+ match self {+ AgentId::ClaudeCode => "claude-code",+ AgentId::Codex => "codex",+ AgentId::Copilot => "copilot",+ AgentId::Cursor => "cursor",+ AgentId::Opencode => "opencode",+ AgentId::Kiro => "kiro",+ AgentId::Gemini => "gemini",+ }+ }++ pub fn from_str(s: &str) -> Option<Self> {+ match s {+ "claude-code" => Some(AgentId::ClaudeCode),+ "codex" => Some(AgentId::Codex),+ "copilot" => Some(AgentId::Copilot),+ "cursor" => Some(AgentId::Cursor),+ "opencode" => Some(AgentId::Opencode),+ "kiro" => Some(AgentId::Kiro),+ "gemini" => Some(AgentId::Gemini),+ _ => None,+ }+ }++ pub fn display_name(&self) -> &'static str {+ match self {+ AgentId::ClaudeCode => "Claude Code",+ AgentId::Codex => "Codex",+ AgentId::Copilot => "Copilot CLI",+ AgentId::Cursor => "Cursor",+ AgentId::Opencode => "OpenCode",+ AgentId::Kiro => "Kiro",+ AgentId::Gemini => "Gemini CLI",+ }+ }++ /// agent 品牌图标——wake crate `Assets` 内嵌的 PNG 路径(lobe-icons 素材,+ /// 与 kooky 同源)。后缀必须带上(与 SVG 图标同理,漏后缀 = 静默空白)。+ /// Copilot/Cursor/OpenCode 是单色字形(白色+alpha):深色模式用白色版,+ /// 浅色模式用 `-light`(深墨 #2B2A26)版——等效 kooky 的 template 染色;+ /// 彩色品牌(Claude/Codex/Gemini/Kiro)保持原色,两模式通用。+ pub fn brand_icon(&self, dark: bool) -> &'static str {+ match self {+ AgentId::ClaudeCode => "brands/claude-code.png",+ AgentId::Codex => "brands/codex.png",+ AgentId::Copilot => {+ if dark { "brands/copilot.png" } else { "brands/copilot-light.png" }+ }+ AgentId::Cursor => {+ if dark { "brands/cursor.png" } else { "brands/cursor-light.png" }+ }+ AgentId::Opencode => {+ if dark { "brands/opencode.png" } else { "brands/opencode-light.png" }+ }+ AgentId::Kiro => "brands/kiro.png",+ AgentId::Gemini => "brands/gemini.png",+ }+ }++}++/// 会话元数据 —— 列表页/索引库统一模型+#[derive(Debug, Clone, Serialize, Deserialize)]+pub struct SessionMeta {+ /// 全局唯一键: `{agent}:{native_id}`+ pub key: String,+ /// 原生会话 id(resume 用)+ pub id: String,+ pub agent: AgentId,+ pub title: String,+ pub project_path: String,+ pub project_name: String,+ pub file_path: String,+ /// epoch ms+ pub created_at: i64,+ pub updated_at: i64,+ pub message_count: i64,+ pub size_bytes: i64,+ pub git_branch: Option<String>,+ pub model: Option<String>,+ pub tokens_used: Option<i64>,+ pub archived: bool,+ pub source: Option<String>,+ // app 自有状态(user_data 表)+ pub favorite: bool,+ pub pinned: bool,+}++#[derive(Debug, Clone, Serialize, Deserialize)]+pub struct ToolCallView {+ pub id: String,+ pub name: String,+ pub input_preview: String,+ pub input: Option<String>,+ pub output: Option<String>,+ pub is_error: bool,+ pub sidechain_ref: Option<String>,+}++#[derive(Debug, Clone, Copy, PartialEq, Eq, Serialize, Deserialize)]+#[serde(rename_all = "kebab-case")]+pub enum MessageKind {+ Text,+ Meta,+ CompactSummary,+}++#[derive(Debug, Clone, Copy, PartialEq, Eq, Serialize, Deserialize)]+#[serde(rename_all = "lowercase")]+pub enum Role {+ User,+ Assistant,+ System,+}++impl Role {+ pub fn as_str(&self) -> &'static str {+ match self {+ Role::User => "user",+ Role::Assistant => "assistant",+ Role::System => "system",+ }+ }+}++/// 详情页统一消息模型+#[derive(Debug, Clone, Serialize, Deserialize)]+pub struct TranscriptMessage {+ /// 会话内稳定序号(搜索定位锚点)+ pub seq: i64,+ pub role: Role,+ pub kind: MessageKind,+ pub text: String,+ pub truncated: bool,+ pub tool_calls: Vec<ToolCallView>,+ pub thinking: Option<String>,+ /// epoch ms+ pub timestamp: Option<i64>,+ pub model: Option<String>,+}++#[derive(Debug, Clone, Serialize, Deserialize)]+pub struct SidechainInfo {+ pub id: String,+ pub agent_type: Option<String>,+ pub description: Option<String>,+ pub tool_use_id: Option<String>,+}++#[derive(Debug, Clone)]+pub struct ParsedTranscript {+ pub meta: SessionMeta,+ pub mainline: Vec<TranscriptMessage>,+ pub sidechains: Vec<SidechainInfo>,+ pub unknown_line_count: u32,+}++/// FTS 索引单元(从解析后消息派生,seq 与详情页一致)+#[derive(Debug, Clone)]+pub struct IndexUnit {+ pub seq: i64,+ pub sidechain_id: Option<String>,+ pub role: Role,+ pub timestamp: Option<i64>,+ pub text: String,+}++#[derive(Debug, Clone)]+pub struct SessionFileRef {+ pub agent: AgentId,+ pub native_id: String,+ pub file_path: String,+ pub mtime_ms: i64,+ pub size: i64,+}++impl SessionFileRef {+ /// 从库内 meta 重建(打开详情/导出等 UI 入口共用)。SQLite 型会话的+ /// file_path 是虚拟路径(`<db>#<id>`),stat 失败时回退库内时间与大小。+ pub fn from_meta(meta: &SessionMeta) -> Self {+ let stat = std::fs::metadata(&meta.file_path).ok();+ Self {+ agent: meta.agent,+ native_id: meta.id.clone(),+ file_path: meta.file_path.clone(),+ mtime_ms: stat+ .as_ref()+ .and_then(|m| m.modified().ok())+ .and_then(|t| t.duration_since(std::time::UNIX_EPOCH).ok())+ .map(|d| d.as_millis() as i64)+ .unwrap_or(meta.updated_at),+ size: stat.map(|m| m.len() as i64).unwrap_or(meta.size_bytes),+ }+ }+}++#[derive(Debug, Clone)]+pub struct ParsedSession {+ pub meta: SessionMeta,+ pub units: Vec<IndexUnit>,+ pub unknown_line_count: u32,+}++#[derive(Debug, Clone, Default)]+pub struct SessionFilter {+ pub agents: Vec<AgentId>,+ pub project_path: Option<String>,+ pub favorite_only: bool,+ pub include_archived: bool,+ pub title_query: Option<String>,+ pub sort: SortKey,+ /// false = 降序(默认,新到旧/多到少)+ pub ascending: bool,+ pub limit: i64,+ pub offset: i64,+}++#[derive(Debug, Clone, Copy, PartialEq, Eq, Default)]+pub enum SortKey {+ #[default]+ Updated,+ Created,+ Messages,+}++#[derive(Debug, Clone)]+pub struct ProjectInfo {+ pub path: String,+ pub name: String,+ pub session_count: i64,+ pub last_active: i64,+}++#[derive(Debug, Clone)]+pub struct SearchHit {+ pub session: SessionMeta,+ pub seq: i64,+ pub sidechain_id: Option<String>,+ pub role: String,+ pub snippet: String,+ pub timestamp: Option<i64>,+}++/// 搜索 snippet 高亮哨兵(UI 层替换为高亮样式)+pub const HL_OPEN: char = '\u{e000}';+pub const HL_CLOSE: char = '\u{e001}';++/// 单条消息正文入库/传输上限+pub const MAX_MSG_TEXT: usize = 32 * 1024;+/// tool 输入/输出、thinking 上限+pub const MAX_TOOL_IO: usize = 16 * 1024;+pub const MAX_TITLE: usize = 80;++/// 无标题会话的占位标题(quickMeta 守卫与 adapters 共用,防半/全角漂移)+pub const UNTITLED: &str = "Untitled";diff --git a/crates/wake-core/src/scanner.rs b/crates/wake-core/src/scanner.rsnew file mode 100644index 0000000..88d5272--- /dev/null+++ b/crates/wake-core/src/scanner.rs@@ -0,0 +1,225 @@+use crate::adapters::AgentAdapter;+use crate::db::Store;+use crate::models::*;+use anyhow::Result;+use std::sync::Arc;++#[derive(Debug, Clone, Default)]+pub struct ScanProgress {+ pub scanning: bool,+ pub done: usize,+ pub total: usize,+ pub error: Option<String>,+}++/// 扫描回调:进度更新 / 会话数据有变化(UI 应刷新)+pub trait ScanEvents: Send + Sync {+ fn on_progress(&self, p: &ScanProgress);+ fn on_sessions_changed(&self);+}++pub struct NullEvents;+impl ScanEvents for NullEvents {+ fn on_progress(&self, _: &ScanProgress) {}+ fn on_sessions_changed(&self) {}+}++/// 扫描收尾守卫:Drop 时必定发出一次 `scanning = false` 的终态进度事件。+///+/// UI 的模态刷新弹窗把三条关闭路径全关了(close_button / overlay_closable /+/// keyboard),只认这个事件收场——扫描中途离开而没发终态,界面就被永久锁死。+/// 把它挂在 Drop 上,提前 `?` 与 panic unwind 就都兜得住,"必发"由类型保证,+/// 不再依赖后来者记得在每条返回路径上补一句。+struct ScanFinale<'a> {+ events: &'a dyn ScanEvents,+ progress: ScanProgress,+ /// 正常收尾时置 true;panic unwind 会让它保持 false,Drop 借此区分两种收场+ graceful: bool,+}++impl Drop for ScanFinale<'_> {+ fn drop(&mut self) {+ self.progress.scanning = false;+ if !self.graceful {+ self.progress.error = Some("Scan stopped unexpectedly".into());+ }+ self.events.on_progress(&self.progress);+ }+}++/// 全量/增量扫描。quickMeta 先行秒出列表,然后按 mtime 降序逐文件解析。+/// 阻塞执行——调用方放后台线程。进度与终态一律经 `events` 上报,终态由+/// `ScanFinale` 保证送达;返回的 `Result` 只用于调用方自己记日志。+pub fn run_scan(+ adapters: &[Box<dyn AgentAdapter>],+ store: &Arc<Store>,+ events: &dyn ScanEvents,+ full: bool,+) -> Result<()> {+ let mut fin = ScanFinale {+ events,+ progress: ScanProgress {+ scanning: true,+ ..Default::default()+ },+ graceful: false,+ };+ events.on_progress(&fin.progress);++ let result = run_scan_inner(adapters, store, events, full, &mut fin.progress);+ fin.progress.error = result.as_ref().err().map(|e| e.to_string());+ fin.graceful = true;+ result+}++fn run_scan_inner(+ adapters: &[Box<dyn AgentAdapter>],+ store: &Arc<Store>,+ events: &dyn ScanEvents,+ full: bool,+ progress: &mut ScanProgress,+) -> Result<()> {+ let known = store.known_files()?;+ let mut seen_paths: std::collections::HashSet<String> = std::collections::HashSet::new();+ struct WorkItem<'a> {+ adapter: &'a dyn AgentAdapter,+ r: SessionFileRef,+ quick: Option<SessionMeta>,+ }+ let mut queue: Vec<WorkItem> = Vec::new();++ for adapter in adapters {+ let refs: Vec<SessionFileRef> = adapter+ .list_session_files()?+ .into_iter()+ .filter(|r| !store.is_tombstoned(&r.file_path))+ .collect();+ for r in &refs {+ seen_paths.insert(r.file_path.clone());+ }++ // 快路径:新/变化的先写 meta 让列表立即可见+ let quick_map = adapter.quick_meta(&refs);+ if let Some(map) = &quick_map {+ let fresh: Vec<(SessionMeta, i64)> = refs+ .iter()+ .filter_map(|r| {+ let meta = map.get(&r.file_path)?;+ let changed = match known.get(&r.file_path) {+ None => true,+ Some((mtime, size, _)) => *mtime != r.mtime_ms || *size != r.size,+ };+ if changed || full {+ // fileMtime=0 → 后续全量解析仍会执行+ Some((meta.clone(), 0))+ } else {+ None+ }+ })+ .collect();+ if !fresh.is_empty() {+ store.write_meta_only(&fresh)?;+ events.on_sessions_changed();+ }+ }++ for r in refs {+ let changed = match known.get(&r.file_path) {+ None => true,+ Some((mtime, size, _)) => *mtime != r.mtime_ms || *size != r.size,+ };+ if full || changed {+ let quick = quick_map.as_ref().and_then(|m| m.get(&r.file_path).cloned());+ queue.push(WorkItem {+ adapter: adapter.as_ref(),+ r,+ quick,+ });+ }+ }+ }++ // 删除检测:库里有但磁盘没了+ for (path, (_, _, key)) in &known {+ if !seen_paths.contains(path) {+ let _ = store.remove_session(key, false);+ }+ }++ // 最近的会话优先+ queue.sort_by(|a, b| b.r.mtime_ms.cmp(&a.r.mtime_ms));+ progress.total = queue.len();+ events.on_progress(progress);++ let mut last_notify = std::time::Instant::now();+ for item in &queue {+ match item.adapter.parse_session(&item.r) {+ Ok(parsed) => {+ // quick/parsed 合并策略属各 adapter(默认 parsed 为准 quick 补缺,+ // Codex 覆写 title/key 优先级),scanner 不再内嵌任何 agent 特例+ let meta = match &item.quick {+ Some(q) => item.adapter.merge_quick_meta(parsed.meta, q),+ None => parsed.meta,+ };+ if let Err(e) = store.write_session(&meta, item.r.mtime_ms, &parsed.units) {+ eprintln!("[scanner] write failed {}: {e}", item.r.file_path);+ }+ }+ Err(e) => eprintln!("[scanner] parse failed {}: {e}", item.r.file_path),+ }+ progress.done += 1;+ if last_notify.elapsed().as_millis() > 800 || progress.done == progress.total {+ last_notify = std::time::Instant::now();+ events.on_progress(progress);+ events.on_sessions_changed();+ }+ }++ Ok(())+}++/// watcher 触发的单文件增量。与 run_scan 走同一道 quick/parsed 合并——+/// 跳过它,Codex 在 state DB 里被用户手动命名的标题就会被首条消息推导的+/// 标题静默覆盖(跨文件不变量 5:quickMeta 双路径)。+pub fn scan_files(+ adapters: &[Box<dyn AgentAdapter>],+ store: &Arc<Store>,+ events: &dyn ScanEvents,+ refs: Vec<SessionFileRef>,+) {+ // 按 agent 分组:quick_meta 是整库查询(Codex 要开 state DB 读整张 threads),+ // 每组只查一次,不能逐文件调+ let mut by_agent: std::collections::HashMap<AgentId, Vec<SessionFileRef>> =+ std::collections::HashMap::new();+ for r in refs {+ if store.is_tombstoned(&r.file_path) {+ continue;+ }+ by_agent.entry(r.agent).or_default().push(r);+ }++ let mut changed = false;+ for (agent, group) in by_agent {+ let Some(adapter) = adapters.iter().find(|a| a.agent() == agent) else {+ continue;+ };+ let quick = adapter.quick_meta(&group);+ for r in &group {+ match adapter.parse_session(r) {+ Ok(parsed) => {+ let meta = match quick.as_ref().and_then(|m| m.get(&r.file_path)) {+ Some(q) => adapter.merge_quick_meta(parsed.meta, q),+ None => parsed.meta,+ };+ if store.write_session(&meta, r.mtime_ms, &parsed.units).is_ok() {+ changed = true;+ }+ }+ Err(e) => eprintln!("[scanner] incremental parse failed {}: {e}", r.file_path),+ }+ }+ }+ if changed {+ events.on_sessions_changed();+ }+}diff --git a/crates/wake-core/src/services/exporter.rs b/crates/wake-core/src/services/exporter.rsnew file mode 100644index 0000000..67e8d7b--- /dev/null+++ b/crates/wake-core/src/services/exporter.rs@@ -0,0 +1,163 @@+use crate::models::*;+use chrono::{Local, TimeZone};++fn fmt_time(ts: Option<i64>) -> String {+ match ts {+ Some(t) if t > 0 => Local+ .timestamp_millis_opt(t)+ .single()+ .map(|d| d.format("%Y-%m-%d %H:%M:%S").to_string())+ .unwrap_or_default(),+ _ => String::new(),+ }+}++pub fn fmt_tokens(n: Option<i64>) -> String {+ match n {+ None | Some(0) => "-".to_string(),+ Some(n) if n >= 1_000_000_000 => format!("{:.1}B", n as f64 / 1e9),+ Some(n) if n >= 1_000_000 => format!("{:.1}M", n as f64 / 1e6),+ Some(n) if n >= 1_000 => format!("{:.1}K", n as f64 / 1e3),+ Some(n) => n.to_string(),+ }+}++fn role_label(role: Role) -> &'static str {+ match role {+ Role::User => "👤 User",+ Role::Assistant => "🤖 Assistant",+ Role::System => "⚙️ System",+ }+}++fn render_message(m: &TranscriptMessage, out: &mut String) {+ out.push_str(&format!(+ "### {}{}\n\n",+ role_label(m.role),+ m.timestamp+ .map(|t| format!(" · {}", fmt_time(Some(t))))+ .unwrap_or_default()+ ));+ if m.kind == MessageKind::CompactSummary {+ out.push_str(&format!("> {}\n\n", m.text));+ return;+ }+ if let Some(th) = &m.thinking {+ out.push_str(&format!("<details><summary>🧠 Thinking</summary>\n\n{th}\n\n</details>\n\n"));+ }+ if !m.text.is_empty() {+ out.push_str(&m.text);+ out.push_str("\n\n");+ }+ for tc in &m.tool_calls {+ out.push_str(&format!(+ "<details><summary>🔧 {} — {}</summary>\n\n",+ tc.name,+ tc.input_preview.replace('<', "<")+ ));+ if let Some(input) = &tc.input {+ out.push_str(&format!("Input:\n\n```\n{input}\n```\n\n"));+ }+ if let Some(output) = &tc.output {+ out.push_str(&format!("Output:\n\n```\n{output}\n```\n\n"));+ }+ out.push_str("</details>\n\n");+ }+}++pub fn to_markdown(+ meta: &SessionMeta,+ messages: &[TranscriptMessage],+ sidechains: &[(SidechainInfo, Vec<TranscriptMessage>)],+) -> String {+ let mut out = String::new();+ out.push_str(&format!("# {}\n\n", meta.title));+ out.push_str(&format!(+ "> **Agent**: {} · **Project**: {}{} · **Time**: {} – {} · **Messages**: {} · **Tokens**: {}\n\n---\n\n",+ meta.agent.display_name(),+ if meta.project_path.is_empty() { "(unknown)" } else { &meta.project_path },+ meta.git_branch.as_deref().map(|b| format!("({b})")).unwrap_or_default(),+ fmt_time(Some(meta.created_at)),+ fmt_time(Some(meta.updated_at)),+ meta.message_count,+ fmt_tokens(meta.tokens_used),+ ));+ for m in messages {+ if m.kind == MessageKind::Meta {+ continue;+ }+ render_message(m, &mut out);+ }+ for (sc, msgs) in sidechains {+ if msgs.is_empty() {+ continue;+ }+ let label = [sc.agent_type.as_deref(), sc.description.as_deref()]+ .iter()+ .flatten()+ .copied()+ .collect::<Vec<_>>()+ .join(":");+ out.push_str(&format!(+ "---\n\n## ⑂ Subagent: {}\n\n",+ if label.is_empty() { &sc.id } else { &label }+ ));+ for m in msgs {+ if m.kind == MessageKind::Meta {+ continue;+ }+ render_message(m, &mut out);+ }+ }+ out+}++pub fn to_json(+ meta: &SessionMeta,+ messages: &[TranscriptMessage],+ sidechains: &[(SidechainInfo, Vec<TranscriptMessage>)],+) -> String {+ let sc_json: Vec<serde_json::Value> = sidechains+ .iter()+ .map(|(sc, msgs)| {+ serde_json::json!({+ "id": sc.id, "agentType": sc.agent_type, "description": sc.description,+ "messages": msgs,+ })+ })+ .collect();+ serde_json::to_string_pretty(&serde_json::json!({+ "exportedAt": chrono::Utc::now().to_rfc3339(),+ "exportedBy": "wake",+ "session": meta,+ "messages": messages,+ "sidechains": sc_json,+ }))+ .unwrap_or_default()+}++/// 导出默认文件名:agent-标题-日期.ext+pub fn default_file_name(meta: &SessionMeta, ext: &str) -> String {+ let title: String = meta+ .title+ .chars()+ .filter(|c| !r#"/\:*?"<>|"#.contains(*c))+ .collect::<String>()+ .split_whitespace()+ .collect::<Vec<_>>()+ .join(" ")+ .chars()+ .take(40)+ .collect();+ let date = Local+ .timestamp_millis_opt(if meta.updated_at > 0 { meta.updated_at } else { crate::db::now_ms() })+ .single()+ .map(|d| d.format("%Y%m%d").to_string())+ .unwrap_or_default();+ format!(+ "{}-{}-{}.{ext}",+ meta.agent.as_str(),+ if title.is_empty() { "session" } else { &title },+ date+ )+}diff --git a/crates/wake-core/src/services/mod.rs b/crates/wake-core/src/services/mod.rsnew file mode 100644index 0000000..43c80ef--- /dev/null+++ b/crates/wake-core/src/services/mod.rs@@ -0,0 +1,2 @@+pub mod exporter;+pub mod terminal;diff --git a/crates/wake-core/src/services/terminal.rs b/crates/wake-core/src/services/terminal.rsnew file mode 100644index 0000000..f61cf98--- /dev/null+++ b/crates/wake-core/src/services/terminal.rs@@ -0,0 +1,462 @@+use crate::models::{AgentId, SessionMeta};+use std::collections::HashMap;+use std::path::Path;+use std::process::Command;+use std::sync::Mutex;++#[derive(Debug, Clone)]+pub struct ResumeOutcome {+ pub ok: bool,+ pub command: String,+ pub error: Option<String>,+}++/// GUI 进程 PATH 不含 ~/.local/bin 等,经 login shell 批量解析并缓存+static CLI_CACHE: Mutex<Option<HashMap<String, Option<String>>>> = Mutex::new(None);++fn resolve_clis(bins: &[&str]) -> HashMap<String, Option<String>> {+ let mut cache = CLI_CACHE.lock().unwrap();+ let map = cache.get_or_insert_with(HashMap::new);+ let missing: Vec<&str> = bins.iter().filter(|b| !map.contains_key(**b)).copied().collect();+ if !missing.is_empty() {+ let script = missing+ .iter()+ .map(|b| format!("printf '%s\\t' {b}; command -v {b} || echo"))+ .collect::<Vec<_>>()+ .join("; ");+ let out = Command::new("/bin/zsh").args(["-lic", &script]).output();+ let stdout = out+ .ok()+ .map(|o| String::from_utf8_lossy(&o.stdout).to_string())+ .unwrap_or_default();+ let mut found: HashMap<&str, String> = HashMap::new();+ for line in stdout.lines() {+ if let Some((name, path)) = line.split_once('\t') {+ if path.starts_with('/') {+ found.insert(name.trim(), path.trim().to_string());+ }+ }+ }+ for b in missing {+ map.insert(b.to_string(), found.get(b).cloned());+ }+ }+ bins.iter()+ .map(|b| (b.to_string(), map.get(*b).cloned().flatten()))+ .collect()+}++pub fn cli_path(agent: AgentId) -> Option<String> {+ let bin = agent_bin(agent)?;+ resolve_clis(&[bin]).get(bin).cloned().flatten()+}++pub fn agent_bin(agent: AgentId) -> Option<&'static str> {+ match agent {+ AgentId::ClaudeCode => Some("claude"),+ AgentId::Codex => Some("codex"),+ AgentId::Copilot => Some("copilot"),+ AgentId::Cursor => Some("cursor-agent"),+ AgentId::Opencode => Some("opencode"),+ AgentId::Kiro => Some("kiro"),+ AgentId::Gemini => Some("gemini"),+ }+}++fn resume_args(agent: AgentId, id: &str) -> Option<(Vec<String>, bool)> {+ match agent {+ AgentId::ClaudeCode => Some((vec!["--resume".into(), id.into()], true)),+ AgentId::Codex => Some((vec!["resume".into(), id.into()], false)),+ AgentId::Copilot => Some((vec![format!("--resume={id}")], false)),+ AgentId::Cursor => Some((vec!["--resume".into(), id.into()], false)),+ _ => None,+ }+}++/// POSIX 单引号 quote+pub fn posix_quote(s: &str) -> String {+ if !s.is_empty()+ && s.chars()+ .all(|c| c.is_ascii_alphanumeric() || "_-./:=".contains(c))+ {+ return s.to_string();+ }+ format!("'{}'", s.replace('\'', r"'\''"))+}++/// AppleScript 双引号字符串转义+pub fn applescript_quote(s: &str) -> String {+ s.replace('\\', r"\\").replace('"', r#"\""#)+}++fn osascript(lines: &[String]) -> std::io::Result<std::process::Output> {+ let mut cmd = Command::new("osascript");+ for l in lines {+ cmd.args(["-e", l]);+ }+ cmd.output()+}++/// Open In 下拉的目标终端。只列本机实际安装且可程序化注入命令的+/// (Tabby 等无稳定命令接口的不做)。+#[derive(Debug, Clone, Copy, PartialEq, Eq)]+pub enum TerminalApp {+ Terminal,+ ITerm,+ Warp,+ Ghostty,+ /// 用户自己的 agent 宿主 app。暂无外部接口(无 URL scheme、不收 open+ /// 参数),只能激活应用,不能带会话跳转。+ Kooky,+}++impl TerminalApp {+ pub fn display_name(&self) -> &'static str {+ match self {+ TerminalApp::Terminal => "Terminal",+ TerminalApp::ITerm => "iTerm",+ TerminalApp::Warp => "Warp",+ TerminalApp::Ghostty => "Ghostty",+ TerminalApp::Kooky => "Kooky",+ }+ }++ /// 稳定短 id(图标缓存文件名、last-used 记忆用)+ pub fn id(&self) -> &'static str {+ match self {+ TerminalApp::Terminal => "terminal",+ TerminalApp::ITerm => "iterm",+ TerminalApp::Warp => "warp",+ TerminalApp::Ghostty => "ghostty",+ TerminalApp::Kooky => "kooky",+ }+ }++ /// 已安装的 .app 绝对路径(首个命中)+ pub fn resolved_app_path(&self) -> Option<std::path::PathBuf> {+ let candidates: &[&str] = match self {+ TerminalApp::Terminal => &["/System/Applications/Utilities/Terminal.app"],+ TerminalApp::ITerm => &["/Applications/iTerm.app"],+ TerminalApp::Warp => &["/Applications/Warp.app"],+ TerminalApp::Ghostty => &["/Applications/Ghostty.app"],+ TerminalApp::Kooky => &["/Applications/Kooky.app"],+ };+ for p in candidates {+ let p = std::path::PathBuf::from(p);+ if p.is_dir() {+ return Some(p);+ }+ }+ let home_app = dirs::home_dir()+ .unwrap_or_default()+ .join("Applications")+ .join(format!("{}.app", self.display_name()));+ home_app.is_dir().then_some(home_app)+ }++ fn is_installed(&self) -> bool {+ self.resolved_app_path().is_some()+ }++ /// 目标消费什么:shell 命令串,还是会话深链。新增非 shell 目标时+ /// 在此声明,resume_session_in 无需再加旁路。+ fn launch_mode(&self) -> Launch {+ match self {+ TerminalApp::Terminal => Launch::Shell(launch_terminal_app),+ TerminalApp::ITerm => Launch::Shell(launch_iterm),+ TerminalApp::Warp => Launch::Shell(launch_warp),+ TerminalApp::Ghostty => Launch::Shell(launch_ghostty),+ TerminalApp::Kooky => Launch::DeepLink,+ }+ }+}++enum Launch {+ /// 在该终端里执行拼好的 shell 命令+ Shell(fn(&str) -> anyhow::Result<()>),+ /// 走会话深链(kooky://),不经过 agent CLI+ DeepLink,+}++/// 确保已装终端的应用图标提取到 `cache_dir/<id>.png`(64px),返回 id → 路径。+/// JXA 走 NSWorkspace.iconForFile,icns/Assets.car 格式都拿得到;已存在直接+/// 复用。阻塞数百 ms,调用方放后台线程。+pub fn ensure_app_icons(cache_dir: &Path) -> HashMap<String, std::path::PathBuf> {+ let _ = std::fs::create_dir_all(cache_dir);+ let mut out = HashMap::new();+ let mut jobs: Vec<(TerminalApp, std::path::PathBuf)> = Vec::new();+ for t in installed_terminals() {+ let png = cache_dir.join(format!("{}.png", t.id()));+ if png.is_file() {+ out.insert(t.id().to_string(), png);+ } else {+ jobs.push((*t, png));+ }+ }+ if jobs.is_empty() {+ return out;+ }+ let mut script =+ String::from("ObjC.import('AppKit');\nconst ws = $.NSWorkspace.sharedWorkspace;\n");+ for (t, png) in &jobs {+ let Some(app) = t.resolved_app_path() else { continue };+ script.push_str(&format!(+ "{{ const i = ws.iconForFile('{app}'); const rep = $.NSBitmapImageRep.imageRepWithData(i.TIFFRepresentation); \+ const png = rep.representationUsingTypeProperties(4, $.NSDictionary.dictionary); \+ png.writeToFileAtomically('{out}', true); }}\n",+ app = app.display(),+ out = png.display(),+ ));+ }+ let ok = Command::new("osascript")+ .args(["-l", "JavaScript", "-e", &script])+ .output()+ .map(|o| o.status.success())+ .unwrap_or(false);+ if ok {+ for (t, png) in &jobs {+ if png.is_file() {+ // NSWorkspace 给的是 1024px,缩到 64 省内存;缩失败原图也能用+ let _ = Command::new("sips").args(["-Z", "64"]).arg(png).output();+ out.insert(t.id().to_string(), png.clone());+ }+ }+ }+ out+}++/// 已安装终端(启动后不变,进程内缓存)+pub fn installed_terminals() -> &'static [TerminalApp] {+ use std::sync::OnceLock;+ static CACHE: OnceLock<Vec<TerminalApp>> = OnceLock::new();+ CACHE.get_or_init(|| {+ [+ TerminalApp::Terminal,+ TerminalApp::Kooky,+ TerminalApp::ITerm,+ TerminalApp::Warp,+ TerminalApp::Ghostty,+ ]+ .into_iter()+ .filter(|t| t.is_installed())+ .collect()+ })+}++fn launch_terminal_app(command: &str) -> anyhow::Result<()> {+ let esc = applescript_quote(command);+ let out = osascript(&[+ "tell application \"Terminal\" to activate".to_string(),+ format!("tell application \"Terminal\" to do script \"{esc}\""),+ ])?;+ if !out.status.success() {+ anyhow::bail!("{}", String::from_utf8_lossy(&out.stderr));+ }+ Ok(())+}++fn launch_iterm(command: &str) -> anyhow::Result<()> {+ let esc = applescript_quote(command);+ let out = osascript(&[+ "tell application \"iTerm\" to activate".to_string(),+ "tell application \"iTerm\" to create window with default profile".to_string(),+ format!("tell current session of current window of application \"iTerm\" to write text \"{esc}\""),+ ])?;+ if !out.status.success() {+ anyhow::bail!("{}", String::from_utf8_lossy(&out.stderr));+ }+ Ok(())+}++/// Ghostty:open --args 直传 argv,无二次 shell 解析;命令跑完 exec 交互+/// shell 保持窗口+fn launch_ghostty(command: &str) -> anyhow::Result<()> {+ let status = Command::new("open")+ .args([+ "-na",+ "Ghostty",+ "--args",+ "-e",+ "/bin/zsh",+ "-lic",+ &format!("{command}; exec /bin/zsh -il"),+ ])+ .status()?;+ if !status.success() {+ anyhow::bail!("open -na Ghostty failed");+ }+ Ok(())+}++/// Warp 无命令注入 CLI,走官方 Launch Configuration:写临时 yaml 再+/// open warp://launch/<path>。exec 用 yaml 块标量,免转义。+fn launch_warp(command: &str) -> anyhow::Result<()> {+ if command.contains('\n') {+ anyhow::bail!("multi-line command");+ }+ let yaml = format!(+ "name: Wake Resume\nwindows:\n - tabs:\n - layout:\n commands:\n - exec: |-\n {command}\n"+ );+ let path = std::env::temp_dir().join("wake-warp-resume.yaml");+ std::fs::write(&path, yaml)?;+ let status = Command::new("open")+ .arg(format!("warp://launch/{}", path.display()))+ .status()?;+ if !status.success() {+ anyhow::bail!("open warp:// failed");+ }+ Ok(())+}++fn copy_to_clipboard(text: &str) {+ use std::io::Write;+ if let Ok(mut child) = Command::new("pbcopy").stdin(std::process::Stdio::piped()).spawn() {+ if let Some(stdin) = child.stdin.as_mut() {+ let _ = stdin.write_all(text.as_bytes());+ }+ let _ = child.wait();+ }+}++/// query 值的保守 percent-encode(unreserved 之外全编)+fn percent_encode_query(s: &str) -> String {+ let mut out = String::with_capacity(s.len());+ for b in s.bytes() {+ match b {+ b'A'..=b'Z' | b'a'..=b'z' | b'0'..=b'9' | b'-' | b'.' | b'_' | b'~' => {+ out.push(b as char)+ }+ _ => out.push_str(&format!("%{b:02X}")),+ }+ }+ out+}++/// Kooky 深链恢复(kooky://resume,约定见 kooky 的 DeepLink.swift):+/// id 校验与 kooky 端同规则;深链失败(未发布的旧版没注册 scheme)退回激活应用。+/// 不依赖 agent CLI——kooky 自己会起 agent。+fn launch_kooky(meta: &SessionMeta) -> ResumeOutcome {+ let id_ok = meta.id.chars().next().is_some_and(|c| c.is_ascii_alphanumeric())+ && meta.id.len() <= 200+ && meta+ .id+ .chars()+ .all(|c| c.is_ascii_alphanumeric() || matches!(c, '_' | '.' | '-'));+ if id_ok {+ let mut url = format!("kooky://resume?agent={}&id={}", meta.agent.as_str(), meta.id);+ if !meta.project_path.is_empty() && Path::new(&meta.project_path).is_dir() {+ url.push_str("&cwd=");+ url.push_str(&percent_encode_query(&meta.project_path));+ }+ let deep_ok = Command::new("open")+ .arg(&url)+ .output()+ .map(|o| o.status.success())+ .unwrap_or(false);+ if deep_ok {+ return ResumeOutcome { ok: true, command: url, error: None };+ }+ }+ let ok = Command::new("open")+ .args(["-a", "Kooky"])+ .status()+ .map(|s| s.success())+ .unwrap_or(false);+ ResumeOutcome {+ ok,+ command: "open -a Kooky (deep link unavailable in this Kooky build)".into(),+ error: (!ok).then(|| "Couldn't open Kooky".to_string()),+ }+}++pub fn resume_session_in(meta: &SessionMeta, term: TerminalApp) -> ResumeOutcome {+ // 深链目标不走 shell 命令构建(不依赖 agent CLI)+ let Launch::Shell(run) = term.launch_mode() else {+ return launch_kooky(meta);+ };+ let Some((args, requires_cwd)) = resume_args(meta.agent, &meta.id) else {+ return ResumeOutcome {+ ok: false,+ command: String::new(),+ error: Some(format!("Resume isn't supported for {} yet", meta.agent.display_name())),+ };+ };+ let Some(cli) = cli_path(meta.agent) else {+ return ResumeOutcome {+ ok: false,+ command: String::new(),+ error: Some(format!(+ "Command {} not found — is it installed?",+ agent_bin(meta.agent).unwrap_or("?")+ )),+ };+ };+ let cwd_ok = !meta.project_path.is_empty() && Path::new(&meta.project_path).is_dir();+ let core = std::iter::once(cli.as_str())+ .chain(args.iter().map(|s| s.as_str()))+ .map(posix_quote)+ .collect::<Vec<_>>()+ .join(" ");+ let command = if cwd_ok {+ format!("cd {} && {core}", posix_quote(&meta.project_path))+ } else {+ core+ };+ if requires_cwd && !cwd_ok {+ copy_to_clipboard(&command);+ return ResumeOutcome {+ ok: false,+ command,+ error: Some(format!("Project directory no longer exists: {} (command copied — run it manually)", meta.project_path)),+ };+ }++ let result = run(&command);+ match result {+ Ok(()) => ResumeOutcome {+ ok: true,+ command,+ error: None,+ },+ Err(e) => {+ copy_to_clipboard(&command);+ ResumeOutcome {+ ok: false,+ command,+ error: Some(format!("Couldn't open terminal ({e}). Command copied to clipboard — paste to run.")),+ }+ }+ }+}++/// 删除会话文件到废纸篓(macOS 用 Finder,可从废纸篓恢复)+pub fn trash_paths(paths: &[String]) -> anyhow::Result<()> {+ for p in paths {+ if !Path::new(p).exists() {+ continue;+ }+ let esc = applescript_quote(p);+ let out = osascript(&[format!(+ "tell application \"Finder\" to delete (POSIX file \"{esc}\" as alias)"+ )])?;+ if !out.status.success() {+ anyhow::bail!("Failed to move to Trash: {}", String::from_utf8_lossy(&out.stderr));+ }+ }+ Ok(())+}++/// 致命错误提示。GPUI 窗口还没起来时这是唯一能让用户看见的通道,+/// 否则应用就是无提示秒退。换行先压平——AppleScript 字符串字面量不能跨行。+pub fn show_fatal_alert(message: &str) {+ eprintln!("[wake] fatal: {message}");+ let flat = message.replace(['\n', '\r'], " ");+ let _ = osascript(&[format!(+ "display alert \"Wake can't start\" message \"{}\" as critical",+ applescript_quote(&flat)+ )]);+}++pub fn reveal_in_finder(path: &str) {+ let _ = Command::new("open").args(["-R", path]).status();+}diff --git a/crates/wake-core/src/watcher.rs b/crates/wake-core/src/watcher.rsnew file mode 100644index 0000000..61c7eec--- /dev/null+++ b/crates/wake-core/src/watcher.rs@@ -0,0 +1,101 @@+use crate::adapters::AgentAdapter;+use crate::db::Store;+use crate::models::*;+use crate::scanner::{scan_files, ScanEvents};+use notify::{RecursiveMode, Watcher};+use std::collections::HashMap;+use std::path::{Path, PathBuf};+use std::sync::mpsc;+use std::sync::Arc;+use std::time::Duration;++/// 监听 adapter 数据目录,800ms 去抖后做单文件增量。+/// 返回的 handle drop 时停止监听。+pub struct SessionWatcher {+ _watcher: notify::RecommendedWatcher,+ _thread: std::thread::JoinHandle<()>,+}++pub fn start_watcher(+ adapters: Arc<Vec<Box<dyn AgentAdapter>>>,+ store: Arc<Store>,+ events: Arc<dyn ScanEvents>,+) -> Option<SessionWatcher> {+ let mut roots: Vec<(PathBuf, AgentId)> = Vec::new();+ for a in adapters.iter() {+ for p in a.watch_paths() {+ roots.push((p, a.agent()));+ }+ }+ if roots.is_empty() {+ return None;+ }++ let (tx, rx) = mpsc::channel::<notify::Result<notify::Event>>();+ let mut watcher = notify::recommended_watcher(tx).ok()?;+ for (root, _) in &roots {+ let _ = watcher.watch(root, RecursiveMode::Recursive);+ }++ let thread = std::thread::spawn(move || {+ let resolve_agent = |path: &Path| -> Option<AgentId> {+ roots+ .iter()+ .find(|(root, _)| path.starts_with(root))+ .map(|(_, agent)| *agent)+ };++ let mut pending: HashMap<PathBuf, AgentId> = HashMap::new();+ let mut removed: Vec<PathBuf> = Vec::new();+ loop {+ // 等首个事件(阻塞),然后 800ms 窗口收敛+ let first = match rx.recv() {+ Ok(e) => e,+ Err(_) => break, // watcher dropped+ };+ let mut batch = vec![first];+ let deadline = std::time::Instant::now() + Duration::from_millis(800);+ while let Ok(ev) = rx.recv_timeout(deadline.saturating_duration_since(std::time::Instant::now())) {+ batch.push(ev);+ if std::time::Instant::now() >= deadline {+ break;+ }+ }++ for ev in batch.into_iter().flatten() {+ for path in ev.paths {+ if matches!(ev.kind, notify::EventKind::Remove(_)) {+ pending.remove(&path);+ removed.push(path.clone());+ } else if let Some(agent) = resolve_agent(&path) {+ pending.insert(path.clone(), agent);+ }+ }+ }++ for path in removed.drain(..) {+ let _ = store.remove_by_path(&path.to_string_lossy());+ events.on_sessions_changed();+ }++ // 路径是否本 agent 的会话文件、native_id 怎么取,统一问 adapter+ let refs: Vec<SessionFileRef> = pending+ .drain()+ .filter_map(|(path, agent)| {+ adapters+ .iter()+ .find(|a| a.agent() == agent)+ .and_then(|a| a.file_ref(&path))+ })+ .collect();+ if !refs.is_empty() {+ scan_files(&adapters, &store, events.as_ref(), refs);+ }+ }+ });++ Some(SessionWatcher {+ _watcher: watcher,+ _thread: thread,+ })+}diff --git a/crates/wake/Cargo.toml b/crates/wake/Cargo.tomlnew file mode 100644index 0000000..1cb5fe1--- /dev/null+++ b/crates/wake/Cargo.toml@@ -0,0 +1,21 @@+[package]+name = "wake"+version.workspace = true+edition.workspace = true+license.workspace = true++# 二进制名即 macOS 菜单栏 App 名(裸二进制无 bundle 时取进程名),须大写 Wake+[[bin]]+name = "Wake"+path = "src/main.rs"++[dependencies]+wake-core = { path = "../wake-core" }+anyhow.workspace = true+serde.workspace = true+serde_json.workspace = true+gpui = "0.2"+gpui-component = { version = "0.5", features = ["tree-sitter-languages"] }+futures = "0.3"+chrono.workspace = true+dirs.workspace = truediff --git a/crates/wake/assets/brands/claude-code.png b/crates/wake/assets/brands/claude-code.pngnew file mode 100644index 0000000..37afd5eBinary files /dev/null and b/crates/wake/assets/brands/claude-code.png differdiff --git a/crates/wake/assets/brands/codex.png b/crates/wake/assets/brands/codex.pngnew file mode 100644index 0000000..f51cbb9Binary files /dev/null and b/crates/wake/assets/brands/codex.png differdiff --git a/crates/wake/assets/brands/copilot-light.png b/crates/wake/assets/brands/copilot-light.pngnew file mode 100644index 0000000..694b818Binary files /dev/null and b/crates/wake/assets/brands/copilot-light.png differdiff --git a/crates/wake/assets/brands/copilot.png b/crates/wake/assets/brands/copilot.pngnew file mode 100644index 0000000..04a8ab2Binary files /dev/null and b/crates/wake/assets/brands/copilot.png differdiff --git a/crates/wake/assets/brands/cursor-light.png b/crates/wake/assets/brands/cursor-light.pngnew file mode 100644index 0000000..b02217eBinary files /dev/null and b/crates/wake/assets/brands/cursor-light.png differdiff --git a/crates/wake/assets/brands/cursor.png b/crates/wake/assets/brands/cursor.pngnew file mode 100644index 0000000..bce7a00Binary files /dev/null and b/crates/wake/assets/brands/cursor.png differdiff --git a/crates/wake/assets/brands/gemini.png b/crates/wake/assets/brands/gemini.pngnew file mode 100644index 0000000..aa96a17Binary files /dev/null and b/crates/wake/assets/brands/gemini.png differdiff --git a/crates/wake/assets/brands/kiro.png b/crates/wake/assets/brands/kiro.pngnew file mode 100644index 0000000..48470ddBinary files /dev/null and b/crates/wake/assets/brands/kiro.png differdiff --git a/crates/wake/assets/brands/opencode-light.png b/crates/wake/assets/brands/opencode-light.pngnew file mode 100644index 0000000..eee96bcBinary files /dev/null and b/crates/wake/assets/brands/opencode-light.png differdiff --git a/crates/wake/assets/brands/opencode.png b/crates/wake/assets/brands/opencode.pngnew file mode 100644index 0000000..e5b0eafBinary files /dev/null and b/crates/wake/assets/brands/opencode.png differdiff --git a/crates/wake/assets/icon.svg b/crates/wake/assets/icon.svgnew file mode 100644index 0000000..b099152--- /dev/null+++ b/crates/wake/assets/icon.svg@@ -0,0 +1,51 @@+<svg width="1024" height="1024" viewBox="0 0 1024 1024" xmlns="http://www.w3.org/2000/svg">+ <!-- 候选 B "Dawn":黎明日出(wake=醒来),水面波光倒影即航迹 -->+ <defs>+ <linearGradient id="sky" x1="0" y1="100" x2="0" y2="608" gradientUnits="userSpaceOnUse">+ <stop offset="0" stop-color="#0C1A34"/>+ <stop offset="0.45" stop-color="#1F3C63"/>+ <stop offset="0.75" stop-color="#8A5B5E"/>+ <stop offset="0.92" stop-color="#E8935F"/>+ <stop offset="1" stop-color="#FFB273"/>+ </linearGradient>+ <linearGradient id="sea" x1="0" y1="608" x2="0" y2="924" gradientUnits="userSpaceOnUse">+ <stop offset="0" stop-color="#20406B"/>+ <stop offset="1" stop-color="#0B1730"/>+ </linearGradient>+ <radialGradient id="sun" cx="0.5" cy="0.5" r="0.5">+ <stop offset="0" stop-color="#FFF0D0"/>+ <stop offset="1" stop-color="#FFA95E"/>+ </radialGradient>+ <clipPath id="squircle">+ <rect x="100" y="100" width="824" height="824" rx="185" ry="185"/>+ </clipPath>+ <clipPath id="skyclip">+ <rect x="100" y="100" width="824" height="508"/>+ </clipPath>+ </defs>++ <g clip-path="url(#squircle)">+ <rect x="100" y="100" width="824" height="508" fill="url(#sky)"/>+ <rect x="100" y="608" width="824" height="316" fill="url(#sea)"/>++ <!-- 星 -->+ <circle cx="300" cy="225" r="7" fill="#E8F0FF" fill-opacity="0.5"/>+ <circle cx="702" cy="185" r="5" fill="#E8F0FF" fill-opacity="0.35"/>+ <circle cx="592" cy="298" r="4" fill="#E8F0FF" fill-opacity="0.25"/>++ <!-- 日出:光晕两层 + 本体半圆(clip 到天空) -->+ <g clip-path="url(#skyclip)">+ <circle cx="512" cy="608" r="210" fill="#FFAE6E" fill-opacity="0.20"/>+ <circle cx="512" cy="608" r="150" fill="#FFC286" fill-opacity="0.22"/>+ <circle cx="512" cy="608" r="105" fill="url(#sun)"/>+ </g>++ <!-- 水面波光:向下渐短渐隐的圆头横线(倒影航迹) -->+ <g stroke="#FFB37E" stroke-linecap="round" fill="none">+ <path d="M 362 668 L 662 668" stroke-width="26" stroke-opacity="0.8"/>+ <path d="M 407 722 L 617 722" stroke-width="22" stroke-opacity="0.5"/>+ <path d="M 442 772 L 582 772" stroke-width="18" stroke-opacity="0.3"/>+ <path d="M 468 818 L 556 818" stroke-width="14" stroke-opacity="0.15"/>+ </g>+ </g>+</svg>diff --git a/crates/wake/assets/icons/arrow-up-down.svg b/crates/wake/assets/icons/arrow-up-down.svgnew file mode 100644index 0000000..bc5ad65--- /dev/null+++ b/crates/wake/assets/icons/arrow-up-down.svg@@ -0,0 +1,18 @@+<!-- @license lucide-static v0.462.0 - ISC -->+<svg+ class="lucide lucide-arrow-up-down"+ xmlns="http://www.w3.org/2000/svg"+ width="24"+ height="24"+ viewBox="0 0 24 24"+ fill="none"+ stroke="currentColor"+ stroke-width="2"+ stroke-linecap="round"+ stroke-linejoin="round"+>+ <path d="m21 16-4 4-4-4" />+ <path d="M17 20V4" />+ <path d="m3 8 4-4 4 4" />+ <path d="M7 4v16" />+</svg>diff --git a/crates/wake/assets/icons/check.svg b/crates/wake/assets/icons/check.svgnew file mode 100644index 0000000..c129ac7--- /dev/null+++ b/crates/wake/assets/icons/check.svg@@ -0,0 +1,15 @@+<!-- @license lucide-static v0.462.0 - ISC -->+<svg+ class="lucide lucide-check"+ xmlns="http://www.w3.org/2000/svg"+ width="24"+ height="24"+ viewBox="0 0 24 24"+ fill="none"+ stroke="currentColor"+ stroke-width="2"+ stroke-linecap="round"+ stroke-linejoin="round"+>+ <path d="M20 6 9 17l-5-5" />+</svg>diff --git a/crates/wake/assets/icons/chevron-down.svg b/crates/wake/assets/icons/chevron-down.svgnew file mode 100644index 0000000..55b9d6e--- /dev/null+++ b/crates/wake/assets/icons/chevron-down.svg@@ -0,0 +1,15 @@+<!-- @license lucide-static v0.462.0 - ISC -->+<svg+ class="lucide lucide-chevron-down"+ xmlns="http://www.w3.org/2000/svg"+ width="24"+ height="24"+ viewBox="0 0 24 24"+ fill="none"+ stroke="currentColor"+ stroke-width="2"+ stroke-linecap="round"+ stroke-linejoin="round"+>+ <path d="m6 9 6 6 6-6" />+</svg>diff --git a/crates/wake/assets/icons/chevron-right.svg b/crates/wake/assets/icons/chevron-right.svgnew file mode 100644index 0000000..7da160e--- /dev/null+++ b/crates/wake/assets/icons/chevron-right.svg@@ -0,0 +1,15 @@+<!-- @license lucide-static v0.462.0 - ISC -->+<svg+ class="lucide lucide-chevron-right"+ xmlns="http://www.w3.org/2000/svg"+ width="24"+ height="24"+ viewBox="0 0 24 24"+ fill="none"+ stroke="currentColor"+ stroke-width="2"+ stroke-linecap="round"+ stroke-linejoin="round"+>+ <path d="m9 18 6-6-6-6" />+</svg>diff --git a/crates/wake/assets/icons/circle-x.svg b/crates/wake/assets/icons/circle-x.svgnew file mode 100644index 0000000..e5af6f4--- /dev/null+++ b/crates/wake/assets/icons/circle-x.svg@@ -0,0 +1,17 @@+<!-- @license lucide-static v0.462.0 - ISC -->+<svg+ class="lucide lucide-circle-x"+ xmlns="http://www.w3.org/2000/svg"+ width="24"+ height="24"+ viewBox="0 0 24 24"+ fill="none"+ stroke="currentColor"+ stroke-width="2"+ stroke-linecap="round"+ stroke-linejoin="round"+>+ <circle cx="12" cy="12" r="10" />+ <path d="m15 9-6 6" />+ <path d="m9 9 6 6" />+</svg>diff --git a/crates/wake/assets/icons/copy.svg b/crates/wake/assets/icons/copy.svgnew file mode 100644index 0000000..1136ad5--- /dev/null+++ b/crates/wake/assets/icons/copy.svg@@ -0,0 +1,16 @@+<!-- @license lucide-static v0.462.0 - ISC -->+<svg+ class="lucide lucide-copy"+ xmlns="http://www.w3.org/2000/svg"+ width="24"+ height="24"+ viewBox="0 0 24 24"+ fill="none"+ stroke="currentColor"+ stroke-width="2"+ stroke-linecap="round"+ stroke-linejoin="round"+>+ <rect width="14" height="14" x="8" y="8" rx="2" ry="2" />+ <path d="M4 16c-1.1 0-2-.9-2-2V4c0-1.1.9-2 2-2h10c1.1 0 2 .9 2 2" />+</svg>diff --git a/crates/wake/assets/icons/download.svg b/crates/wake/assets/icons/download.svgnew file mode 100644index 0000000..7b816d8--- /dev/null+++ b/crates/wake/assets/icons/download.svg@@ -0,0 +1,17 @@+<!-- @license lucide-static v0.462.0 - ISC -->+<svg+ class="lucide lucide-download"+ xmlns="http://www.w3.org/2000/svg"+ width="24"+ height="24"+ viewBox="0 0 24 24"+ fill="none"+ stroke="currentColor"+ stroke-width="2"+ stroke-linecap="round"+ stroke-linejoin="round"+>+ <path d="M21 15v4a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-4" />+ <polyline points="7 10 12 15 17 10" />+ <line x1="12" x2="12" y1="15" y2="3" />+</svg>diff --git a/crates/wake/assets/icons/file-text.svg b/crates/wake/assets/icons/file-text.svgnew file mode 100644index 0000000..13cbac4--- /dev/null+++ b/crates/wake/assets/icons/file-text.svg@@ -0,0 +1,19 @@+<!-- @license lucide-static v0.462.0 - ISC -->+<svg+ class="lucide lucide-file-text"+ xmlns="http://www.w3.org/2000/svg"+ width="24"+ height="24"+ viewBox="0 0 24 24"+ fill="none"+ stroke="currentColor"+ stroke-width="2"+ stroke-linecap="round"+ stroke-linejoin="round"+>+ <path d="M15 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V7Z" />+ <path d="M14 2v4a2 2 0 0 0 2 2h4" />+ <path d="M10 9H8" />+ <path d="M16 13H8" />+ <path d="M16 17H8" />+</svg>diff --git a/crates/wake/assets/icons/folder.svg b/crates/wake/assets/icons/folder.svgnew file mode 100644index 0000000..cfde7b9--- /dev/null+++ b/crates/wake/assets/icons/folder.svg@@ -0,0 +1,15 @@+<!-- @license lucide-static v0.462.0 - ISC -->+<svg+ class="lucide lucide-folder"+ xmlns="http://www.w3.org/2000/svg"+ width="24"+ height="24"+ viewBox="0 0 24 24"+ fill="none"+ stroke="currentColor"+ stroke-width="2"+ stroke-linecap="round"+ stroke-linejoin="round"+>+ <path d="M20 20a2 2 0 0 0 2-2V8a2 2 0 0 0-2-2h-7.9a2 2 0 0 1-1.69-.9L9.6 3.9A2 2 0 0 0 7.93 3H4a2 2 0 0 0-2 2v13a2 2 0 0 0 2 2Z" />+</svg>diff --git a/crates/wake/assets/icons/git-branch.svg b/crates/wake/assets/icons/git-branch.svgnew file mode 100644index 0000000..b4e7e0b--- /dev/null+++ b/crates/wake/assets/icons/git-branch.svg@@ -0,0 +1,18 @@+<!-- @license lucide-static v0.462.0 - ISC -->+<svg+ class="lucide lucide-git-branch"+ xmlns="http://www.w3.org/2000/svg"+ width="24"+ height="24"+ viewBox="0 0 24 24"+ fill="none"+ stroke="currentColor"+ stroke-width="2"+ stroke-linecap="round"+ stroke-linejoin="round"+>+ <line x1="6" x2="6" y1="3" y2="15" />+ <circle cx="18" cy="6" r="3" />+ <circle cx="6" cy="18" r="3" />+ <path d="M18 9a9 9 0 0 1-9 9" />+</svg>diff --git a/crates/wake/assets/icons/inbox.svg b/crates/wake/assets/icons/inbox.svgnew file mode 100644index 0000000..0679ae9--- /dev/null+++ b/crates/wake/assets/icons/inbox.svg@@ -0,0 +1,16 @@+<!-- @license lucide-static v0.462.0 - ISC -->+<svg+ class="lucide lucide-inbox"+ xmlns="http://www.w3.org/2000/svg"+ width="24"+ height="24"+ viewBox="0 0 24 24"+ fill="none"+ stroke="currentColor"+ stroke-width="2"+ stroke-linecap="round"+ stroke-linejoin="round"+>+ <polyline points="22 12 16 12 14 15 10 15 8 12 2 12" />+ <path d="M5.45 5.11 2 12v6a2 2 0 0 0 2 2h16a2 2 0 0 0 2-2v-6l-3.45-6.89A2 2 0 0 0 16.76 4H7.24a2 2 0 0 0-1.79 1.11z" />+</svg>diff --git a/crates/wake/assets/icons/layers.svg b/crates/wake/assets/icons/layers.svgnew file mode 100644index 0000000..1134fbc--- /dev/null+++ b/crates/wake/assets/icons/layers.svg@@ -0,0 +1,17 @@+<!-- @license lucide-static v0.462.0 - ISC -->+<svg+ class="lucide lucide-layers"+ xmlns="http://www.w3.org/2000/svg"+ width="24"+ height="24"+ viewBox="0 0 24 24"+ fill="none"+ stroke="currentColor"+ stroke-width="2"+ stroke-linecap="round"+ stroke-linejoin="round"+>+ <path d="m12.83 2.18a2 2 0 0 0-1.66 0L2.6 6.08a1 1 0 0 0 0 1.83l8.58 3.91a2 2 0 0 0 1.66 0l8.58-3.9a1 1 0 0 0 0-1.83Z" />+ <path d="m22 17.65-9.17 4.16a2 2 0 0 1-1.66 0L2 17.65" />+ <path d="m22 12.65-9.17 4.16a2 2 0 0 1-1.66 0L2 12.65" />+</svg>diff --git a/crates/wake/assets/icons/loader-circle.svg b/crates/wake/assets/icons/loader-circle.svgnew file mode 100644index 0000000..792b1c5--- /dev/null+++ b/crates/wake/assets/icons/loader-circle.svg@@ -0,0 +1,15 @@+<!-- @license lucide-static v0.462.0 - ISC -->+<svg+ class="lucide lucide-loader-circle"+ xmlns="http://www.w3.org/2000/svg"+ width="24"+ height="24"+ viewBox="0 0 24 24"+ fill="none"+ stroke="currentColor"+ stroke-width="2"+ stroke-linecap="round"+ stroke-linejoin="round"+>+ <path d="M21 12a9 9 0 1 1-6.219-8.56" />+</svg>diff --git a/crates/wake/assets/icons/loader.svg b/crates/wake/assets/icons/loader.svgnew file mode 100644index 0000000..5cff624--- /dev/null+++ b/crates/wake/assets/icons/loader.svg@@ -0,0 +1,22 @@+<!-- @license lucide-static v0.462.0 - ISC -->+<svg+ class="lucide lucide-loader"+ xmlns="http://www.w3.org/2000/svg"+ width="24"+ height="24"+ viewBox="0 0 24 24"+ fill="none"+ stroke="currentColor"+ stroke-width="2"+ stroke-linecap="round"+ stroke-linejoin="round"+>+ <path d="M12 2v4" />+ <path d="m16.2 7.8 2.9-2.9" />+ <path d="M18 12h4" />+ <path d="m16.2 16.2 2.9 2.9" />+ <path d="M12 18v4" />+ <path d="m4.9 19.1 2.9-2.9" />+ <path d="M2 12h4" />+ <path d="m4.9 4.9 2.9 2.9" />+</svg>diff --git a/crates/wake/assets/icons/message-square.svg b/crates/wake/assets/icons/message-square.svgnew file mode 100644index 0000000..1905915--- /dev/null+++ b/crates/wake/assets/icons/message-square.svg@@ -0,0 +1,15 @@+<!-- @license lucide-static v0.462.0 - ISC -->+<svg+ class="lucide lucide-message-square"+ xmlns="http://www.w3.org/2000/svg"+ width="24"+ height="24"+ viewBox="0 0 24 24"+ fill="none"+ stroke="currentColor"+ stroke-width="2"+ stroke-linecap="round"+ stroke-linejoin="round"+>+ <path d="M21 15a2 2 0 0 1-2 2H7l-4 4V5a2 2 0 0 1 2-2h14a2 2 0 0 1 2 2z" />+</svg>diff --git a/crates/wake/assets/icons/more-horizontal.svg b/crates/wake/assets/icons/more-horizontal.svgnew file mode 100644index 0000000..15a1f56--- /dev/null+++ b/crates/wake/assets/icons/more-horizontal.svg@@ -0,0 +1,5 @@+<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round">+ <circle cx="5" cy="12" r="1"/>+ <circle cx="12" cy="12" r="1"/>+ <circle cx="19" cy="12" r="1"/>+</svg>diff --git a/crates/wake/assets/icons/pin-filled.svg b/crates/wake/assets/icons/pin-filled.svgnew file mode 100644index 0000000..aba1a6a--- /dev/null+++ b/crates/wake/assets/icons/pin-filled.svg@@ -0,0 +1,19 @@+<!-- @license lucide-static v0.462.0 - ISC (filled variant) -->+<svg+ class="lucide lucide-pin-filled"+ xmlns="http://www.w3.org/2000/svg"+ width="24"+ height="24"+ viewBox="0 0 24 24"+ fill="none"+ stroke="currentColor"+ stroke-width="2"+ stroke-linecap="round"+ stroke-linejoin="round"+>+ <path d="M12 17v5" />+ <path+ d="M9 10.76a2 2 0 0 1-1.11 1.79l-1.78.9A2 2 0 0 0 5 15.24V16a1 1 0 0 0 1 1h12a1 1 0 0 0 1-1v-.76a2 2 0 0 0-1.11-1.79l-1.78-.9A2 2 0 0 1 15 10.76V7a1 1 0 0 1 1-1 2 2 0 0 0 0-4H8a2 2 0 0 0 0 4 1 1 0 0 1 1 1z"+ fill="currentColor"+ />+</svg>diff --git a/crates/wake/assets/icons/pin.svg b/crates/wake/assets/icons/pin.svgnew file mode 100644index 0000000..fd6399e--- /dev/null+++ b/crates/wake/assets/icons/pin.svg@@ -0,0 +1,16 @@+<!-- @license lucide-static v0.462.0 - ISC -->+<svg+ class="lucide lucide-pin"+ xmlns="http://www.w3.org/2000/svg"+ width="24"+ height="24"+ viewBox="0 0 24 24"+ fill="none"+ stroke="currentColor"+ stroke-width="2"+ stroke-linecap="round"+ stroke-linejoin="round"+>+ <path d="M12 17v5" />+ <path d="M9 10.76a2 2 0 0 1-1.11 1.79l-1.78.9A2 2 0 0 0 5 15.24V16a1 1 0 0 0 1 1h12a1 1 0 0 0 1-1v-.76a2 2 0 0 0-1.11-1.79l-1.78-.9A2 2 0 0 1 15 10.76V7a1 1 0 0 1 1-1 2 2 0 0 0 0-4H8a2 2 0 0 0 0 4 1 1 0 0 1 1 1z" />+</svg>diff --git a/crates/wake/assets/icons/refresh-cw.svg b/crates/wake/assets/icons/refresh-cw.svgnew file mode 100644index 0000000..1ce1fdc--- /dev/null+++ b/crates/wake/assets/icons/refresh-cw.svg@@ -0,0 +1,18 @@+<!-- @license lucide-static v0.462.0 - ISC -->+<svg+ class="lucide lucide-refresh-cw"+ xmlns="http://www.w3.org/2000/svg"+ width="24"+ height="24"+ viewBox="0 0 24 24"+ fill="none"+ stroke="currentColor"+ stroke-width="2"+ stroke-linecap="round"+ stroke-linejoin="round"+>+ <path d="M3 12a9 9 0 0 1 9-9 9.75 9.75 0 0 1 6.74 2.74L21 8" />+ <path d="M21 3v5h-5" />+ <path d="M21 12a9 9 0 0 1-9 9 9.75 9.75 0 0 1-6.74-2.74L3 16" />+ <path d="M8 16H3v5" />+</svg>diff --git a/crates/wake/assets/icons/search.svg b/crates/wake/assets/icons/search.svgnew file mode 100644index 0000000..56e5ec1--- /dev/null+++ b/crates/wake/assets/icons/search.svg@@ -0,0 +1,16 @@+<!-- @license lucide-static v0.462.0 - ISC -->+<svg+ class="lucide lucide-search"+ xmlns="http://www.w3.org/2000/svg"+ width="24"+ height="24"+ viewBox="0 0 24 24"+ fill="none"+ stroke="currentColor"+ stroke-width="2"+ stroke-linecap="round"+ stroke-linejoin="round"+>+ <circle cx="11" cy="11" r="8" />+ <path d="m21 21-4.3-4.3" />+</svg>diff --git a/crates/wake/assets/icons/star-filled.svg b/crates/wake/assets/icons/star-filled.svgnew file mode 100644index 0000000..937cefd--- /dev/null+++ b/crates/wake/assets/icons/star-filled.svg@@ -0,0 +1,15 @@+<!-- @license lucide-static v0.462.0 - ISC (filled variant) -->+<svg+ class="lucide lucide-star-filled"+ xmlns="http://www.w3.org/2000/svg"+ width="24"+ height="24"+ viewBox="0 0 24 24"+ fill="currentColor"+ stroke="currentColor"+ stroke-width="2"+ stroke-linecap="round"+ stroke-linejoin="round"+>+ <path d="M11.525 2.295a.53.53 0 0 1 .95 0l2.31 4.679a2.123 2.123 0 0 0 1.595 1.16l5.166.756a.53.53 0 0 1 .294.904l-3.736 3.638a2.123 2.123 0 0 0-.611 1.878l.882 5.14a.53.53 0 0 1-.771.56l-4.618-2.428a2.122 2.122 0 0 0-1.973 0L6.396 21.01a.53.53 0 0 1-.77-.56l.881-5.139a2.122 2.122 0 0 0-.611-1.879L2.16 9.795a.53.53 0 0 1 .294-.906l5.165-.755a2.122 2.122 0 0 0 1.597-1.16z" />+</svg>diff --git a/crates/wake/assets/icons/star.svg b/crates/wake/assets/icons/star.svgnew file mode 100644index 0000000..dae20fc--- /dev/null+++ b/crates/wake/assets/icons/star.svg@@ -0,0 +1,15 @@+<!-- @license lucide-static v0.462.0 - ISC -->+<svg+ class="lucide lucide-star"+ xmlns="http://www.w3.org/2000/svg"+ width="24"+ height="24"+ viewBox="0 0 24 24"+ fill="none"+ stroke="currentColor"+ stroke-width="2"+ stroke-linecap="round"+ stroke-linejoin="round"+>+ <path d="M11.525 2.295a.53.53 0 0 1 .95 0l2.31 4.679a2.123 2.123 0 0 0 1.595 1.16l5.166.756a.53.53 0 0 1 .294.904l-3.736 3.638a2.123 2.123 0 0 0-.611 1.878l.882 5.14a.53.53 0 0 1-.771.56l-4.618-2.428a2.122 2.122 0 0 0-1.973 0L6.396 21.01a.53.53 0 0 1-.77-.56l.881-5.139a2.122 2.122 0 0 0-.611-1.879L2.16 9.795a.53.53 0 0 1 .294-.906l5.165-.755a2.122 2.122 0 0 0 1.597-1.16z" />+</svg>diff --git a/crates/wake/assets/icons/terminal.svg b/crates/wake/assets/icons/terminal.svgnew file mode 100644index 0000000..ec688eb--- /dev/null+++ b/crates/wake/assets/icons/terminal.svg@@ -0,0 +1,16 @@+<!-- @license lucide-static v0.462.0 - ISC -->+<svg+ class="lucide lucide-terminal"+ xmlns="http://www.w3.org/2000/svg"+ width="24"+ height="24"+ viewBox="0 0 24 24"+ fill="none"+ stroke="currentColor"+ stroke-width="2"+ stroke-linecap="round"+ stroke-linejoin="round"+>+ <polyline points="4 17 10 11 4 5" />+ <line x1="12" x2="20" y1="19" y2="19" />+</svg>diff --git a/crates/wake/assets/icons/trash-2.svg b/crates/wake/assets/icons/trash-2.svgnew file mode 100644index 0000000..3d5d87a--- /dev/null+++ b/crates/wake/assets/icons/trash-2.svg@@ -0,0 +1,19 @@+<!-- @license lucide-static v0.462.0 - ISC -->+<svg+ class="lucide lucide-trash-2"+ xmlns="http://www.w3.org/2000/svg"+ width="24"+ height="24"+ viewBox="0 0 24 24"+ fill="none"+ stroke="currentColor"+ stroke-width="2"+ stroke-linecap="round"+ stroke-linejoin="round"+>+ <path d="M3 6h18" />+ <path d="M19 6v14c0 1-1 2-2 2H7c-1 0-2-1-2-2V6" />+ <path d="M8 6V4c0-1 1-2 2-2h4c1 0 2 1 2 2v2" />+ <line x1="10" x2="10" y1="11" y2="17" />+ <line x1="14" x2="14" y1="11" y2="17" />+</svg>diff --git a/crates/wake/assets/icons/x.svg b/crates/wake/assets/icons/x.svgnew file mode 100644index 0000000..fcf1c82--- /dev/null+++ b/crates/wake/assets/icons/x.svg@@ -0,0 +1,16 @@+<!-- @license lucide-static v0.462.0 - ISC -->+<svg+ class="lucide lucide-x"+ xmlns="http://www.w3.org/2000/svg"+ width="24"+ height="24"+ viewBox="0 0 24 24"+ fill="none"+ stroke="currentColor"+ stroke-width="2"+ stroke-linecap="round"+ stroke-linejoin="round"+>+ <path d="M18 6 6 18" />+ <path d="m6 6 12 12" />+</svg>diff --git a/crates/wake/src/assets.rs b/crates/wake/src/assets.rsnew file mode 100644index 0000000..5fdae52--- /dev/null+++ b/crates/wake/src/assets.rs@@ -0,0 +1,86 @@+use anyhow::Result;+use gpui::{AssetSource, SharedString};+use std::borrow::Cow;++/// 内嵌 lucide 图标(ISC License)。GPUI 无 SF Symbols,以 lucide 作为图标系统。+pub struct Assets;++macro_rules! icons {+ ($($name:literal),* $(,)?) => {+ fn lookup(path: &str) -> Option<&'static [u8]> {+ match path {+ $(concat!("icons/", $name, ".svg") =>+ Some(include_bytes!(concat!("../assets/icons/", $name, ".svg"))),)*+ _ => None,+ }+ }+ #[allow(dead_code)]+ pub const ICON_NAMES: &[&str] = &[$($name),*];+ };+}++/// Agent 品牌图标(彩色 PNG,640×640 带 alpha)。经 `img()` 渲染,+/// 不走 Icon——品牌色必须原样保留,不能被 text_color 着色。+/// 文件名即 `AgentId::as_str()`,见 `AgentId::brand_icon()`。+macro_rules! brands {+ ($($name:literal),* $(,)?) => {+ fn lookup_brand(path: &str) -> Option<&'static [u8]> {+ match path {+ $(concat!("brands/", $name, ".png") =>+ Some(include_bytes!(concat!("../assets/brands/", $name, ".png"))),)*+ _ => None,+ }+ }+ };+}++brands!(+ "claude-code",+ "codex",+ "copilot",+ "copilot-light",+ "cursor",+ "cursor-light",+ "opencode",+ "opencode-light",+ "kiro",+ "gemini",+);++icons!(+ "star",+ "pin",+ "download",+ "folder",+ "trash-2",+ "search",+ "arrow-up-down",+ "check",+ "copy",+ "pin-filled",+ "star-filled",+ "terminal",+ "message-square",+ "layers",+ "x",+ "git-branch",+ "refresh-cw",+ "inbox",+ "chevron-down",+ "chevron-right",+ "loader-circle",+ "loader",+ "circle-x",+ "file-text",+ "more-horizontal",+);++impl AssetSource for Assets {+ fn load(&self, path: &str) -> Result<Option<Cow<'static, [u8]>>> {+ Ok(lookup(path).or_else(|| lookup_brand(path)).map(Cow::Borrowed))+ }++ fn list(&self, _path: &str) -> Result<Vec<SharedString>> {+ Ok(Vec::new())+ }+}diff --git a/crates/wake/src/format.rs b/crates/wake/src/format.rsnew file mode 100644index 0000000..baeaee8--- /dev/null+++ b/crates/wake/src/format.rs@@ -0,0 +1,60 @@+use chrono::{Local, TimeZone};++pub fn relative_time(ts: i64) -> String {+ if ts <= 0 {+ return String::new();+ }+ let now = chrono::Utc::now().timestamp_millis();+ let diff = now - ts;+ const MIN: i64 = 60_000;+ if diff < MIN {+ "now".to_string()+ } else if diff < 60 * MIN {+ format!("{}m", diff / MIN)+ } else if diff < 24 * 60 * MIN {+ format!("{}h", diff / (60 * MIN))+ } else if diff < 7 * 24 * 60 * MIN {+ format!("{}d", diff / (24 * 60 * MIN))+ } else {+ Local+ .timestamp_millis_opt(ts)+ .single()+ .map(|d| d.format("%m-%d").to_string())+ .unwrap_or_default()+ }+}++/// 绝对时间(详情页时间行):yyyy-MM-dd HH:mm:ss+pub fn abs_date(ts: i64) -> String {+ if ts <= 0 {+ return String::new();+ }+ Local+ .timestamp_millis_opt(ts)+ .single()+ .map(|dt| dt.format("%Y-%m-%d %H:%M:%S").to_string())+ .unwrap_or_default()+}++pub fn fmt_tokens(n: Option<i64>) -> String {+ match n {+ None | Some(0) => String::new(),+ Some(n) if n >= 1_000_000_000 => format!("{:.1}B", n as f64 / 1e9),+ Some(n) if n >= 1_000_000 => format!("{:.1}M", n as f64 / 1e6),+ Some(n) if n >= 1_000 => format!("{:.1}K", n as f64 / 1e3),+ Some(n) => n.to_string(),+ }+}++/// 首行截断预览+pub fn one_line(s: &str, max_chars: usize) -> String {+ let joined = s.split_whitespace().collect::<Vec<_>>().join(" ");+ let chars: Vec<char> = joined.chars().collect();+ if chars.len() > max_chars {+ let mut t: String = chars[..max_chars].iter().collect();+ t.push('…');+ t+ } else {+ joined+ }+}diff --git a/crates/wake/src/main.rs b/crates/wake/src/main.rsnew file mode 100644index 0000000..64d7d54--- /dev/null+++ b/crates/wake/src/main.rs@@ -0,0 +1,82 @@+mod assets;+mod format;+mod theme;+mod ui;+mod workbench;++use assets::Assets;+use gpui::*;+use gpui_component::Root;+use workbench::{+ PaletteDown, PaletteUp, RefreshSessions, ToggleSearch, Workbench, KEY_CONTEXT, PALETTE_CONTEXT,+};++actions!(wake_app, [Quit, CloseWindow]);++fn main() {+ let app = Application::new().with_assets(Assets);+ app.run(move |cx: &mut App| {+ gpui_component::init(cx);+ gpui_component::set_locale("en");+ theme::sync_appearance(None, cx);++ cx.on_action(|_: &Quit, cx| cx.quit());+ cx.on_action(|_: &CloseWindow, cx| {+ if let Some(w) = cx.active_window() {+ w.update(cx, |_, window, _| window.remove_window()).ok();+ }+ });+ cx.bind_keys([+ KeyBinding::new("cmd-k", ToggleSearch, Some(KEY_CONTEXT)),+ KeyBinding::new("cmd-r", RefreshSessions, Some(KEY_CONTEXT)),+ KeyBinding::new("cmd-q", Quit, None),+ KeyBinding::new("cmd-w", CloseWindow, None),+ // ⌘K 面板:焦点在搜索输入框,↑↓ 冒泡到面板容器挪选中+ KeyBinding::new("up", PaletteUp, Some(PALETTE_CONTEXT)),+ KeyBinding::new("down", PaletteDown, Some(PALETTE_CONTEXT)),+ ]);+ cx.set_menus(vec![+ Menu {+ name: "Wake".into(),+ items: vec![MenuItem::action("Quit Wake", Quit)],+ },+ Menu {+ name: "File".into(),+ items: vec![+ MenuItem::action("Refresh Sessions", RefreshSessions),+ MenuItem::separator(),+ MenuItem::action("Close Window", CloseWindow),+ ],+ },+ ]);++ let bounds = Bounds::centered(None, size(px(1180.), px(760.)), cx);+ cx.open_window(+ WindowOptions {+ titlebar: Some(TitlebarOptions {+ title: None,+ appears_transparent: true,+ traffic_light_position: Some(point(px(20.), px(11.))),+ }),+ window_bounds: Some(WindowBounds::Windowed(bounds)),+ window_min_size: Some(size(px(940.), px(620.))),+ ..Default::default()+ },+ |window, cx| {+ // 跟随系统深浅色切换+ window+ .observe_window_appearance(|window, cx| {+ theme::sync_appearance(Some(window), cx);+ })+ .detach();+ theme::sync_appearance(Some(window), cx);++ let workbench = cx.new(|cx| Workbench::new(window, cx));+ window.focus(&workbench.read(cx).focus_handle(cx));+ cx.new(|cx| Root::new(workbench, window, cx))+ },+ )+ .expect("failed to open window");+ cx.activate(true);+ });+}diff --git a/crates/wake/src/theme.rs b/crates/wake/src/theme.rsnew file mode 100644index 0000000..818385c--- /dev/null+++ b/crates/wake/src/theme.rs@@ -0,0 +1,186 @@+//! Wake 的双模式主题:Things / Bear 基准的 macOS 原生质感。+//! 浅色 = 纸感白 + 暖灰侧栏;深色 = 暖黑 + 柔和层次。accent 取系统蓝。+use gpui::{App, Hsla, Rgba, Window};+use gpui_component::{ActiveTheme as _, Theme, ThemeMode};++/// 带透明度的色值(文字选区等叠加层用)+fn ca(hex: u32, a: f32) -> Hsla {+ let mut col = c(hex);+ col.a = a;+ col+}++fn c(hex: u32) -> Hsla {+ Rgba {+ r: ((hex >> 16) & 0xff) as f32 / 255.0,+ g: ((hex >> 8) & 0xff) as f32 / 255.0,+ b: (hex & 0xff) as f32 / 255.0,+ a: 1.0,+ }+ .into()+}++/// 详情页 model badge 色——用户指定的 Claude 橙(非 agent 语义,纯配色选择);+/// outline badge 形态,两模式通用+pub const MODEL_BADGE_BG: u32 = 0xD97757;++/// 收藏星选中色——macOS systemYellow(Finder/Mail 星标惯例),两模式通用+pub const STAR_YELLOW: u32 = 0xFFCC00;++/// 在 gpui-component 默认主题之上覆写 Wake 的 token。+/// 每次外观切换后都要重新调用(sync_system_appearance 会重置为默认)。+pub fn apply_wake_theme(cx: &mut App) {+ let dark = cx.theme().mode.is_dark();+ let theme = Theme::global_mut(cx);++ if dark {+ // ---- 深色:石墨材质,层级从侧栏向阅读面逐步提亮 ----+ theme.background = c(0x242422);+ theme.foreground = c(0xF0EFED);+ theme.border = c(0x353431);+ theme.ring = c(0x4C8DFF);++ theme.sidebar = c(0x1B1B1A);+ theme.sidebar_foreground = c(0xD3D2CE);+ theme.sidebar_border = c(0x292927);+ theme.sidebar_accent = c(0x343432);+ theme.sidebar_accent_foreground = c(0xF5F4F1);+ theme.sidebar_primary = c(0x4C8DFF);+ theme.sidebar_primary_foreground = c(0xFFFFFF);++ theme.list = c(0x20201F);+ theme.list_hover = c(0x2A2A28);+ theme.list_active = c(0x303B4C);+ theme.list_active_border = c(0x303B4C);+ theme.list_even = c(0x20201F);+ theme.list_head = c(0x20201F);++ theme.muted = c(0x323230);+ theme.muted_foreground = c(0xA9A8A2);+ theme.accent = c(0x383836);+ theme.accent_foreground = c(0xF4F3F0);++ theme.primary = c(0x4C8DFF);+ theme.primary_hover = c(0x5E99FF);+ theme.primary_active = c(0x3D7EF0);+ theme.primary_foreground = c(0xFFFFFF);++ theme.secondary = c(0x30302E);+ theme.secondary_hover = c(0x3A3A37);+ theme.secondary_active = c(0x41413D);+ theme.secondary_foreground = c(0xECEBE8);++ theme.popover = c(0x2C2C2A);+ theme.popover_foreground = c(0xF0EFED);+ theme.group_box = c(0x2C2C2A);+ theme.group_box_foreground = c(0xF0EFED);+ theme.input = c(0x44423E);+ theme.selection = ca(0x4C8DFF, 0.32);+ theme.caret = c(0x4C8DFF);++ theme.title_bar = c(0x1B1B1A);+ theme.title_bar_border = c(0x1B1B1A);++ theme.scrollbar_thumb = c(0x3E3E3B);+ theme.scrollbar_thumb_hover = c(0x4A4A47);++ theme.link = c(0x6EA3FF);+ theme.danger = c(0xFF6B60);+ theme.danger_hover = c(0xFF7B72);+ theme.danger_active = c(0xEE5D54);+ theme.danger_foreground = c(0xFFFFFF);+ theme.success = c(0x56C789);+ theme.success_foreground = c(0x10271B);+ // 琥珀(侧栏 "Live updates off" 状态点用)+ theme.warning = c(0xD9A741);+ theme.warning_foreground = c(0x2A2105);+ theme.overlay = gpui::hsla(0., 0., 0., 0.45);+ } else {+ // ---- 浅色:银白材质,阅读卡悬在分区背景之上 ----+ theme.background = c(0xF1F1EF);+ theme.foreground = c(0x1D1D1F);+ theme.border = c(0xE3E3DF);+ theme.ring = c(0x0A84FF);++ theme.sidebar = c(0xEDEDEA);+ theme.sidebar_foreground = c(0x41413D);+ theme.sidebar_border = c(0xE1E1DD);+ theme.sidebar_accent = c(0xDEDEDA);+ theme.sidebar_accent_foreground = c(0x1D1D1F);+ theme.sidebar_primary = c(0x0A84FF);+ theme.sidebar_primary_foreground = c(0xFFFFFF);++ theme.list = c(0xF7F7F5);+ theme.list_hover = c(0xEDEDEA);+ theme.list_active = c(0xE3EBF6);+ theme.list_active_border = c(0xE3EBF6);+ theme.list_even = c(0xF7F7F5);+ theme.list_head = c(0xF7F7F5);++ theme.muted = c(0xE8E8E5);+ theme.muted_foreground = c(0x686761);+ theme.accent = c(0xE7E7E3);+ theme.accent_foreground = c(0x1D1D1F);++ theme.primary = c(0x0A84FF);+ theme.primary_hover = c(0x268FFF);+ theme.primary_active = c(0x0071E3);+ theme.primary_foreground = c(0xFFFFFF);++ theme.secondary = c(0xE8E8E5);+ theme.secondary_hover = c(0xDEDEDA);+ theme.secondary_active = c(0xD4D4D0);+ theme.secondary_foreground = c(0x2B2B2D);++ theme.popover = c(0xFDFDFC);+ theme.popover_foreground = c(0x1D1D1F);+ theme.group_box = c(0xFDFDFC);+ theme.group_box_foreground = c(0x1D1D1F);+ theme.input = c(0xDADAD6);+ theme.selection = ca(0x0A7AFF, 0.22);+ theme.caret = c(0x0A84FF);++ theme.title_bar = c(0xEDEDEA);+ theme.title_bar_border = c(0xEDEDEA);++ theme.scrollbar_thumb = c(0xD2D2CF);+ theme.scrollbar_thumb_hover = c(0xBFBFBC);++ theme.link = c(0x0A84FF);+ theme.danger = c(0xE5484D);+ theme.danger_hover = c(0xEE5C61);+ theme.danger_active = c(0xD93C42);+ theme.danger_foreground = c(0xFFFFFF);+ theme.success = c(0x2F9E63);+ theme.success_foreground = c(0xFFFFFF);+ // 琥珀(侧栏 "Live updates off" 状态点用),白字对比 4.9:1+ theme.warning = c(0xA16207);+ theme.warning_foreground = c(0xFFFFFF);+ theme.overlay = gpui::hsla(0., 0., 0., 0.25);+ }++ // 系统字体与 macOS 圆角习惯+ theme.font_family = ".AppleSystemUIFont".into();+ theme.font_size = gpui::px(14.);+ theme.radius = gpui::px(8.);+ theme.radius_lg = gpui::px(12.);+ theme.shadow = true;+}++/// 跟随系统外观:同步模式 → 重套 Wake token。+pub fn sync_appearance(window: Option<&mut Window>, cx: &mut App) {+ // WAKE_THEME=dark|light 可强制模式(调试/截图用)+ match std::env::var("WAKE_THEME").as_deref() {+ Ok("dark") => Theme::change(ThemeMode::Dark, window, cx),+ Ok("light") => Theme::change(ThemeMode::Light, window, cx),+ _ => Theme::sync_system_appearance(window, cx),+ }+ apply_wake_theme(cx);+}++/// 手动切换(调试/后续设置页用)+#[allow(dead_code)]+pub fn set_mode(mode: ThemeMode, window: Option<&mut Window>, cx: &mut App) {+ Theme::change(mode, window, cx);+ apply_wake_theme(cx);+}diff --git a/crates/wake/src/ui.rs b/crates/wake/src/ui.rsnew file mode 100644index 0000000..2c22356--- /dev/null+++ b/crates/wake/src/ui.rs@@ -0,0 +1,87 @@+//! Wake 界面尺度规范——六档字阶。+//! 规则:所有 UI 字号必须引用本模块常量,禁止裸 px 数字与 rem 工具类+//! (text_sm 等按 rem=14px 折算会产生 12.25px 这类幽灵值)。+//! 颜色只用三级:foreground(主文字)/muted_foreground(辅助)/primary(强调)。+use gpui::{px, Hsla, Pixels, Styled};++/// 上下文大标题(中栏头部)——semibold+pub const FONT_TITLE: Pixels = px(22.);+/// 区块标题(详情页会话标题)——semibold+pub const FONT_HEADING: Pixels = px(16.);+/// 界面正文(导航行/列表标题/按钮/输入);列表标题用 medium+pub const FONT_BODY: Pixels = px(14.);+/// 辅助说明(列表副行/元信息/占位/空态提示/侧栏子级行)+pub const FONT_CAPTION: Pixels = px(12.);+/// 标签(分组头/计数/快捷键徽标/状态栏);组头 semibold + 大写+pub const FONT_LABEL: Pixels = px(11.);++// ---- 对话区附档(详情逐消息渲染,经用户逐轮校准,与六档并存)----++/// 用户气泡正文(比 FONT_BODY 收半档,气泡内更紧凑)+pub const FONT_MSG_USER: Pixels = px(13.5);+/// 助手平铺正文+pub const FONT_MSG_BODY: Pixels = px(13.);+/// thinking 摘要行(斜体)+pub const FONT_MSG_THINKING: Pixels = px(11.5);++// ---------------- 间距与结构 ----------------+// 间距刻度:4px 网格。新代码一律引用常量或显式 px();+// 注意 gpui 的 rem 间距类有幽灵值(rem=14px 下 p_2p5=8.75px、p_3=10.5px,+// 均不在网格上)——对齐敏感处禁止使用,存量逐步迁移。++pub const SPACE_XS: Pixels = px(4.);+pub const SPACE_SM: Pixels = px(8.);+pub const SPACE_MD: Pixels = px(12.);+pub const SPACE_LG: Pixels = px(16.);+pub const SPACE_XL: Pixels = px(20.);+pub const SPACE_XXL: Pixels = px(24.);++/// 侧栏容器水平内边距(行的 hover/选中胶囊左右各留这么多)。+pub const SIDEBAR_EDGE: Pixels = px(10.);++// ---- 侧栏中轴:LEAD_AXIS = 26.75 ----+// traffic light 实测左缘 20、直径 13.5,中心即 26.75。侧栏每一行的行首元素+// (导航图标、品牌图、文件夹图标、组头首字母)的**中心**都压在这条竖线上。+// 注意:中心对齐与左缘对齐是同一个自由度,只能满足一个——选了中心,+// 图标左缘就会落在 17.75,比红灯左缘还靠左 2.25,这是预期而非错位。+// 三个内边距是同一条轴推出来的,改任何一个都必须重算另外两个。++/// 行首槽位:取最大前导元素(品牌图 18px)的尺寸;槽位内**居中**,+/// 于是 14/15px 的小图标中心也落在轴上。+pub const LEAD_BOX: Pixels = px(18.);+/// 行左内边距 = 26.75(轴) − 9(槽位半宽) − 10(SIDEBAR_EDGE,容器那一半)+pub const LEAD_INSET: Pixels = px(7.75);+/// 分组项(agent/项目)相对轴的右缩进,表达从属。+/// 压轴的只有主导航行与组头;分组项一律偏这么多。+pub const SUB_INDENT: Pixels = px(12.);+/// 组头左内边距:让首字母字形中心落在轴上。组头用 FONT_BODY 常规字重,+/// 实测 A 宽 8.25、P 宽 7.25,两者字形中心恰好重合,一个值同时命中两个组头。+/// **字号或字重一变这个数就失效**——它是从字形宽度反推的,不是间距刻度+/// (semibold 时实测需 12.0/12.25,两个组头还对不上同一个值)。+/// 12.125 实测落位 −0.125;调到 12.25 反而变成 +0.375——2x 屏光栅化步长是+/// 0.5px,两者落进不同物理像素,别再往小数点后调了。+pub const GROUP_HEAD_INSET: Pixels = px(12.125);+/// 侧栏标题 "Wake" 的左内边距:同样让首字母 W 的字形中心落在轴上。+/// 实测 16px semibold 的 W 宽 14.25、左承距 0.5,文字左缘需 19.65;+/// 减去容器的 SIDEBAR_EDGE 得 9.15,取 9.0(2x 屏下 0.5px 以下的差会被光栅化吃掉)。+pub const TITLE_INSET: Pixels = px(9.);+/// 侧栏主导航行高(固定区:All Sessions/Starred;搜索框同高)+pub const ROW_HEIGHT: Pixels = px(32.);+/// 侧栏子级行高(分组展开项:agent/项目)——比主导航低一级,+/// 配 FONT_CAPTION 形成侧栏纵向层级(macOS 原生侧栏惯例)+pub const ROW_HEIGHT_SUB: Pixels = px(26.);++// ---------------- 交互态文字 ----------------++/// gpui 陷阱兜底:`.hover()`/`.active()` 闭包的 text 样式对 base 是**整体替换**+/// (`Style.text` 无 `#[refineable]`,refine 直接覆盖)——闭包里只改文字色会把+/// base 的字号一并丢掉、回退窗口默认 14px。交互闭包内改文字色一律走本方法,+/// 把该元素 base 的字号原样重申;禁止在 hover/active 里裸调 `text_color`+/// (图标-only 元素除外:图标尺寸走 `with_size`,不受 text 替换影响)。+pub trait TextColored: Styled + Sized {+ fn text_colored(self, color: Hsla, size: Pixels) -> Self {+ self.text_color(color).text_size(size)+ }+}++impl<T: Styled + Sized> TextColored for T {}diff --git a/crates/wake/src/workbench.rs b/crates/wake/src/workbench.rsnew file mode 100644index 0000000..b5511f7--- /dev/null+++ b/crates/wake/src/workbench.rs@@ -0,0 +1,2531 @@+// ============================================================================+// DIRECTION CONTRACT (impeccable)+// THESIS: 找回任何一段 agent 对话只需几秒;界面以 macOS 原生语言隐入背景,+// 拒绝"开发者工具=黑底霓虹终端风"的品类默认。+// OWN-WORLD: Things/Bear + Claude 客户端基准的原生 macOS 质感——暖白/暖黑双模式、+// 色差分区(无 hairline 依赖)、8px 圆角胶囊选中态(按钮 6px)、系统蓝 accent、+// lucide 单线图标、SF 系统字体 14px 基准;agent 品牌色仅作识别圆点。+// STORY: 打开即见全部会话按时间流动;左栏收窄范围,中栏定位会话,右栏读全文;+// ⌘K 直达任意一句话;一键回到终端继续。+// FIRST VIEWPORT: 全高三栏——240px 侧栏(全局搜索/全部/收藏/智能体/项目)、+// 372px 会话列表(22px 上下文标题+双行卡),余宽详情(标题+操作+markdown 正文)。+// FORM: brief-pinned canon(用户指定"现代 macOS 设计规范",对标 Things/Bear);+// concept tournament 依规跳过,canon at full fidelity。+// FINISH: unreviewed and undocumented is unfinished; this build ends with the+// finish review, the verdict, and DESIGN.md+// ============================================================================+use std::cell::Cell;+use std::collections::{HashMap, HashSet};+use std::path::PathBuf;+use std::rc::Rc;+use std::sync::Arc;++use futures::StreamExt;+use gpui::prelude::FluentBuilder as _;+use gpui::*;+use gpui_component::button::{Button, ButtonCustomVariant, ButtonVariants as _};+use gpui_component::input::{Input, InputEvent, InputState};+use gpui_component::list::{List, ListDelegate, ListEvent, ListItem, ListState};+use gpui_component::menu::{DropdownMenu as _, PopupMenuItem};+use gpui_component::notification::Notification;+use gpui_component::progress::Progress;+use gpui_component::scroll::ScrollableElement as _;+use gpui_component::spinner::Spinner;+use gpui_component::text::{TextView, TextViewStyle};+use gpui_component::{+ h_flex, v_flex, ActiveTheme as _, Icon, IndexPath, Root, Sizable as _,+ StyledExt as _, TitleBar, WindowExt as _,+};++use wake_core::adapters::{create_adapters, AgentAdapter};+use wake_core::db::Store;+use wake_core::models::*;+use wake_core::scanner::{run_scan, ScanEvents, ScanProgress};+use wake_core::services::{exporter, terminal};+use wake_core::watcher::{start_watcher, SessionWatcher};++use crate::ui::*;+use crate::format::{abs_date, fmt_tokens, one_line, relative_time};++actions!(wake, [ToggleSearch, RefreshSessions, PaletteUp, PaletteDown]);++pub const KEY_CONTEXT: &str = "Workbench";+/// ⌘K 面板容器的 key context(main.rs 的 ↑↓ 绑定与 dialog 元素共用)+pub const PALETTE_CONTEXT: &str = "WakePalette";+/// ⌘K 面板内容总高(输入行 + 结果列表 + footer);列表 flex_1 吃剩余空间+const PALETTE_HEIGHT: Pixels = px(492.);++fn icon(path: &'static str) -> Icon {+ Icon::empty().path(path)+}++/// 起一条后台扫描线程。启动时的自动扫描(full=false)与用户主动重扫(full=true)+/// 共用;返回的 Result 由 run_scan 的终态事件代为上报,这里只需丢弃。+fn spawn_scan(+ adapters: Arc<Vec<Box<dyn AgentAdapter>>>,+ store: Arc<Store>,+ events: Arc<dyn ScanEvents>,+ full: bool,+) {+ std::thread::spawn(move || {+ let _ = run_scan(&adapters, &store, events.as_ref(), full);+ });+}++// ---------------- 后台事件桥 ----------------++enum BgEvent {+ Progress(ScanProgress),+ Changed,+}++struct ChannelEvents(futures::channel::mpsc::UnboundedSender<BgEvent>);++impl ScanEvents for ChannelEvents {+ fn on_progress(&self, p: &ScanProgress) {+ let _ = self.0.unbounded_send(BgEvent::Progress(p.clone()));+ }+ fn on_sessions_changed(&self) {+ let _ = self.0.unbounded_send(BgEvent::Changed);+ }+}++// ---------------- 会话列表 delegate ----------------++pub struct SessionsDelegate {+ pub sessions: Vec<SessionMeta>,+}++impl ListDelegate for SessionsDelegate {+ type Item = ListItem;++ fn items_count(&self, _section: usize, _cx: &App) -> usize {+ self.sessions.len()+ }++ fn render_item(+ &mut self,+ ix: IndexPath,+ _window: &mut Window,+ cx: &mut Context<ListState<Self>>,+ ) -> Option<Self::Item> {+ let s = self.sessions.get(ix.row)?;+ let theme = cx.theme();++ Some(+ ListItem::new(ix.row).rounded(theme.radius).mx(SPACE_SM).child(+ v_flex()+ .w_full()+ .px(SPACE_XS)+ .py(SPACE_SM)+ .gap(SPACE_XS)+ .child(+ h_flex()+ .gap_1p5()+ .child(+ div()+ .flex_1()+ .min_w_0()+ .text_size(FONT_BODY)+ .font_medium()+ .text_color(theme.foreground)+ .truncate()+ .child(s.title.clone()),+ )+ .when(s.pinned, |this| {+ this.child(+ icon("icons/pin-filled.svg")+ .with_size(px(11.))+ .text_color(theme.primary),+ )+ })+ .when(s.favorite, |this| {+ this.child(+ icon("icons/star-filled.svg")+ .with_size(px(11.))+ .text_color(rgb(crate::theme::STAR_YELLOW)),+ )+ }),+ )+ .child(+ h_flex()+ .gap_1p5()+ .text_size(FONT_LABEL)+ .text_color(theme.muted_foreground)+ .child(img(s.agent.brand_icon(theme.mode.is_dark())).size(px(15.)).flex_shrink_0())+ .child(badge(s.project_name.clone(), theme.muted, theme.muted_foreground))+ .child(div().flex_1())+ .child(div().flex_shrink_0().child(relative_time(s.updated_at))),+ ),+ ),+ )+ }++ // 点击/回车走 ListEvent::Confirm(ix),无需自存选中态+ fn set_selected_index(+ &mut self,+ _ix: Option<IndexPath>,+ _window: &mut Window,+ _cx: &mut Context<ListState<Self>>,+ ) {+ }+}++// ---------------- 搜索面板 delegate ----------------++pub struct SearchDelegate {+ pub hits: Vec<SearchHit>,+ pub degraded: bool,+ store: Arc<Store>,+ last_query: String,+}++impl ListDelegate for SearchDelegate {+ type Item = ListItem;++ fn items_count(&self, _section: usize, _cx: &App) -> usize {+ self.hits.len()+ }++ fn render_item(+ &mut self,+ ix: IndexPath,+ _window: &mut Window,+ cx: &mut Context<ListState<Self>>,+ ) -> Option<Self::Item> {+ let h = self.hits.get(ix.row)?;+ let theme = cx.theme();+ let snippet = h+ .snippet+ .replace(HL_OPEN, "「")+ .replace(HL_CLOSE, "」")+ .replace('\n', " ");+ Some(+ // ListItem 无默认 margin,行块与内容区同宽(胶囊边对齐 Scope 行/+ // 输入行);块内文字缩进保持组件默认(px_3)+ 内容 px_2+ ListItem::new(ix.row).rounded(theme.radius).child(+ v_flex()+ .w_full()+ .px_2()+ .py_2p5()+ .gap_1p5()+ .child(+ h_flex()+ .gap_2()+ .text_size(FONT_CAPTION)+ .child(img(h.session.agent.brand_icon(theme.mode.is_dark())).size(px(15.)).flex_shrink_0())+ .child(+ div()+ .min_w_0()+ .font_medium()+ .text_color(theme.foreground)+ .truncate()+ .child(h.session.title.clone()),+ )+ .child(div().flex_1())+ .child(+ div()+ .flex_shrink_0()+ .text_size(FONT_CAPTION)+ .text_color(theme.muted_foreground)+ .child(format!(+ "{} · {}",+ h.session.project_name,+ relative_time(h.timestamp.unwrap_or(0))+ )),+ ),+ )+ .child(+ div()+ .text_size(FONT_CAPTION)+ .text_color(theme.muted_foreground)+ .truncate()+ .child(snippet),+ ),+ ),+ )+ }++ fn set_selected_index(+ &mut self,+ _ix: Option<IndexPath>,+ _window: &mut Window,+ _cx: &mut Context<ListState<Self>>,+ ) {+ }++ fn perform_search(+ &mut self,+ query: &str,+ window: &mut Window,+ cx: &mut Context<ListState<Self>>,+ ) -> gpui::Task<()> {+ let q = query.to_string();+ self.last_query = q.clone();+ let store = self.store.clone();+ let bg = cx.background_spawn(async move {+ if q.trim().is_empty() {+ (Vec::new(), false)+ } else {+ store.search(&q, &[], None, 60).unwrap_or((Vec::new(), false))+ }+ });+ cx.spawn_in(window, async move |this, cx| {+ let (hits, degraded) = bg.await;+ this.update(cx, |state, cx| {+ let d = state.delegate_mut();+ d.hits = hits;+ d.degraded = degraded;+ cx.notify();+ })+ .ok();+ })+ }++ // 查询为空时的引导页也走这里:搜索框已拆出 List 自管(searchable(false)),+ // ListState 不再有 query_input,render_initial 永不触发+ fn render_empty(+ &mut self,+ _window: &mut Window,+ cx: &mut Context<ListState<Self>>,+ ) -> impl IntoElement {+ let theme = cx.theme();+ if self.last_query.trim().is_empty() {+ return v_flex()+ .h(px(250.))+ .w_full()+ .justify_center()+ .child(empty_state(+ "icons/search.svg",+ px(48.),+ px(22.),+ "Search full conversation text",+ "Matches natural language and code, like \"useEffect(\".",+ cx,+ ));+ }+ v_flex()+ .h(px(250.))+ .w_full()+ .items_center()+ .justify_center()+ .gap_3()+ .text_color(theme.muted_foreground)+ .child(icon("icons/inbox.svg").with_size(px(24.)))+ .child(+ div()+ .text_size(FONT_BODY)+ .font_medium()+ .child(format!("No results for \"{}\"", self.last_query)),+ )+ .child(+ div()+ .text_size(FONT_CAPTION)+ .child("Try a different or shorter query."),+ )+ }++ fn render_section_header(+ &mut self,+ _section: usize,+ _window: &mut Window,+ cx: &mut Context<ListState<Self>>,+ ) -> Option<impl IntoElement> {+ if !self.degraded {+ return None;+ }+ Some(+ div()+ .px_2()+ .pb_1()+ .text_size(FONT_LABEL)+ .text_color(cx.theme().muted_foreground)+ .child("Short query — using fallback search. Longer keywords are faster."),+ )+ }+}++// ---------------- 详情状态 ----------------++struct DetailState {+ meta: SessionMeta,+ /// 过滤后的可见消息。Rc 让行渲染以引用计数克隆代替整条消息深拷贝+ transcript: Rc<Vec<TranscriptMessage>>,+ loading: bool,+ /// 逐消息不等高列表(gpui 原生 ListState,惰性测量)+ msg_list: gpui::ListState,+ /// 展开的工具簇/thinking(按消息在 transcript 里的下标)+ expanded_rows: HashSet<usize>,+ /// 搜索跳转目标(FTS seq,契约=消息 seq);解析完成后滚到该消息并保持高亮+ jump_seq: Option<i64>,+}++// ---------------- Workbench ----------------++pub struct Workbench {+ focus_handle: FocusHandle,+ store: Arc<Store>,+ adapters: Arc<Vec<Box<dyn AgentAdapter>>>,++ selected_agent: Option<AgentId>,+ selected_project: Option<String>,+ favorite_only: bool,+ sort_key: SortKey,+ sort_ascending: bool,++ agent_counts: Vec<(AgentId, i64)>,+ projects: Vec<ProjectInfo>,+ agents_collapsed: bool,+ projects_collapsed: bool,+ starred_count: i64,+ /// 后台扫描的最新状态,启动时的自动扫描与用户主动重扫共用。整份留存而不是+ /// 摊成几个字段:刷新入口的守卫、侧栏状态文案、按钮 busy 态全部从它派生,+ /// 单一写入点就不会互相失步——把派生出的文案反过来当守卫,正是+ /// "扫描失败后刷新按钮再也点不动"的来源+ scan: ScanProgress,+ /// 用户主动重扫中(模态进度弹窗开着,阻断其他操作)。与 scan.scanning 正交:+ /// 那是"扫没扫",这是"要不要弹模态"+ refreshing: bool,+ /// 全量解析进度 (done, total);None = 仍在枚举文件。+ /// 用 Rc<Cell> 而非 entity 字段:进度弹窗 builder 在本 entity 的+ /// render 期间执行,entity.read(cx) 会 double-lease panic。+ refresh_progress: Rc<Cell<Option<(usize, usize)>>>,+ total_sessions: i64,++ list_state: Entity<ListState<SessionsDelegate>>,+ palette_list: Entity<ListState<SearchDelegate>>,+ /// ⌘K 搜索输入框(自管,不用 List 内置 searchable:清除钮可控)+ palette_input: Entity<InputState>,+ /// 进行中的搜索任务;新输入覆盖旧值即取消过期搜索+ _palette_search_task: Option<Task<()>>,++ detail: Option<DetailState>,++ scan_events: Arc<dyn ScanEvents>,+ watcher: Option<SessionWatcher>,+ /// 终端 id → 提取好的应用图标 png(后台 JXA 提取,详情页 Open In 用)+ terminal_icons: HashMap<String, PathBuf>,+ /// Open In 上次选择(split 按钮左段直开目标),None = 已装列表首个+ preferred_terminal: Option<terminal::TerminalApp>,+ _subs: Vec<Subscription>,+}++impl Workbench {+ pub fn new(window: &mut Window, cx: &mut Context<Self>) -> Self {+ let db_path = wake_core::db::default_db_path();+ // 库损坏时降级重建而不是崩掉:GUI 秒退什么都不告诉用户,他们也无从知道+ // 删掉那个文件就能自愈。重建也失败说明是目录权限/磁盘问题,那才没救——+ // 但至少要用系统弹窗把话说清楚再退。+ let (store, db_note) = match wake_core::db::open_or_rebuild(&db_path) {+ Ok(v) => v,+ Err(e) => {+ terminal::show_fatal_alert(&format!(+ "Wake couldn't open or rebuild its index at {}. {e}",+ db_path.display()+ ));+ std::process::exit(1);+ }+ };+ let store = Arc::new(store);+ let adapters: Arc<Vec<Box<dyn AgentAdapter>>> = Arc::new(create_adapters());++ let list_state = cx.new(|cx| {+ ListState::new(+ SessionsDelegate {+ sessions: Vec::new(),+ },+ window,+ cx,+ )+ .searchable(false)+ });+ let palette_list = cx.new(|cx| {+ ListState::new(+ SearchDelegate {+ hits: Vec::new(),+ degraded: false,+ store: store.clone(),+ last_query: String::new(),+ },+ window,+ cx,+ )+ .searchable(false)+ });+ let palette_input = cx.new(|cx| {+ InputState::new(window, cx).placeholder("Search everything \u{2014} prose or code")+ });++ // 后台:全量扫描线程 + 文件监听+ let (tx, mut rx) = futures::channel::mpsc::unbounded::<BgEvent>();+ let events: Arc<dyn ScanEvents> = Arc::new(ChannelEvents(tx));+ spawn_scan(adapters.clone(), store.clone(), events.clone(), false);+ let watcher = start_watcher(adapters.clone(), store.clone(), events.clone());+ let scan_events = events.clone();++ cx.spawn_in(window, async move |this, cx| {+ while let Some(ev) = rx.next().await {+ if this+ .update_in(cx, |this, window, cx| this.on_bg_event(ev, window, cx))+ .is_err()+ {+ break;+ }+ }+ })+ .detach();++ let subs = vec![+ cx.subscribe_in(&list_state, window, Self::on_list_event),+ cx.subscribe_in(&palette_list, window, Self::on_palette_event),+ cx.subscribe_in(&palette_input, window, Self::on_palette_input_event),+ ];++ let mut this = Self {+ focus_handle: cx.focus_handle(),+ store,+ adapters,+ selected_agent: None,+ selected_project: None,+ sort_key: SortKey::Updated,+ sort_ascending: false,+ favorite_only: false,+ agent_counts: Vec::new(),+ projects: Vec::new(),+ agents_collapsed: false,+ projects_collapsed: false,+ starred_count: 0,+ // 扫描线程已在上面 spawn,首个 Progress 事件到达前先占位为"扫描中",+ // 否则这个窗口内按 ⌘R 会起第二条并发全量扫描+ scan: ScanProgress {+ scanning: true,+ ..Default::default()+ },+ refreshing: false,+ refresh_progress: Rc::new(Cell::new(None)),+ total_sessions: 0,+ list_state,+ palette_list,+ palette_input,+ _palette_search_task: None,+ detail: None,+ scan_events,+ watcher,+ terminal_icons: HashMap::new(),+ preferred_terminal: None,+ _subs: subs,+ };+ this.refresh(window, cx);++ // 索引重建过就告诉用户一声——收藏/置顶没了,总得让人知道为什么。+ // defer 到下一帧:此刻 Root 还没建好,notification 层挂不上+ if let Some(note) = db_note {+ cx.defer_in(window, move |_, window, cx| {+ window.push_notification(Notification::warning(note), cx);+ });+ }++ // 终端应用图标后台提取(首次数百 ms,之后命中缓存)+ let icons_task = cx.background_spawn(async {+ let dir = dirs::data_dir().unwrap_or_default().join("wake").join("app-icons");+ terminal::ensure_app_icons(&dir)+ });+ cx.spawn_in(window, async move |this, cx| {+ let icons = icons_task.await;+ this.update(cx, |this, cx| {+ this.terminal_icons = icons;+ cx.notify();+ })+ .ok();+ })+ .detach();+ this+ }++ // ---------- 数据刷新 ----------++ fn current_filter(&self) -> SessionFilter {+ SessionFilter {+ agents: self.selected_agent.into_iter().collect(),+ project_path: self.selected_project.clone(),+ favorite_only: self.favorite_only,+ include_archived: false,+ title_query: None,+ sort: self.sort_key,+ ascending: self.sort_ascending,+ limit: 500,+ offset: 0,+ }+ }++ fn refresh(&mut self, _window: &mut Window, cx: &mut Context<Self>) {+ let filter = self.current_filter();+ if let Ok((sessions, total)) = self.store.list_sessions(&filter) {+ self.total_sessions = total;+ self.list_state.update(cx, |state, cx| {+ state.delegate_mut().sessions = sessions;+ cx.notify();+ });+ }+ let mut counts: Vec<(AgentId, i64)> = self+ .store+ .agent_counts()+ .unwrap_or_default()+ .into_iter()+ .filter_map(|(k, v)| AgentId::from_str(&k).map(|a| (a, v)))+ .collect();+ counts.sort_by(|a, b| b.1.cmp(&a.1));+ self.agent_counts = counts;+ self.projects = self.store.list_projects().unwrap_or_default();+ self.starred_count = self.store.starred_count().unwrap_or(0);+ cx.notify();+ }++ /// 手动全量重扫(菜单 File → Refresh Sessions,⌘R)。刷新中忽略重复触发。+ /// 弹出模态进度弹窗阻断其他操作,完成后 on_bg_event 自动关闭。+ fn refresh_sessions(&mut self, window: &mut Window, cx: &mut Context<Self>) {+ if self.scan.scanning {+ return;+ }+ self.scan = ScanProgress {+ scanning: true,+ ..Default::default()+ };+ self.refresh_progress.set(None);+ self.refreshing = true;+ cx.notify();+ spawn_scan(+ self.adapters.clone(),+ self.store.clone(),+ self.scan_events.clone(),+ true,+ );++ let shared_progress = self.refresh_progress.clone();+ window.open_dialog(cx, move |dialog, _window, cx| {+ let progress = shared_progress.get();+ let theme = cx.theme();+ let (pct, note) = match progress {+ Some((done, total)) if total > 0 => (+ ((done as f32 / total as f32) * 100.).max(3.),+ format!("{done} of {total} sessions"),+ ),+ _ => (3., "Looking for sessions…".to_string()),+ };+ dialog+ .w(px(380.))+ .close_button(false)+ .overlay_closable(false)+ .keyboard(false)+ .child(+ v_flex()+ .gap(SPACE_LG)+ .child(+ h_flex()+ .gap_2()+ .child(Spinner::new().small())+ .child(+ div()+ .text_size(FONT_HEADING)+ .font_semibold()+ .text_color(theme.foreground)+ .child("Refreshing sessions"),+ ),+ )+ .child(Progress::new().value(pct))+ .child(+ div()+ .text_size(FONT_CAPTION)+ .text_color(theme.muted_foreground)+ .child(note),+ ),+ )+ });+ }++ fn on_bg_event(&mut self, ev: BgEvent, window: &mut Window, cx: &mut Context<Self>) {+ match ev {+ BgEvent::Progress(p) => {+ self.refresh_progress.set(if p.total > 0 {+ Some((p.done, p.total))+ } else {+ None+ });+ if !p.scanning && self.refreshing {+ self.refreshing = false;+ window.close_dialog(cx);+ let note = match &p.error {+ None => Notification::success("Sessions refreshed"),+ Some(err) => Notification::error(format!("Refresh failed: {err}")),+ };+ window.push_notification(note, cx);+ }+ self.scan = p;+ cx.notify();+ }+ BgEvent::Changed => self.refresh(window, cx),+ }+ }++ // ---------- 事件处理 ----------++ fn on_list_event(+ &mut self,+ list: &Entity<ListState<SessionsDelegate>>,+ ev: &ListEvent,+ window: &mut Window,+ cx: &mut Context<Self>,+ ) {+ let ix = match ev {+ ListEvent::Select(ix) | ListEvent::Confirm(ix) => *ix,+ ListEvent::Cancel => return,+ };+ let key = list+ .read(cx)+ .delegate()+ .sessions+ .get(ix.row)+ .map(|s| s.key.clone());+ if let Some(key) = key {+ self.open_detail(&key, None, window, cx);+ }+ }++ fn on_palette_event(+ &mut self,+ _list: &Entity<ListState<SearchDelegate>>,+ ev: &ListEvent,+ window: &mut Window,+ cx: &mut Context<Self>,+ ) {+ match ev {+ ListEvent::Confirm(ix) => self.open_palette_hit(ix.row, window, cx),+ // Select 仅表示高亮移动,不打开+ ListEvent::Select(_) => {}+ // 焦点在结果列表内(鼠标点过行)时 esc 走这里;焦点在输入框时+ // esc 由 Input 冒泡给 Dialog 的 keyboard Cancel 关闭+ ListEvent::Cancel => window.close_dialog(cx),+ }+ }++ pub fn toggle_search(+ &mut self,+ _: &ToggleSearch,+ window: &mut Window,+ cx: &mut Context<Self>,+ ) {+ if self.refreshing {+ return;+ }+ if window.has_active_dialog(cx) {+ window.close_dialog(cx);+ return;+ }+ let list = self.palette_list.clone();+ let input = self.palette_input.clone();+ let this = cx.entity();+ window.open_dialog(cx, move |dialog, window, cx| {+ let theme = cx.theme();+ let has_query = input.read(cx).text().len() > 0;+ // 输入框尺寸;清除钮的 suffix 补偿 margin 从它派生,改档自动跟随+ let input_size = gpui_component::Size::Large;+ dialog+ .w(px(680.))+ .margin_top(px(72.))+ // Dialog 默认内容 padding 24px 四边;水平 20,用户定稿(2026-08-18)+ .px(SPACE_XL)+ .close_button(false)+ .overlay_closable(true)+ .child(+ v_flex()+ // ↑↓ 在 Input 内不被消费,冒泡到这里走 main.rs 的+ // PALETTE_CONTEXT 键位(Input 拆出 List 后原生 List 绑定够不着)+ .key_context(PALETTE_CONTEXT)+ .on_action(window.listener_for(&this, |wb: &mut Self, _: &PaletteUp, window, cx| {+ wb.palette_move(-1, window, cx)+ }))+ .on_action(window.listener_for(&this, |wb: &mut Self, _: &PaletteDown, window, cx| {+ wb.palette_move(1, window, cx)+ }))+ // 定高 + 列表 flex_1:输入行/footer 尺寸变化时列表自适应,+ // 不用手工重算列表高度+ .h(PALETTE_HEIGHT)+ .gap_3()+ .child(+ div()+ .flex_shrink_0()+ .px(SPACE_SM)+ .border_b_1()+ .border_color(theme.border)+ .child(+ Input::new(&input)+ .with_size(input_size)+ .prefix(+ icon("icons/search.svg")+ .with_size(px(16.))+ .text_color(theme.muted_foreground),+ )+ // 清除钮自绘,不用内置 cleanable:内置钮固定+ // xsmall(实渲 10.5px 图标)且无尺寸配置口+ .when(has_query, |i| {+ i.suffix(+ div()+ .id("palette-clear")+ .size(px(24.))+ // 抵消组件对 suffix 区强加的+ // pr(input_px(size)),它在 p_0+ // 之后应用盖不掉;不抵消则清除钮+ // 右缩进与左侧放大镜不对称+ .mr(-input_size.input_px())+ .flex()+ .items_center()+ .justify_center()+ .rounded(theme.radius)+ .cursor_pointer()+ .text_color(theme.muted_foreground)+ // 图标-only:尺寸走 with_size,+ // hover 裸改色不踩 text 替换陷阱+ .hover(|s| {+ s.bg(theme.secondary_hover)+ .text_color(theme.foreground)+ })+ .on_click({+ let input = input.clone();+ move |_, window, cx| {+ input.update(cx, |st, cx| {+ st.set_value("", window, cx);+ st.focus(window, cx);+ });+ }+ })+ .child(+ icon("icons/circle-x.svg")+ .with_size(px(16.)),+ ),+ )+ })+ .p_0()+ .appearance(false),+ ),+ )+ .child(+ List::new(&list)+ .with_size(gpui_component::Size::Large)+ .flex_1()+ .min_h_0(),+ )+ .child(+ h_flex()+ .flex_shrink_0()+ .border_t_1()+ .border_color(theme.border)+ .pt(SPACE_SM)+ // 与输入行的壳同缩进:文字与放大镜/清除钮左右对齐+ .px(SPACE_SM)+ .justify_between()+ .text_size(FONT_LABEL)+ .text_color(theme.muted_foreground)+ .child("Scope: all sessions")+ .child(+ h_flex()+ .gap_3()+ .child("\u{2191}\u{2193} navigate")+ .child("\u{21a9} open")+ .child("esc close"),+ ),+ ),+ )+ });+ let focus_input = self.palette_input.clone();+ cx.defer_in(window, move |_, window, cx| {+ focus_input.update(cx, |st, cx| st.focus(window, cx));+ });+ cx.notify();+ }++ /// ⌘K 输入框事件:文字变化驱动搜索,回车打开选中项+ fn on_palette_input_event(+ &mut self,+ input: &Entity<InputState>,+ ev: &InputEvent,+ window: &mut Window,+ cx: &mut Context<Self>,+ ) {+ match ev {+ InputEvent::Change => {+ let q = input.read(cx).value().trim().to_string();+ if self.palette_list.read(cx).delegate().last_query == q {+ return;+ }+ // 清空(点清除钮/删光)结果已知,同步清态,省掉线程往返+ if q.is_empty() {+ self._palette_search_task = None;+ self.palette_list.update(cx, |state, cx| {+ let d = state.delegate_mut();+ d.hits = Vec::new();+ d.degraded = false;+ d.last_query = String::new();+ state.set_selected_index(None, window, cx);+ cx.notify();+ });+ return;+ }+ let task = self.palette_list.update(cx, |state, cx| {+ state.set_selected_index(None, window, cx);+ state.delegate_mut().perform_search(&q, window, cx)+ });+ // 搜索回填后选中首条并回滚到顶(覆盖旧任务 = 取消过期搜索)+ self._palette_search_task = Some(cx.spawn_in(window, async move |this, cx| {+ task.await;+ this.update_in(cx, |this, window, cx| {+ this.palette_list.update(cx, |state, cx| {+ let has_hits = !state.delegate().hits.is_empty();+ state.set_selected_index(+ has_hits.then(IndexPath::default),+ window,+ cx,+ );+ // scroll_to_item 自带 notify,列表随之重绘+ state.scroll_to_item(+ IndexPath::default(),+ ScrollStrategy::Top,+ window,+ cx,+ );+ });+ })+ .ok();+ }));+ }+ InputEvent::PressEnter { .. } => {+ let row = self+ .palette_list+ .read(cx)+ .selected_index()+ .map(|i| i.row)+ .unwrap_or(0);+ self.open_palette_hit(row, window, cx);+ }+ _ => {}+ }+ }++ /// 打开第 row 条搜索命中(回车与鼠标点击共用),定位到命中消息+ fn open_palette_hit(&mut self, row: usize, window: &mut Window, cx: &mut Context<Self>) {+ let hit = self+ .palette_list+ .read(cx)+ .delegate()+ .hits+ .get(row)+ .map(|h| (h.session.key.clone(), h.seq));+ if let Some((key, seq)) = hit {+ window.close_dialog(cx);+ self.open_detail(&key, Some(seq), window, cx);+ }+ }++ /// ⌘K 面板 ↑↓:焦点在输入框,选中态手动挪(clamp 到两端,不循环)。+ /// 按 row 平移——SearchDelegate 单 section,section 恒 0+ fn palette_move(&mut self, delta: i64, window: &mut Window, cx: &mut Context<Self>) {+ self.palette_list.update(cx, |state, cx| {+ let n = state.delegate().hits.len() as i64;+ if n == 0 {+ return;+ }+ let cur = state+ .selected_index()+ .map(|ix| ix.row as i64)+ .unwrap_or(-1);+ let next = (cur + delta).clamp(0, n - 1) as usize;+ state.set_selected_index(Some(IndexPath::new(next)), window, cx);+ // scroll_to_selected_item 内部 notify,选中高亮随之重绘+ state.scroll_to_selected_item(window, cx);+ });+ }++ // ---------- 详情 ----------++ fn open_detail(+ &mut self,+ key: &str,+ jump_seq: Option<i64>,+ window: &mut Window,+ cx: &mut Context<Self>,+ ) {+ let Ok(Some(meta)) = self.store.get_session(key) else {+ return;+ };+ self.detail = Some(DetailState {+ meta: meta.clone(),+ transcript: Rc::new(Vec::new()),+ loading: true,+ // Bottom 对齐 = 聊天语义:打开落在最新消息,向上翻历史+ msg_list: gpui::ListState::new(0, gpui::ListAlignment::Bottom, px(512.)),+ expanded_rows: HashSet::new(),+ jump_seq,+ });+ // 搜索路径:中栏列表同步选中并滚到该会话。+ // 列表点击路径(jump=None)不走——List 点击自带选中,再滚会跳视口+ if jump_seq.is_some() {+ self.sync_list_selection(key, window, cx);+ }+ cx.notify();++ let adapters = self.adapters.clone();+ let task = cx.background_spawn(async move {+ let adapter = adapters.iter().find(|a| a.agent() == meta.agent)?;+ let r = SessionFileRef::from_meta(&meta);+ let t = adapter.parse_transcript(&r).ok()?;+ let visible: Vec<TranscriptMessage> = t+ .mainline+ .into_iter()+ .filter(|m| {+ m.kind != MessageKind::Meta+ && (!m.text.trim().is_empty()+ || !m.tool_calls.is_empty()+ || m.thinking.is_some()+ || m.kind == MessageKind::CompactSummary)+ })+ .collect();+ Some((meta.key.clone(), visible))+ });+ cx.spawn_in(window, async move |this, cx| {+ let result = task.await;+ this.update_in(cx, |this, _window, cx| {+ if let Some(detail) = &mut this.detail {+ match result {+ Some((key, messages)) if key == detail.meta.key => {+ detail.msg_list =+ gpui::ListState::new(messages.len(), gpui::ListAlignment::Bottom, px(512.));+ // 搜索跳转:seq → 可见消息下标,滚到视口顶。+ // FTS 命中的行可能被详情过滤(如空文本),用 >= 落到+ // 其后最近一条;找不到(尾部被滤)则保持默认落底。+ // jump_seq 归一为落点消息的实际 seq——高亮按精确相等+ // 渲染,不归一则命中被滤时滚动与高亮指向不同行+ if let Some(seq) = detail.jump_seq {+ if let Some(ix) = messages.iter().position(|m| m.seq >= seq) {+ detail.jump_seq = Some(messages[ix].seq);+ detail.msg_list.scroll_to(gpui::ListOffset {+ item_ix: ix,+ offset_in_item: px(0.),+ });+ }+ }+ detail.transcript = Rc::new(messages);+ detail.loading = false;+ }+ _ => detail.loading = false,+ }+ }+ cx.notify();+ })+ .ok();+ })+ .detach();+ }++ /// 清空过滤回 All Sessions 视图(侧栏点击与搜索打开共用;+ /// 已在 All Sessions 时 refresh 幂等,微秒级)+ fn show_all_sessions(&mut self, window: &mut Window, cx: &mut Context<Self>) {+ self.selected_agent = None;+ self.selected_project = None;+ self.favorite_only = false;+ self.refresh(window, cx);+ }++ /// 搜索命中打开:侧栏切回 All Sessions(搜索是全库范围,过滤视图下+ /// 命中可能不在列表里),中栏定位选中该会话并滚到可见+ fn sync_list_selection(&mut self, key: &str, window: &mut Window, cx: &mut Context<Self>) {+ self.show_all_sessions(window, cx);+ let row = self+ .list_state+ .read(cx)+ .delegate()+ .sessions+ .iter()+ .position(|s| s.key == key);+ if let Some(row) = row {+ self.list_state.update(cx, |state, cx| {+ state.set_selected_index(Some(IndexPath::new(row)), window, cx);+ // 组件无 strict-Top:非 Center 策略都是"最小滚动恰好可见",+ // 目标从下方进入会贴底。先把 offset 拉到超底,deferred 消费时+ // 目标位于视口上方,最小滚动分支即把它对齐到视口顶。+ // 耦合 gpui-component 0.5.1 行为;上游 DeferredScrollToItem 的+ // scroll_strict 字段目前写死 false 未被读——它被接通之日,+ // 换成 strict-Top 调用并删掉这行 set_offset+ state.scroll_handle().set_offset(point(px(0.), px(-1e9)));+ state.scroll_to_item(IndexPath::new(row), ScrollStrategy::Top, window, cx);+ });+ }+ }++ // ---------- 操作 ----------++ /// 后台任务完成 → 推通知的通用桥(do_resume/do_export 共用)+ fn notify_when_done<T: Send + 'static>(+ window: &mut Window,+ cx: &mut Context<Self>,+ task: gpui::Task<T>,+ to_note: impl FnOnce(T) -> Notification + Send + 'static,+ ) {+ cx.spawn_in(window, async move |_this, cx| {+ let result = task.await;+ cx.update(|window, cx| {+ window.push_notification(to_note(result), cx);+ })+ .ok();+ })+ .detach();+ }++ fn do_resume(&mut self, term: terminal::TerminalApp, window: &mut Window, cx: &mut Context<Self>) {+ let Some(detail) = &self.detail else { return };+ self.preferred_terminal = Some(term);+ cx.notify(); // split 按钮左段立即切到本次选择+ let meta = detail.meta.clone();+ let task = cx.background_spawn(async move { terminal::resume_session_in(&meta, term) });+ Self::notify_when_done(window, cx, task, |outcome| {+ if outcome.ok {+ Notification::success(format!("Opened in terminal: {}", outcome.command))+ } else {+ Notification::error(outcome.error.unwrap_or_else(|| "Resume failed".into()))+ }+ });+ }++ fn toggle_favorite(&mut self, window: &mut Window, cx: &mut Context<Self>) {+ if let Some(detail) = &mut self.detail {+ let v = !detail.meta.favorite;+ let _ = self.store.set_user_data(&detail.meta.key, Some(v), None);+ detail.meta.favorite = v;+ self.refresh(window, cx);+ }+ }++ fn toggle_pinned(&mut self, window: &mut Window, cx: &mut Context<Self>) {+ if let Some(detail) = &mut self.detail {+ let v = !detail.meta.pinned;+ let _ = self.store.set_user_data(&detail.meta.key, None, Some(v));+ detail.meta.pinned = v;+ self.refresh(window, cx);+ }+ }++ fn do_export(&mut self, window: &mut Window, cx: &mut Context<Self>) {+ let Some(detail) = &self.detail else { return };+ let meta = detail.meta.clone();+ let adapters = self.adapters.clone();+ let task = cx.background_spawn(async move {+ let adapter = adapters.iter().find(|a| a.agent() == meta.agent)?;+ // from_meta 对虚拟路径(SQLite 型)自动回退,导出不再依赖真实文件存在+ let r = SessionFileRef::from_meta(&meta);+ let t = adapter.parse_transcript(&r).ok()?;+ let sidechains: Vec<(SidechainInfo, Vec<TranscriptMessage>)> = t+ .sidechains+ .iter()+ .map(|sc| {+ let msgs = adapter.load_sidechain(&r, &sc.id).unwrap_or_default();+ (sc.clone(), msgs)+ })+ .collect();+ let md = exporter::to_markdown(&t.meta, &t.mainline, &sidechains);+ let name = exporter::default_file_name(&meta, "md");+ let path = dirs::download_dir()?.join(name);+ std::fs::write(&path, md).ok()?;+ Some(path)+ });+ Self::notify_when_done(window, cx, task, |path| match path {+ Some(p) => Notification::success(format!("Exported to {}", p.display())),+ None => Notification::error("Export failed"),+ });+ }++ /// 执行删除:文件进废纸篓 + 自库 tombstone。trash_paths 走 osascript 驱动+ /// Finder,首次触发自动化授权时会一直停着等用户点选——必须离开 UI 线程,+ /// 否则界面在授权框弹出的整段时间里完全冻结。+ fn do_delete(+ &mut self,+ key: String,+ targets: Vec<String>,+ window: &mut Window,+ cx: &mut Context<Self>,+ ) {+ let store = self.store.clone();+ let trash_key = key.clone();+ let task = cx.background_spawn(async move {+ terminal::trash_paths(&targets).and_then(|()| store.remove_session(&trash_key, true))+ });+ cx.spawn_in(window, async move |this, cx| {+ let result = task.await;+ this.update_in(cx, |this, window, cx| match result {+ Ok(()) => {+ // 等待期间用户可能已翻到别的会话,只在仍停在被删那条时才清空+ if this.detail.as_ref().is_some_and(|d| d.meta.key == key) {+ this.detail = None;+ }+ window.push_notification(Notification::success("Session moved to Trash"), cx);+ // 立刻把它从列表摘掉,不等 watcher 那 800ms 去抖+ this.refresh(window, cx);+ }+ Err(e) => window+ .push_notification(Notification::error(format!("Delete failed: {e}")), cx),+ })+ .ok();+ })+ .detach();+ }++ fn confirm_delete(&mut self, window: &mut Window, cx: &mut Context<Self>) {+ let Some(detail) = &self.detail else { return };+ let meta = detail.meta.clone();+ // 会话归属哪些磁盘路径(主文件/边车目录)是 adapter 的布局知识+ let targets = self+ .adapters+ .iter()+ .find(|a| a.agent() == meta.agent)+ .map(|a| a.session_paths(&meta))+ .unwrap_or_else(|| vec![meta.file_path.clone()]);+ let entity = cx.entity();+ window.open_dialog(cx, move |dialog, _window, cx| {+ let meta = meta.clone();+ let targets = targets.clone();+ let entity = entity.clone();+ let theme = cx.theme();+ dialog+ .title(div().font_semibold().child("Delete this session?"))+ .w(px(440.))+ .child(+ v_flex()+ .gap_2()+ .text_size(FONT_BODY)+ .child("The session file will be moved to Trash. You can restore it anytime:")+ .child(+ div()+ .px_2()+ .py_1()+ .rounded(theme.radius)+ .bg(theme.muted)+ .text_size(FONT_CAPTION)+ .font_family("Menlo")+ .child(meta.file_path.clone()),+ )+ .when(meta.agent == AgentId::Codex, |this| {+ this.child(+ div()+ .text_size(FONT_CAPTION)+ .text_color(theme.muted_foreground)+ .child("Only the local file is removed — Codex's own records stay intact."),+ )+ }),+ )+ .on_ok(move |_, window, cx| {+ entity.update(cx, |this, cx| {+ this.do_delete(meta.key.clone(), targets.clone(), window, cx);+ });+ true+ })+ });+ }++ fn context_title(&self) -> String {+ if self.favorite_only {+ return "Starred".to_string();+ }+ if let Some(p) = &self.selected_project {+ // 项目显示名以侧栏列表(store 的 ProjectInfo)为准,不再重推+ return self+ .projects+ .iter()+ .find(|info| info.path == *p)+ .map(|info| info.name.clone())+ .unwrap_or_else(|| "Projects".to_string());+ }+ match self.selected_agent {+ None => "All Sessions".to_string(),+ Some(one) => one.display_name().to_string(),+ }+ }++ // ---------- 渲染 ----------++ fn render_sidebar(&self, cx: &Context<Self>) -> impl IntoElement {+ let theme = cx.theme();+ let all_active = self.selected_agent.is_none()+ && self.selected_project.is_none()+ && !self.favorite_only;+ // 常态沉默,仅刷新中/监听失效时出现;None 时状态栏整行不渲染。+ // 文案在此按 scan 现算,不另存字段——存下来就会有第二个写入点要维护+ let note = if self.scan.scanning {+ Some(match self.scan.total {+ 0 => "Refreshing…".to_string(),+ total => format!("Refreshing {}/{}", self.scan.done, total),+ })+ } else {+ self.scan.error.as_ref().map(|e| format!("Refresh failed: {e}"))+ };+ let status: Option<AnyElement> = if let Some(note) = note {+ Some(+ h_flex()+ .w_full()+ .gap(SPACE_SM)+ .text_color(theme.muted_foreground)+ .child(icon("icons/refresh-cw.svg").with_size(px(12.)).flex_shrink_0())+ .child(div().min_w_0().truncate().child(note))+ .into_any_element(),+ )+ } else if self.watcher.is_none() {+ Some(+ h_flex()+ .w_full()+ .gap(SPACE_SM)+ .text_color(theme.muted_foreground)+ .child(div().size(px(7.)).rounded_full().flex_shrink_0().bg(theme.warning))+ .child(div().min_w_0().truncate().child("Live updates off"))+ .into_any_element(),+ )+ } else {+ None+ };++ v_flex()+ .w(px(224.))+ .h_full()+ .flex_shrink_0()+ .bg(theme.sidebar)+ // 压平 titlebar 靠 theme.rs 的 title_bar/title_bar_border token,不再叠加覆写+ .child(TitleBar::new())+ .child(+ div()+ .flex_shrink_0()+ .px(SIDEBAR_EDGE)+ .pt(SPACE_SM)+ .pb(SPACE_MD)+ .child(+ div()+ .pl(TITLE_INSET)+ .pr(SIDEBAR_EDGE)+ .text_size(FONT_HEADING)+ .font_semibold()+ .text_color(theme.foreground)+ .child("Wake"),+ ),+ )+ .child(+ div().flex_shrink_0().px(SIDEBAR_EDGE).pb_3().child(+ h_flex()+ .gap_2()+ .child(+ h_flex()+ .id("sidebar-search")+ .flex_1()+ .min_w_0()+ .h(ROW_HEIGHT)+ .px(SIDEBAR_EDGE)+ .gap(SPACE_SM)+ .rounded(theme.radius)+ .cursor_pointer()+ .bg(theme.secondary)+ .text_size(FONT_CAPTION)+ .text_color(theme.muted_foreground)+ .hover(|s| {+ s.bg(theme.secondary_hover)+ .text_colored(theme.foreground, FONT_CAPTION)+ })+ .active(|s| {+ s.bg(theme.secondary_active)+ .text_colored(theme.foreground, FONT_CAPTION)+ })+ .on_click(cx.listener(|this, _, window, cx| {+ this.toggle_search(&ToggleSearch, window, cx)+ }))+ .child(+ icon("icons/search.svg")+ .with_size(px(13.))+ .flex_shrink_0(),+ )+ // flex_1 + min_w_0 + truncate:空间不足时压这里,+ // 绝不把右侧刷新按钮挤出侧栏+ .child(+ div().flex_1().min_w_0().truncate().child("Search sessions"),+ )+ .child(+ div()+ .flex_shrink_0()+ .text_size(FONT_LABEL)+ .child("⌘K"),+ ),+ )+ .child({+ let busy = self.scan.scanning;+ div()+ .id("refresh")+ .size(ROW_HEIGHT)+ .flex_shrink_0()+ .rounded(theme.radius)+ .bg(theme.secondary)+ .flex()+ .items_center()+ .justify_center()+ .text_color(theme.muted_foreground)+ .when(!busy, |el| {+ el.cursor_pointer()+ .hover(|s| {+ s.bg(theme.secondary_hover)+ .text_color(theme.foreground)+ })+ .active(|s| {+ s.bg(theme.secondary_active)+ .text_color(theme.foreground)+ })+ .on_click(cx.listener(|this, _, window, cx| {+ this.refresh_sessions(window, cx)+ }))+ })+ .child(if busy {+ Spinner::new().small().into_any_element()+ } else {+ icon("icons/refresh-cw.svg")+ .with_size(px(14.))+ .into_any_element()+ })+ }),+ ),+ )+ .child(+ v_flex()+ .flex_shrink_0()+ .px(SIDEBAR_EDGE)+ .pb_1()+ .gap_1()+ .child(sidebar_row(+ "all",+ RowLead::Icon(icon("icons/layers.svg")),+ "All Sessions",+ Some(self.agent_counts.iter().map(|(_, n)| n).sum()),+ all_active,+ RowLevel::Primary,+ cx.listener(|this, _, window, cx| {+ this.show_all_sessions(window, cx);+ }),+ cx,+ ))+ .child(sidebar_row(+ "fav",+ RowLead::Icon(icon("icons/star.svg")),+ "Starred",+ if self.starred_count > 0 { Some(self.starred_count) } else { None },+ self.favorite_only,+ RowLevel::Primary,+ cx.listener(|this, _, window, cx| {+ this.favorite_only = !this.favorite_only;+ if this.favorite_only {+ this.selected_agent = None;+ this.selected_project = None;+ }+ this.refresh(window, cx);+ }),+ cx,+ )),+ )+ .child(+ v_flex()+ .id("sidebar-scroll")+ .flex_1()+ .min_h_0()+ .overflow_y_scroll()+ .px(SIDEBAR_EDGE)+ .pt_1()+ .pb_4()+ .gap_1()+ .child(group_header(+ "agents-header",+ "Agents",+ self.agents_collapsed,+ cx.listener(|this, _, _window, cx| {+ this.agents_collapsed = !this.agents_collapsed;+ cx.notify();+ }),+ cx,+ ))+ .when(!self.agents_collapsed, |this| {+ this.children(self.agent_counts.iter().map(|(agent, count)| {+ let agent = *agent;+ sidebar_row(+ agent.as_str(),+ RowLead::Brand(agent.brand_icon(theme.mode.is_dark())),+ agent.display_name(),+ Some(*count),+ self.selected_agent == Some(agent),+ RowLevel::Sub,+ cx.listener(move |this, _, window, cx| {+ this.selected_agent = if this.selected_agent == Some(agent) {+ None+ } else {+ Some(agent)+ };+ this.selected_project = None;+ this.favorite_only = false;+ this.refresh(window, cx);+ }),+ cx,+ )+ }))+ })+ .child(group_header(+ "projects-header",+ "Projects",+ self.projects_collapsed,+ cx.listener(|this, _, _window, cx| {+ this.projects_collapsed = !this.projects_collapsed;+ cx.notify();+ }),+ cx,+ ))+ .when(!self.projects_collapsed, |this| {+ this.children(self.projects.iter().enumerate().map(|(ix, p)| {+ let path = p.path.clone();+ sidebar_row(+ ("proj", ix),+ RowLead::Icon(icon("icons/folder.svg")),+ p.name.clone(),+ Some(p.session_count),+ self.selected_project.as_deref() == Some(p.path.as_str()),+ RowLevel::Sub,+ cx.listener(move |this, _, window, cx| {+ this.selected_project = if this.selected_project.as_deref()+ == Some(path.as_str())+ {+ None+ } else {+ Some(path.clone())+ };+ this.selected_agent = None;+ this.favorite_only = false;+ this.refresh(window, cx);+ }),+ cx,+ )+ }))+ }),+ )+ .when_some(status, |this, status| {+ this.child(+ h_flex()+ .flex_shrink_0()+ .px(SPACE_XL)+ .py_3()+ .border_t_1()+ .border_color(theme.sidebar_border)+ .text_size(FONT_LABEL)+ .child(status),+ )+ })+ }++ fn render_session_list(&self, cx: &Context<Self>) -> impl IntoElement {+ let theme = cx.theme();+ let shown = self.list_state.read(cx).delegate().sessions.len();+ let sort_key = self.sort_key;+ let sort_ascending = self.sort_ascending;+ let sort_entity = cx.entity();+ let sort_label = match sort_key {+ SortKey::Updated => "Date updated",+ SortKey::Created => "Date created",+ SortKey::Messages => "Message count",+ };+ // ghost + 当前排序文案(outline/muted 胶囊都试过,用户定的 ghost)+ let sort_menu = Button::new("sort-sessions")+ .ghost()+ .small()+ .rounded(px(6.))+ .icon(icon("icons/arrow-up-down.svg").with_size(px(13.)))+ .label(sort_label)+ .tooltip("Sort sessions")+ .dropdown_menu(move |menu, _, _| {+ let mk_key = |label: &'static str, key: SortKey| {+ let entity = sort_entity.clone();+ PopupMenuItem::new(label)+ .checked(sort_key == key)+ .on_click(move |_, window, cx| {+ entity.update(cx, |this, cx| {+ this.sort_key = key;+ this.refresh(window, cx);+ });+ })+ };+ let mk_dir = |label: &'static str, ascending: bool| {+ let entity = sort_entity.clone();+ PopupMenuItem::new(label)+ .checked(sort_ascending == ascending)+ .on_click(move |_, window, cx| {+ entity.update(cx, |this, cx| {+ this.sort_ascending = ascending;+ this.refresh(window, cx);+ });+ })+ };+ menu.min_w(px(180.))+ .item(mk_key("Date updated", SortKey::Updated))+ .item(mk_key("Date created", SortKey::Created))+ .item(mk_key("Message count", SortKey::Messages))+ .separator()+ .item(mk_dir("Descending", false))+ .item(mk_dir("Ascending", true))+ })+ .anchor(Corner::TopRight);+ v_flex()+ .w(px(336.))+ .h_full()+ .flex_shrink_0()+ .bg(theme.list)+ .child(+ v_flex()+ .id("list-header")+ .flex_shrink_0()+ .window_control_area(WindowControlArea::Drag)+ .px(SPACE_LG)+ .pt(SPACE_XL)+ .pb(SPACE_MD)+ .child(+ h_flex()+ .items_center()+ .justify_between()+ .child(+ div()+ .text_size(FONT_TITLE)+ .font_semibold()+ .child(self.context_title()),+ )+ .child(sort_menu),+ ),+ )+ .child(if shown == 0 {+ v_flex()+ .flex_1()+ .justify_center()+ .child(empty_state(+ "icons/inbox.svg",+ px(48.),+ px(22.),+ "No matching sessions",+ "Try different filters or clear the query",+ cx,+ ))+ .into_any_element()+ } else {+ List::new(&self.list_state).flex_1().min_h_0().into_any_element()+ })+ }++ // ---------- 对话区逐消息渲染(设计语言:用户右气泡 / 助手平铺 / 工具折叠簇) ----------++ /// gpui::list 的行渲染。在布局阶段经 entity.update 调用(render 已返回,+ /// lease 已释放,无 double-lease 风险——与 dialog builder 的时机不同)。+ fn render_msg_row(&mut self, ix: usize, window: &mut Window, cx: &mut Context<Self>) -> AnyElement {+ let theme = cx.theme();+ let dark = theme.mode.is_dark();+ let muted_fg = theme.muted_foreground;+ // 尾部要用的 Copy 值提前取出,theme 借用不跨越 inner 构建期的 &mut cx+ let jump_bg = theme.primary.opacity(0.09);+ let jump_radius = theme.radius;+ let Some(detail) = &self.detail else {+ return div().into_any_element();+ };+ let total = detail.transcript.len();+ let expanded = detail.expanded_rows.contains(&ix);+ let jump_seq = detail.jump_seq;+ // Rc 克隆只加引用计数;逐行借用,避免每帧深拷贝整条消息(text 可达 32KB)+ let transcript = detail.transcript.clone();+ let Some(m) = transcript.get(ix) else {+ return div().into_any_element();+ };+ // 搜索跳转的落点消息:淡 primary 底色保持高亮,直到换会话+ let is_jump_target = jump_seq == Some(m.seq);++ let inner: AnyElement = if m.kind == MessageKind::CompactSummary {+ centered_pill("Context compacted", cx).into_any_element()+ } else {+ match m.role {+ Role::User => h_flex()+ .w_full()+ .justify_end()+ .child(+ div()+ .max_w(px(540.))+ .min_w_0()+ .rounded(px(12.))+ .bg(theme.muted)+ .px(px(12.))+ .py(px(7.))+ .text_size(FONT_MSG_USER)+ .child(+ TextView::markdown(+ SharedString::from(format!("dmsg-{}", m.seq)),+ m.text.clone(),+ window,+ cx,+ )+ .style(TextViewStyle {+ heading_base_font_size: FONT_MSG_USER,+ paragraph_gap: gpui::rems(0.5),+ is_dark: dark,+ ..Default::default()+ })+ .selectable(true),+ ),+ )+ .into_any_element(),+ Role::Assistant => {+ let mut col = v_flex().w_full().min_w_0().gap(px(6.));+ if let Some(th) = &m.thinking {+ col = col.child(+ div()+ .text_size(FONT_MSG_THINKING)+ .italic()+ .text_color(muted_fg)+ .truncate()+ .child(format!("Thinking · {}", one_line(th, 200))),+ );+ }+ if !m.text.is_empty() {+ col = col.child(+ div().text_size(FONT_MSG_BODY).child(+ TextView::markdown(+ SharedString::from(format!("dmsg-{}", m.seq)),+ m.text.clone(),+ window,+ cx,+ )+ .style(TextViewStyle {+ heading_base_font_size: FONT_MSG_BODY,+ paragraph_gap: gpui::rems(0.6),+ is_dark: dark,+ ..Default::default()+ })+ .selectable(true),+ ),+ );+ }+ if !m.tool_calls.is_empty() {+ col = col.child(tool_cluster(+ ix,+ &m.tool_calls,+ expanded,+ cx.listener(move |this, _, _window, cx| {+ if let Some(detail) = &mut this.detail {+ if !detail.expanded_rows.insert(ix) {+ detail.expanded_rows.remove(&ix);+ }+ // 行高随展开变化,让 list 重测该行+ detail.msg_list.splice(ix..ix + 1, 1);+ }+ cx.notify();+ }),+ cx,+ ));+ }+ col.into_any_element()+ }+ Role::System => centered_pill(one_line(&m.text, 120), cx).into_any_element(),+ }+ };++ div()+ .w_full()+ .flex()+ .justify_center()+ // 10px:用户定稿(2026-08-18),16 显大 8 显小,不在 4px 网格上是有意的+ .px(px(10.))+ .py(px(6.))+ .when(ix == 0, |d| d.pt(SPACE_LG))+ .when(ix + 1 == total, |d| d.pb(SPACE_XXL))+ .child(+ div()+ .w_full()+ .max_w(px(720.))+ .min_w_0()+ // 淡 primary 底:标记搜索命中落点(尾部命中不滚动,全靠它识别)。+ // 负 margin + 等量 padding:背景向外扩出呼吸边,内容原位不推挤,+ // 与相邻消息的对齐和行距都不变+ .when(is_jump_target, |d| {+ d.rounded(jump_radius)+ .bg(jump_bg)+ .mx(-SPACE_SM)+ .px(SPACE_SM)+ .my(-SPACE_XS)+ .py(SPACE_XS)+ })+ .child(inner),+ )+ .into_any_element()+ }++ fn render_detail(&self, _window: &mut Window, cx: &mut Context<Self>) -> AnyElement {+ let theme = cx.theme();+ let Some(detail) = &self.detail else {+ return v_flex()+ .flex_1()+ .h_full()+ .items_center()+ .justify_center()+ .bg(theme.background)+ .child(+ div()+ .w(px(360.))+ .px(SPACE_XXL)+ .py(SPACE_XXL)+ .rounded(theme.radius_lg)+ .bg(theme.popover)+ .child(empty_state(+ "icons/message-square.svg",+ px(58.),+ px(26.),+ "No session selected",+ "Pick one from the list, or press ⌘K to search.",+ cx,+ )),+ )+ .into_any_element();+ };+ let meta = &detail.meta;+ let session_id = meta.id.clone();+ let export_entity = cx.entity();+ let reveal_entity = export_entity.clone();+ let delete_entity = export_entity.clone();+ let more_menu = Button::new("more-actions")+ .ghost()+ .rounded(px(6.))+ .icon(icon("icons/more-horizontal.svg").with_size(px(16.)))+ .dropdown_menu(move |menu, _, _| {+ let export_entity = export_entity.clone();+ let reveal_entity = reveal_entity.clone();+ let delete_entity = delete_entity.clone();+ menu.min_w(px(210.))+ .item(+ PopupMenuItem::new(" Export as Markdown")+ .icon(icon("icons/download.svg").with_size(px(15.)))+ .on_click(move |_, window, cx| {+ export_entity.update(cx, |this, cx| {+ this.do_export(window, cx);+ });+ }),+ )+ .item(+ PopupMenuItem::new(" Reveal in Finder")+ .icon(icon("icons/folder.svg").with_size(px(15.)))+ .on_click(move |_, _, cx| {+ reveal_entity.update(cx, |this, _| {+ if let Some(detail) = &this.detail {+ terminal::reveal_in_finder(&detail.meta.file_path);+ }+ });+ }),+ )+ .item(+ PopupMenuItem::new(" Copy Session ID")+ .icon(icon("icons/copy.svg").with_size(px(15.)))+ .on_click({+ let id = session_id.clone();+ move |_, _, cx| {+ cx.write_to_clipboard(ClipboardItem::new_string(id.clone()));+ }+ }),+ )+ .separator()+ .item(+ PopupMenuItem::new(" Move to Trash")+ .icon(icon("icons/trash-2.svg").with_size(px(15.)))+ .on_click(move |_, window, cx| {+ delete_entity.update(cx, |this, cx| {+ this.confirm_delete(window, cx);+ });+ }),+ )+ })+ .anchor(Corner::TopRight);++ v_flex()+ .flex_1()+ .min_w_0()+ .h_full()+ .bg(theme.background)+ .child(+ v_flex()+ .id("detail-header")+ .flex_shrink_0()+ .window_control_area(WindowControlArea::Drag)+ .px(SPACE_LG)+ .pt(SPACE_XL)+ .pb(SPACE_MD)+ .gap(SPACE_SM)+ .child(+ h_flex()+ .gap_2()+ .text_size(FONT_LABEL)+ .text_color(theme.muted_foreground)+ .child(img(meta.agent.brand_icon(theme.mode.is_dark())).size(px(15.)).flex_shrink_0())+ .child(div().flex_shrink_0().child(meta.agent.display_name()))+ .child(badge(meta.project_name.clone(), theme.muted, theme.muted_foreground))+ .when_some(meta.git_branch.clone(), |this, branch| {+ this.child(+ h_flex()+ .min_w_0()+ .gap_1()+ .child(icon("icons/git-branch.svg").with_size(px(11.)).flex_shrink_0())+ .child(div().min_w_0().truncate().child(branch)),+ )+ }),+ )+ .child(+ h_flex()+ .justify_between()+ .gap_5()+ .child(+ div()+ .flex_1()+ .min_w_0()+ .text_size(FONT_TITLE)+ .font_semibold()+ .truncate()+ .child(meta.title.clone()),+ )+ .child(+ h_flex()+ .flex_shrink_0()+ .gap_1()+ .child({+ // Open In split 按钮(Codex/kooky 风):左段 = 上次+ // 目标的应用图标,点击直开;右段 chevron 展开列表+ let terms = terminal::installed_terminals();+ let current = self+ .preferred_terminal+ .or_else(|| terms.first().copied());+ let current_icon = current+ .and_then(|t| self.terminal_icons.get(t.id()).cloned());+ let term_items: Vec<(terminal::TerminalApp, Option<PathBuf>)> =+ terms+ .iter()+ .map(|t| {+ (*t, self.terminal_icons.get(t.id()).cloned())+ })+ .collect();+ let menu_entity = cx.entity();+ // 无常显分隔线,hover 分段高亮暗示两段(Codex 同款);+ // 右段 Button 用 custom variant 与左段 hover 完全一致+ h_flex()+ .h(px(28.))+ .rounded(px(6.))+ .border_1()+ .border_color(theme.border)+ .bg(theme.secondary)+ .overflow_hidden()+ .child(+ div()+ .id("open-in-main")+ .h_full()+ .px(px(7.))+ .flex()+ .items_center()+ .cursor_pointer()+ .hover(|s| s.bg(theme.secondary_hover))+ .active(|s| s.bg(theme.secondary_active))+ .child(match ¤t_icon {+ Some(p) => img(p.clone())+ .size(px(14.))+ .into_any_element(),+ None => icon("icons/terminal.svg")+ .with_size(px(13.))+ .text_color(theme.secondary_foreground)+ .into_any_element(),+ })+ .on_click(cx.listener(move |this, _, window, cx| {+ if let Some(term) = current {+ this.do_resume(term, window, cx);+ }+ })),+ )+ .child(+ div()+ .w(px(1.))+ .h_full()+ .flex_shrink_0()+ .bg(theme.border),+ )+ .child(+ Button::new("open-in-more")+ .custom(+ ButtonCustomVariant::new(cx)+ .foreground(theme.muted_foreground)+ .hover(theme.secondary_hover)+ .active(theme.secondary_active),+ )+ .rounded(px(0.))+ .h(px(26.))+ .w(px(22.))+ .icon(+ icon("icons/chevron-down.svg")+ .with_size(px(12.)),+ )+ .tooltip("Open this session in…")+ .dropdown_menu(move |menu, _, _| {+ let mut menu = menu.min_w(px(170.));+ for (term, icon_path) in term_items.clone() {+ let entity = menu_entity.clone();+ menu = menu.item(+ PopupMenuItem::element(move |_, _| {+ h_flex()+ .gap_2()+ .items_center()+ .child(match &icon_path {+ Some(p) => img(p.clone())+ .size(px(16.))+ .into_any_element(),+ None => icon("icons/terminal.svg")+ .with_size(px(15.))+ .into_any_element(),+ })+ .child(term.display_name())+ })+ .on_click(move |_, window, cx| {+ entity.update(cx, |this, cx| {+ this.do_resume(term, window, cx);+ });+ }),+ );+ }+ menu+ })+ .anchor(Corner::TopRight),+ )+ })+ .child(tool_btn(+ "fav",+ "icons/star.svg",+ "icons/star-filled.svg",+ rgb(crate::theme::STAR_YELLOW).into(),+ if meta.favorite {+ "Unstar"+ } else {+ "Star"+ },+ meta.favorite,+ cx.listener(|this, _, window, cx| {+ this.toggle_favorite(window, cx)+ }),+ ))+ .child(tool_btn(+ "pin",+ "icons/pin.svg",+ "icons/pin-filled.svg",+ theme.primary,+ if meta.pinned {+ "Unpin"+ } else {+ "Pin"+ },+ meta.pinned,+ cx.listener(|this, _, window, cx| {+ this.toggle_pinned(window, cx)+ }),+ ))+ .child(more_menu),+ ),+ )+ .child(+ h_flex()+ .gap_1p5()+ .text_size(FONT_LABEL)+ .text_color(theme.muted_foreground)+ .child(icon("icons/folder.svg").with_size(px(12.)).flex_shrink_0())+ .child(div().min_w_0().truncate().child(+ if meta.project_path.is_empty() {+ "Unknown project".to_string()+ } else {+ meta.project_path.clone()+ },+ )),+ )+ .child({+ // 属性行:model / source outline badge + 统计;空值自动省略+ let mut stats: Vec<String> = Vec::new();+ if meta.message_count > 0 {+ stats.push(format!("{} messages", meta.message_count));+ }+ if let Some(tokens) = meta.tokens_used {+ stats.push(format!("{} tokens", fmt_tokens(Some(tokens))));+ }+ h_flex()+ .gap_2()+ .text_size(FONT_LABEL)+ .text_color(theme.muted_foreground)+ .when_some(meta.model.clone(), |this, model| {+ this.child(outline_badge(+ model,+ rgb(crate::theme::MODEL_BADGE_BG).into(),+ ))+ })+ .when_some(+ meta.source.clone().filter(|s| !s.is_empty()),+ |this, source| {+ this.child(outline_badge(source, theme.success))+ },+ )+ .child(div().min_w_0().truncate().child(stats.join(" · ")))+ })+ .child({+ // 时间行:创建 / 最后活动,精确时间+ let mut times: Vec<String> = Vec::new();+ if meta.created_at > 0 {+ times.push(format!("Created {}", abs_date(meta.created_at)));+ }+ if meta.updated_at > 0 {+ times.push(format!("Updated {}", abs_date(meta.updated_at)));+ }+ div()+ .text_size(FONT_LABEL)+ .text_color(theme.muted_foreground)+ .truncate()+ .child(times.join(" · "))+ }),+ )+ .child(if detail.loading {+ h_flex()+ .flex_1()+ .items_center()+ .justify_center()+ .gap_2()+ .text_color(theme.muted_foreground)+ .child(Spinner::new().small())+ .child(div().text_size(FONT_BODY).child("Loading session…"))+ .into_any_element()+ } else {+ let entity = cx.entity().downgrade();+ div()+ .flex_1()+ .min_h_0()+ .px(SPACE_MD)+ .pb(SPACE_MD)+ .child(+ div()+ .size_full()+ .rounded(theme.radius_lg)+ .bg(theme.popover)+ .relative()+ .child(+ gpui::list(detail.msg_list.clone(), move |ix, window, cx| {+ entity+ .upgrade()+ .map(|e| {+ e.update(cx, |this, cx| {+ this.render_msg_row(ix, window, cx)+ })+ })+ .unwrap_or_else(|| div().into_any_element())+ })+ .size_full(),+ )+ .vertical_scrollbar(&detail.msg_list),+ )+ .into_any_element()+ })+ .into_any_element()+ }+}++/// 可折叠分组头:chevron + 文字,点击切换+fn group_header(+ id: &'static str,+ text: &'static str,+ collapsed: bool,+ on_click: impl Fn(&ClickEvent, &mut Window, &mut App) + 'static,+ cx: &Context<Workbench>,+) -> Stateful<Div> {+ let theme = cx.theme();+ div()+ .id(id)+ .flex_shrink_0()+ .pl(GROUP_HEAD_INSET)+ .pr(SIDEBAR_EDGE)+ .pt(SPACE_MD)+ .pb(SPACE_XS)+ .cursor_pointer()+ .active(|s| s.opacity(0.7))+ .on_click(on_click)+ .child(+ h_flex()+ .gap(SPACE_XS)+ // 与主导航行同字号同字重(FONT_BODY / 常规),仅靠 muted 色+ // 与"无行首图标"区分——加粗会让组头压过它统辖的行+ .text_size(FONT_BODY)+ .text_color(theme.muted_foreground)+ .hover(|s| s.text_colored(theme.foreground, FONT_BODY))+ .child(text)+ .child(+ icon("icons/chevron-right.svg")+ .with_size(px(13.))+ .when(!collapsed, |ic| {+ ic.rotate(gpui::Radians(std::f32::consts::FRAC_PI_2))+ }),+ ),+ )+}++/// 侧栏行层级:Primary=固定主导航(32px/FONT_BODY),Sub=分组展开项(26px/FONT_CAPTION)。+/// 行首元素一律对齐同一条中轴(见 ui.rs LEAD_BOX),子级不再缩进——+/// 行高与字号是仅剩的层级来源,禁止把子级行改回主导航尺度。+#[derive(Clone, Copy, PartialEq)]+enum RowLevel {+ Primary,+ Sub,+}++/// 侧栏行首元素——每行必须有一个,槽位定宽,保证同组文字起点对齐。+/// Lucide 图标随选中态着色;品牌 PNG 保留原色不着色。+enum RowLead {+ Icon(Icon),+ /// Agent 品牌图标,取 `AgentId::brand_icon()`+ Brand(&'static str),+}++/// 空态占位(⌘K 初始 / 列表空 / 详情未选中共用):muted 圆底图标 + 标题 + 说明。+/// 圆径/图标径按场景传入,字阶与间距固定,保证三处视觉一致。+fn empty_state(+ icon_path: &'static str,+ circle: Pixels,+ icon_size: Pixels,+ title: impl Into<SharedString>,+ caption: impl Into<SharedString>,+ cx: &App,+) -> Div {+ let theme = cx.theme();+ v_flex()+ .items_center()+ .gap(SPACE_MD)+ .text_color(theme.muted_foreground)+ .child(+ div()+ .size(circle)+ .rounded_full()+ .bg(theme.muted)+ .flex()+ .items_center()+ .justify_center()+ .child(+ icon(icon_path)+ .with_size(icon_size)+ .text_color(theme.muted_foreground),+ ),+ )+ .child(+ div()+ .text_size(FONT_BODY)+ .font_medium()+ .text_color(theme.foreground)+ .child(title.into()),+ )+ .child(div().text_size(FONT_CAPTION).child(caption.into()))+}++/// 对话区居中小胶囊(System 消息 / Context compacted)+fn centered_pill(text: impl Into<SharedString>, cx: &App) -> Div {+ let theme = cx.theme();+ div().w_full().flex().justify_center().child(+ div()+ .px(px(10.))+ .py(px(3.))+ .rounded_full()+ .bg(theme.muted)+ .text_size(FONT_LABEL)+ .text_color(theme.muted_foreground)+ .max_w(px(520.))+ .truncate()+ .child(text.into()),+ )+}++/// 工具调用折叠簇:头行(chevron + 名字序列 + 失败计数)默认收起,+/// 展开为左竖线缩进列表;仅失败项内联输出(错误才是回顾重点)。+fn tool_cluster(+ ix: usize,+ calls: &[ToolCallView],+ expanded: bool,+ on_toggle: impl Fn(&ClickEvent, &mut Window, &mut App) + 'static,+ cx: &App,+) -> Div {+ let theme = cx.theme();+ let failed = calls.iter().filter(|c| c.is_error).count();+ let names = calls+ .iter()+ .map(|c| c.name.as_str())+ .collect::<Vec<_>>()+ .join(" · ");+ let head_label = if calls.len() == 1 {+ names.clone()+ } else {+ format!("{} tools · {}", calls.len(), names)+ };+ let mono = theme.mono_font_family.clone();++ let mut cluster = v_flex().w_full().min_w_0().gap(px(4.)).child(+ h_flex()+ .id(("tool-cluster", ix))+ .w_full()+ .min_w_0()+ .gap(px(6.))+ .cursor_pointer()+ .text_size(FONT_CAPTION)+ .text_color(theme.muted_foreground)+ .hover(|s| s.text_colored(theme.foreground, FONT_CAPTION))+ .child(+ icon("icons/chevron-right.svg")+ .with_size(px(11.))+ .flex_shrink_0()+ .when(expanded, |ic| {+ ic.rotate(gpui::Radians(std::f32::consts::FRAC_PI_2))+ }),+ )+ .child(div().min_w_0().truncate().font_medium().child(head_label))+ .when(failed > 0, |this| {+ this.child(+ div()+ .flex_shrink_0()+ .text_color(theme.danger)+ .child(format!("{failed} failed")),+ )+ })+ .on_click(on_toggle),+ );+ if expanded {+ let mut items = v_flex()+ .w_full()+ .min_w_0()+ .ml(px(5.))+ .pl(px(12.))+ .border_l_1()+ .border_color(theme.border)+ .gap(px(6.));+ for tc in calls {+ let mut item = v_flex().w_full().min_w_0().gap(px(2.)).child(+ h_flex()+ .w_full()+ .min_w_0()+ .gap(px(6.))+ .child(+ div()+ .flex_shrink_0()+ .text_size(FONT_CAPTION)+ .font_medium()+ .text_color(if tc.is_error {+ theme.danger+ } else {+ theme.foreground+ })+ .child(tc.name.clone()),+ )+ .child(+ div()+ .min_w_0()+ .truncate()+ .text_size(FONT_MSG_THINKING)+ .font_family(mono.clone())+ .text_color(theme.muted_foreground)+ .child(tc.input_preview.clone()),+ ),+ );+ if tc.is_error {+ if let Some(out) = &tc.output {+ let shown: String = out.trim().chars().take(400).collect();+ if !shown.is_empty() {+ item = item.child(+ div()+ .w_full()+ .min_w_0()+ .px(px(8.))+ .py(px(5.))+ .rounded(px(5.))+ .bg(theme.muted)+ .text_size(FONT_LABEL)+ .font_family(mono.clone())+ .text_color(theme.muted_foreground)+ .child(shown),+ );+ }+ }+ }+ items = items.child(item);+ }+ cluster = cluster.child(items);+ }+ cluster+}++/// 小胶囊 badge(项目名/model/source 共用):4px 圆角,内部截断。+/// 项目名用 muted 灰;model/source 用主题色 tint(淡底+同色文字)。+fn badge(name: impl Into<SharedString>, bg: Hsla, fg: Hsla) -> impl IntoElement {+ div()+ .min_w_0()+ .px(px(6.))+ .py(px(1.))+ .rounded(px(4.))+ .bg(bg)+ .text_color(fg)+ .font_medium()+ .child(div().truncate().child(name.into()))+}++/// outline 变体(model/source 用):透明底,边框与文字同色+fn outline_badge(name: impl Into<SharedString>, color: Hsla) -> impl IntoElement {+ div()+ .min_w_0()+ .px(px(6.))+ .py(px(1.))+ .rounded(px(4.))+ .border_1()+ .border_color(color)+ .text_color(color)+ .font_medium()+ .child(div().truncate().child(name.into()))+}++/// Things 风源列表行:图标 + 文字 + 计数,6px 圆角选中胶囊+#[allow(clippy::too_many_arguments)]+fn sidebar_row(+ id: impl Into<ElementId>,+ lead: RowLead,+ label: impl Into<SharedString>,+ count: Option<i64>,+ active: bool,+ level: RowLevel,+ on_click: impl Fn(&ClickEvent, &mut Window, &mut App) + 'static,+ cx: &Context<Workbench>,+) -> Stateful<Div> {+ let theme = cx.theme();+ let sub = level == RowLevel::Sub;+ div()+ .id(id)+ .h(if sub { ROW_HEIGHT_SUB } else { ROW_HEIGHT })+ .flex_shrink_0()+ // 分组项整行右移一档表达从属:行首因此落在轴右侧 SUB_INDENT 处,+ // 压轴的是主导航与组头,不是这里+ .pl(if sub { LEAD_INSET + SUB_INDENT } else { LEAD_INSET })+ .pr(SIDEBAR_EDGE)+ .rounded(theme.radius)+ .cursor_pointer()+ .flex()+ .items_center()+ .when(active, |s| {+ s.bg(theme.sidebar_accent)+ .text_color(theme.sidebar_accent_foreground)+ })+ .when(!active, |s| {+ s.text_color(theme.sidebar_foreground)+ .hover(|s| s.bg(theme.sidebar_accent.opacity(0.55)))+ .active(|s| s.bg(theme.sidebar_accent))+ })+ .on_click(on_click)+ .child(+ h_flex()+ .w_full()+ .gap(SPACE_SM)+ .child(+ // 定宽槽位保证文字起点统一;内部居中,使小图标的中心也落在+ // LEAD_AXIS 上(左对齐会让 14/15px 图标的中心偏离轴 1.5~2pt)+ div()+ .w(LEAD_BOX)+ .flex_shrink_0()+ .flex()+ .items_center()+ .justify_center()+ .child(match lead {+ // 线条图标比实心品牌图视觉轻,给它小一档才平衡+ RowLead::Icon(ic) => ic+ .with_size(if sub { px(14.) } else { px(15.) })+ .text_color(if active {+ theme.sidebar_accent_foreground+ } else {+ theme.muted_foreground+ })+ .into_any_element(),+ // 品牌图不着色:img 走 AssetSource 取内嵌 PNG,原色渲染+ // (侧栏单色化试过,用户否决——保持彩色)+ RowLead::Brand(path) => {+ img(path).size(LEAD_BOX).into_any_element()+ }+ }),+ )+ .child(+ div()+ .flex_1()+ .min_w_0()+ .text_size(if sub { FONT_CAPTION } else { FONT_BODY })+ .truncate()+ .child(label.into()),+ )+ .when_some(count, |this, n| {+ this.child(+ div()+ .flex_shrink_0()+ .text_size(FONT_LABEL)+ .text_color(theme.muted_foreground)+ .child(n.to_string()),+ )+ }),+ )+}++/// 详情工具栏图标按钮。选中态 = 填充版图标 + 语义色(macOS 惯例),+/// 按钮本身不落底色(.selected 的 hover 底被否)。+fn tool_btn(+ id: &'static str,+ icon_path: &'static str,+ filled_icon_path: &'static str,+ active_color: Hsla,+ tooltip: &'static str,+ highlighted: bool,+ on_click: impl Fn(&ClickEvent, &mut Window, &mut App) + 'static,+) -> Button {+ let ic = if highlighted {+ icon(filled_icon_path).with_size(px(16.)).text_color(active_color)+ } else {+ icon(icon_path).with_size(px(16.))+ };+ Button::new(id)+ .ghost()+ .rounded(px(6.))+ .icon(ic)+ .tooltip(tooltip)+ .on_click(on_click)+}++impl Focusable for Workbench {+ fn focus_handle(&self, _cx: &App) -> FocusHandle {+ self.focus_handle.clone()+ }+}++impl Render for Workbench {+ fn render(&mut self, window: &mut Window, cx: &mut Context<Self>) -> impl IntoElement {+ let theme = cx.theme();+ div()+ .id("workbench")+ .key_context(KEY_CONTEXT)+ .track_focus(&self.focus_handle)+ .on_action(cx.listener(Self::toggle_search))+ .on_action(cx.listener(|this, _: &RefreshSessions, window, cx| {+ this.refresh_sessions(window, cx)+ }))+ .size_full()+ .bg(theme.background)+ .text_color(theme.foreground)+ .child(+ h_flex()+ .size_full()+ .child(self.render_sidebar(cx))+ .child(self.render_session_list(cx))+ .child(self.render_detail(window, cx)),+ )+ .children(Root::render_dialog_layer(window, cx))+ .children(Root::render_notification_layer(window, cx))+ }+}diff --git a/scripts/build_and_run.sh b/scripts/build_and_run.shnew file mode 100755index 0000000..6ea6841--- /dev/null+++ b/scripts/build_and_run.sh@@ -0,0 +1,58 @@+#!/usr/bin/env bash+set -euo pipefail++MODE="${1:-run}"+APP_NAME="Wake"+APP_PROCESS="Wake"+BUNDLE_ID="dev.corey.wake"++ROOT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")/.." && pwd)"+APP_BUNDLE="$ROOT_DIR/dist/$APP_NAME.app"+APP_BINARY="$APP_BUNDLE/Contents/MacOS/$APP_PROCESS"++pkill -x "$APP_PROCESS" >/dev/null 2>&1 || true+for _ in {1..30}; do+ if ! pgrep -x "$APP_PROCESS" >/dev/null; then+ break+ fi+ sleep 0.1+done+"$ROOT_DIR/scripts/make-app.sh"+# Launch Services may still be refreshing the just-replaced, re-signed bundle.+sleep 0.5++open_app() {+ /usr/bin/open "$APP_BUNDLE"+}++case "$MODE" in+ run)+ open_app+ ;;+ --debug|debug)+ lldb -- "$APP_BINARY"+ ;;+ --logs|logs)+ open_app+ /usr/bin/log stream --info --style compact --predicate "process == \"$APP_PROCESS\""+ ;;+ --telemetry|telemetry)+ open_app+ /usr/bin/log stream --info --style compact --predicate "subsystem == \"$BUNDLE_ID\""+ ;;+ --verify|verify)+ open_app+ for _ in {1..20}; do+ if pgrep -x "$APP_PROCESS" >/dev/null; then+ break+ fi+ sleep 0.25+ done+ pgrep -x "$APP_PROCESS" >/dev/null+ echo "✓ $APP_NAME 正在运行"+ ;;+ *)+ echo "用法:$0 [run|--debug|--logs|--telemetry|--verify]" >&2+ exit 2+ ;;+esacdiff --git a/scripts/make-app.sh b/scripts/make-app.shnew file mode 100755index 0000000..871c882--- /dev/null+++ b/scripts/make-app.sh@@ -0,0 +1,64 @@+#!/bin/zsh+# 构建 Wake.app:release 二进制 + icns 图标 + Info.plist,ad-hoc 签名。+# 用法: scripts/make-app.sh [--run]+set -euo pipefail+cd "$(dirname "$0")/.."++ASSETS=crates/wake/assets+BUILD=target/release+APP=dist/Wake.app++# 1. 图标:svg → 1024 png(ImageIO 渲染,保透明;qlmanage 会把透明边距填成白底) → iconset → icns+if [ ! -f "$ASSETS/icon-1024.png" ] || [ "$ASSETS/icon.svg" -nt "$ASSETS/icon-1024.png" ]; then+ swift scripts/render-icon.swift "$ASSETS/icon.svg" "$ASSETS/icon-1024.png" 1024+fi+ICONSET=$(mktemp -d)/wake.iconset+mkdir -p "$ICONSET"+for size in 16 32 128 256 512; do+ sips -z $size $size "$ASSETS/icon-1024.png" --out "$ICONSET/icon_${size}x${size}.png" > /dev/null+ double=$((size * 2))+ sips -z $double $double "$ASSETS/icon-1024.png" --out "$ICONSET/icon_${size}x${size}@2x.png" > /dev/null+done+mkdir -p dist+iconutil -c icns "$ICONSET" -o dist/wake.icns++# 2. release 构建+cargo build --release -p wake++# 3. bundle 组装+rm -rf "$APP"+mkdir -p "$APP/Contents/MacOS" "$APP/Contents/Resources"+cp "$BUILD/Wake" "$APP/Contents/MacOS/Wake"+cp dist/wake.icns "$APP/Contents/Resources/wake.icns"+cat > "$APP/Contents/Info.plist" <<'PLIST'+<?xml version="1.0" encoding="UTF-8"?>+<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">+<plist version="1.0">+<dict>+ <key>CFBundleName</key><string>Wake</string>+ <key>CFBundleDisplayName</key><string>Wake</string>+ <key>CFBundleIdentifier</key><string>dev.corey.wake</string>+ <key>CFBundleExecutable</key><string>Wake</string>+ <key>CFBundleIconFile</key><string>wake</string>+ <key>CFBundlePackageType</key><string>APPL</string>+ <key>CFBundleShortVersionString</key><string>0.2.0</string>+ <key>CFBundleVersion</key><string>0.2.0</string>+ <key>LSMinimumSystemVersion</key><string>13.0</string>+ <!-- 恢复会话要驱动 Terminal/iTerm,删除会话要驱动 Finder。缺这个键,+ macOS 的自动化授权框没有说明文字,启用 hardened runtime 后更会被+ TCC 直接拒绝——两个核心功能都会在别人的机器上静默失效。 -->+ <key>NSAppleEventsUsageDescription</key>+ <string>Wake uses automation to reopen sessions in your terminal and to move session files to the Trash.</string>+ <key>NSHighResolutionCapable</key><true/>+ <key>NSHumanReadableCopyright</key><string>© 2026 Corey Chiu · MIT License</string>+</dict>+</plist>+PLIST++# 4. ad-hoc 签名(本机运行足够;分发需开发者证书 + notarize)+codesign --force --deep -s - "$APP"++echo "✓ $APP"+if [ "${1:-}" = "--run" ]; then+ open "$APP"+fidiff --git a/scripts/render-icon.swift b/scripts/render-icon.swiftnew file mode 100644index 0000000..211e2f6--- /dev/null+++ b/scripts/render-icon.swift@@ -0,0 +1,28 @@+// SVG → 透明背景 PNG(ImageIO/CoreSVG 渲染,替代会填白底的 qlmanage)+// 用法: swift scripts/render-icon.swift <in.svg> <out.png> <size>+import AppKit++let args = CommandLine.arguments+guard args.count == 4, let size = Int(args[3]) else {+ fputs("usage: render-icon.swift <in.svg> <out.png> <size>\n", stderr)+ exit(1)+}+guard let img = NSImage(contentsOfFile: args[1]) else {+ fputs("error: cannot load \(args[1])\n", stderr)+ exit(2)+}+guard let rep = NSBitmapImageRep(+ bitmapDataPlanes: nil, pixelsWide: size, pixelsHigh: size,+ bitsPerSample: 8, samplesPerPixel: 4, hasAlpha: true, isPlanar: false,+ colorSpaceName: .deviceRGB, bytesPerRow: 0, bitsPerPixel: 0+) else { exit(3) }++NSGraphicsContext.saveGraphicsState()+NSGraphicsContext.current = NSGraphicsContext(bitmapImageRep: rep)+NSGraphicsContext.current?.imageInterpolation = .high+img.draw(in: NSRect(x: 0, y: 0, width: size, height: size),+ from: .zero, operation: .copy, fraction: 1.0)+NSGraphicsContext.restoreGraphicsState()++guard let png = rep.representation(using: .png, properties: [:]) else { exit(4) }+try! png.write(to: URL(fileURLWithPath: args[2]))