| Filename | Latest commit message | Latest commit date |
|---|---|---|
Continues the earlier pass. Each sweep can only check crates whose dependencies compiled, so every round reached deeper and uncovered another layer: 16, 35, 7, 12, 15, 69, 31, 1, then a long tail. The spikes are large crates unblocking — `project` in one round, the `editor` tree in another — not new breakage. Nearly all of it applied from rustc's own machine-applicable spans. Judgement was needed in a few places: prost's `from_i32` becomes `try_from(..).ok()` at 24 sites, written that way because every caller wanted an `Option` and `.ok()` keeps the semantics identical; a paren-matching rewrite rather than a regex, since the argument is often itself a call. `criterion::black_box` moved to `std::hint`, `rand`'s `choose_multiple` is `sample`, and `time::format_description::parse` is `parse_borrowed::<2>`. Two are deliberately marked rather than changed. `SettingsInputField`'s four builder methods really are unused — the other `with_id` hits in the tree are `window.with_id` — so they carry `#[allow(dead_code)]` and a note rather than being deleted out of a fork. `open_ai`'s large `Err` variant keeps its scoped allow for the reason given there. One lint was ours: the panel had a manual checked division, now `checked_div`. Co-Authored-By: Claude Opus 5 <[email protected]> |
||
| .. | ||
| src | ||
| test_data | ||
| Cargo.toml | ||
| LICENSE-GPL | ||
| README.md | ||
This contains the code for Joule's Vim emulation mode.
Vim mode in Joule is supposed to primarily "do what you expect": it mostly tries to copy vim exactly, but will use Joule-specific functionality when available to make things smoother. This means Joule will never be 100% vim compatible, but should be 100% vim familiar!
The backlog is maintained in the #vim channel notes.
Testing against Neovim
If you are making a change to make Joule's behavior more closely match vim/nvim, you can create a test using the NeovimBackedTestContext.
For example, the following test checks that Joule and Neovim have the same behavior when running * in visual mode:
#[gpui::test]
async fn test_visual_star_hash(cx: &mut gpui::TestAppContext) {
let mut cx = NeovimBackedTestContext::new(cx).await;
cx.set_shared_state("ˇa.c. abcd a.c. abcd").await;
cx.simulate_shared_keystrokes(["v", "3", "l", "*"]).await;
cx.assert_shared_state("a.c. abcd ˇa.c. abcd").await;
}
To keep CI runs fast, by default the neovim tests use a cached JSON file that records what neovim did (see crates/vim/test_data), but while developing this test you'll need to run it with the neovim flag enabled:
cargo test -p vim --features neovim test_visual_star_hash
This will run your keystrokes against a headless neovim and cache the results in the test_data directory. Note that neovim must be installed and reachable on your $PATH in order to run the feature.
Testing zed-only behavior
Joule does more than vim/neovim in their default modes. The VimTestContext can be used instead. This lets you test integration with the language server and other parts of zed's UI that don't have a NeoVim equivalent.