Default to the git GPUI pair for fresh gpui (crates.io as fallback) - #2
Merged
Conversation
…llback Deck shipped on the pure-crates.io GPUI pair, which froze gpui at Zed's Oct-2025 published snapshot (~8 months stale). gpui-component is developed against Zed's gpui HEAD, so the matched git pair is the only way to run fresh gpui with the component kit. Switch the default to it; keep crates.io as a documented fallback. Dependencies (Cargo.toml + committed Cargo.lock = the reproducible pin): - gpui + gpui_platform from github.com/zed-industries/zed (gpui 86effff) - gpui-component + -assets from github.com/longbridge/gpui-component (dadfca9 -> 0.5.2) - Renderer now Metal on macOS, wgpu on Linux (Zed dropped blade, PR #46758) Toolchain (single source of truth): - Pin rust-toolchain.toml to 1.95.0 to match Zed; gpui HEAD uses std::hint::cold_path, stabilized in 1.95 - Remove the duplicate dtolnay/rust-toolchain@stable pin from CI so the toolchain is declared once and CI inherits it Source port (Oct-2025 -> mid-2026 API drift): - main.rs: Application::new() -> gpui_platform::application(); Menu.disabled field - shell.rs: window.focus(&handle, cx) - tray.rs: AsyncApp::update no longer returns Result (drop `let _ =`) Tooling & docs: - just bump-gpui helper for monthly bumps - new docs/UPGRADING.md: bump runbook + toolchain note + crates.io fallback swap - README/LEARNINGS: correct the lineage (crates.io gpui is Zed's official crate, not a "longbridge fork"); git pair = default; blade -> wgpu Verified: cargo build (default + tray), clippy -D warnings (default + tray), cargo fmt, and a runtime smoke test (window opens, no panic).
Brings in the ⌘K command palette (#1) and the LEARNINGS tightening (13a300d). Conflict resolution: - src/main.rs (View menu): keep the new "Command Palette…" item AND the git-gpui-required `Menu { disabled: false, .. }` field. - docs/LEARNINGS.md §2: keep the corrected git-default dependency story (the incoming side reverted to the old "longbridge fork" text). Ported the merged-in palette to the git gpui API: - src/command_palette.rs: window.focus(&handle, cx) (gained a cx arg). - README "Why this exists": "pure crates.io deps" -> "fresh git-pinned GPUI". Re-verified on the merged tree: cargo build (default + tray), clippy -D warnings (default + tray), cargo fmt, runtime smoke (no panic).
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Why
Deck shipped on the pure-crates.io GPUI pair, which pins gpui to Zed's Oct-2025 published snapshot — ~8 months stale, no wgpu Linux renderer, none of the recent gpui work.
gpui-componentis developed against Zed's gpui HEAD, and no other distribution can feed it (gpui-ceis stale since Dec 2025 and version-incompatible;gpui-unofficialis a different crate name). So the matched git pair is the only way to run fresh gpui with the component kit — this PR makes it the default and keeps crates.io as a documented fallback.It also corrects a load-bearing error in the old docs: crates.io
gpuiis Zed's own official crate (owners: Brunsfeld/Maki/zed-industries), not a "longbridge fork."What changed
Dependencies (
Cargo.toml+ committedCargo.lock= the reproducible pin)gpui+gpui_platformfromzed-industries/zed(gpui86effff)gpui-component+-assetsfromlongbridge/gpui-component(dadfca9→ 0.5.2)Toolchain — single source of truth
rust-toolchain.toml→1.95.0(matches Zed; gpui HEAD usesstd::hint::cold_path, stabilized in 1.95)dtolnay/rust-toolchain@stablefrom CI so the version is declared once and CI inherits it (rustup auto-installs it + components on firstcargocall)Source port (Oct-2025 → mid-2026 API drift — the whole thing)
main.rs:Application::new()→gpui_platform::application(); newMenu { disabled, .. }fieldshell.rs:window.focus(&handle, cx)(gained acxarg)tray.rs:AsyncApp::updateno longer returnsResult(droppedlet _ =)Tooling & docs (forkable story)
just bump-gpui— monthly bump helperdocs/UPGRADING.md— bump runbook, toolchain note, and the crates.io fallback swapREADME/LEARNINGS— git pair = default, lineage corrected, blade → wgpuReproducibility / forks
The committed
Cargo.lockpins exact upstream commits — every fork and CI builds identical bytes. Bump on a cadence withjust bump-gpui(≈monthly); if an unstable-feature error appears, matchrust-toolchain.tomlto Zed's. Full procedure indocs/UPGRADING.md.Verification
cargo build(default +--features tray)cargo clippy --all-targets -- -D warnings(default + tray)cargo fmt --checkNote for reviewers
First build/CI run clones Zed's repo and compiles gpui from source (slower once;
Swatinem/rust-cachecaches it). The large diff is mostlyCargo.lockchurn from the registry→git source switch.