This PR includes several minor modifications and improvements related to
Git hosting providers, covering the following areas:
1. Bitbucket Owner Parsing Fix: Remove the common `scm` prefix from the
remote URL of self-hosted Bitbucket instances to prevent incorrect owner
parsing.
[Reference](a6e3c6fbb2/src/git/remotes/bitbucket-server.ts (L72-L74))
2. Bitbucket Avatars in Blame: Add support for displaying Bitbucket
avatars in the Git blame view.
<img width="2750" height="1994" alt="CleanShot 2025-11-10 at 20 34
40@2x"
src="https://github.com/user-attachments/assets/9e26abdf-7880-4085-b636-a1f99ebeeb97"
/>
3. Self-hosted SourceHut Support: Add support for self-hosted SourceHut
instances.
4. Configuration: Add recently introduced self-hosted Git providers
(Gitea, Forgejo, and SourceHut) to the `git_hosting_providers` setting
option.
<img width="2750" height="1994" alt="CleanShot 2025-11-10 at 20 33
48@2x"
src="https://github.com/user-attachments/assets/44ffc799-182d-4145-9b89-e509bbc08843"
/>
Closes#11043
Release Notes:
- Improved self-hosted git provider support and Bitbucket integration
When using the latest version of `GPUI`, I found some grid layout
issues. I discovered #43555 modified the default behavior of grid
template columns. I checked the implementation at
https://tailwindcss.com/docs/grid-template-columns, and it seems our
previous implementation was correct.
If a grid layout is placed inside a flexbox, the layout becomes
unpredictable.
```rust
impl Render for HelloWorld {
fn render(&mut self, _window: &mut Window, _cx: &mut Context<Self>) -> impl IntoElement {
div()
.flex()
.size(px(500.0))
.bg(rgb(0x505050))
.text_xl()
.text_color(rgb(0xffffff))
.child(
div()
.size_full()
.gap_1()
.grid()
.grid_cols(2)
.border_1()
.border_color(gpui::red())
.children((0..10).map(|ix| {
div()
.w_full()
.border_1()
.border_color(gpui::green())
.child(ix.to_string())
})),
)
}
}
```
| Before | After |
| - | - |
| <img width="612" height="644" alt="After1"
src="https://github.com/user-attachments/assets/64eaf949-0f38-4f0b-aae7-6637f8f40038"
/> | <img width="612" height="644" alt="Before1"
src="https://github.com/user-attachments/assets/561a508d-29ea-4fd2-bd1e-909ad14b9ee3"
/> |
I also placed the grid layout example inside a flexbox too.
| Before | After |
| - | - |
| <img width="612" height="644" alt="After"
src="https://github.com/user-attachments/assets/fa6f4a2d-21d8-413e-8b66-7bd073e05f87"
/> | <img width="612" height="644" alt="Before"
src="https://github.com/user-attachments/assets/9e0783d1-18e9-470d-b913-0dbe4ba88835"
/> |
I tested the changes from the previous PR, and it seems that setting the
table's parent to `v_flex` is sufficient to achieve a non-full table
width without modifying the grid layout. This was already done in the
previous PR.
I reverted the grid changes, the blue border represents the table width.
cc @RemcoSmitsDev
<img width="1107" height="1000" alt="table"
src="https://github.com/user-attachments/assets/4b7ba2a2-a66a-444d-ad42-d80bc9057cce"
/>
So, I believe we should revert to this implementation to align with
tailwindcss behavior and avoid potential future problems, especially
since the cause of this issue is difficult to pinpoint.
Release Notes:
- N/A
Release Notes:
- Added support for Grok 4.1 Fast (reasoning and non-reasoning) models
in the xAI provider, with 2M token context windows and full vision
capabilities.
- Extended 2M token context to existing Grok 4 Fast variants (from 128K)
for consistency with xAI updates.
- Enabled image/vision support for all Grok 4 family models.
Doc:
https://docs.x.ai/docs/models/grok-4-1-fast-reasoninghttps://docs.x.ai/docs/models/grok-4-1-fast-non-reasoning
**Problem addressed:**
Cannot distinguish an identical path on multiple remote hosts in the
"Recent Projects" picker.
**Related work:**
- Issue #40358 (already closed) identified the issue in the "Expected
Behavior" section for both WSL and SSH remotes.
- PR #40375 implemented WSL distro labels.
**Screenshots:**
Before:
<img width="485" height="98" alt="screenshot-sample-project-before"
src="https://github.com/user-attachments/assets/182d907a-6f11-44aa-8ca5-8114f5551c93"
/>
After:
<img width="481" height="94" alt="screenshot-sample-project-after"
src="https://github.com/user-attachments/assets/5f87ff12-6577-404e-9319-717f84b7d2e7"
/>
**Implementation notes:**
RemoteConnectionOptions::display_name() will be subject to
exhaustiveness checking on RemoteConnectionOption variants.
Keeps the same UI approach as the WSL distro variants.
Release Notes:
- Improved Recent Projects picker: now displays SSH hostname with
remotes.
When installing local "dev" extensions that provide tree-sitter
grammars, compiling the parser can be quite intensive[^anecdote]. This
PR changes the logic to only compile the parser if the WASM object
doesn't exist or the source files are newer than the object (just like
`make(1)` would do).
[^anecdote]: The tree-sitter parser for LLVM IR takes >10 minutes to
compile and uses 20 GB of memory on my laptop.
Release Notes:
- N/A
---------
Co-authored-by: Finn Evers <finn.evers@outlook.de>
This mostly affects Channel Notes, but due to a change in
https://github.com/zed-industries/zed/pull/43921 we were
short-circuiting before opening links.
I moved the workspace checks back to right before we need them so that
we still follow the same control flow as usual for these editors.
Closes#44207
Release Notes:
- N/A
Closes#26949
## Summary
1. Split editor references to avoid borrow conflicts in event handlers
2. Check
[has_mouse_context_menu()](vscode-file://vscode-app/Applications/Visual%20Studio%20Code.app/Contents/Resources/app/out/vs/code/electron-browser/workbench/workbench.html)
state directly in tooltip conditional instead of caching stale value
3. Restructured context menu deployment to ensure proper sequencing:
hide popover → build menu → deploy menu → notify for re-render
**Screen recording**
https://github.com/user-attachments/assets/8a00f882-1c54-47b0-9211-4f28f8deb867
Release Notes:
- Fixed an issue where the context menu in the Git Blame view would be
frequently overlapped by the commit information tooltip.
---------
Co-authored-by: Finn Evers <finn.evers@outlook.de>
This ensures that the casing of this entry aligns with other entries in
the app popover Menus.
Release Notes:
- N/A
---------
Co-authored-by: Piotr Osiewicz <24362066+osiewicz@users.noreply.github.com>
This PR removes the default, error, warning, and success color variants
from the `SwitchColor` enum. In the most YAGNI spirit, I think we'll
probably never want to use these colors for the switch, so there's no
reason to support them. And if we ever want to do it, we can re-add
them.
I also took the opportunity to change the default color to be "accent",
which is _already_ what we use for all instances of this component, so
there's no need to have to define it every time. This effectively makes
the enum support only "accent" and "custom", which I think is okay for
now if we ever need an escape hatch before committing to supporting new
values.
Release Notes:
- N/A
This PR partially implements a knowledge distillation data pipeline.
`zeta distill` gets a dataset of chronologically ordered commits and
generates synthetic predictions with a teacher model (one-shot Claude
Sonnet).
`zeta distill --batches cache.db` will enable Message Batches API. Under
the first run, this command will collect all LLM requests and upload a
batch of them to Anthropic. On subsequent runs, it will check the batch
status. If ready, it will download the result and put them into the
local cache.
Release Notes:
- N/A
---------
Co-authored-by: Piotr Osiewicz <24362066+osiewicz@users.noreply.github.com>
Co-authored-by: Ben Kunkle <ben@zed.dev>
This pull request enhances syntax highlighting for JavaScript,
TypeScript, TSX, and JSDoc by adding more precise rules for parameters,
types, and punctuation.
- Added queries for highlighting parameters (`@variable.parameter`)
- Expanded highlighting for type identifiers, type aliases, interfaces,
classes
- Extended/implemented types to improve distinction between different
type constructs (`@type`, `@type.class`)
- Added highlighting for punctuation in type parameters, unions,
intersections, annotations, index signatures, optional fields, and
predicates (`@punctuation.special`, `@punctuation.bracket`)
- Added highlighting for identifiers in JSDoc comments
(`@variable.jsdoc`)
Release Notes:
- Refined syntax highlighting in JavaScript and TypeScript for better
visual distinction of
types, parameters, and JSDoc elements
## Summary
Follow-up to #40716. This applies the same `reset_exception_ports()` fix
to `set_pre_exec_to_start_new_session()`, which is used by shell
environment capture, terminal spawning, and DAP transport.
### Root Cause
After more debugging, I finally figured out what was causing the issue
on my machine. Here's what was happening:
1. Zed spawns a login shell (zsh) to capture environment variables
2. A pipe is created: reader in Zed, writer mapped to fd 0 in zsh
3. zsh sources `.zshrc` → loads oh-my-zsh → runs poetry plugin
4. Poetry plugin runs `poetry completions zsh &|` in background
5. Poetry inherits fd 0 (the pipe's write end) from zsh
6. zsh finishes `zed --printenv` and exits
7. Poetry still holds fd 0 open
8. Zed's `reader.read_to_end()` blocks waiting for all writers to close
9. Poetry hangs (likely due to inherited crash handler exception ports
interfering with its normal operation)
10. Pipe stays open → Zed stuck → no more processes spawn (including
LSPs)
I confirmed this by killing the hanging `poetry` process, which
immediately unblocked Zed and allowed LSPs to start. However, this
workaround was needed every time I started Zed.
While poetry was the culprit in my case, this can affect any shell
configuration that spawns background processes during initialization
(oh-my-zsh plugins, direnv, asdf, nvm, etc.).
Fixes#36754
## Test plan
- [x] Build with `ZED_GENERATE_MINIDUMPS=true` to force crash handler
initialization
- [x] Verify crash handler logs appear ("spawning crash handler
process", "crash handler registered")
- [x] Confirm LSPs start correctly with shell plugins that spawn
background processes
Release Notes:
- Fixed an issue on macOS where LSPs could fail to start when shell
plugins spawn background processes during environment capture.
This bug was caused by using two separate keys for writing/reading from
the KVP database. The bug didn't show up in my debug build because there
was an old entry of a valid key.
I added an integration test for this feature to prevent future
regressions as well.
Release Notes:
- debugger: Fix a bug where the stack frame filter state wouldn't
persist between sessions
This PR fixes that the `Current State` option inside the history
dropdown does not updating the UI. This was because we didn't send the
`SessionEvent::HistoricSnapshotSelected` event in the reset case. This
was just a mistake.
**After**
https://github.com/user-attachments/assets/6df5f990-fd66-4c6b-9633-f85b422fb95a
cc @Anthony-Eid
Release Notes:
- N/A
This allows users to select any snapshot in the debugger history feature
and go back to the active session snapshot.
We also change variable names to use hsitoric snapshot instead of
history and move the snapshot icon to the back of the debugger top
control strip.
https://github.com/user-attachments/assets/805de8d0-30c1-4719-8af7-2d47e1df1da4
Release Notes:
- N/A
Co-authored-by: Anthony Eid <hello@anthonyeid.me>
This PR adds the basic logic for a feature that allows you to visit any
stopped information back in time. We will follow up with PRs to improve
this and actually add UI for it so the UX is better.
https://github.com/user-attachments/assets/42d8a5b3-8ab8-471a-bdd0-f579662eadd6
Edit Anthony:
We feature flagged this so external users won't be able to access this
until the feature is polished
Release Notes:
- N/A
---------
Co-authored-by: Anthony Eid <hello@anthonyeid.me>
Even if `workspace_diagnostics_refresh_tasks` is empty, registrations
which didn't advertise support for workspace diagnostics may still
exist.
Release Notes:
- N/A
Closes https://github.com/zed-industries/zed/issues/43292
We were seeing clicks on the "View Panel" and "Dismiss" buttons
sometimes not being triggered. I believe this was happening because the
overall parent also had an on_click, which due to this being a popup
window, was causing conflicts with the buttons' on click handlers. This
should hopefully fix that issue.
Release Notes:
- agent: Fixed an issue where clicking on the agent notification buttons
would sometimes not trigger their actions.
It's just distracting having excerpts for all the successfully merged
hunks.
Release Notes:
- git: The project diff now focuses on merge conflicts for files that
have them.
Make gpui's `rems()`, `phi()`, `auto()` length related helpers into
const functions.
I can't see why these functions aren't already const except that it
must've been overlooked when they were written?
In my project I had need for rems() to be const, and I thought I'd do
phi() and auto() whilst I was in the neighbourhood
Release Notes:
- N/A
We were just deleting them before
Co-Authored-By: Matthew Chisolm <mchisolm0@gmail.com>
Closes #ISSUE
Release Notes:
- Fixed restoring window location for single-file worktrees
Co-authored-by: Matthew Chisolm <mchisolm0@gmail.com>
Instead of allocating a one-element vec on the heap, we can just use an
array here (since `Editor::edit` accepts anything that implements
`IntoIterator`).
I haven't checked if there are more instances that can be simplified,
just accidentally stumbled upon this when working on something else in
the markdown preview crate.
Release Notes:
- N/A
Follow-up of https://github.com/zed-industries/zed/pull/43854
Closes https://github.com/zed-industries/zed/issues/40970
Seems that json language server does not distinguish between JSONC and
JSON files in runtime, but there is a static schema, which accepts globs
in its `fileMatch` fields.
Use all glob overrides and file suffixes for JSONC inside those match
fields, and provide a grammar for such matches, which accepts trailing
commas.
Release Notes:
- Improved JSONC trailing comma handling
Follow up to https://github.com/zed-industries/zed/pull/42819 and
https://github.com/zed-industries/zed/pull/44206.
- Make this picker feel more consistent with other similar pickers
(namely, the project picker)
- Move actions to the footer and toggle them conditionally
- Only show the "Create" and "Create New From: {default}" when we're
selecting the "Create" list item _or_ when that item is the only
visible. This means I'm changing here the state transition to only
change to `NewBranch/NewRemote` if we only have those items available.
- Reuse more UI code and use components when available (e.g.,
`ListHeader`)
- Remove secondary actions from the list item
Next step (in another PR), will be refine the same picker in the
smaller, panel version.
https://github.com/user-attachments/assets/fe72ac06-c1df-4829-a8a4-df8a9222672f
Release Notes:
- N/A
There's still a weird problem happening where the labels (and the label
on the tab, too, for what is worth) flicker as the file history view
gets smaller. I suspect that problem is related to something
else—potentially the truncation algorithm or focus management—so I'm not
solving it here.
<img width="500" height="1948" alt="Screenshot 2025-12-05 at 11 24@2x"
src="https://github.com/user-attachments/assets/25715725-e2cb-475a-bdab-f506bb75475f"
/>
Release Notes:
- N/A
Tracing code is not included in normal release builds
Documents how to use them in our performance docs
Only the maps and cursors are instrumented atm
# Compile times:
current main: fresh release build (cargo clean then build --release)
377.34 secs
current main: fresh debug build (cargo clean then build )
89.31 secs
tracing tracy: fresh release build (cargo clean then build --release)
374.84 secs
tracing tracy: fresh debug build (cargo clean then build )
88.95 secs
tracing tracy: fresh release build with timings (cargo clean then build
--release --features tracing)
375.77 secs
tracing tracy: fresh debug build with timings (cargo clean then build
--features tracing)
90.03 secs
Release Notes:
- N/A
---------
Co-authored-by: localcc <work@localcc.cc>
Addresses a regression introduced by
https://github.com/zed-industries/zed/pull/44021 that caused @mentions
and slash commands to stop working if you set
`show_completions_on_input: false` in your settings.
In this case, we should always show these menus, otherwise the features
won't work at all.
Release Notes:
- N/A
- Replace `gpui::styled::Styled.font_family()` calls with
`gpui::styled::Styled.font()` when laying out inline diagnostics and
inline blame, to ensure that the font's features are also used, and
not just the font feature.
- Update both `editor::hover_popover::hover_markdown_style` and
`editor::hover_popover::diagnostics_markdown_style` to ensure that
both the UI and Buffer font features are used in both markdown and
diagnostics popover.
Closes#44209
Release Notes:
- Fixed font feature application for inline git blame, inline
diagnostics, markdown popovers and diagnostics popovers
Sometimes machines are configured to drop outbound packets (rather than
reject connections). In these cases, curl/wget just hang causing our
download step to never complete. This PR adds a timeout of 10s for the
connection (not the whole download), so that in situations like this we
can fallback to our client-side download eventually.
Related to but doesn't fully fix:
https://github.com/zed-industries/zed/issues/43694 and
https://github.com/zed-industries/zed/issues/43718
Release Notes:
- remote: Add 10s connect timeout for server download
We have seen cases (see
https://github.com/zed-industries/zed/issues/43694) where the user's
shell initialization script includes text that ends up in the output of
the commands we use to detect the platform and shell of the remote. This
solution isn't perfect, but it should address the issue in most
situations since both commands should only output one line.
Release Notes:
- remote: Improve resiliency when initialization scripts output text
The bug was introduced in this recent PR:
https://github.com/zed-industries/zed/pull/42819. Since it's still in
nightly, there is no need for release notes.
I also polished the feature a bit by:
- Ensuring branch names are always a single line so the branch picker's
uniform list uses the correct element height.
- Adding tooltip text for the filter remotes button.
- Fixing the create branch from default icon showing up for non-new
branch entries.
Release Notes:
- N/A
Evaluate selection now acts as if the text was typed verbatim into the
console.
Closes ##33526
Release Notes:
- debugger: Fixed "evaluate selection" not behaving as if the
highlighted text was not typed verbatim into the console.
To do
* [x] Default to no context retrieval. Allow opting in to LSP-based
retrieval via a setting (for users in `zeta2` feature flag)
* [x] Feed this context to models when enabled
* [x] Make the zeta2 context view work well with LSP retrieval
* [x] Add a UI for the setting (for feature-flagged users)
* [x] Ensure Zeta CLI `context` command is usable
---
* [ ] Filter out LSP definitions that are too large / entire files (e.g.
modules)
* [ ] Introduce timeouts
* [ ] Test with other LSPs
* [ ] Figure out hangs
Release Notes:
- N/A
---------
Co-authored-by: Ben Kunkle <ben@zed.dev>
Co-authored-by: Agus Zubiaga <agus@zed.dev>
The JSON language server looks for a top-level `allowTrailingCommas`
flag to decide whether it should warn for trailing commas. Since the
JSONC parser for these builtin files can handles trailing commas, adding
this flag to the schema also prevents a warning for those commas.
I don't think there's an issue that is only for this specific issue, but
it relates to *many* existing / older issues:
- #18509
- #17487
- #40970
- #18509
- #21303
Release Notes:
- Suppress warning for trailing commas in builtin JSON files
(`settings.json`, `keymap.json`, etc.)
Just recently realized we don't need this custom component for it given
we now have `Tooltip::element`. UI result is exactly the same; nothing
changes.
Release Notes:
- N/A
Follow up to https://github.com/zed-industries/zed/pull/44162 where my
strategy for not displaying the indent guides only in the commit message
was wrong given I ended up... disabling indent guides for all the
buffers. This PR adds a new method to the editor where we can disable it
for a specific buffer ID following the pattern of
`disable_header_for_buffer`.
Release Notes:
- N/A
Closes#40757
## Summary
This PR addresses an issue where Zed incorrectly adjusts the indentation
of Markdown lists when inserting text using multiple cursors. Currently:
- Editing individual lines with a single cursor behaves correctly (no
unwanted indentation changes).
- Using multiple cursors, Zed automatically adjusts the indentation,
unlike VS Code, which preserves the existing formatting.
## Tasks
- [x] Implement a new test to verify correct Markdown indentation
behavior with multiple cursors.
- [x] Apply the fix to prevent Zed from adjusting indentation when
inserting text on multiple cursors.
------------------------
Release Notes:
- Fixed an issue where inserting text with multiple cursors inside a
nested Markdown list would cause it to lose its indentation.
---------
Co-authored-by: Smit Barmase <heysmitbarmase@gmail.com>
We already store the remote URLs for `origin` and `upstream` in the
`RepositorySnapshot`, so just use that data. Follow-up to #44092.
Release Notes:
- N/A
Reformat document structure like other language docs, improve
information flow, add missing requirements, and fix typos.
Release Notes:
- N/A
---------
Co-authored-by: Piotr Osiewicz <24362066+osiewicz@users.noreply.github.com>
One half of https://github.com/zed-industries/zed/issues/42861
This basically reduces the main thread work for large enough json (and
other) files from multiple milliseconds (15ms was observed in that test
case) down to microseconds (100ms here).
Release Notes:
- Improved cursor movement performance when edit predictions are enabled
Closes#41521
Release Notes:
- Fixed codex web login not working on wsl remotes if no browser is
installed
Co-authored-by: Ben Brandt <benjamin.j.brandt@gmail.com>
Fixes a deadlock in the background scanner that occurs on single-core
Linux devices. This happens because the background scanner would `block`
on a background thread waiting for a future, but on single-core Linux
devices there would be no other thread to pick it up. This mostly
affects SSH remoting use cases where it's common for servers to have 1
vCPU.
Closes#43884Closes#43809
Release Notes:
- Fix SSH remoting hang when connecting to 1 vCPU servers
Closes#44148
the existing rate == 0 check inside the timer callback already handles
disabling repeat - it just drops the timer immediately. So the fix
prevents the crash while preserving correct behavior.
Release Notes:
- Linux (Wayland): Fixed a crash that could occur when
`characters_per_second` was zero
Closes#44090
Co-authored-by: Smit Barmase <heysmitbarmase@gmail.com>
Release Notes:
- python: Improved sorting order of toolchains in monorepos with
multiple local virtual environments.
- python: Fixed toolchain selector not having an active toolchain
selected on open.
---------
Co-authored-by: Smit Barmase <heysmitbarmase@gmail.com>
Co-authored-by: Smit <smit@zed.dev>
Set `prettier_parser` explicitly if the file extension for the buffer
does not match a known one for the current language
Release Notes:
- N/A
---------
Co-authored-by: Kirill Bulatov <kirill@zed.dev>
In project search UI code we were seeing an issue where "Go to next
match" would act up and behave weirdly. It would not wrap at times.
Stuff would be weird, yo. It turned out that match ranges reported by
core project search were sometimes out of sync with the state of the
multi-buffer. As in, the sort order of
`search::ProjectSearch::match_ranges` would not match up with
multi-buffer's sort order. This is ~because multi-buffers maintain their
own sort order.
What happened within project search is that we were skipping straight
from stage 1 (filtering paths) to stage 3 via an internal channel and in
the process we've dropped the channel used to maintain result sorting.
This made is so that, given 2 files to scan:
- project/file1.rs <- not open, has to go through stage2 (FS scan)
- project/file2.rs <- open, goes straight from stage1 (path filtering)
to stage3 (finding all matches) We would report matches for
project/file2.rs first, because we would notice that there's an
existing language::Buffer for it. However, we should wait for
project/file1.rs status to be reported first before we kick off
project/file2.rs
The fix is to use the sorting channel instead of an internal one, as
that keeps the sorting worker "in the loop" about the state of the
world.
Closes#43672
Co-authored-by: Smit Barmase <heysmitbarmase@gmail.com>
Release Notes:
- Fixed "Select next match" in project search results misbehaving when
some of the buffers within the search results were open before search
was ran.
- Fixed project search results being scrolled to the last file active
prior to running the search.
---------
Co-authored-by: Smit Barmase <heysmitbarmase@gmail.com>
Co-authored-by: Smit <smit@zed.dev>
Closes#43598
Release Notes:
- bedrock: Added opt-in `allow_global` which enables global endpoints
- bedrock: Updated cross-region-inference endpoint and model list
- bedrock: Fixed Opus 4.5 access on Bedrock, now only accessible through the `allow_global` setting
Related to https://github.com/zed-industries/zed/pull/44109,
https://github.com/zed-industries/zed/issues/43884,
https://github.com/zed-industries/zed/issues/43809.
In the Linux dispatcher, we create one background thread per CPU, but
when a single core is available, having a single background thread
significantly hinders the perceived performance of Zed. This is
particularly helpful when SSH remoting to low-resource servers.
We may want to bump this to more than two threads actually, but I wanted
to be conservative, and this seems to make a big difference already.
Release Notes:
- N/A
Adds `com.apple.security.files.user-selected.read-write` and
`com.apple.security.files.downloads.read-write` to zed.entitlements.
This resolves an issue where the integrated terminal could not access
external drives or user-selected files on macOS, even when "Full Disk
Access" was granted. These entitlements are required for the application
to properly inherit file access permissions.
Release Notes:
- Resolves an issue where the integrated terminal could not access
external drives or user-selected files on macOS.
`WorkItemPriority::High` will enqueue the work items to threads with
higher-than-normal priority. If the work items are very intensive, this
can cause the system to become unresponsive. It's not clear what this
gets us, so let's avoid the responsiveness issue by deleting this.
Release Notes:
- N/A
Fancy regex has a max backtracking limit which defaults to 1,000,000
backtracks. This avoids spinning the CPU forever in the case that a
match is taking a long time (though does mean that some matches may be
missed).
Unfortunately the verison we depended on causes an infinite loop when
the backtracking limit is hit
(https://github.com/fancy-regex/fancy-regex/issues/137), so we got the
worse of both worlds: matches were missed *and* we spun the CPU forever.
Updating fixes this.
Excitingly regex may gain support for lookarounds
(https://github.com/rust-lang/regex/pull/1315), which will make
fancy-regex much less load bearing.
Closes#43821
Release Notes:
- Fix a bug where search regexes with look-around or backreferences
could hang
the CPU. They will now abort after a certain number of match attempts.
When adding the File History option here, I used the pattern to hide the
option, since that's what another option was already doing here, but I
see other menus in the git panel (`...`) that use disabling over hiding,
which is what I think is a nicer experience (allows you to learn of
actions, the full range of actions is always visible, don't have to
worry about how multiple hidden items might interact in various
configurations, etc).
<img width="336" height="241" alt="SCR-20251203-pnpy"
src="https://github.com/user-attachments/assets/0da90b9a-c230-4ce3-87b9-553ffb83604f"
/>
<img width="332" height="265" alt="SCR-20251203-pobg"
src="https://github.com/user-attachments/assets/5da95c7d-faa9-4f0f-a069-f1d099f952b9"
/>
In general, I think it would be good to move to being more consistent
with disabling over hiding - there are other places in the app that are
hiding - some might be valid, but others might just choices made on a
whim.
Release Notes:
- N/A
Closes#43171
Previously the tab switcher only subscribed to events from a single pane
so closing tabs in other panes wouldn't cause the tab switcher to
update. This PR changes that so the tab switcher subscribes to the whole
workspace and thus updates when tabs in other panes are closed.
It also modifies the work in #44006 to sync selected index across the
whole workspace instead of just the original pane in the case of the
all-panes tab switcher.
Release Notes:
- Fixed all-panes tab switcher not updating in response to changes in
other panes
Closes https://github.com/zed-industries/zed/issues/41935
The registration ID responsible for generating each diagnostic is now
tracked. This allows us to replace only the diagnostics from the same
registration ID when a pull diagnostics report is applied.
Additionally, various deficiencies in our support for pull diagnostics
have been fixed:
- Document pulls are issued for all open buffers, not just the edited
one. A shorter debounce is used for the edited buffer. Workspace
diagnostics are also now ignored for open buffers.
- Tracking of `lastResultId` is improved.
- Stored pull diagnostics are discarded when the corresponding buffer is
closed.
Release Notes:
- Improved compatibility with language servers that use the "pull
diagnostics" feature of Language Server Protocol.
---------
Co-authored-by: Kirill Bulatov <mail4score@gmail.com>
Co-authored-by: Kirill Bulatov <kirill@zed.dev>
This reverts commit 05764e8af7.
Internally we've seen a much higher incidence of macOS code-signing
failing on
the download rust analyzer than we did before this change.
It's unclear why this would be a problem, but we want to try reverting
to see if that fixes it.
Release Notes:
- Reverted a change that seemed to cause problems with code-signing on
rust-analyzer
Whenever an item is removed using the Tab Switcher, the list of matches
is automatically updated, which can lead to the order of the elements
being updated and changing in comparison to what the user was previously
seeing. Unfortunately this can lead to a situation where the selected
index, since it wasn't being updated, would end up in a different item
than the one that was actually active in the pane.
This Pull Request updates the handling of the `PaneEvent::RemovedItem`
event so that the `TabSwitcherDelegate.selected_index` field is
automatically updated to match the pane's new active item.
Seeing as this is being updated, the
`test_close_preserves_selected_position` test is also removed, as it no
longer makes sense with the current implementation. I believe a better
user experience would be to actually not update the order of the
matches, simply removing the ones that no longer exist, and keep the
selected index position, but will tackle that in a different Pull
Request.
Closes#44005
Release Notes:
- Fixed a bug with the tab switcher where, after closing a tab, the
selected entry would not match the pane's active item
Use `MotionKind::LineWise` in both
`vim::normal::change::Vim.change_object` and
`vim::normal::yank::Vim.yank_object` when dealing with objects that
target `Mode::VisualLine`, for example, paragraphs. This fixes an issue
where yanking and changing paragraphs would not include the trailing
newline character.
Closes#28804
Release Notes:
- Fixed linewise text object operations (`yap`, `cap`, etc.) omitting
trailing blank line in vim mode
---------
Co-authored-by: dino <dinojoaocosta@gmail.com>
Closes#40851
Release Notes:
- Fixed: Commit diff multibuffers now open real project files whenever
possible, restoring navigation and annotations inside those excerpts.
---------
Co-authored-by: Anthony Eid <anthony@zed.dev>
Closes#39152
This PR fixes an issue where we would render Markdown tables full width
based on their container size. We now render tables based on their
content min size, meaning you are still allowed to make the table render
as it was before by making the columns `w_full`.
I had to change the `div()` to `v_flex().items_start()` because this
introduced a weird displaying behavior of the outside table border,
because the grid container was not shrinking due to It was always taking
up the full width of their container.
**Before**
<img width="1273" height="800" alt="Screenshot 2025-11-26 at 14 37 19"
src="https://github.com/user-attachments/assets/2e152021-8679-48c2-b7bd-1c02768c0253"
/>
**After**
<img width="1273" height="797" alt="Screenshot 2025-11-26 at 14 56 12"
src="https://github.com/user-attachments/assets/4459d20e-8c3b-487b-a215-c95ee5c1fc8e"
/>
**Code example**
```markdown
| Name | Age | Occupation |
|:--------:|:-------:|:--------------:|
| Alice | 28 | Engineer |
| Bob | 34 | Designer |
| Carol | 25 | Developer |
| Syntax | Description |
| ----------- | ----------- |
| Header | Title |
| Paragraph | Text |
| City | Population (approx.) | Known For |
|----------------|----------------------|------------------------------------|
| New York | 8,500,000 | Statue of Liberty, Wall Street |
| Los Angeles | 4,000,000 | Hollywood, film industry |
| Chicago | 2,700,000 | Architecture, deep-dish pizza |
| Houston | 2,300,000 | NASA, energy industry |
| Miami | 470,000 | Beaches, Latin culture |
| San Francisco | 800,000 | Golden Gate Bridge, Silicon Valley |
| Las Vegas | 650,000 | Casinos, nightlife |
<table>
<caption>Table Caption</caption>
<thead>
<tr>
<th>ID asjkfjaslkf jalksjflksajflka jlksdla k</th>
<th>Name</th>
</tr>
</thead>
<tbody>
<tr>
<td>1</td>
<td>Chris</td>
</tr>
<tr>
<td>2</td>
<td>Dennis</td>
</tr>
<tr>
<td>3</td>
<td>Sarah</td>
</tr>
<tr>
<td>4</td>
<td>Karen</td>
</tr>
</tbody>
</table>
```
cc @bennetbo
Release Notes:
- Markdown Preview: Markdown tables scale now based on their content
size
This seems sensible to do - it already was the case prior but
indirectly, lets rather be explicit about this.
Release Notes:
- N/A
Co-authored-by: Agus Zubiaga <agus@zed.dev>
Uses the latest version of the SDK + schema crate. A bit painful because
we needed to move to `#[non_exhaustive]` on all of these structs/enums,
but will be much easier going forward.
Also, since we depend on unstable features, I am pinning the version so
we don't accidentally introduce compilation errors from other update
cycles.
Release Notes:
- N/A
Add informational banners for extensions that have been integrated into
Zed core:
- Basedpyright (Python language server)
- Ruff (Python linter)
- Ty (Python language server)
These banners appear when users search for these extensions, informing
them that the functionality is now built-in and linking to relevant
documentation.
The banners trigger when:
- Users search by extension ID (e.g., 'id:ruff')
- Users search using relevant keywords (e.g., 'basedpyright', 'pyright',
'ruff', 'ty')
Supersedes #43844Closes#43837
Release Notes:
- Added banners to the extensions page when searching for Basedpyright,
Ruff, or Ty, indicating that these features are now built-in.
---------
Co-authored-by: Marshall Bowers <git@maxdeviant.com>
#42441 moved the commit message out of the multi-buffer editor into its
own header element which looks nicer, but unfortunately can make the
view become unusable when the commit message is too long since it
doesn't scroll with the diff.
This PR maintains the metadata in its own element, but moves the commit
message back to the editor so the user can scroll past it. This does
mean that we lose markdown rendering for now, but we think this is a
good solution for the moment.
https://github.com/user-attachments/assets/d67cf22e-1a79-451a-932a-cdc8a65e43de
Release Notes:
- N/A
---------
Co-authored-by: cameron <cameron.studdstreet@gmail.com>
With the merging and publishing of
https://github.com/tree-sitter/tree-sitter-bash/pull/311 , we can now go
ahead and update the version of `tree-sitter-bash` that Zed relies on to
the latest version.
Closes#42091
Release Notes:
- Improved grammar for "Shell Script"
This PR forks a new version of the `zed_extension_api` in preparation
for new changes.
We're jumping from v0.6.0 to v0.8.0 for the WIT because we released
v0.7.0 of the `zed_extension_api` without any WIT changes (it probably
should have been v0.6.1, instead).
Release Notes:
- N/A
Closes#43408
Previously, we checked the setting inside `is_completion_trigger()`,
which only affects LSP completions. This was ok because user-defined
snippets were tacked onto LSP completions. Then #42122 and #42398 made
snippet completions their own thing, similar to word completions,
surfacing #43408. This PR moves the settings check into
`open_or_update_completions_menu()` so it applies to all completions.
Release Notes:
- Fixed setting `show_completions_on_input: false` so that it affects
word and user-defined snippet completions as well as LSP completions
Closes#41582
Release Notes:
- Improves the '%' vim motion for html by moving the cursor to the
opening tag when its positioned on the `/` ( slash ) of the closing tag
Hello, this is my first time contributing here! The issue creation
button noted that "feature request"-esque items should go to
discussions, so with this PR, I'm closing that discussion and not an
issue. I hope that's ok :)
---
Closes https://github.com/zed-industries/zed/discussions/43769
Preview:
<img width="500" alt="image"
src="https://github.com/user-attachments/assets/00b8d475-d452-42e9-934b-ee5dbe48586e"
/><p/>
Release Notes:
- Added JavaScript highlighting via YAML `injections.scm` for script
blocks of `actions/github-script`
We currently attempt to flush all rejected predictions at once even if
we have accumulated more than
`MAX_EDIT_PREDICTION_REJECTIONS_PER_REQUEST`. Instead, we will now flush
as many as possible, and then keep the rest for the next batch.
Release Notes:
- N/A
Windows applications tend to be fairly re-entrant which does not work
well with our current top-level `RefCell` approach. We have worked
around a bunch of panics in the past due to this, but ultimately this
will re-occur (and still does according to sentry) in the future. So
this PR moves all interior mutability down to the fields.
Fixes ZED-1HM
Fixes ZED-3SH
Fixes ZED-1YV
Fixes ZED-29S
Fixes ZED-29X
Fixes ZED-369
Fixes ZED-20W
Release Notes:
- Fixed panics on windows caused by unexpected re-entrancy for interior
mutability
Closes https://github.com/zed-industries/zed/issues/43328
Instead of trying to guess whether we can `--exec`, this now
restructures things to only attempt to use that flag where its
necessary. We only need to `--exec` when we are interested in the shell
output after all.
Release Notes:
- Fixed wsl remoting not working with some nixOS setups
Currently, Zed does not provide suggestions and validations for Gleam,
as it is only available for languages specified in `tailwind.rs`. This
pull-request adds Gleam to that list of languages.
After this, if Tailwind is configured to work with Gleam, suggestions
and validation appear correctly.
Even after this change, Tailwind will not be able to detect and give
suggestions in Gleam directly. Below is the config required for Tailwind
classes to be detected in all Gleam strings.
<details><summary>Zed Config for Tailwind detection in Gleam</summary>
<p>
```
{
"languages": {
"Gleam": {
"language_servers": [
"gleam",
"tailwindcss-language-server"
]
}
},
"lsp": {
"tailwindcss-language-server": {
"settings": {
"experimental": {
"classRegex": [
"\"([^\"]*)\""
]
}
}
}
}
}
```
The `classRegex` will match all Gleam strings, making it work seamlessly
with Lustre templates and plain string literals.
</p>
</details>
Release Notes:
- Added support for Tailwind suggestions and validations for the [Gleam
programming language](https://gleam.run/).
Release Notes:
- pane::ActivatePreviousItem and pane::ActivateNextItem now toggle the
most recent pane when called from a dock panel
a couple months ago i posted a work around that used `SendKeystrokes` to
cycle through pane items when focused on a dock.
#35253
this pr would add this functionality to the these actions by default.
i implemented this by adding an action listener to the workspace level.
------
if the current context is a dock that does not hold a pane
it retrieves the most recent pane from `activation_history` and
activates the next item on that pane instead.
- `"Pane > Editor"`
cycles through the current pane like normal
- `"Dock > Pane > Terminal"`
also cycles through the pane items like normal
- `"Dock > (Any Child that is not a child of Pane)"`
cycles through the items of the most recent pane.
this is the standard behavior in VS Code i believe.
in the video below you can see the actions cycling through the editor
like normal when focus is on the editor.
then you can see the editor continue to cycle when the focus is on the
project panel.
and that the focus stays on the project panel.
and you can see the action cycle the terminal items when the focus is
moved to the terminal
https://github.com/user-attachments/assets/999ab740-d2fa-4d00-9e53-f7605217e6ac
the only thing i noticed is that for this to work the keybindings must
be set above `Pane`
so they have to be set globally or on workspace. otherwise they do not
match in the context
Tracking Issue (does not close):
https://github.com/zed-industries/zed/issues/35552
This is somewhat of a blocker for
https://github.com/zed-industries/zed/pull/40035 (but also the current
behavior doesn't really make sense).
The current behavior of `ThemeSelectorDelegate::set_theme` (the theme
selector menu) is to simply set the in-memory settings to `Static`,
regardless of if it is currently `Dynamic`. The reason this doesn't
matter now is that the `theme::set_theme` function that updates the
user's settings file _will_ make this check, so dynamic settings stay
dynamic in `settings.json`, but not in memory.
But this is also sort of strange, because `theme::set_theme` will set
the setting of whatever the old appearance was to the new theme name. In
other words, if I am currently on a light mode theme and I change my
theme to a dark mode theme using the theme selector, the `light` field
of `theme` in `settings.json` is set to a dark mode theme!
_I think this is because displaying the new theme in the theme selector
does not update the global context, so
`ThemeSettings::get_global(cx).theme.name(appearance).0` returns the
original theme appearance, not the new one._
---
This PR makes `ThemeSelectorDelegate::set_theme` keep the current
`ThemeSelection`, as well as changes the behavior of the
`theme::set_theme` call to always choose the correct setting to update.
One edge case that might be slightly strange now is that if the user has
specified the mode as `System`, this will now override that with the
appearance of the new theme. I think this is fine, as otherwise a user
might set a dark theme and nothing will change because the
`ThemeAppearanceMode` is set to `light` or `system` (where `system` is
also light).
I also have an `unreachable!` in there that I'm pretty sure is true but
I don't really know how to formally prove that...
Release Notes:
- N/A *or* Added/Fixed/Improved ...
---------
Signed-off-by: Connor Tsui <connor.tsui20@gmail.com>
This PR adds word/character diff for expanded diff hunks that have both
a deleted and added section, as well as a setting `word_diff_enabled` to
enable/disable word diffs per language.
- `word_diff_enabled`: Defaults to true. Whether or not expanded diff
hunks will show word diff highlights when they're able to.
### Preview
<img width="1502" height="430" alt="image"
src="https://github.com/user-attachments/assets/1a8d5b71-449e-44cd-bc87-d6b65bfca545"
/>
### Architecture
I had three architecture goals I wanted to have when adding word diff
support:
- Caching: We should only calculate word diffs once and save the result.
This is because calculating word diffs can be expensive, and Zed should
always be responsive.
- Don't block the main thread: Word diffs should be computed in the
background to prevent hanging Zed.
- Lazy calculation: We should calculate word diffs for buffers that are
not visible to a user.
To accomplish the three goals, word diffs are computed as a part of
`BufferDiff` diff hunk processing because it happens on a background
thread, is cached until the file is edited, and is only refreshed for
open buffers.
My original implementation calculated word diffs every frame in the
Editor element. This had the benefit of lazy evaluation because it only
calculated visible frames, but it didn't have caching for the
calculations, and the code wasn't organized. Because the hunk
calculations would happen in two separate places instead of just
`BufferDiff`. Finally, it always happened on the main thread because it
was during the `EditorElement` layout phase.
I used Zed's
[`diff_internal`](02b2aa6c50/crates/language/src/text_diff.rs (L230-L267))
as a starting place for word diff calculations because it uses
`Imara_diff` behind the scenes and already has language-specific
support.
#### Future Improvements
In the future, we could add `AST` based word diff highlights, e.g.
https://github.com/zed-industries/zed/pull/43691.
Release Notes:
- git: Show word diff highlight in expanded diff hunks with less than 5
lines.
- git: Add `word_diff_enabled` as a language setting that defaults to
true.
---------
Co-authored-by: David Kleingeld <davidsk@zed.dev>
Co-authored-by: Cole Miller <cole@zed.dev>
Co-authored-by: cameron <cameron.studdstreet@gmail.com>
Co-authored-by: Lukas Wirth <lukas@zed.dev>
Follow-up to #43586--when the diff is not split, just render the primary
editor. Otherwise the child `Pane` intercepts `CloseActiveItem`. (This
is still a bug for the actual split diff, but just fixing the
user-visible regression for now.)
Release Notes:
- N/A
Related: #42574
If an integration test is annotated with the ignore attribute, allow the
"debug: Test" option of the debug scenario or Code Action to run with
the "--include-ignored" and "--exact" arguments. Inclusion of "--exact"
covers the case where more that one test shares a base name. For
example, consider two tests named "test_no_ace_in_middle_of_straight"
and "test_no_ace_in_middle_of_straight_flush." Without the "--exact"
argument both tests would run if a user attempts to debug
"test_no_ace_in_middle_of_straight".
Release Notes:
- Improved "debug test" experience in Rust with ignored tests.
This makes rolling this out across extensions a far bit easier and also
safer, because we don't have to manually set `run_tests` for every
extension (and never have to consider this when updating these).
Release Notes:
- N/A
We were allowing the client to build up to
`MAX_EDIT_PREDICTION_REJECTIONS_PER_REQUEST`. We'll now attempt to flush
the rejections when we reach half max.
Release Notes:
- N/A
Mostly cleaning up the UI code. The UI looks fairly the same just a bit
more polished, with proper colors and spacing. Also added a scrollbar in
there. Next step would be to make it keyboard navigable.
<img width="500" height="1948" alt="Screenshot 2025-12-01 at 5 38@2x"
src="https://github.com/user-attachments/assets/c266b97c-4a79-4a0e-8e78-2f1ed1ba495f"
/>
Release Notes:
- N/A
While this does work for PRs and such, it does not work with main...
Hence, moving the token a few chars to the right to fix this issue.
Release Notes:
- N/A
- Updates tone to match bug template
- Removes the "current vs expected" behavior section
- It doesn't feel very useful. Users expect Zed to not crash, regardless
of what they are doing.
Release Notes:
- N/A
This PR adds workflows to be used for CD in extension reposiories in the
`zed-extensions` organization and updates some of the existing ones with
minor improvemts.
Release Notes:
- N/A
For now, just using Sonnet 4.5 and Opus 4.5 - I'll make a separate PR
for non-Anthropic models, in case they introduce new failures.
Release Notes:
- N/A
Release Notes:
- Fixed the behavior of the attach to process feature for the Golang
debugger.
**Step to reprorduce:**
1. Build and run golang binary
2. In Zed open debugger
3. Go to Attach tab
4. Select the binary you just built from the list
**Actual result:**
```
Tried to launch debugger with: {
"request": "attach",
"mode": "debug",
"processId": 74702,
"stopOnEntry": false,
"cwd": "/path/to/the/current/working/directory"
}
error: Failed to attach: invalid debug configuration - unsupported 'mode' attribute "debug"
```
**Expected result:** The debugger can attach to the process.
According to the [Delve
documentation](https://github.com/go-delve/delve/tree/master/Documentation/api/dap#launch-and-attach-configurations)
`attach` request supports `local` and `remote` values only
At some point, rust-analyzer started including the snippet expression
for some completions in the description field, but that can look like a
bug:
<img width="1570" height="578" alt="CleanShot 2025-11-27 at 20 39 49@2x"
src="https://github.com/user-attachments/assets/5a87c9fe-c0a8-472f-8d83-3bc9e9e00bbc"></img>
In these cases, we will now inline the tab stops as an ellipsis
character:
<img width="1544" height="428" alt="CleanShot 2025-12-01 at 10 01 18@2x"
src="https://github.com/user-attachments/assets/4c550891-4545-47cd-a295-a5eb07e78e92"></img>
You may also notice that we now syntax highlight the pattern closer to
what it looks like after accepted.
Alternatively, when the tab stop isn't just one position, it gets
highlighted as a selection since that's what it would do when accepted:
<img width="1558" height="314" alt="CleanShot 2025-12-01 at 10 04 37@2x"
src="https://github.com/user-attachments/assets/ce630ab2-da22-4072-a996-7b71ba21637d"
/>
Release Notes:
- rust: Display completion tab stops inline rather than as a raw LSP
snippet expression
Gist is we only need to block the foreground thread for reparsing if
immediate language changes are useful to the user. That is usually only
the case when they edit the buffer
Release Notes:
- Improved performance of large project searches and project diffs
Co-authored by: David Kleingeld <david@zed.dev>
Generalizes the digest verification logic from `rust-analyzer` and
`clangd` into a reusable helper function in
`http_client::github_download`.
This removes ~100 lines of duplicated code across the two language
adapters and makes it easier for other language servers to adopt digest
verification in the future.
Closes#35201
Release Notes:
- N/A
Relates to #35759, but maybe doesn't entirely fix it? I think it will
improve the situation, at least.
Also provides a workaround for the issue described in
https://github.com/zed-industries/zed/issues/40094#issuecomment-3559808526
for users of WSL + `nix-direnv`.
Rationale: there are cases where automatic direnv integration is not
always desirable, but Zed currently has no way of opting out of this
integration besides `direnv revoke` (which is often not desirable).
This PR provides such an opt-out for users who run into problems with
the existing direnv integration methods. Some reasons why disabling
might be useful:
- Security concerns about auto-loading `.envrc` (arguably, `direnv
revoke` should cover this most of the time)
- As in #35759, for users who use different shells/envs for
interactive/non-interactive cases and want to manually control the
environment Zed uses
- As in #40094, to workaround OS limits on environment variable /
command-line parameter size
Release Notes:
- Added the ability to disable direnv integration entirely
After #39928, if a font's weight changes between text runs without other
decoration changing, the earlier weight continues to be used for the
subsequent run(s).
PR #40840 fixes this in shape_text, but similar code exists also in
layout_text. The latter is used for text in the editor view itself, so
the issue continues to appear when using a highlighting theme with
varied font weights.
Fix the issue by applying the same fix in layout_text.
Closes#42297
Release Notes:
- Fixed incorrect font weights in editor view when using a highlighting
theme with varying font weights
We were previously always highlighting the last header in the table of
contents as active even if you were at the top of the page. This is now
fixed, where upon loading the page, no header is highlighted, and as you
scroll, we highlight the top-most heading one by one.
Release Notes:
- N/A
Summary
Fixed the thread deletion issue by:
1. Click handler conflict between the trash icon and the main ListItem
2. Added `cx.stop_propagation()` to prevent the click event from
bubbling up to the parent ListItem's click handler
3. Followed the established `cx.stop_propagation()` pattern used
throughout the codebase
Now when you click the trash icon to delete a thread:
- ✅ The thread deletion happens immediately on the first click
- ✅ No race condition between deletion and activation
- ✅ No double-clicking required
The fix is minimal, follows established patterns, and addresses the
exact root cause of the issue.
- Stop event propagation in thread removal handler
Release Notes:
- agent: Improved delete thread action in the history view by preventing
it from also triggering the thread activation.
Closes https://github.com/zed-industries/zed/issues/43721
This PR makes the loading state clearer by disabling the message editor
while the agent is loading as well as pulsating the icon.
Release Notes:
- agent: Made the thread loading state clearer in the agent panel.
Follow up to https://github.com/zed-industries/zed/pull/43758.
This PR uses view transition animations to reduce the page flickering
when navigating between one and the other. Pretty cool CSS-only
solution.
Release Notes:
- N/A
Closes https://github.com/zed-industries/zed/issues/43726
Note that the truncation strategy on the file path is not yet perfect.
I'm just applying the regular method from the label component, but we
should wrap path text from the start rather than from the end. Some time
in the future!
<img width="500" height="712" alt="Screenshot 2025-11-28 at 7 17@2x"
src="https://github.com/user-attachments/assets/6ebc618a-4b4a-42fd-b5b7-39fec3ae5335"
/>
Release Notes:
- Fixed a bug where the "Open File" button would overflow in the
multibuffer header if the file path was too long.
Closes https://github.com/zed-industries/zed/issues/43728
Release Notes:
- agent: Fixed a bug where the plan and edit files list would consume
the whole space of the thread if they were too long. They're now capped
by a max-height and scrollable.
This is still not perfect, but it reduces the shift that happens when
navigating between pages that have and don't have the table of contents.
It also tries to reduce the theme flicker that happens by moving its
loading to an earlier moment.
Release Notes:
- N/A
Adds clarifying examples and information about the `include_pattern`
parameter for the grep tool, analogous to the `path` parameter of the
read and list tools and others.
The lack of clarity led to unexpected agent behavior described in
#41189. This change is confirmed to improve the precision of Claude
Sonnet 4.5 when searching for code in an empty conversation (without it,
it leaves out the root directory in the query).
Closes#41189.
```
Release Notes:
- Clarify grep tool description to improve agent precision when using it with the `include_pattern` parameter
```
Closes#43040
Release Notes:
- Remove the end-of-support Gemini 1.5 model from the options.
- Remove the older Gemini 2.0 model from the options.
- Please let me know if you think it's better to keep it, as it is still
a usable model.
- Update the incorrect amounts for some input/output tokens.
- Update the default model to Gemini 2.5 Flash-Lite.
- Rename variant `Gemini3ProPreview` to `Gemini3Pro`
When this PR is merged, users will be able to select the following
Gemini models.
- 2.5 Flash
- 2.5 Flash-Lite
- 2.5 Pro
- 3 Pro
This PR adds the ability to collapse section in the docs sidebar (which
are persistent until you close the tab), and some design facelift to the
docs, which makes its design close to the site as well as polishing up
many elements and interactions (like moving the search to a modal and
making the table of content visible in smaller breakpoints).
<img width="600" height="2270" alt="Screenshot 2025-11-28 at 5 26@2x"
src="https://github.com/user-attachments/assets/3a8606c6-f74f-4bd2-84c8-d7a67ff97564"
/>
Release Notes:
- N/A
Release Notes:
- Added a keybinding to open the `settings.json` file when the Settings
UI is in focus: `cmd-,` (macOS) / `ctrl-,` (Windows / Linux).
- A tooltip was added to the `Edit in settings.json` button to show this
keybinding.
- shorten some phrases to (hopefully) retain attention better
- move the required field up to not bore people with scrolling
- call it a bug and not an issue to further emphasize we want feature
requests in Discussions where the product managers are
- remove the default from the WSL question since not everyone does
WSL or even Windows
Release Notes:
- N/A
---------
Co-authored-by: Miguel Raz Guzmán Macedo <miguel@zed.dev>
Co-authored-by: Kunall Banerjee <hey@kimchiii.space>
Closes#9648#9755
Release Notes:
- Added way to configure ESLint's working directories in settings. For
example:
`{"lsp":{"eslint":{"settings":{"workingDirectories":["./client","./server"]}}}}`
---------
Co-authored-by: Piotr Osiewicz <24362066+osiewicz@users.noreply.github.com>
Closes#26649
Release Notes:
- Improved git support for remotes handling. Git will now check pushRemote and pushDefault configurations before
falling back to branch remote.
---------
Co-authored-by: Jakub Konka <kubkon@jakubkonka.com>
There is still room for improvement here as `anchor(s)_in_excerpt` is
generally a bad API here due to it reseeking the entire excerpt tree
from the start on every call which we don't really need. But this at
least cuts the seeks down by a factor of 4 for now.
Release Notes:
- Improved performance of bracket colorization in large multibuffers
Introduces new "mapping point cursors" for the different display map
layers allowing one to map multiple points in increasing order more
efficiently than using the one shot operations.
This is used in the `BlockMap::sync` for `header_and_footer_blocks`
which spends a significant time in sumtree traversal due to repeatedly
transforming points between the different layers. This effectively turns
the complexity of those operations from quadratic in the number of
excerpts to linear, as we only go through the respective sumtrees once
instead of restarting from the start over and over again.
Release Notes:
- Improved performance for editors of large multibuffers with many
different files
These are long running foreground tasks that tend to not have pending
await points, meaning once we start executing them they will never
reschedule themselves, starving the foreground thread.
Release Notes:
- Improved git project diff responsiveness
Replace single quotes with double quotes when referencing the askpass
script name in the helper command. The Windows command processor
(cmd.exe) requires double quotes for proper string handling, as single
quotes are treated as literal characters.
Error I get when trying to open remote project:
<img width="396" height="390" alt="image"
src="https://github.com/user-attachments/assets/1538ee10-8efc-4f80-a867-b367908091b6"
/>
```
Zed Nightly 0.216.0
c2281779af
0.216.0+nightly.1965.c2281779af56bd52c829ccd31aae4eb82b682ebc
```
Release Notes:
- N/A
Without this new flag, the Sweep API will actually produce a combination
of UTF-16 and char indices, leading to incorrect edit positions.
Release Notes:
- N/A
We restructured `struct Repository` a bit so that it now stores a shared
task of `enum RepositoryState`. This way, we can now re-use it outside
of the git job queue when spawning a git job a standalone bg task. An
example here would be `git-blame` that does not require any file locks
and is not susceptible to git job ordering.
As a result of this change, loading (and modifying) a file that contains
a huge git history will no longer block other git operations on the repo
such as staging/unstaging/committing.
Release Notes:
- Improved overall git experience when loading buffers with massive git
history where they would block other git jobs from running (such as
staging/unstaging/commiting). Now, git-blame will run separately from
the git job queue on the side and the buffer with blame hints when
finished thus unblocking other git operations.
Co-authored-by: Cole Miller <cole@zed.dev>
This reduces hangs on windows when we have many tasks queued up on the
main thread that yield a lot.
Release Notes:
- Reduced hangs on windows in some situations
Introducing this little popover here that's aimed at better
communicating what Zed's built-in edit prediction feature is and how
much people can get of it for free by purely just signing in.
<img width="600" height="1914" alt="Screenshot 2025-11-27 at 9 50@2x"
src="https://github.com/user-attachments/assets/a7013292-f662-4cae-9a6f-0e69a4a4fa1d"
/>
Release Notes:
- N/A
- **release_channel: Do not use prerelease channel for build id**
Prerelease channel specifiers always compare as less than to
non-prerelease, which led to 2 auto-update bugs fixed in
https://github.com/zed-industries/zed/pull/43595 and
https://github.com/zed-industries/zed/pull/43611.
We'll use a dot-delimited build specifiers in form:
release-channel.build_number.sha1 instead
- **auto_update: Do not display full build metadata in update
notification**
Release Notes:
- N/A
Sometimes we are unable to receive messages at all from an agent. This
puts on upper bound on the `initialize` call so we can at least give a
message to the user that something is wrong here.
30s might feel like too long, but I wanted to avoid some false positives
in case there was something an agent needed to do at startup. This will
still communicate to the user at some point that something is wrong,
rather than leave them waiting forever with no signal that something is
going wrong.
Release Notes:
- agent: Show an error message to the user if we are unable to
initialize an ACP agent in a reasonable amount of time.
Update the way that both
`search::buffer_search::BufferSearchBar.replace_next` and
`search::buffer_search::BufferSearchBar.replace_all` are registered as
listeners, so that we don't require the replacement editor to be focused
in order for these listeners to be active, only requiring the
replacement mode to be active in the buffer search bar.
This means that, even if the user is focused on the buffer editor, if
the "Replace Next Match" or "Replace All Matches" buttons are clicked,
the replacement will be performed.
Closes#42471
Release Notes:
- Fixed issue with buffer search bar where the replacement buttons
("Replace Next Match" & "Replace All Matches") wouldn't work if search
bar was not focused
Fixes ZED-3P9
We only clamped the end which for a completely wrong input could cause
us to construct a reversed range which will end up underflowing later
on.
Release Notes:
- N/A *or* Added/Fixed/Improved ...
Zeta evals now include a character n-gram metric adapted for multi-edit diffs (“delta chrF”). It works as follows:
1. Reconstruct the original, golden (expected), and actual texts from unified diffs.
- "original": the text before any edits
- "golden": the text after applying the expected edits
- "actual": the text after applying the actual edits
2. Compute n-gram count deltas between original→golden and original→actual.
- n-grams are computed as in chrF (max n=6, whitespace ignored).
3. Compare these deltas to assess how well the actual edits match the expected edits.
- As in standard chrF, classify n-grams as true positives, false positives, and false negatives, and report the F-beta score with beta=2.
Release Notes:
- N/A
Current approach is to colorize brackets based on their depth, which was
broken for markdown:
<img width="388" height="50" alt="image"
src="https://github.com/user-attachments/assets/bd8b6c2f-5a26-4d6b-a301-88675bf05920"
/>
Markdown grammar, for bracket queries
00e93bfa11/crates/languages/src/markdown/brackets.scm (L1-L8)
and markdown document `[LLM-powered features](./ai/overview.md), [bring
and configure your own API
keys](./ai/llm-providers.md#use-your-own-keys)`, matches first bracket
(offset 0) with two different ones:
* `[LLM-powered features]`
* `[LLM-powered features](./ai/overview.md), [bring and configure your
own API keys]`
which mix and add different color markers.
Now, in case multiple pairs exist for the same first bracket, Zed will
only colorize the shortest one:
<img width="373" height="33" alt="image"
src="https://github.com/user-attachments/assets/04b3f7af-8927-4a8b-8f52-de8b5bb063ac"
/>
Release Notes:
- Fixed bracket colorization mixing colors in markdown files
There are 3 factors:
1. The Preview channel endpoint does not propagate versions with build
identifier (which we oh-so-conveniently store in pre-release field of
semver).
2. Preview build, once fetched, sees it's version *with* build
identifier (as that's baked into the binary).
3. Auto update logic treats versions with pre-release version as less
than versions without pre-release version.
This in turn makes any Preview client see itself as versioned like
0.214.4-123-asdf1234455311, whereas the latest version on the endpoint
is 0.214.4. Thus, the endpoint version is always more recent than the
client version, causing an update loop.
The fix is to ignore build identifier when comparing versions of
non-nightly channels. This should still let us introduce changes to
auto-update behavior in minor releases in the future.
Closes#43584
Release Notes:
- (Preview only): Fixed an update loop with latest Preview update.
CLOSES #39042
This is a reopening of #34985+.
_Original descrioption_:
In Wayland, the client implement key repeat themself. In Zed this is
ultimately handled by the gpui crate by inserting a timer source into
the event loop which repeat itself if the key is still held down [1].
But it seems the processing of the repeated key event happen
synchronously inside the timer source handler, meaning the effective
rate become slightly lower (since the repeated timer is scheduled using
the 1/rate as delay).
I measured the event processing time on my laptop and it's typically
around 3ms, but sometimes spiking at 10ms. At low key repeat rates this
is probably not _very_ noticeable. I see the default in Zed is set to a
(measly) 16/s, but I assume most systems will use something closer to
25, which is a 40ms delay. So ~3ms is around 7.5% of the delay. At
higher rate the discrepancy become worse of course.
I can visible notice the spikes, and doing some crude stopwatch
measurements using gedit as a reference I can reproduce around 5-10%
slower rates in Zed.
IMO this is significant enough to warrant improving, especially since
some people can get quite used the repeat rate and might feel something
being "off" in Zed.
~~The suggested fix simply subtract the processing time from the next
delay timer.~~
[1] 32df726f3b/crates/gpui/src/platform/linux/wayland/client.rs (L1355)
Release Notes:
- Improved Wayland (Linux) key repeat rate precision
Adds a `trigger` field to the zeta1/zeta2 prediction requests so that we
can distinguish between editor, diagnostic, and zeta-cli requests.
Release Notes:
- N/A
Many prediction requests end up being rejected early without ever being
set as the current prediction. Before this change, those cases weren’t
reported as rejections because the `request_prediction_with_*` functions
simply returned `Ok(None)`.
With this update, whenever we get a successful response from the
provider, we will return at least the `id`, allowing it to be properly
reported. The request now also includes a “reject reason,” since the
different variants carry distinct implications for prediction quality.
All of these scenarios are now covered by tests. While adding them, I
also found and fixed a bug where some cancelled predictions were
incorrectly being set as the current one.
Release Notes:
- N/A
---------
Co-authored-by: MrSubidubi <dev@bahn.sh>
Update the `fs::RenameOptions` used by
`project::lsp_store::LocalLspStore.deserialize_workspace_edit` in order
to always set `create_parents` to `true`. Doing this ensures that we'll
always create the folders for the new file path provided by the language
server instead of failing to handle the request in case the parent
- Introduce `create_parents` field to `fs::RenameOptions`
- Update `fs::RealFs.rename` to ensure that the `create_parents` option
is respected
Closes#41820
Release Notes:
- Fixed a bug where using language server's file renaming actions could
fail if the parent directory of the new file did not exist
We were using `std::path::Path::strip_prefix` to determine which
repository an absolute path belongs to, which doesn't work when the
paths are Windows-style but the code is running on unix. Replace it with
a platform-agnostic implementation of `strip_prefix`.
Release Notes:
- Fixed git features not working when a Windows host collaborates with a
unix guest
This adds an intial workflow file that can be pulled in to create a bump
commit for an extension version in an extension repository.
Release Notes:
- N/A
Follow-up to https://github.com/zed-industries/zed/pull/39367
Release Notes:
- Fixed a small issue where a scrollbar would sometimes show in the
editor although the content fix exactly on screen.
While logically not really correct, its better than tearing down the
application until we figure out the root cause here
Release Notes:
- N/A *or* Added/Fixed/Improved ...
Closes#28667
Release Notes:
- Fixed git not preserving file mode when committing. Now if an input file is executable it will be preserved when committed with Zed.
---------
Signed-off-by: 11happy <soni5happy@gmail.com>
Signed-off-by: 11happy <bhuminjaysoni@gmail.com>
Co-authored-by: Jakub Konka <kubkon@jakubkonka.com>
I have git installed via [scoop](https://scoop.sh). The current
implementation finds `git.exe` in scoop's shims folder and then tries to
find `bash.exe` relative to it.
For example, `git.exe` (shim) is located at:
```
C:\Users\<username>\scoop\shims\git.exe
```
And the code tries to find `bash.exe` at:
```
C:\Users\<username>\scoop\shims\..\bin\bash.exe
```
which doesn't exist.
This PR changes the logic to first check if `bash.exe` is available in
PATH (using `which::which`), and only falls back to the git-relative
path if that fails.
The fix for this is emitting a wake-up event to tell the terminal to
recalculate its search highlights on resize.
Release Notes:
- terminal: Fix bug where search match highlights wouldn't update their
position when resizing the terminal.
Clang-Format uses uses a YAML config file format.
Use YAML language by default for `.clang-format` and `_clang-format`
filenames.
([source](https://clang.llvm.org/docs/ClangFormatStyleOptions.html))
Add `#yaml-language-server: $schema` to `.clang-format` example in C
language docs.
Release Notes:
- Added support for identifying. `.clang-format` files as YAML by
default
Most of the features for collab were previously listed in the section
that was written for private calls. Most of this PR is moving that
content over to the channel documentation and adapting it slightly.
Private calls have similar collaboration, so we can just point back to
the channels doc in that section and keep it pretty thin / DRY.
Release Notes:
- N/A
Fixes an issue where the terminal cursor wouldn't always be displayed in
the default `blink: "terminal_controlled"` mode unless the terminal
requested cursor blinking.
Release Notes:
- N/A
Closes#41723
This PR fixes an issue with accepting partial semver completions by
including `.` in the completion query. This makes the editor treat the
entire version string as the query, instead of breaking segment at last
`.` .
This PR also adds a test for sorting semver completions. The actual
sorting fix is handled in the `package-version-server` by having it
provide `sort_text`. More:
https://github.com/zed-industries/package-version-server/pull/10
<img width="600" alt="image"
src="https://github.com/user-attachments/assets/7657912f-c6da-4e05-956b-1c044918304f"
/>
Release Notes:
- Fixed an issue where accepting a completion for a semver version in
package.json would append the suggestion to the existing text instead of
replacing it.
- Improved the sorting of semver completions in package.json so the
latest versions appear at the top.
It is easy for us to get the two fields out of sync causing weird
problems, there is no reason to have both here so.
Release Notes:
- N/A *or* Added/Fixed/Improved ...
Co-authored by: Antonio Scandurra <antonio@zed.dev>
Follow up to #39021.
<img width="576" height="141" alt="image"
src="https://github.com/user-attachments/assets/c89885a4-e664-4614-9bb0-86442dff34ee"
/>
- Add migration to remove `source` tag because `ContextServerSettings`
is now untagged
- Fix typos in context server modal
- PR seems to have removed the `test_action_namespaces` test, which I
brought back in this PR
Release Notes:
- Fixed an issue where the `source` property of MCP settings would show
up as unrecognised
Overview
- Channels
- Private calls
---
Up next would be to
- [ ] Update any zed.dev links to point to items in this structure
- [ ] Update content in these docs (would prefer to do that in a
separate PR from this one)
Release Notes:
- N/A
This reverts #39643, effectively
For the record, @SomeoneToIgnore found it quite cumbersome to scroll
through logs just to see which tests have failed. I kinda see the
argument. At the same time, I wish nextest could do both: it could
aggregate logs of failed tests and then print out the summary.
Release Notes:
- N/A
Closes#43209Closes#38121
Starting on the first character.
Running `v e` before changes:
<img width="410" height="162" alt="image"
src="https://github.com/user-attachments/assets/ee13fa29-826c-45c0-9ea0-a598cc8e781a"
/>
Running `v e` after changes:
<img width="483" height="166" alt="image"
src="https://github.com/user-attachments/assets/24791a07-97df-47cd-9ef2-171522adb796"
/>
Change Notes:
- Added helix selection sanitation code that directly mirrors the code
in the Vim
[`visual_motion`](b6728c080c/crates/vim/src/visual.rs (L237))
method. I kept the comments from the Vim section that explains its
purpose.
- The above change converted the problem from fixing `v e` to fixing `v
w`. Since `w` is treated differently in Helix than in Vim (i.e. `w` in
Vim goes to the first character of a word and `w` in Helix goes to the
character before a word. Commented
[here](b6728c080c/crates/vim/src/helix.rs (L132))),
the code treats `w` in `HelixSelect` as a motion that differs from the
Vim motion in the same way that the function
[`helix_move_cursor`](b6728c080c/crates/vim/src/helix.rs (L353))
separates these behaviors.
- Added a regression test
Release Notes:
- Fixes bug where `Vim::NextWordEnd` in `HelixSelect` would not select
whole word.
The bug is easily verified by:
1. open any multi-buffer
2. place the cursor at the beginning of an excerpt
3. run the editor::ExpandExcerpts / editor: expand excerpts action
4. The excerpt is not expanded
Since the `buffer_ids_for_range` function basically did the same and had
even been changed the same way earlier I DRYed these functions as well.
Note: I'm a rust novice, so keep an extra eye on rust technicalities
when reviewing :)
---
Release Notes:
- Fix editor: expand excerpts failing when cursor is at excerpt start
---------
Co-authored-by: Lukas Wirth <me@lukaswirth.dev>
We've realized that a lot of the logic within an
`EditPredictionProvider` is not specific to a particular edit prediction
model / service. Rather, it is just the generic state management
required to perform edit predictions at all in Zed. We want to move to a
setup where there's one "built-in" edit prediction provider in Zed,
which can be pointed at different edit prediction models. The only logic
that is different for different models is how we construct the prompt,
send the request, and parse the output.
This PR also changes the behavior of the staff-only `zeta2` feature flag
so that in only gates your *ability* to use Zeta2, but you can still use
your local settings file to choose between different edit prediction
models/services: zeta1, zeta2, and sweep.
This PR also makes zeta1's outcome reporting and prediction-rating
features work with all prediction models, not just zeta1.
To do:
* [x] remove duplicated logic around sending cloud requests between
zeta1 and zeta2
* [x] port the outcome reporting logic from zeta to zeta2.
* [x] get the "rate completions" modal working with all EP models
* [x] display edit prediction diff
* [x] show edit history events
* [x] remove the original `zeta` crate.
Release Notes:
- N/A
---------
Co-authored-by: Agus Zubiaga <agus@zed.dev>
Co-authored-by: Ben Kunkle <ben@zed.dev>
9a119b18ee/extension.toml
provides 3 language servers for `php`, so `...` will always include all
3 if those are not excluded or included explicitly.
Change the configs and docs so, that only one php language server is
used.
Release Notes:
- N/A
This fixes running `zed <path>` inside nixos wsl instances. We're
copying the approach used elsewhere which is to try using `--exec`
first, and if that fails use an actual shell which should cover the
nixos case because it only puts binaries on your PATH inside the
`/etc/profile` script which is sourced on shell startup.
Release Notes:
- N/A
---------
Co-authored-by: John Tur <john-tur@outlook.com>
Update the `Vim.deactivate` method to ensure that the cursor shape is
reset to the one available in the user's settings, in the `cursor_shape`
setting, instead of simply defaulting to `CursorShape::Bar`.
In order to test this behavior, the `Editor.cursor_shape` method was
also introduced.
Release Notes:
- Fixed the cursor shape reset in vim mode deactivation, ensuring that
the user's `cursor_shape` setting is used
---------
Co-authored-by: dino <dinojoaocosta@gmail.com>
Adds support for Opus 4.5
- [x] BYOK
- [x] Amazon Bedrock
Release Notes:
- Added support for Opus 4.5
Co-authored-by: Richard Feldman <oss@rtfeldman.com>
Path canonicalization on windows will now favor keeping the drive letter
intact when canonicalizing paths. This helps some lsps with mapped
network drive compatibility.
Closes#41336
Release Notes:
- N/A
We’re reworking our triage process and in doing so, reworking our issue
templates is worth looking into. We have multiple issue templates, for
arbitrary categories, and not enough enforcement. The plan is to
consolidate the issue templates (maybe all into one) and drop the
others.
Release Notes:
- N/A
Closes#39448Closes#37866
This PR expands the env-clearing fix from #42587 to include the
SystemNodeRuntime, which covers Node.js installations managed by Mise.
When running under the system runtime, npm subcommands were still
launched with a cleared environment, preventing variables such as
MISE_DATA_DIR from reaching the shim or the mise binary itself. As a
result, Mise finds the npm binary in the default MISE_DATA_DIR,
consistent with the behavior described in
https://github.com/zed-industries/zed/issues/39448#issuecomment-3433644569.
This change ensures that environment variables are passed through for
npm subcommands when using the system Node runtime, restoring expected
behavior for Mise-managed Node installations. This also fixes cases
where envs are used by npm itself.
Release Notes:
- Enable environment passthrough for npm subcommands
We'll now add panels to the workspace as soon as they're ready rather
than waiting for all the rest to complete. We should strive to make all
panels fast, but given that their load tasks are fallible and do IO,
this approach seems more resilient.
Additionally, we'll now start loading the agent panel at the same time
as the rest.
Release Notes:
- workspace: Add panels as soon as they are ready
This bug seems to be caused by pushing an operator (i.e. `d`) followed
by a repeat (i.e. `.`) so the recording includes the push operator and
the repeat. When this is repeated (i.e. `.`) it causes an infinite loop.
This change fixes this bug by pushing a ClearOperator action if there is
an ongoing recording when repeat is called.
Release Notes:
- Fixed bug where pressing `d . .` in Vim mode would freeze the editor.
---------
Co-authored-by: dino <dinojoaocosta@gmail.com>
Closes#41550
Release Notes:
- Fixed `<g-l>` behavior in helix mode which will now correctly go to the last charactor of the line.
- Fixed not switching to helix normal mode when in default vim context and pressing escape.
---------
Co-authored-by: Jakub Konka <kubkon@jakubkonka.com>
1. Introduce a common `PromptFormatter` trait
2. Let models define their generation params.
3. Add support for the experimental 1120-seedcoder prompt format
Release Notes:
- N/A
This PR adds a button to close the panel when it is docked to the
bottom. Effectively, the button triggers the same `ToggleBottomDock`
action that clicking on the button that opened the panel triggers, but I
think having it there just makes it extra obvious how to close it, which
is beneficial.
As a bonus, also fixed the panel controls container height when it is
docked to the sides, so it perfectly aligns with the panel tabbar
height.
| Perfectly Aligned Header | Close Button |
|--------|--------|
| <img width="2620" height="2010" alt="Screenshot 2025-11-24 at 12 01
2@2x"
src="https://github.com/user-attachments/assets/08a50858-1b50-4ebd-af7a-c5dae32cf4f6"
/> | <img width="2620" height="2010" alt="Screenshot 2025-11-24 at 12
01@2x"
src="https://github.com/user-attachments/assets/17a6eee0-9934-4949-8741-fffd5b106e95"
/> |
Release Notes:
- N/A
Closes https://github.com/zed-industries/zed/issues/42753
Consider the following flow: you submit prompt A. Prompt A generates
some edits. You don't click on either "reject" or "keep"; they stay in a
pending state. You then submit prompt B, but before the agent outputs
any response, you click to edit prompt B, thus submitting a
regeneration.
Before this PR, the above flow would make the edits originated from
prompt A to be auto-rejected. This feels very incorrect and can surprise
users when they see that the edits that were pending got rejected. It
feels more correct to only auto-reject changes if you're regenerating
the prompt that directly generated those edits in the first place. Then,
it also feels more correct to assume that if there was a follow-up
prompt after some edits were made, those edits were passively
"accepted".
So, this is what this PR is doing. Consider the following flow to get a
picture of the behavior change:
- You submit prompt A.
- Prompt A generates some edits.
- You don't click on either "reject" or "keep"; they're pending.
- You then submit prompt B, but before the agents outputs anything, you
click to edit prompt B, submitting a regeneration.
- Now, edits from prompt A will be auto-kept.
Release Notes:
- agent: Improved the "reject"/"keep" behavior when regenerating older
prompts by auto-keeping pending edits that don't originate from the
prompt to-be-regenerated.
The `SumTree::append` method is slow when appending large trees to small
trees. The reason is this code here:
f57f4cd360/crates/sum_tree/src/sum_tree.rs (L628-L630)
`append` is called recursively until `self` and `other` have the same
height, effectively making this code `O(log^2 n)` in the number of
leaves of `other` tree in the worst case.
There are no algorithmic reasons why appending large trees must be this
much slower.
This PR proves it by providing implementation of `append` that works in
logarithmic time regardless if `self` is smaller or larger than `other`.
The helper method `append_large` has the symmetric logic to
`push_tree_recursive` but moves the (unlikely) case of merging
underflowing node in a separate helper function to reduce stack usage. I
am a bit unsure about some implementation choices made in
`push_tree_recursive` and would like to discuss some of these later, but
at the moment I didn't change anything there and tried to follow the
same logic in `append_large`.
We might also consider adding `push_front`/`prepend` methods to
`SumTree`.
I did not find a good benchmark that covers this case so I added a new
one to rope benchmarks.
<details>
<summary>cargo bench (compared to current main)</summary>
```
Running benches\rope_benchmark.rs (D:\zed\target\release\deps\rope_benchmark-59c669d2895cd2c4.exe)
Gnuplot not found, using plotters backend
push/4096 time: [195.67 µs 195.75 µs 195.86 µs]
thrpt: [19.944 MiB/s 19.955 MiB/s 19.964 MiB/s]
change:
time: [+0.2162% +0.3040% +0.4057%] (p = 0.00 < 0.05)
thrpt: [-0.4040% -0.3030% -0.2157%]
Change within noise threshold.
Found 14 outliers among 100 measurements (14.00%)
2 (2.00%) low mild
6 (6.00%) high mild
6 (6.00%) high severe
Benchmarking push/65536: Warming up for 3.0000 s
Warning: Unable to complete 100 samples in 5.0s. You may wish to increase target time to 7.8s, enable flat sampling, or reduce sample count to 50.
push/65536 time: [1.4431 ms 1.4485 ms 1.4546 ms]
thrpt: [42.966 MiB/s 43.147 MiB/s 43.310 MiB/s]
change:
time: [-3.2257% -1.2013% +0.6431%] (p = 0.27 > 0.05)
thrpt: [-0.6390% +1.2159% +3.3332%]
No change in performance detected.
Found 11 outliers among 100 measurements (11.00%)
1 (1.00%) low mild
5 (5.00%) high mild
5 (5.00%) high severe
append/4096 time: [15.107 µs 15.128 µs 15.149 µs]
thrpt: [257.86 MiB/s 258.22 MiB/s 258.58 MiB/s]
change:
time: [+0.9650% +1.5256% +1.9057%] (p = 0.00 < 0.05)
thrpt: [-1.8701% -1.5026% -0.9557%]
Change within noise threshold.
Found 2 outliers among 100 measurements (2.00%)
1 (1.00%) low mild
1 (1.00%) high severe
append/65536 time: [1.2870 µs 1.4496 µs 1.6484 µs]
thrpt: [37.028 GiB/s 42.106 GiB/s 47.425 GiB/s]
change:
time: [-28.699% -16.073% -0.3133%] (p = 0.04 < 0.05)
thrpt: [+0.3142% +19.151% +40.250%]
Change within noise threshold.
Found 17 outliers among 100 measurements (17.00%)
1 (1.00%) high mild
16 (16.00%) high severe
slice/4096 time: [30.580 µs 30.611 µs 30.639 µs]
thrpt: [127.49 MiB/s 127.61 MiB/s 127.74 MiB/s]
change:
time: [-2.2958% -0.9674% -0.1835%] (p = 0.08 > 0.05)
thrpt: [+0.1838% +0.9769% +2.3498%]
No change in performance detected.
slice/65536 time: [614.86 µs 795.04 µs 1.0293 ms]
thrpt: [60.723 MiB/s 78.613 MiB/s 101.65 MiB/s]
change:
time: [-12.714% +7.2092% +30.676%] (p = 0.52 > 0.05)
thrpt: [-23.475% -6.7244% +14.566%]
No change in performance detected.
Found 14 outliers among 100 measurements (14.00%)
14 (14.00%) high severe
bytes_in_range/4096 time: [3.3298 µs 3.3416 µs 3.3563 µs]
thrpt: [1.1366 GiB/s 1.1416 GiB/s 1.1456 GiB/s]
change:
time: [+2.0652% +3.0667% +4.3765%] (p = 0.00 < 0.05)
thrpt: [-4.1930% -2.9754% -2.0234%]
Performance has regressed.
Found 2 outliers among 100 measurements (2.00%)
2 (2.00%) high severe
bytes_in_range/65536 time: [80.640 µs 80.825 µs 81.024 µs]
thrpt: [771.38 MiB/s 773.28 MiB/s 775.05 MiB/s]
change:
time: [-0.6566% +1.0994% +2.9691%] (p = 0.27 > 0.05)
thrpt: [-2.8835% -1.0875% +0.6609%]
No change in performance detected.
Found 10 outliers among 100 measurements (10.00%)
2 (2.00%) high mild
8 (8.00%) high severe
chars/4096 time: [763.17 ns 763.68 ns 764.36 ns]
thrpt: [4.9907 GiB/s 4.9952 GiB/s 4.9985 GiB/s]
change:
time: [-2.1138% -0.7973% +0.1096%] (p = 0.18 > 0.05)
thrpt: [-0.1095% +0.8037% +2.1595%]
No change in performance detected.
Found 10 outliers among 100 measurements (10.00%)
1 (1.00%) low severe
6 (6.00%) low mild
3 (3.00%) high severe
chars/65536 time: [12.479 µs 12.503 µs 12.529 µs]
thrpt: [4.8714 GiB/s 4.8817 GiB/s 4.8910 GiB/s]
change:
time: [-2.4451% -1.0638% +0.6633%] (p = 0.16 > 0.05)
thrpt: [-0.6589% +1.0753% +2.5063%]
No change in performance detected.
Found 11 outliers among 100 measurements (11.00%)
4 (4.00%) high mild
7 (7.00%) high severe
clip_point/4096 time: [63.148 µs 63.182 µs 63.229 µs]
thrpt: [61.779 MiB/s 61.825 MiB/s 61.859 MiB/s]
change:
time: [+1.0107% +2.1329% +4.2849%] (p = 0.02 < 0.05)
thrpt: [-4.1088% -2.0883% -1.0006%]
Performance has regressed.
Found 5 outliers among 100 measurements (5.00%)
4 (4.00%) high mild
1 (1.00%) high severe
Benchmarking clip_point/65536: Warming up for 3.0000 s
Warning: Unable to complete 100 samples in 5.0s. You may wish to increase target time to 7.8s, enable flat sampling, or reduce sample count to 50.
clip_point/65536 time: [1.2578 ms 1.2593 ms 1.2608 ms]
thrpt: [49.573 MiB/s 49.631 MiB/s 49.690 MiB/s]
change:
time: [+0.4881% +0.8942% +1.3488%] (p = 0.00 < 0.05)
thrpt: [-1.3308% -0.8863% -0.4857%]
Change within noise threshold.
Found 15 outliers among 100 measurements (15.00%)
1 (1.00%) high mild
14 (14.00%) high severe
point_to_offset/4096 time: [16.211 µs 16.235 µs 16.257 µs]
thrpt: [240.28 MiB/s 240.61 MiB/s 240.97 MiB/s]
change:
time: [-1.4913% +0.1685% +2.2662%] (p = 0.89 > 0.05)
thrpt: [-2.2159% -0.1682% +1.5139%]
No change in performance detected.
Found 2 outliers among 100 measurements (2.00%)
1 (1.00%) high mild
1 (1.00%) high severe
point_to_offset/65536 time: [360.06 µs 360.58 µs 361.16 µs]
thrpt: [173.05 MiB/s 173.33 MiB/s 173.58 MiB/s]
change:
time: [+0.0939% +0.8792% +1.8751%] (p = 0.06 > 0.05)
thrpt: [-1.8406% -0.8715% -0.0938%]
No change in performance detected.
Found 10 outliers among 100 measurements (10.00%)
3 (3.00%) high mild
7 (7.00%) high severe
cursor/4096 time: [19.266 µs 19.282 µs 19.302 µs]
thrpt: [202.38 MiB/s 202.58 MiB/s 202.75 MiB/s]
change:
time: [+1.2457% +2.2477% +2.8702%] (p = 0.00 < 0.05)
thrpt: [-2.7901% -2.1983% -1.2304%]
Performance has regressed.
Found 4 outliers among 100 measurements (4.00%)
2 (2.00%) high mild
2 (2.00%) high severe
cursor/65536 time: [467.63 µs 468.36 µs 469.14 µs]
thrpt: [133.22 MiB/s 133.44 MiB/s 133.65 MiB/s]
change:
time: [-0.2019% +1.3419% +2.8915%] (p = 0.10 > 0.05)
thrpt: [-2.8103% -1.3241% +0.2023%]
No change in performance detected.
Found 12 outliers among 100 measurements (12.00%)
3 (3.00%) high mild
9 (9.00%) high severe
append many/small to large
time: [37.419 ms 37.656 ms 37.929 ms]
thrpt: [321.84 MiB/s 324.17 MiB/s 326.22 MiB/s]
change:
time: [+0.8113% +1.7361% +2.6538%] (p = 0.00 < 0.05)
thrpt: [-2.5852% -1.7065% -0.8047%]
Change within noise threshold.
Found 9 outliers among 100 measurements (9.00%)
9 (9.00%) high severe
append many/large to small
time: [51.289 ms 51.437 ms 51.614 ms]
thrpt: [236.50 MiB/s 237.32 MiB/s 238.00 MiB/s]
change:
time: [-87.518% -87.479% -87.438%] (p = 0.00 < 0.05)
thrpt: [+696.08% +698.66% +701.13%]
Performance has improved.
Found 13 outliers among 100 measurements (13.00%)
4 (4.00%) high mild
9 (9.00%) high severe
```
</details>
Release Notes:
- sum_tree: Make SumTree::append run in logarithmic time
Closes#33903
Release Notes:
- Ensured Zed reuses `GITHUB_TOKEN` env variable when querying GitHub
---
Before fixing:
- The `crates-lsp` extension request captured:
```
curl 'https://api.github.com/repos/MathiasPius/crates-lsp/releases' \
-H 'accept: */*' \
-H 'user-agent: Zed/0.212.3 (macos; aarch64)' \
-H 'host: api.github.com' \
```
- `crates-lsp` extension error:
```
Language server crates-lsp:
from extension "Crates LSP" version 0.2.0: status error 403, response: "{\"message\":\"API rate limit exceeded for x.x.x.x. (But here's the good news: Authenticated requests get a higher rate limit. Check out the documentation for more details.)\",\"documentation_url\":\"https://docs.github.com/rest/overview/resources-in-the-rest-api#rate-limiting\"}\n"
```
After fixing:
```
export GITHUB_TOKEN=$(gh auth token)
cargo run
```
- The `crates-lsp` extension request captured:
```
curl 'https://api.github.com/repos/MathiasPius/crates-lsp/releases' \
-H 'authorization: Bearer gho_Nt*****************2KXLw2' \
-H 'accept: */*' \
-H 'user-agent: Zed/0.214.0 (macos; aarch64)' \
-H 'host: api.github.com' \
```
The API rate limitation is resolved.
---
This isn't a perfect solution, but it enables users to avoid the noise.
Closes#38433
Document how to register self-hosted GitHub/GitLab/Bitbucket instances
via git_hosting_providers setting so permalinks and issue links resolve.
Release Notes:
- Added documentation on how to register self-hosted
GitHub/GitLab/Bitbucket instances via the `git_hosting_providers`
setting. This ensures permalinks and issue links can be resolved for
these instances.
### Description
The `installing-extensions.md` guide was missing the directory path for
the Windows platform. It currently only lists the paths for macOS and
Linux. This PR adds the correct path for Windows users
(`%LOCALAPPDATA%\zed\extensions`).
Release Notes:
- N/A
---------
Co-authored-by: Kirill Bulatov <mail4score@gmail.com>
Changes are made to `parse_path_with_position`:
we try to get the canonical, existing parts of
a path, then append the non-existing parts.
Closes#4441
Release Notes:
- Added the possibility to open a non-existing path using `zed` CLI
```
zed path/to/non/existing/file.txt
```
Co-authored-by: Syed Sadiq Ali <sadiqonemail@gmail.com>
This PR makes the thread markdown editable. This refers to the "open
thread as markdown" feature, where you previously could only read. One
benefit of this move is that it makes a bit more obvious that you can
`cmd-s` to save the markdown, allowing you to store the content of a
given thread. You could already do this before, but due to it being
editable now, you see the tab with a dirty indicator, which communicates
that better.
Release Notes:
- agent: Made the thread markdown editable.
This PR improves the edit prediction page particularly by adding
information about pricing and plans, which wasn't at all mentioned here
before, _and_ by including a section with a keybinding example
demonstrating how to always use just `tab` to always accept edit
predictions.
Release Notes:
- N/A
Fixes a panic that was introduced in #42633. Repro steps:
1. Open the inline assistant and mention a file in the prompt
2. Run the inline assistant
3. Remove the mention and insert a different one
4. 💥
This would happen because the mention set still had a reference to the
old editor, because we create a new one in `PromptEditor::unlink`.
Also removes the unused
`crates/agent_ui/src/context_picker/completion_provider.rs` file, which
was not removed by mistake in the previous PR.
Release Notes:
- N/A
This PR adds back the footer with the "Configure" button in the model
selector but only when the seeing it from the Zed agent (or inline
assistant/text threads). I had removed it a while back because seeing
the "Configure" button, which takes you to the agent panel settings
view, when clicking from an external agent didn't make much sense, given
there's nothing model-wise you can configure from Zed (at least yet) for
an external agent.
This also makes the button in the footer a bit nicer by making it full
screen and displaying a keybinding, so that you can easily do the whole
"trigger model selector → go to settings view" all with the keyboard.
<img width="400" height="870" alt="Screenshot 2025-11-21 at 10 38@2x"
src="https://github.com/user-attachments/assets/c14f2acf-b793-4bc1-ac53-8a8a53b219e6"
/>
Release Notes:
- N/A
- In the launch tab of the new session mode, I've switched it to use the
`InputField` component instead given that had all that we needed
already. Allows for removing a good chunk of editor-related code
- Also in the launch tab, added support for keyboard navigation between
all of the elements there (dropdown, inputs, and switch component)
- Added some simple an empty state treatment for the breakpoint column
when there are none set
https://github.com/user-attachments/assets/a441aa8a-360b-4e38-839f-786315a8a235
Release Notes:
- debugger: Made the input elements within the launch tab in the new
session modal keyboard navigable˙.
This PR finally removes the `CheckboxWithLabel` component, which is not
fully needed given the `Checkbox` can take a `label` method. Then, took
advantage of the opportunity to add more methods with regards to label
customization (position, size, and color) in both the `Checkbox` and
`Switch` components.
Release Notes:
- N/A
We now run git pre-commit hooks before we commit. This ensures we don't
run into timeout issues with askpass delegate and report invalid error
to the user.
Closes#43157
Release Notes:
- Fixed long running pre-commit hooks causing committing from Zed to
fail.
Co-authored-by: Cole Miller <cole@zed.dev>
Previously, this was controllable via the undocumented
ZED_WINDOW_DECORATIONS environment variable (added in #13866). Using an
environment variable for this is inconvenient because it requires users
to set that environment variable somehow before starting Zed, such as in
the .desktop file or persistently in their shell. Controlling this via a
Zed setting is more convenient.
This does not modify the design of the titlebar in any way. It only
moves the existing option from an environment variable to a Zed setting.
Fixes#14165
Client-side decorations (default):
<img width="3840" height="2160" alt="image"
src="https://github.com/user-attachments/assets/525feb92-2f60-47d3-b0ca-47c98770fa8c"
/>
Server-side decorations in KDE Plasma:
<img width="3840" height="2160" alt="image"
src="https://github.com/user-attachments/assets/7379c7c8-e5e3-47ba-a3ea-4191fec9434d"
/>
Release Notes:
- Changed option for Wayland server-side decorations from an environment
variable to settings.json field
---------
Co-authored-by: Conrad Irwin <conrad.irwin@gmail.com>
It is optional for Wayland servers to support server-side decorations.
In particular, GNOME chooses to not implement SSD
(https://gitlab.gnome.org/GNOME/mutter/-/issues/217). So, even if the
application requests SSD, it must draw client-side decorations unless
the application receives a response from the server confirming the
request for SSD.
Before, when the user requested SSD for Zed, but the Wayland server did
not support it, there were no server-side decorations (window titlebar)
drawn, but Zed did not draw the window minimize, maximize, and close
buttons either. This fixes Zed so it always draws the window control
buttons if the Wayland server does not support SSD.
Before on GNOME Wayland with SSD requested:
<img width="3840" height="2160" alt="image"
src="https://github.com/user-attachments/assets/68a6d853-623d-401f-8e7f-21d4dea00543"
/>
After on GNOME Wayland with SSD requested:
<img width="3840" height="2160" alt="image"
src="https://github.com/user-attachments/assets/b258ae8b-fe0e-4ba2-a541-ef6f2c38f788"
/>
Release Notes:
- Fixed window control buttons not showing in GNOME Wayland when SSD
requested
Closes:
- #12338
- #40202
1. Adds two new settings which allow customizing the set of regexes used
to identify path hyperlinks in terminal
1. Fixes path hyperlinks for paths containing unicode emoji and
punctuation, for example, `mojo.🔥`
1. Fixes path hyperlinks for Windows verbatim paths, for example,
`\\?\C:\Over\here.rs`.
1. Improves path hyperlink performance, especially for terminals with a
lot of content
1. Replaces existing custom hard-coded default path hyperlink parsing
logic with a set of customizable default regexes
## New settings
(from default.json)
### terminal.path_hyperlink_regexes
Regexes used to identify paths for hyperlink navigation. Supports
optional named capture
groups `path`, `line`, `column`, and `link`. If none of these are
present, the entire match
is the hyperlink target. If `path` is present, it is the hyperlink
target, along with `line`
and `column` if present. `link` may be used to customize what text in
terminal is part of the
hyperlink. If `link` is not present, the text of the entire match is
used. If `line` and
`column` are not present, the default built-in line and column suffix
processing is used
which parses `line:column` and `(line,column)` variants. The default
value handles Python
diagnostics and common path, line, column syntaxes. This can be extended
or replaced to
handle specific scenarios. For example, to enable support for
hyperlinking paths which
contain spaces in rust output,
```
[
"\\s+(-->|:::|at) (?<link>(?<path>.+?))(:$|$)",
"\\s+(Compiling|Checking|Documenting) [^(]+\\((?<link>(?<path>.+))\\)"
],
```
could be used. Processing stops at the first regex with a match, even if
no link is
produced which is the case when the cursor is not over the hyperlinked
text. For best
performance it is recommended to order regexes from most common to least
common. For
readability and documentation, each regex may be an array of strings
which are collected
into one multi-line regex string for use in terminal path hyperlink
detection.
### terminal.path_hyperlink_timeout_ms
Timeout for hover and Cmd-click path hyperlink discovery in
milliseconds. Specifying a
timeout of `0` will disable path hyperlinking in terminal.
## Performance
This PR fixes terminal to only search the hovered line for hyperlinks
and adds a benchmark. Before this fix, hyperlink detection grows
linearly with terminal content, with this fix it is proportional only to
the hovered line. The gains come from replacing
`visible_regex_match_iter`, which searched all visible lines, with code
that only searches the line hovered on (including if the line is
wrapped).
Local benchmark timings (terminal with 500 lines of content):
||main|this PR|Δ|
|-|-|-:|-|
| cargo_hyperlink_benchmark | 1.4 ms | 13 µs | -99.0% |
| rust_hyperlink_benchmark | 1.2 ms | 11 µs | -99.1% |
| ls_hyperlink_benchmark | 1.3 ms | 7 µs | -99.5% |
Release Notes:
- terminal: New settings to allow customizing the set of regexes used to
identify path hyperlinks in terminal
- terminal: Fixed terminal path hyperlinks for paths containing unicode
punctuation and emoji, e.g. mojo.🔥
- terminal: Fixed path hyperlinks for Windows verbatim paths, for
example, `\\?\C:\Over\here.rs`
- terminal: Improved terminal hyperlink performance, especially for
terminals with a lot of content visible
When no predictions are available for the current buffer, we will now
attempt to predict at the closest diagnostic from the cursor location
that wasn't included in the last prediction request. This enables a
commonly desired kind of far-away jump without requiring explicit model
support.
Release Notes:
- N/A
Reverts zed-industries/zed#36848
Turns out this broke copying a screenshot from apps like CleanShot X and
then pasting it over. We should land this again after taking a look at
those cases. Pasting screenshots from the native macOS screenshot
functionality works though.
cc @seantimm
Release Notes:
- Fixed issue where copying a screenshot from apps like CleanShot X into
Agent Panel didn't work as expected.
Also tidies up error notifications so that in the case of syntax errors
we don't see noise about the migration failing as well.
Release Notes:
- Invalid values in settings files will no longer prevent the rest of
the file from being parsed.
We were just missing adding keybindings for these.
Release Notes:
- onboarding: The onboarding pages can now be zoomed in/out with the
same keybindings you'd use to zoom in/out a regular buffer.
While zed itself is not a heavy user of rayon, wasmtime is, especially
for compilation. This change is similar to the rayon default but we
halve the number of threads still so we don't spawn too many threads
overall.
Release Notes:
- N/A *or* Added/Fixed/Improved ...
Closes https://github.com/zed-industries/zed/issues/14639
## Release Notes:
Various improvements to the Jetbrains keymap. Added various missing
keyboard shortcuts that I use on a daily basis in Jetbrains, and changed
a few which were present in the keymap but mapped to the wrong behavior.
### Added:
- Added various missing keybindings for Jetbrains keymap
- `ctrl-n` → `project_symbols::Toggle`
- `ctrl-alt-n` → `file_finder::Toggle` (open project files)
- `ctrl-~` → `git::Branch`
- `ctrl-\` → `assistant::InlineAssist`
- `ctrl-space` → `editor::ShowCompletions`
- `ctrl-q` → `editor::Hover`
- `ctrl-p` → `editor::ShowSignatureHelp`
- `ctrl-f5` → `task::Rerun`
- `shift-f9` → `debugger::Start`
- `shift-f10` → `task::Spawn`
- Added macOS equivalents for all of the above, however I only have a
Linux machine so I have not tested the mac bindings. The binding are
generally the same except `ctrl → cmd` with few exceptions.
- `cmd-j` → `editor::Hover`
### Fixed:
- Several incorrectly mapped keybindings for the Jetbrains keymap
- `ctrl-alt-s` → `editor::OpenSettings` (was `editor::OpenSettingsFile`)
- `ctrl-alt-b` → `editor::GoToImplementation` (was
`editor::GoToDefinitionSplit`)
- `alt-left` → `pane::ActivatePreviousItem`
- `alt-right` → `pane::ActivateNextItem`
- `ctrl-k` now opens the Git panel. I believe this was commented out
because of a bug where focus is not given to the commit message text
box, but imo the current behavior of not doing anything at all feels
more confusing/frustrating to a Jetbrains user (projecting a little
here, happy to revert).
Closes#42727
Unfortunately we can only support IPv4 addresses right now because
`TcpArguments` only supports an IPv4 address. I'm not sure how difficult
it would be to lift this limitation.
Release Notes:
- Fixed `connect.host` setting being ignored by debugpy
Co-authored-by: Cole Miller <cole@zed.dev>
Closes https://github.com/zed-industries/zed/issues/42360
If updating a language server takes longer than 10 seconds, we now fall
back to launching the currently installed version (if exists) and
continue downloading the update in the background.
Release Notes:
- Improved language server updates for slow connection, now Zed launches
existing server if the update is taking too long.
---------
Co-authored-by: Piotr Osiewicz <24362066+osiewicz@users.noreply.github.com>
Problem: Some macOS environments report no devices via
MTLCopyAllDevices, causing startup failure with “unable to access a
compatible graphics device,” especially on Apple Silicon.
Change: Prefer MTLCreateSystemDefaultDevice
(metal::Device::system_default()) first. If None, enumerate devices and
select a non‑removable, low‑power device by preference.
Why this works: On Apple Silicon the system default is the unified GPU;
on Intel, the fallback keeps a stable policy and avoids accidentally
picking removable/high‑power devices.
Impact: Fixes startup on affected ASi systems; improves selection
consistency on Intel multi‑GPU. Behavior unchanged where
system_default() succeeds.
Risk: Low. Aligns with Apple’s recommended selection path. Still fails
early with a clearer message if no Metal devices exist.
Closes#37689.
Release Notes:
- Fixed: Startup failure on some Apple Silicon machines when Metal
device enumeration returned no devices by falling back to the system
default device.
---------
Co-authored-by: 张小白 <364772080@qq.com>
Co-authored-by: Kate <work@localcc.cc>
Part One for Resolving #10910
### Summary
Typing prefix (partial keybinding) will behave like Vim. No timeout
until you either finish the sequence or hit Escape, while ambiguous
sequences still auto-resolve after 1s.
### Description
This follow-up tweaks the which-key system first part groundwork so our
timeout behavior matches Vim’s expectations. Then we can implement the
UI part in the next step (reference latest comments in
https://github.com/zed-industries/zed/pull/34798)
- `DispatchResult` now reports when the current keystrokes are already a
complete binding in the active context stack (`pending_has_binding`). We
only start the 1s flush timer in that case. Pure prefixes or sequences
that only match in other contexts—stay pending indefinitely, so
leader-style combos like `space f g` no longer evaporate after a second.
- `Window::dispatch_key_event` cancels any prior timer before scheduling
a new one and only spawns the background flush task when
`pending_has_binding` is true. If there’s no matching binding, we keep
the pending keystrokes and rely on an explicit Escape or more typing to
resolve them.
Release Notes:
- Fixed multi-stroke keybindings so only ambiguous prefixes auto-trigger
after 1 s; unmatched prefixes now stay pending until canceled, matching
Vim-style leader behavior.
This PR fixes the casing of the operating system names in the
language-specific sections of `default.json`.
This files serves as documentation for users (since it can be viewed
through `zed: open default settings`), so we should make sure it is
tidy.
Release Notes:
- N/A
This PR simplifies error and event handling by removing the
`Ok(LanguageModelCompletionEvent::Status(CompletionRequestStatus::Failed)))`
state from the stream returned by `LanguageModel::stream_completion()`,
by changing it into an `Err(LanguageModelCompletionError)`. This was
done by collapsing the valid `CompletionRequestStatus` values into
`LanguageModelCompletionEvent`.
Release Notes:
- N/A
---------
Co-authored-by: Michael Benfield <mbenfield@zed.dev>
This mostly affects the collab and outline panels for now. It has always
been a bit weird that the search field was at the bottom of the panel,
even more so because in both cases, you can _arrow down_ to start
navigating the list with your keyboard. So, with the search at the
bottom, you'd arrow down and get to the top of the list, which was very
strange. Now, with it at the top, it not only looks better but it is
also more generally consistent with other surfaces in the app, like
pickers, the settings UI, rules library, etc. Most search fields are
always at the top.
<img width="800" height="1830" alt="image"
src="https://github.com/user-attachments/assets/3e2c3b8f-5907-4d83-8804-b3fc77342103"
/>
Release Notes:
- N/A
The WM_DPICHANGED suggested RECT is calculated for non-maximized
windows. When a maximized window's DPI changes, we now query the
monitor's work area directly to ensure the window correctly fills the
entire screen.
For non-maximized windows, the original behavior using the
system-suggested RECT is preserved.
Release Notes:
- windows: Fixed maximized window size when DPI scale changes
Signed-off-by: Xiaobo Liu <cppcoffee@gmail.com>
These appear in a lot of stacktraces (especially on windows) despite
them being plain forwarding calls.
Also removes some intermediate calls within gpui that will only turn
into more unnecessary compiler work.
Release Notes:
- N/A *or* Added/Fixed/Improved ...
Deals with https://github.com/zed-industries/zed/issues/5259
Highlights brackets with different colors based on their depth.
Uses existing tree-sitter queries from brackets.scm to find brackets,
uses theme's accents to color them.
https://github.com/user-attachments/assets/cc5f3aba-22fa-446d-9af7-ba6e772029da
1. Adds `colorize_brackets` language setting that allows, per language
or globally for all languages, to configure whether Zed should color the
brackets for a particular language.
Disabled for all languages by default.
2. Any given language can opt-out a certain bracket pair by amending the
brackets.scm like `("\"" @open "\"" @close) ` -> `(("\"" @open "\""
@close) (#set! rainbow.exclude))`
3. Brackets are using colors from theme accents, which can be overridden
as
```jsonc
"theme_overrides": {
"One Dark": {
"accents": ["#ff69b4", "#7fff00", "#ff1493", "#00ffff", "#ff8c00", "#9400d3"]
}
},
```
Release Notes:
- Added bracket colorization (rainbow brackets) support. Use
`colorize_brackets` language setting to enable.
---------
Co-authored-by: MrSubidubi <dev@bahn.sh>
Co-authored-by: Lukas Wirth <lukas@zed.dev>
Co-authored-by: MrSubidubi <finn@zed.dev>
Co-authored-by: Lukas Wirth <me@lukaswirth.dev>
Co-authored-by: Smit Barmase <heysmitbarmase@gmail.com>
Before we were simply not rendering anything which could lead to some
very surprising situations when joining channels ...
Now it will look like so
<img width="147" height="50" alt="image"
src="https://github.com/user-attachments/assets/13069de8-3dc0-45e1-b562-3fe81507dd87"
/>
Release Notes:
- Improved rendering of avatars that failed to load by rendering a
fallback icon
Closes#39088
Release Notes:
- Fixed AI assistant edits being scrambled when file was modified while
it was open
--
Co-authored-by: Conrad Irwin <conrad.irwin@gmail.com>
This allows you to specify default_model and default_mode for ACP
extensions, e.g.
```
"auggie": {
"default_model": "gpt-5",
"default_mode": "default",
"type": "extension"
},
```
Release Notes:
- Added support for specifying settings for ACP extensions
(`default_mode`, `default_model`)
While investigating a bug report that, in Helix mode, pressing the
`escape` key would only hide the signature help popup and not the
completions menu, when `auto_signature_help` was enabled, it was noted
that the `editor::Editor.dismiss_menus_and_popups` method was not
dismissing all possible menus and popups and was, instead, stopping as
soon as a single menu or popup was dismissed.
From the name of the method it appears that we actually want to dismiss
all so this commit updates it as such, ensuring that the bug reported is
also fixed.
Closes#42499
Release Notes:
- Fixed issue with popups and menus not being dismissed while using
`auto_signature_help` in Helix Mode
We're not using it anywhere anymore, so I think we can clean it up now.
This was a somewhat specific component we did for the sake of
Onboarding, but it ended up being removed.
Release Notes:
- N/A
Closes#33286
This PR adds support for Zed's `$ZED_PICK_PID` command in debug
configurations, which allows users to select a process to attach to at
debug time. When this variable is present in a debug configuration, Zed
automatically opens a process picker modal.
Follow up for this will be integrating this variable in the task system
instead of just the debug configuration system.
Release Notes:
- Added `$ZED_PICK_PID` variable for debug configurations, allowing
users to select which process to attach the debugger to at runtime
---------
Co-authored-by: Remco Smits <djsmits12@gmail.com>
This PR compresses diff capped at 20000 bytes by:
- Truncation of all lines to 256 chars
- Iteratively removing last hunks from each file until size <= 20000
bytes.
Closes#34486
Release Notes:
- Improved: Compress large diffs for commit message generation (thanks
@11happy)
---------
Signed-off-by: 11happy <soni5happy@gmail.com>
Co-authored-by: Oleksiy Syvokon <oleksiy@zed.dev>
Editor is a choke point in our compilation graph while also being a very
common crate that is being edited. So reducing things that depend on it
will generally improve compilation times for us.
Release Notes:
- N/A *or* Added/Fixed/Improved ...
Closes _unknown_
<img width="1212" height="463" alt="image"
src="https://github.com/user-attachments/assets/ec00fcf0-7eb9-4291-b1e2-66e014dc30ac"
/>
This PR places the file_name before the file_path so that when the panel
is slim it is still usable, mirrors the behaviour of the file picker
(cmd+P)
Release Notes:
- Improved readability of files in the git changes panel
This PR builds on top of the `default_mode` feature where it was
possible to set an external agent mode as the default if you held a
modifier while clicking on the desired option. Now, if you want to have,
for example, Haiku as your default Claude Code model, you can do that.
This feature adds parity between external agents and Zed's built-in one,
which already supported this feature for a little while.
Note: This still doesn't work with external agents installed from
extensions. At the moment, this is limited to Claude Code, Codex, and
Gemini—the ones we include out of the box.
Release Notes:
- agent: Added the ability to set a model as the default for a given
built-in external agent (Claude Code, Codex CLI, or Gemini CLI).
This PR removes basically all of the component stories, with the
exception of the context menu, which is a bit more intricate to set up.
All of the component that won't have a story after this PR will have an
entry in the Component Preview, which serves basically the same purpose.
Release Notes:
- N/A
This PR removes the old `ToggleButton` component, replacing it with the
newer `ToggleButtonGroup` component in the couple of places that used to
use it. Ended up also adding a few more methods to the newer toggle
button group so the UI for the extensions page and the debugger main
picker didn't get visually impacted much. Then, as I was already in the
extensions page, decided to bake in some reasonably small UI
improvements to it as well.
Release Notes:
- N/A
This led to a problem where we'd have a zombie entries in LSP dropdown
because they were treated as if they originated from an unknown
worktree.
Closes#42077
Release Notes:
- Fixed LSP status list containing zombie entries for LSPs in other
windows
---------
Co-authored-by: HactarCE <6060305+HactarCE@users.noreply.github.com>
Co-authored-by: Kirill Bulatov <kirill@zed.dev>
This PR introduces a new `MultiBufferOffset` new type wrapping size. The
goal of this is to make it clear at the type level when we are
interacting with offsets of a multi buffer versus offsets of a language
/ text buffer. This improves readability of things quite a bit by making
it clear what kind of offsets one is working with while also reducing
accidental bugs by using the wrong kin of offset for the wrong API.
This PR also uncovered two minor bugs due to that.
Does not yet introduce the MultiBufferPoint equivalent, that is for a
follow up PR.
Release Notes:
- N/A *or* Added/Fixed/Improved ...
We call `entry_by_path` on the `bulk_staging` anchor entry at the
beginning of `update_visible_entries`, but in the codepath where
`sort_by_path` is toggled on or off, we clear entries without clearing
`bulk_staging` or counts, causing that `entry_by_path` to do an out of
bounds index. Fixed by clearing `bulk_staging` as well.
Release Notes:
- N/A
This PR restructures the subcommands in `zeta-cli`, so that the
prediction engine (currently `zeta1` vs `zeta2`) is no longer the
highest order subcommand. Instead, there is just one layer of
subcommands: `eval`, `predict`, `context`, etc. Within these commands,
there are flags for using `zeta1`, `zeta2`, and now `sweep`.
Release Notes:
- N/A
---------
Co-authored-by: Ben Kunkle <ben@zed.dev>
Co-authored-by: Agus <agus@zed.dev>
Calloop (used by our linux executor) was running all futures regardless
of how long they take. Unfortunaly some of our futures are rather busy
and take a while (>10ms).
Running all of them froze the editor for multiple seconds or even
minutes when opening a large project diff (git reset HEAD~2000 in
chromium for example).
Closes #ISSUE
Release Notes:
- N/A
---------
Co-authored-by: Jakub Konka <kubkon@jakubkonka.com>
Lots of folks were accidentally clicking this. Even though it’s the
default in macOS Finder, it’s a good idea to not have it as the default
for us.
Release Notes:
- Removed the default `cmd-opt-.` binding for toggling hidden files in
the Project Panel so it’s harder to hide them by accident.
This PR redoes the desired behavior changes of #41583 (reverted in
#42892) but less invasively
Closes#41125Closes#41164
Release Notes:
- N/A
Co-authored-by: Conrad Irwin <conrad.irwin@gmail.com>
Closes#40210
Previously attempted in #40423 and #42756. Third time's the charm?
Release Notes:
- Fixed encoding error in terms & conditions displayed when installing
This starts the work on a workflow that can be invoked in extension CI
to test changes on extension repositories.
Release Notes:
- N/A
---------
Co-authored-by: Agus Zubiaga <agus@zed.dev>
Co-authored-by: Conrad Irwin <conrad.irwin@gmail.com>
Delay the stalebot runs until the end of the year since it's currently
broken and leaves unhelpful comments on all the issues, including feature requests. Bad
bot. Allegedly this bug will soon be gone
https://github.com/actions/stale/issues/1302 but it's too much work
protecting issues from the bot until then.
Release Notes:
- N/A
The bug is in the `place_near` logic, specifically the
`!row_block_types.contains_key(&(row - 1))` check. The problem isn’t
really that condition itself, but it’s that it relies on
`row_block_types`, which does not take into account that upon block
resizes, subsequent block start row moves up/down. Since `place_near`
depends on this incorrect map, it ends up causing incorrect resize syncs
to the block map, which then triggers more bad recursive calls. The
reason it worked till now in most of the cases is that recursive resizes
eventually lead to stabilizing it.
Before `place_near`, we never touched `row_block_types` during the first
prepaint pass because we knew it was based on outdated heights. Once all
heights are finalized, using it is fine.
The fix is to make sure `row_block_types` is accurate from the very
first prepaint pass by keeping an offset whenever a block shrinks or
expands. Now ideally it should take only one subsequent prepaint. But
due to shrinking, new custom/diagnostics blocks might come into the view
from below, which needs further prepaint calls for resolving. Right now,
tests pass after 2 subsequent prepaint calls. Just to be safe, we have
set it to 5.
<img width="500" alt="image"
src="https://github.com/user-attachments/assets/da3d32ff-5972-46d9-8597-b438e162552b"
/>
Release Notes:
- Fix issue where sometimes Zed used to experience freeze while working
with inline diagnostics.
I was trying to use Zed for Rust debugging on windows, but was getting
this warning in debugger console: "Could not initialize Python
interpreter - some features will be unavailable (e.g. debug
visualizers)."
As the warning suggests this led to bad debugging experience where the
variables were not visualized properly in the "Variables" panel.
After some investigation I found that the problem is that Zed silently
failed to extract all files from the debug adapter package
(https://github.com/vadimcn/codelldb/releases/download/v1.11.8/codelldb-win32-x64.vsix).
Particularly `python-lldb` folder was missing, which caused the warning.
The error occurred here:
cf7c64d77f/crates/util/src/archive.rs (L47)
And then gets ignored here:
cf7c64d77f/crates/dap/src/adapters.rs (L323-L326)
The simple fix is to update `async_zip` crate to version 0.0.18 where
this issue appears to be fixed. I also added logging instead of silently
ignoring the error, as I believe that would have helped to catch it
earlier.
To reproduce the original issue you can try to follow these steps:
0. (Optional) Remove/rename old codelldb adapter at
`%localappdata%\Zed\debug_adapters\CodeLLDB`. Restart Zed.
1. Create a simple Rust project. Make sure you use gnu toolchain (target
`x86_64-pc-windows-gnu`)
```rust
fn world() -> String {
"world".into()
}
fn main() {
let w = world();
println!("hello {}", w);
}
```
2. Put a breakpoint on line 7 (`println`)
3. In the command palette choose "debugger: start" and then select "run
*crate name*"
Screenshot before the fix:
<img width="893" height="411" alt="image"
src="https://github.com/user-attachments/assets/78097690-b55e-4989-bfa4-20452560f9fc"
/>
<details>
<summary>Console before the fix</summary>
```
Checking latest version of CodeLLDB...
Downloading from https://github.com/vadimcn/codelldb/releases/download/v1.11.8/codelldb-win32-x64.vsix...
Download complete
Could not initialize Python interpreter - some features will be unavailable (e.g. debug visualizers).
Console is in 'commands' mode, prefix expressions with '?'.
warning: (x86_64) D:\repro\target\x86_64-pc-windows-gnu\debug\repro.exe unable to locate separate debug file (dwo, dwp). Debugging will be degraded.
Launching: D:\repro\target\x86_64-pc-windows-gnu\debug\repro.exe
Launched process 13836 from 'D:\repro\target\x86_64-pc-windows-gnu\debug\repro.exe'
error: repro.exe [0x0000000000002074]: DIE has DW_AT_ranges(DW_FORM_sec_offset 0x000000000000001a) attribute, but range extraction failed (invalid range list offset 0x1a), please file a bug and attach the file at the start of this error message
error: repro.exe [0x000000000000208c]: DIE has DW_AT_ranges(DW_FORM_sec_offset 0x0000000000000025) attribute, but range extraction failed (invalid range list offset 0x25), please file a bug and attach the file at the start of this error message
error: repro.exe [0x00000000000020af]: DIE has DW_AT_ranges(DW_FORM_sec_offset 0x0000000000000030) attribute, but range extraction failed (invalid range list offset 0x30), please file a bug and attach the file at the start of this error message
error: repro.exe [0x00000000000020c4]: DIE has DW_AT_ranges(DW_FORM_sec_offset 0x000000000000003b) attribute, but range extraction failed (invalid range list offset 0x3b), please file a bug and attach the file at the start of this error message
error: repro.exe [0x00000000000020fc]: DIE has DW_AT_ranges(DW_FORM_sec_offset 0x0000000000000046) attribute, but range extraction failed (invalid range list offset 0x46), please file a bug and attach the file at the start of this error message
error: repro.exe [0x0000000000002130]: DIE has DW_AT_ranges(DW_FORM_sec_offset 0x0000000000000046) attribute, but range extraction failed (invalid range list offset 0x46), please file a bug and attach the file at the start of this error message
> ? w
< {...}
```
</details>
Screenshot after the fix:
<img width="634" height="295" alt="image"
src="https://github.com/user-attachments/assets/67e36a64-97d2-406c-9216-7ac5b01f4101"
/>
<details>
<summary>Console after the fix</summary>
```
Checking latest version of CodeLLDB...
Downloading from https://github.com/vadimcn/codelldb/releases/download/v1.11.8/codelldb-win32-x64.vsix...
Download complete
Console is in 'commands' mode, prefix expressions with '?'.
Loading Rust formatters from C:\Users\Vasyl\.rustup\toolchains\1.91.1-x86_64-pc-windows-msvc\lib/rustlib/etc
warning: (x86_64) D:\repro\target\x86_64-pc-windows-gnu\debug\repro.exe unable to locate separate debug file (dwo, dwp). Debugging will be degraded.
Launching: D:\repro\target\x86_64-pc-windows-gnu\debug\repro.exe
Launched process 10364 from 'D:\repro\target\x86_64-pc-windows-gnu\debug\repro.exe'
error: repro.exe [0x0000000000002074]: DIE has DW_AT_ranges(DW_FORM_sec_offset 0x000000000000001a) attribute, but range extraction failed (invalid range list offset 0x1a), please file a bug and attach the file at the start of this error message
error: repro.exe [0x000000000000208c]: DIE has DW_AT_ranges(DW_FORM_sec_offset 0x0000000000000025) attribute, but range extraction failed (invalid range list offset 0x25), please file a bug and attach the file at the start of this error message
error: repro.exe [0x00000000000020af]: DIE has DW_AT_ranges(DW_FORM_sec_offset 0x0000000000000030) attribute, but range extraction failed (invalid range list offset 0x30), please file a bug and attach the file at the start of this error message
error: repro.exe [0x00000000000020c4]: DIE has DW_AT_ranges(DW_FORM_sec_offset 0x000000000000003b) attribute, but range extraction failed (invalid range list offset 0x3b), please file a bug and attach the file at the start of this error message
error: repro.exe [0x00000000000020fc]: DIE has DW_AT_ranges(DW_FORM_sec_offset 0x0000000000000046) attribute, but range extraction failed (invalid range list offset 0x46), please file a bug and attach the file at the start of this error message
error: repro.exe [0x0000000000002130]: DIE has DW_AT_ranges(DW_FORM_sec_offset 0x0000000000000046) attribute, but range extraction failed (invalid range list offset 0x46), please file a bug and attach the file at the start of this error message
> ? w
< "world"
```
</details>
This fixes#33753
Release Notes:
- util: Fixed archive::extract_zip failing to extract some archives
Closes https://github.com/zed-industries/zed/issues/42944
The powershell we discovered might be in a directory with higher
permission requirements which will cause us to fail using it.
Release Notes:
- Fixed powershell discovery disregarding admin requirements
This reverts commit b0a7defd09.
It looks like this doesn't interact correctly with the project diff or
with staging, let's revert and reland with bugs fixed.
Release Notes:
- N/A
Small QOL improvement for branch picker to only dismiss when focus lost
in active window.
This can benefit those who need to switch windows mid branch creation to
fetch correct jira ticket number or etc.
Added `window.is_active_window()` guard in `picker.rs` -> `cancel` event
Release Notes:
- (Let's Git Together) Fixed a behavior where pickers would
automatically close upon the window becoming inactive.
We install phpactor by default, but on windows it doesn't work out of
the box (see
[here](https://github.com/phpactor/phpactor/discussions/2579) for
details). For now we'll default to using intelephense, but in the future
we'd like to switch back if phpactor lands windows support given that
it's open source.
Release Notes:
- N/A
https://github.com/zed-industries/zed/pull/40883 implemented this
incorrectly. It was marking a random background thread as a wasm thread
(whatever thread picked up the wasm epoch timer background task),
instead of marking the threads that actually run the wasm extension.
This has two implications:
1. it didn't prevent extension panics from tearing down as planned
2. Worse, it actually made us hide legit panics in sentry for one of our
background workers.
Now 2 still technically applies for all tokio threads after this, but we
basically only use these for wasm extensions in the main zed binary.
Release Notes:
- Fixed extension panics crashing Zed on Linux
Closes#42288
This will actually print the parsing error that prevented the vscode
settings file from being loaded which should make it easier for users to
self help when they have an invalid config.
Release Notes:
- N/A
This PR updates window background rendering to use the **official DWM
backdrop API** (`DwmSetWindowAttribute`) instead of the legacy
`SetWindowCompositionAttribute`.
It also adds **Mica** and **Mica Alt** options to
`WindowBackgroundAppearance` for native Windows 11 effects.
### Motivation
Enables modern, stable, and GPU-accelerated backdrops consistent with
Windows 11’s Fluent Design.
Removes reliance on undocumented APIs while maintaining backward
compatibility with older Windows versions.
### Changes
* Added `MicaBackdrop` and `MicaAltBackdrop` variants.
* Switched to DWM API for applying backdrop effects.
* Verified fallback behavior on Windows 10.
### Release Notes:
- Added `WindowBackgroundAppearance::MicaBackdrop` and
`WindowBackgroundAppearance::MicaAltBackdrop` for Windows 11 Mica and
Mica Alt window backdrops.
### Screenshots
- `WindowBackgroundAppearance::Blurred`
<img width="553" height="354" alt="image"
src="https://github.com/user-attachments/assets/57c9c25d-9412-4141-94b5-00000cc0b1ec"
/>
- `WindowBackgroundAppearance::MicaBackdrop`
<img width="553" height="354" alt="image"
src="https://github.com/user-attachments/assets/019f541c-3335-4c9e-b026-71f5a1786534"
/>
- `WindowBackgroundAppearance::MicaAltBackdrop`
<img width="553" height="354" alt="image"
src="https://github.com/user-attachments/assets/5128d600-c94d-4c89-b81a-8b842fe1337a"
/>
---------
Co-authored-by: John Tur <john-tur@outlook.com>
Closes #ISSUE
The model often uses the wrong closing tag, or has spaces around the
closing tag name. This PR makes it so that opening tags are treated as
authoritative and any closing tag with the name `new_text` `old_text` or
`edits` is accepted based on depth. This has the additional benefit that
the parsing is more robust with contents that contain `new_text`
`old_text` or `edits. I.e. the following test passes
```rust
#[test]
fn test_extract_xml_edits_with_conflicting_content() {
let input = indoc! {r#"
<edits path="component.tsx">
<old_text>
<new_text></new_text>
</old_text>
<new_text>
<old_text></old_text>
</new_text>
</edits>
"#};
let result = extract_xml_replacements(input).unwrap();
assert_eq!(result.file_path, "component.tsx");
assert_eq!(result.replacements.len(), 1);
assert_eq!(result.replacements[0].0, "<new_text></new_text>");
assert_eq!(result.replacements[0].1, "<old_text></old_text>");
}
```
Release Notes:
- N/A *or* Added/Fixed/Improved ...
### What this solves
This PR adds support for HTTP and SSE (Server-Sent Events) transports to
Zed's context server implementation, enabling communication with remote
MCP servers. Currently, Zed only supports local MCP servers via stdio
transport. This limitation prevents users from:
- Connecting to cloud-hosted MCP servers
- Using MCP servers running in containers or on remote machines
- Leveraging MCP servers that are designed to work over HTTP/SSE
### Why it's important
The MCP (Model Context Protocol) specification includes HTTP/SSE as
standard transport options, and many MCP server implementations are
being built with these transports in mind. Without this support, Zed
users are limited to a subset of the MCP ecosystem. This is particularly
important for:
- Enterprise users who need to connect to centralized MCP services
- Developers working with MCP servers that require network isolation
- Users wanting to leverage cloud-based context providers (e.g.,
knowledge bases, API integrations)
### Implementation approach
The implementation follows Zed's existing architectural patterns:
- **Transports**: Added `HttpTransport` and `SseTransport` to the
`context_server` crate, built on top of the existing `http_client` crate
- **Async handling**: Uses `gpui::spawn` for network operations instead
of introducing a new Tokio runtime
- **Settings**: Extended `ContextServerSettings` enum with a `Remote`
variant to support URL-based configuration
- **UI**: Updated the agent configuration UI with an "Add Remote Server"
option and dedicated modal for remote server management
### Changes included
- [x] HTTP transport implementation with request/response handling
- [x] SSE transport for server-sent events streaming
- [x] `build_transport` function to construct appropriate transport
based on URL scheme
- [x] Settings system updates to support remote server configuration
- [x] UI updates for adding/editing remote servers
- [x] Unit tests using `FakeHttpClient` for both transports
- [x] Integration tests (WIP)
- [x] Documentation updates (WIP)
### Testing
- Unit tests for both `HttpTransport` and `SseTransport` using mocked
HTTP client
- Manual testing with example MCP servers over HTTP/SSE
- Settings validation and UI interaction testing
### Screenshots/Recordings
[TODO: Add screenshots of the new "Add Remote Server" UI and
configuration modal]
### Example configuration
Users can now configure remote MCP servers in their `settings.json`:
```json
{
"context_servers": {
"my-remote-server": {
"enabled": true,
"url": "http://localhost:3000/mcp"
}
}
}
```
### AI assistance disclosure
I used AI to help with:
- Understanding the MCP protocol specification and how HTTP/SSE
transports should work
- Reviewing Zed's existing patterns for async operations and suggesting
consistent approaches
- Generating boilerplate for test cases
- Debugging SSE streaming issues
All code has been manually reviewed, tested, and adapted to fit Zed's
architecture. The core logic, architectural decisions, and integration
with Zed's systems were done with human understanding of the codebase.
AI was primarily used as a reference tool and for getting unstuck on
specific technical issues.
Release notes:
* You can now configure MCP Servers that connect over HTTP in your
settings file. These are not yet available in the extensions API.
```
{
"context_servers": {
"my-remote-server": {
"enabled": true,
"url": "http://localhost:3000/mcp"
}
}
}
```
---------
Co-authored-by: Conrad Irwin <conrad.irwin@gmail.com>
Fixes#42945
## Problem
When opening a single file via command line (e.g., `zed
~/Downloads/file.txt`), the terminal panel was opening in the root
directory (/) instead of the file's directory.
## Root Cause
The code only checked for active project directory, which returns None
when a single file is opened. Additionally, file worktrees weren't
handling parent directory lookup.
## Solution
Added fallback logic to use the first project directory when there's no
active entry, and made file worktrees return their parent directory
instead of None.
## Testing
- All existing tests pass
- Added test coverage for file worktree scenarios
- Manually tested with `zed ~/Downloads/file.txt` - terminal now opens
in correct directory
This improves the user experience for users who frequently open single
files from the command line.
## Release Notes
- Fixed terminal opening in root directory when editing single files
from the command line
The idea is that we only store running (`!self.finished`) or finished
(`self.finished`) pending ops, while everything else (skipped, errored)
jobs are pruned out immediately. We don't really need them in the grand
scheme of things anyway.
Release Notes:
- N/A
Closes#42922
Release Notes:
- Fixed Correctly highlighting the 'for' keyword in Rust as
keyword.control only in for loops.
- Fixed Highlighting the 'await' keyword in Rust as keyword.control
This PR's goal is to improve discoverability of how Zed "remembers" the
currently selected agent when hitting `cmd-n` (or `ctrl-n`). Hitting
that binding starts a new thread with whatever agent is currently
selected.
In the example below, I am in a Claude Code thread and if I hit `cmd-n`,
a new, fresh CC thread will be started:
<img width="500" height="822" alt="Screenshot 2025-11-18 at 1 13@2x"
src="https://github.com/user-attachments/assets/d3acd1aa-459d-4078-9b62-bbac3b8c1600"
/>
Release Notes:
- agent: Improved discoverability of the `cmd-n` keybinding to create a
new thread with the currently selected agent.
This should make it easier to correlate Sentry reports with user reports
and
github issues (for users who have diagnostics enabled)
Release Notes:
- N/A
As discussed in the first responders meeting. We have collected a lot of
backtraces from these, but it's not quite clear yet what causes this.
Removing these should ideally make things a bit more stable even if we
may run into panics later one when the faulty anchor is used still.
Release Notes:
- N/A *or* Added/Fixed/Improved ...
Closes#40906Closes#39729
SFTP uploads weren't quoting the install directory which was causing
extension syncing to fail. We were also only running `install_extension`
once per remote-connection instead of once per project (thx @feeiyu for
pointing this out) so extension weren't being loaded in subsequently
opened remote projects.
Release Notes:
- N/A
---------
Co-authored-by: Conrad Irwin <conrad.irwin@gmail.com>
This fixes various issues where rustfmt failed to format code due to too
long strings, most of which I stumbled across over the last week and
some additonal ones I searched for whilst fixing the others.
Release Notes:
- N/A
The `Vim.exit_temporary_normal` method had been updated
(https://github.com/zed-industries/zed/pull/42742) to expect and
`Option<&Motion>` that would then be used to determine whether to move
the cursor right in case the motion was `Some(EndOfLine { ..})`.
Unfortunately this meant that all callers now had to provide this
argument, even if just `None`.
After merging those changes I remember that we could probably play
around with `clip_at_line_ends` so this commit removes those intial
changes in favor of updating the `vim::normal::Vim.move_cursor` method
so that, if vim is in temporary mode and `EndOfLine` is used, it
disables clipping at line ends so that the newline character can be
selected.
Closes [#42278](https://github.com/zed-industries/zed/issues/42278)
Release Notes:
- N/A
Closes #ISSUE
Makes it so that a file named `bucketed_analysis.md` is written to the
runs directory after an eval is ran with > 1 repetitions. This file
buckets the predictions made by the model by comparing the edits made so
that seeing how many times different failure modes were encountered
becomes much easier.
Release Notes:
- N/A *or* Added/Fixed/Improved ...
Returning the favor from @rgbkrk in
https://github.com/posit-dev/air/pull/445
I noticed the R docs around Air are a bit incorrect / out of date. I'll
make a few more comments inline. Feel free to take over for any other
edits.
Release Notes:
- Improved R language support documentation
This prompt is for a fine-tuned model. It has the following changes,
compared to `minimal`:
- No instructions at all, except for one sentence at the beginning of
the prompt.
- Output is a simplified unified diff -- hunk headers have no line
counts (e.g., `@@ -20 +20 @@`)
- Qwen's FIM tokens are used where possible (`<|file_sep|>`,
`<|fim_prefix|>`, `<|fim_suffix|>`, etc.)
To evaluate this model:
```
ZED_ZETA2_MODEL=zeta2-exp [usual zeta-cli eval params ...] --prompt-format minimal-qwen
```
This will point to the most recent Baseten deployment of zeta2-exp
(which may change in the future, so the prompt-format may get out of
sync).
Release Notes:
- N/A
Closes https://github.com/zed-industries/zed/issues/32701
Release Notes:
- agent: Fixed a bug where hitting the `NewThread` keybinding when
focused inside a terminal within the agent panel would create a new
terminal tab instead of a new thread.
Closes https://github.com/zed-industries/zed/issues/42094
This will make it consistent with the regular/main page. Also ended up
fixing a bug along the way where this button wouldn't work for subpage
items.
Release Notes:
- settings ui: Fixed a bug where the "Edit in settings.json" wouldn't
work for subpages like all the Language pages.
I think having the "exact mode" turned on by default is usually what
users will expect when searching for a specific keybinding. When it's
turned off, it's very odd to search for a super common binding like
"command-enter" and get no results. That happens because without that
mode, we're trying to match for subsequent matches, which I'm betting
it's an edge case. Hopefully, this change will make the keymap editor
feel more like it works well.
I'm also adding the toggle icon button inside the keystroke input for
consistency with the project search input.
Making this change very inspired by [Sam Rose's
feedback](https://bsky.app/profile/samwho.dev/post/3m5juszqyd22w).
Release Notes:
- keymap editor: Made the "toggle exact match mode" the default
keystroke search mode so that whatever you search for matches exactly to
results.
Closes#42406
The issue for the fish-extension is that a `extension.json` is still
present next to a `extension.toml`, although the former is deprecated.
We should prefer the `extension.toml` if it is present and only fall
back to the `extension.json` if needed. This PR tackles this.
Release Notes:
- N/A
Closes #ISSUE
Remove unused method `HttpClient::type_name`. Looking at the PR from a
year ago when it was added, it was never actually used for anything and
seems like a prototyping artifact.
Other misc changes for the `http_client` crate include:
- Use `derive_more::Deref` for `HttpClientWithUrl` (already used for
`HttpClientWithProxy`)
- Move `http_client::proxy()` higher up in the trait definition. (It was
in between methods that have default implementations)
Release Notes:
- N/A *or* Added/Fixed/Improved ...
- Only showing the "Create" menu item in the right-click context menu
for actions that _do not_ contain a binding already assigned to them
- Only show the "Clear Input" icon button in the keystroke modal when
the input is focused/in recording mode
- Add a subtle hover style to the table rows just to make it easier to
navigate
Release Notes:
- N/A
This enables optimizations for our own proc-macros as well as some heavy
hitters. Additionally this gates the `derive_inspector_reflection` to be
skipped for rust-analyzer as it currently slows down rust-analyzer way
too much
Release Notes:
- N/A *or* Added/Fixed/Improved ...
Closes#4533 (partly at least)
Release Notes:
- Added `project_panel.sort_mode` option to control explorer file sort
(directories first, mixed, files first)
## Summary
Adds three sorting modes for the project panel to give users more
control over how files and directories are displayed:
- **`directories_first`** (default): Current behaviour - directories
grouped before files
- **`mixed`**: Files and directories sorted together alphabetically
- **`files_first`**: filed grouped before directories
## Motivation
Users coming from different editors and file managers have different
expectations for file sorting. Some prefer directories grouped at the
top (traditional), while others prefer the macOS Finder-style mixed
sorting where "Apple1/", "apple2.tsx" and "Apple3/" appear
alphabetically mixed together.
### Screenshots
New sort options in settings:
<img width="515" height="160" alt="image"
src="https://github.com/user-attachments/assets/8f4e6668-6989-4881-a9bd-ed1f4f0beb40"
/>
Directories first | Mixed | Files first
-------------|-----|-----
<img width="328" height="888" alt="image"
src="https://github.com/user-attachments/assets/308e5c7a-6e6a-46ba-813d-6e268222925c"
/> | <img width="327" height="891" alt="image"
src="https://github.com/user-attachments/assets/8274d8ca-b60f-456e-be36-e35a3259483c"
/> | <img width="328" height="890" alt="image"
src="https://github.com/user-attachments/assets/3c3b1332-cf08-4eaf-9bed-527c00b41529"
/>
### Agent usage
Copilot-cli/claude-code/codex-cli helped out a lot. I'm not from a rust
background, but really wanted this solved, and it gave me a chance to
play with some of the coding agents I'm not permitted to use for work
stuff
---------
Co-authored-by: Smit Barmase <heysmitbarmase@gmail.com>
Closes#41484
With preview tabs disabled, when you click once on a file in the project
panel, rather than focusing on that file, zed will incorrectly focus on
the text editor panel. This means if you click on a file to focus it,
then follow up with a keybind like backspace to delete that file, it
doesn't delete that file because the backspace goes through to the text
editor instead.
Incorrect behaviour seen here:
https://github.com/user-attachments/assets/8c2dea90-bd90-4507-8ba6-344be348f151
Release Notes:
- Fixed improper UI focus behaviour in the project panel when preview
tabs are disabled
When using the end of line motion ($) while in temporary mode, the
cursor would be placed in insert mode just before the last character
instead of after, just like in NeoVim.
This happens because `EndOfLine` kind of assumes that we're in `Normal`
mode and simply places the cursor in the last character instead of the
newline character.
This commit moves the cursor one position to the right when exiting
temporary mode and the motion used was `Motion::EndOfLine`
- Update `vim::normal::Vim.exit_temporary_normal` to now accept a
`Option<&Motion>` argument, in case callers want this new logic to
potentially be applied
Closes#42278
Release Notes:
- Fixed temporary mode exit when using `$` to move to the end of the
line
We weren't reporting predictions that were generated but never made it
out of the provider, such as predictions that failed to interpolate, and
those that are cancelled because another request completes before it.
Release Notes:
- N/A
---------
Co-authored-by: Max Brunsfeld <maxbrunsfeld@gmail.com>
Co-authored-by: Ben Kunkle <ben@zed.dev>
We now correctly use bracket ranges from the deepest syntax layer when
finding enclosing brackets.
Release Notes:
- Fixed an issue where `MoveToEnclosingBracket` didn’t work correctly
inside Markdown code blocks.
- Fixed an issue where unmatched forward/backward Vim motions didn’t
work correctly inside Markdown code blocks.
---------
Co-authored-by: MuskanPaliwal <muskan10112002@gmail.com>
Use
[`command`](https://www.gnu.org/software/bash/manual/bash.html#index-command)
instead of `which` to check if `wild` is installed.
Using `which` will result in an error being printed to stdout:
```bash
./script/install-wild
which: invalid option -- 's'
/usr/local/bin/wild
Warning: existing wild 0.6.0 found at /usr/local/bin/wild. Skipping installation.
```
Release Notes:
- N/A
Closes#4947
Taken inspiration from @tasuren implementation, plus the addition for
the double click enabled on the whole title bar too to
maximizes/restores the window.
I was not able to test the application on Linux, no need to test on
Windows since the feature is enabled by the OS.
Release Notes:
- Fixed title bar not fully draggable on macOS
- Fixed not being able to maximizes/restores the window with double
click on the whole title bar on macOS
Closes https://github.com/zed-industries/zed/issues/40867
Since the recent changes in
[https://github.com/zed-industries/zed/pull/38881](https://github.com/zed-industries/zed/pull/38881),
the filename editor is sometimes not focused after duplicating a file or
creating a new one, and similarly, autoscroll sometimes didn’t work. It
turns out that multiple calls to `update_visible_entries_task` cancel
the existing task, which might contain information about whether we need
to focus the filename editor and autoscroll after the task ends. To fix
this, we now carry that information forward to the next task that
overwrites it, so that when the latest task ends, we can use that
information to do the right thing.
Release Notes:
- Fixed an issue in the Project Panel where duplicating or creating an
entry sometimes didn’t focus the rename editing field.
This PR improves Zeta2's matching of `old_text`/`new_text` pairs, using
similar code to what we use in the edit agent. For right now, we've
duplicated the code, as opposed to trying to generalize it.
Release Notes:
- N/A
---------
Co-authored-by: Max <max@zed.dev>
Co-authored-by: Michael <michael@zed.dev>
Co-authored-by: Max Brunsfeld <maxbrunsfeld@gmail.com>
Co-authored-by: Agus <agus@zed.dev>
The command used to run go subtests was breaking if the test contained
square brackets, for example:
```
go test . -v -run ^TestInventoryCheckout$/^\[test\]_test_checkout$
```
After a bit of testing it appears that the best way to actually resolve
this in a way supported by `go test` is to wrap this command in quotes.
As such, this commit updates the command to, considering the example
above:
```
go test . -v -run '^TestInventoryCheckout$/^\[test\]_test_checkout$'
```
We also tested escape the square brackets, using `\\\[` instead of `\[`,
but that would lead to a more complex change, so we opted for the
simpler solution of wrapping the command in quotes.
Closes#42347
Release Notes:
- Fixed command used to run Go subtests to ensure that escaped
characters don't lead to a failure in finding tests to run
This PR makes the description in the callout that display general errors
in the agent panel be rendered as markdown. This allow us to pass URLs
to these error strings that will be clickable, improving the overall
interaction with them. Here's an example:
<img width="500" height="396" alt="Screenshot 2025-11-14 at 11 43@2x"
src="https://github.com/user-attachments/assets/f4fc629a-6314-4da1-8c19-b60e1a09653b"
/>
Release Notes:
- agent: Improved the interaction with errors by allowing links to be
clickable.
So i just discovered `editor::ExpandAllDiffHunks`
I have been really missing the ability to look at changes NOT in a multi
buffer so i was very pleased to finally figure out that this is already
possible in Zed.
i have seen alot of discussion/issues requesting this feature so i think
it is safe to say i'm not the only one that is not aware it exists.
i think the wording in the docs could better communicate what this
feature actually is, however, i think an even better way to show users
that this feature exists would be to just put it in front of them.
In the `GitPanel`:
- `menu::Confirm` opens the project diff
- `menu::SecondaryConfirm` opens the selected file in a new editor.
I think it would be REALLY nice if opening a file with
`SecondaryConfirm` opened the file with the diff hunks already expanded
and scrolled the editor to the first hunk.
ideally i see this being toggle-able in settings something like
`GitPanel - Open File with Diffs Expanded` or something. so the user
could turn this off if they preferred.
I tried creating a new keybinding using the new `actions::Sequence`
it was something like:
```json
{
"context": "GitPanel && ChangesList",
"bindings": {
"cmd-enter" : [ "actions::Sequence", ["menu:SecondaryConfirm", "editor::ToggleFocus", "editor::ExpandAllDiffHunks", "editor::GoToHunk"]]
}
}
```
but the action sequence does not work. i think because opening the file
is an async task.
i have a first attempt here, of just trying to get the diff hunks to
expand after opening the file.
i tried to copy and paste the logic/structure as best i could from the
confirm method in file_finder.rs:1432
it compiles, but it does not work, and i do not have enough experience
in rust or in this project to figure out anything further.
if anyone was interested in working on this with me i would enjoy
learning more and i think this would be a nice way to showcase this
tool!
1. Add `--prompt-format=minimal` that matches single-sentence
instructions used in fine-tuned models (specifically, in `1028-*` and
`1029-*` models)
2. Use separate configs for agentic context search model and edit
prediction model. This is useful when running a fine-tuned EP model, but
we still want to run vanilla model for context retrieval.
3. `zeta2-exp` is a symlink to the same-named Baseten deployment. This
model can be redeployed and updated without having to update the
deployment id.
4. Print scores as a compact table
Release Notes:
- N/A
---------
Co-authored-by: Piotr Osiewicz <piotr@zed.dev>
including a new identifier on the Editor key context will allow for some
more flexibility when creating keybindings.
for example i would like to be able to set the following:
```json
{
"context": "Editor",
"bindings": {
"pageup": ["editor::MovePageUp", { "center_cursor": true }],
"pagedown": ["editor::MovePageDown", { "center_cursor": true }],
}
},
{
"context": "Editor && diffs_expanded",
"bindings": {
"pageup": "editor::GoToPrevHunk",
"pagedown": "editor::GoToHunk",
}
},
```
<img width="1392" height="1167" alt="Screenshot 2025-10-18 at 23 51 46"
src="https://github.com/user-attachments/assets/cf4e262e-97e7-4dd9-bbda-cd272770f1ac"
/>
very open to suggestions for the name. that's the best i could come up
with.
the action *IS* called `editor::ExpandAllDiffHunks` so this seems
fitting.
the identifier is included if *any* diff hunk is visible, even if some
of them have been closed using `editor::ToggleSelectedDiffHunk`
Release Notes:
- The Editor key context now includes 'diffs_expanded' when diff changes
are visible
Closes#31155
Release Notes:
- Ensure `git_panel::FocusChanges` bypasses the panel’s `Focusable`
logic and directly focuses the `ChangesList` handle so the command works
even when the repository has no entries.
- Keep the `Focusable` behavior from the commit 45b126a (which routes
empty panels to the commit editor) by handling this special-case action
rather than regressing the default focus experience.
This PR makes the `OpenProjectSettings` action open the settings UI in
project settings mode for the first visible worktree, instead of opening
the file. It also adds a `OpenProjectSettingsFile` action that maintains
the old behavior.
Finally, this PR partially fixes a bug where the settings UI won't load
project settings when the settings window is loaded before opening a
project/workspace. This happens because the global `app_state` isn't
correct in the `Subscription` that refreshes the available setting files
to open. The bug is still present in some cases, but it's out of scope
for this PR.
Release Notes:
- settings ui: Project Settings action now opens settings UI instead of
a file
This PR makes it so we clear the user's plan and usage information when
they sign out.
Release Notes:
- Signing out will now clear the local cache containing the plan and
usage information.
Closes https://github.com/zed-industries/zed/issues/36330
Closes https://github.com/zed-industries/zed/issues/35460
This PR improves how we display markdown tables by relying on grids
rather than flexbox. Given this makes text inside each cell wrap, I
ended up removing the `table_overflow_x_scroll` method, as it was 1)
used only in the agent panel, and 2) arguably not the best approach as a
whole, because as soon as you need to scroll a table, you probably need
more elements to make it be really great.
One thing I'm slightly unsatisfied with, though, is the border
situation. I added a half pixel border to the cell so they all sum up to
1px, but there are cases where there's a tiny space between rows and I
don't quite know where that's coming from and how it happens. But I
think it's a reasonable improvement overall.
<img width="500" height="1248" alt="Screenshot 2025-11-13 at 7 05@2x"
src="https://github.com/user-attachments/assets/182b2235-efeb-4a61-ada2-98262967355d"
/>
Release Notes:
- agent: Improved table rendering in the agent panel, ensuring cell text
wraps, not going off-screen.
Release Notes:
- Adds support for `:[range]w {file}`
- This writes the lines in the range to the specified
- Adds support for `:[range]w`
- This replaces the current file with the selected lines
Closes#41467
My first PR in Zed, any guidance or tips are appreciated.
This fixes the flickering/resize loop that occurred on the tab
immediately to the right of a pinned tab.
Removed the conditional border on the pinned tabs container. The border
was a visual indicator to show when unpinned tabs were scrolled, but it
wasn't essential and was causing the layout thrashing.
Release Notes:
- Fixed
---------
Co-authored-by: Smit Barmase <heysmitbarmase@gmail.com>
Fixed outline panel space key behavior by removing duplicate toggle call
The `open_selected_entry` function in `outline_panel.rs` was incorrectly
calling `self.toggle_expanded(&selected_entry, window, cx)` in addition
to its primary logic, causing the space key to both open/close entries
AND toggle their expanded state. Removed the redundant `toggle_expanded`
call to achieve the intended behavior.
Closes#41711
Release Notes:
- Fixed issue with the outline panel where pressing space would cause an
open selected entry to collapse and cause a closed selected entry to
open.
---------
Co-authored-by: Smit Barmase <heysmitbarmase@gmail.com>
Closes#40888
This updates runtimed to the latest version, which handles the
"starting" variant of `execution_state`. It actually handles a bunch of
other variants that are not documented in the protocol (see
https://jupyter-client.readthedocs.io/en/stable/messaging.html#kernel-status),
like "starting", "terminating", etc. I added implementations for these
variants as well.
Release Notes:
- Fixed issue that prevented the Ark kernel from working in Zed
(#40888).
---------
Co-authored-by: Conrad Irwin <conrad.irwin@gmail.com>
Release Notes:
- Fixed logging into Gemini CLI and Claude Code when remoting and
authenticating via CLI
Co-authored-by: Lukas Wirth <me@lukaswirth.dev>
Summary
Fixes UI scaling issue that occurs when starting Zed after disconnecting
an external monitor on macOS. The window's scale factor and drawable
size are now properly updated when the window changes screens.
Problem Description
When an external monitor is disconnected and Zed is started with only
the built-in screen active, the UI scale becomes incorrect. This happens
because:
1. macOS triggers the `window_did_change_screen` callback when a window
moves between displays (including when displays are disconnected)
2. The existing implementation only restarted the display link but
didn't update the window's scale factor or drawable size
3. This left the window with stale scaling information from the previous
display configuration
Root Cause
The `window_did_change_screen` callback in
`crates/gpui/src/platform/mac/window.rs` was missing the logic to update
the window's scale factor and drawable size when moving between screens.
This logic was only present in the `view_did_change_backing_properties
callback`, which isn't triggered when external monitors are
disconnected.
Solution
- Extracted common logic: Created a new `update_window_scale_factor()`
function that encapsulates the scale factor and drawable size update
logic
- Added scale factor update to screen change: Modified
`window_did_change_screen` to call this function after restarting the
display link
- Refactored existing code: Updated `view_did_change_backing_properties`
to use the new shared function, reducing code duplication
The fix ensures that whenever a window changes screens (due to monitor
disconnect, reconnect, or manual movement), the scale factor, drawable
size, and renderer state are properly synchronized.
Testing
- ✅ Verified that UI scaling remains correct after disconnecting
external monitor
- ✅ Confirmed that reconnecting external monitor works properly
- ✅ Tested that manual window movement between displays updates scaling
correctly
- ✅ No regressions observed in normal window operations
To verity my fix worked I had to copy my preview workspace over my dev
workspace, once I had done this I could reproduce the issue on main
consistently. After switching to the branch with this fix the issue was
resolved.
The fix is similar to what was done on
https://github.com/zed-industries/zed/pull/35686 (Windows)
Closes#37245#38229
Release Notes:
- Fixed: Update scale factor and drawable size when macOS window changes
screen
---------
Co-authored-by: Kate <work@localcc.cc>
Closes #ISSUE
The namespace runners mount the `target` directory to the cache drive,
so `rm -rf target` would fail with `Device Busy`. Instead we now do `rm
-rf target/* target/.*` to remove all files (including hidden files)
from the `target` directory, without removing the target directory
itself
Release Notes:
- N/A *or* Added/Fixed/Improved ...
Whenever right-click was used on the editor, the pane's tab buttons
would flicker, which was confirmed to happen because of the following
check:
```
self.focus_handle.contains_focused(window, cx)
|| self
.active_item()
.is_some_and(|item| {
item.item_focus_handle(cx).contains_focused(window, cx)
})
```
This check was returning `false` right after right-clicking but
returning `true` right after. When digging into it a little bit more,
this appears to be happening because the editor's `MouseContextMenu`
relies on `ContextMenu` which is rendered in a deferred fashion but
`MouseContextMenu` updates the window's focus to it instantaneously.
Since the `ContextMenu` is rendered in a deferred fashion, its focus
handle is not yet a descendant of the editor (pane's active item) focus
handle, so the `contains_focused(window, cx)` call would return `false`,
with it returning `true` after the menu was rendered.
This commit updates the `MouseContextMenu::new` function to leverage
`cx.on_next_frame` and ensure that the focus is only moved to the
`ContextMenu` 2 frames later, ensuring that by the time the focus is
moved, the `ContextMenu`'s focus handle is a descendant of the editor's.
Closes#41771
Release Notes:
- Fixed pane's tab buttons flickering when using right-click on the
editor
Automatically retry the agent's LLM completion requests when the
provider returns 429 Too Many Requests. Uses the Retry-After header to
determine the retry delay if it is available.
Many providers are frequently overloaded or have low rate limits. These
providers are essentially unusable without automatic retries.
Tested with Cerebras configured via openai_compatible.
Related: #31531
Release Notes:
- Added automatic retries for OpenAI-compatible LLM providers
---------
Co-authored-by: Bennet Bo Fenner <bennetbo@gmx.de>
This PR adds support for `HTML` href elements. It also refactored the
way we stored the regions, this was done because otherwise I had to add
2 extra arguments to each `HTML` parser method. It's now also more
inline with how we have done it for the highlights.
**Small note**: the markdown parser only supports HTML href tags inside
a paragraph tag. So adding them as a root node will result in just
showing the inner text. This is a limitation of the markdown parser we
use itself.
**Before**
<img width="935" height="174" alt="Screenshot 2025-11-08 at 15 40 28"
src="https://github.com/user-attachments/assets/42172222-ed49-4a4b-8957-a46330e54c69"
/>
**After**
<img width="1026" height="180" alt="Screenshot 2025-11-08 at 15 29 55"
src="https://github.com/user-attachments/assets/9e139c2d-d43a-4952-8d1f-15eb92966241"
/>
**Example code**
```markdown
<p>asd <a href="https://example.com">Link Text</a> more text</p>
<p><a href="https://example.com">Link Text</a></p>
[Duck Duck Go](https://duckduckgo.com)
```
**TODO**:
- [x] Add tests
cc @bennetbo
Release Notes:
- Markdown Preview: Add support for `HTML` href elements.
---------
Co-authored-by: Bennet Bo Fenner <bennet@zed.dev>
This is an in-progress work on changing how task scheduler affects
performance of project search. Instead of relying on tasks being
executed at a discretion of the task scheduler, we want to experiment
with having a set of "agents" that prioritize driving in-progress
project search matches to completion over pushing the whole thing to
completion. This should hopefully significantly improve throughput &
latency of project search.
This PR has been reverted previously in #40831.
Release Notes:
- Improved project search performance in local projects.
---------
Co-authored-by: Smit Barmase <smit@zed.dev>
Co-authored-by: Smit Barmase <heysmitbarmase@gmail.com>
## Summary
Fixes#42342
When installing a dev extension with long installation instructions, the
configuration modal would overflow and users couldn't scroll to see the
full content or interact with buttons at the bottom.
## Solution
This PR adds a `ScrollHandle` to the `ConfigureContextServerModal` and
passes it to the `Modal` component, enabling the built-in modal
scrolling capability. This ensures all content remains accessible
regardless of length.
## Changes
- Added `ScrollHandle` import to the ui imports
- Added `scroll_handle: ScrollHandle` field to
`ConfigureContextServerModal` struct
- Initialize `scroll_handle` with `ScrollHandle::new()` when creating
the modal
- Pass the scroll handle to `Modal::new()` instead of `None`
## Testing
- Built the changes locally
- Tested with extensions that have long installation instructions
- Verified scrolling works and all content is accessible
- Confirmed no regression for extensions with short descriptions
Release Notes:
- Fixed scrolling issue in extension configuration modal when
installation instructions overflow the viewport
---------
Co-authored-by: Finn Evers <finn.evers@outlook.de>
Address #40429
If an integration test is annotated with the ignore attribute, allow the
"debug: Test" option of the debug scenario or Code Action to run with
"--include-ignored"
Closes#40429
Release Notes:
- N/A
New rustc starts to output a few warnings, fix them by updating the
corresponding packages.
<details>
<summary>Incompatibility notes</summary>
```
The following warnings were discovered during the build. These warnings
are an
indication that the packages contain code that will become an error in a
future release of Rust. These warnings typically cover changes to close
soundness problems, unintended or undocumented behavior, or critical
problems
that cannot be fixed in a backwards-compatible fashion, and are not
expected
to be in wide use.
Each warning should contain a link for more information on what the
warning
means and how to resolve it.
To solve this problem, you can try the following approaches:
- Some affected dependencies have newer versions available.
You may want to consider updating them to a newer version to see if the
issue has been fixed.
num-bigint-dig v0.8.4 has the following newer versions available: 0.8.5,
0.9.0, 0.9.1
- If the issue is not solved by updating the dependencies, a fix has to
be
implemented by those dependencies. You can help with that by notifying
the
maintainers of this problem (e.g. by creating a bug report) or by
proposing a
fix to the maintainers (e.g. by creating a pull request):
- num-bigint-dig@0.8.4
- Repository: https://github.com/dignifiedquire/num-bigint
- Detailed warning command: `cargo report future-incompatibilities --id
1 --package num-bigint-dig@0.8.4`
- If waiting for an upstream fix is not an option, you can use the
`[patch]`
section in `Cargo.toml` to use your own version of the dependency. For
more
information, see:
https://doc.rust-lang.org/cargo/reference/overriding-dependencies.html#the-patch-section
The package `num-bigint-dig v0.8.4` currently triggers the following
future incompatibility lints:
> warning: macro `vec` is private
> -->
/Users/someonetoignore/.cargo/registry/src/index.crates.io-1949cf8c6b5b557f/num-bigint-dig-0.8.4/src/biguint.rs:490:22
> |
> 490 | BigUint::new(vec![1])
> | ^^^
> |
> = warning: this was previously accepted by the compiler but is being
phased out; it will become a hard error in a future release!
> = note: for more information, see issue #120192
<https://github.com/rust-lang/rust/issues/120192>
>
> warning: macro `vec` is private
> -->
/Users/someonetoignore/.cargo/registry/src/index.crates.io-1949cf8c6b5b557f/num-bigint-dig-0.8.4/src/biguint.rs:2005:9
> |
> 2005 | vec![0]
> | ^^^
> |
> = warning: this was previously accepted by the compiler but is being
phased out; it will become a hard error in a future release!
> = note: for more information, see issue #120192
<https://github.com/rust-lang/rust/issues/120192>
>
> warning: macro `vec` is private
> -->
/Users/someonetoignore/.cargo/registry/src/index.crates.io-1949cf8c6b5b557f/num-bigint-dig-0.8.4/src/biguint.rs:2027:16
> |
> 2027 | return vec![b'0'];
> | ^^^
> |
> = warning: this was previously accepted by the compiler but is being
phased out; it will become a hard error in a future release!
> = note: for more information, see issue #120192
<https://github.com/rust-lang/rust/issues/120192>
>
> warning: macro `vec` is private
> -->
/Users/someonetoignore/.cargo/registry/src/index.crates.io-1949cf8c6b5b557f/num-bigint-dig-0.8.4/src/biguint.rs:2313:13
> |
> 2313 | vec![0]
> | ^^^
> |
> = warning: this was previously accepted by the compiler but is being
phased out; it will become a hard error in a future release!
> = note: for more information, see issue #120192
<https://github.com/rust-lang/rust/issues/120192>
>
> warning: macro `vec` is private
> -->
/Users/someonetoignore/.cargo/registry/src/index.crates.io-1949cf8c6b5b557f/num-bigint-dig-0.8.4/src/prime.rs:138:22
> |
> 138 | let mut moduli = vec![BigUint::zero(); prime_limit];
> | ^^^
> |
> = warning: this was previously accepted by the compiler but is being
phased out; it will become a hard error in a future release!
> = note: for more information, see issue #120192
<https://github.com/rust-lang/rust/issues/120192>
>
> warning: macro `vec` is private
> -->
/Users/someonetoignore/.cargo/registry/src/index.crates.io-1949cf8c6b5b557f/num-bigint-dig-0.8.4/src/bigrand.rs:319:25
> |
> 319 | let mut bytes = vec![0u8; bytes_len];
> | ^^^
> |
> = warning: this was previously accepted by the compiler but is being
phased out; it will become a hard error in a future release!
> = note: for more information, see issue #120192
<https://github.com/rust-lang/rust/issues/120192>
>
```
</details>
Release Notes:
- N/A
Release Notes:
- Pressing `u` after multiple `.` in rapid succession will now only undo
the latest repeat instead of all repeats.
---------
Co-authored-by: Conrad Irwin <conrad.irwin@gmail.com>
Fixes#39448
Several node version managers such as [volta](https://volta.sh) use thin
wrappers that locate the "real" node/npm binary with an env var that
points at their install root. When it finds this, it prepends the
correct directory to PATH, otherwise it'll check a hardcoded default
location and prepend that to PATH if it exists.
We were clearing env for npm subcommands, which meant that volta and co.
failed to locate the install root, and because they were installed via
scoop they don't use the default install path either so it simply
doesn't prepend anything to PATH (winget on the other hand installs
volta to the right place, which is why it worked when using that instead
of scoop to install volta @IllusionaryX).
So volta's npm wrapper executes a subcommand `npm`, but when that
doesn't prepend a different directory to PATH the first `npm` found in
PATH is that same wrapper itself, which horrifyingly causes itself to
re-exec continuously. I think they might have some logic to try to
prevent this using, you'll never guess, another env var that they set
whenever a volta wrapper execs something. Of course since we clear the
env that var also fails to propagate.
Removing env clearing (but keeping the prepending of npm path from your
settings) fixes these issues.
Release Notes:
- Fixed issues with scoop installations of mise/volta
Co-authored-by: John Tur <john-tur@outlook.com>
Adds a `--repeat` flag to the zeta eval that runs each example as many
times as specified. Also makes the output nicer in a few ways.
Release Notes:
- N/A
---------
Co-authored-by: Ben Kunkle <ben@zed.dev>
Co-authored-by: Michael <michael@zed.dev>
The existing sorting approach when faced with `Dir1`, `dir2`, `Dir3`,
would only get as far as comparing the stems without numbers (`dir` and
`Dir`), and then the lowercase-first tie breaker in that function would
determine that `dir2` should come first, resulting in an undesirable
order of `dir2`, `Dir1`, `Dir3`.
This patch defers tie-breaking until it's determined that there's no
other difference in the strings outside of case to order on, at which
point we tie-break to provide a stable sort.
Natural number sorting is still preserved, and mixing different cases
alphabetically (as opposed to all lowercase alpha, followed by all
uppercase alpha) is preserved.
Closes#41080
Release Notes:
- Fixed: ProjectPanel sorting bug
Screenshots:
Before | After
----|---
<img width="237" height="325" alt="image"
src="https://github.com/user-attachments/assets/6e92e8c0-2172-4a8f-a058-484749da047b"
/> | <img width="239" height="325" alt="image"
src="https://github.com/user-attachments/assets/874ad29f-7238-4bfc-b89b-fd64f9b8889a"
/>
I'm having trouble reasoning through what was previously going wrong
with `docs` in the before screenshot, but it also seems to now appear
alphabetically where you'd expect it with this patch
---------
Co-authored-by: Smit Barmase <heysmitbarmase@gmail.com>
This adds additional comments which were left out from #42494 by
accident. Namely, it describes why we have additional custom
highlighting in `highlights.scm` for the Typescript grammar.
Release Notes:
- N/A
Closes#7844
This change uses tree-sitter highlights as a method of showing
typescript errors prettily, keeping regex as simple as possible:
<img width="832" height="446" alt="Screenshot 2025-11-11 at 3 40 24 PM"
src="https://github.com/user-attachments/assets/0b3b6cf1-4d4d-4398-b89b-ef5ec0df87ec"
/>
It covers three main areas:
1. Diagnostics
Diagnostics are now rendered with language-aware typescript, by
providing the project's language registry.
2. Vtsls
The LSP provider for typescript now implements the
`diagnostic_message_to_markdown` function in the `LspAdapter` trait, so
as to provide Diagnostics with \`\`\`typescript...\`\`\`-style code
blocks for any selection of typescript longer than one word. In the
single-word case, it simply wraps with \`\`
3. Typescript's `highlights.scm`
`vtsls` doesn't provide strictly valid typescript in much of its
messaging. Rather, it returns a message with snippets of typescript
values which are invalid. Tree-sitter was not properly highlighting
these snippets because it was expecting key-value formats. For instance:
```
type foo = { foo: string; bar: string; baz: number[] }
```
is valid, whereas simply
```
{ foo: string; bar: string; baz: number[] }
```
is not.
Therefore, highlights.scm needed to be adjusted in order to
pattern-match on literal values that might be returned from the vtsls
diagnostics messages. This was done by a) identifying arrow functions on
their own, and b) augmenting the `statment_block` pattern matching in
order to match on values which were clearly object literals.
This approach may not be exhaustive - I'm happy to work on any
additional cases we might identify from `vtsls` here - but hopefully
demonstrates an extensible approach to making these messages look nice,
without taking on the technical burden of extensive regex.
Release Notes:
- Show pretty TypeScript errors with language-aware Markdown.
- Improves the determinism of the search step for better cache
reusability
- Adds a `--cache force` mode that refuses to make any requests or
searches that aren't cached
- The structure of the `zeta-*` directories under `target` has been
rethought for convenience
Release Notes:
- N/A
---------
Co-authored-by: Agus <agus@zed.dev>
Closes #ISSUE
Improves error reporting for various failure modes of zeta2, including
failing to parse the `<old_text>`/`<new_text>` pattern, and the contents
of `<old_text>` failing to match.
Additionally, makes it so that evals are checked out into a worktree
with the _repo_ name instead of the _example_ name, in order to make
sure that the eval name has no influence on the models prediction. The
repo name worktrees are still namespaced by the example name like
`{example_name}/{repo_name}` to ensure evals pointing to the same repo
do not conflict.
Release Notes:
- N/A *or* Added/Fixed/Improved ...
---------
Co-authored-by: Agus <agus@zed.dev>
This PR introduces `Nearest` scrolling strategy to `UniformList`. This
is now used in completions menu and the picker to choose the appropriate
scrolling strategy depending on movement direction. Previously,
selecting the next element after the last visible item caused the menu
to scroll with `ScrollStrategy::Top`, which scrolled the whole page and
placed the next element at the top. This behavior is inconsistent,
because using `ScrollStrategy::Top` when moving up only scrolls one
element, not the whole page.
https://github.com/user-attachments/assets/ccfb238f-8f76-4a18-a18d-bbcb63340c5a
The solution is to introduce the `Nearest` scrolling strategy which will
internally choose the scrolling strategy depending on whether the new
selected item is below or above currently visible items. This ensures a
single-item scroll regardless of movement direction.
https://github.com/user-attachments/assets/8502efb8-e2c0-4ab1-bd8d-93103841a9c4
I also noticed that some functions in the file have different logic
depending on `y_flipped`. This appears related to reversing the order of
elements in the list when the completion menu appears above the cursor.
This was a feature suggested in #11200 and implemented in #23446. It
looks like this feature was reverted in #27765 and there currently seem
to be no way to have `y_flipped` to be set to `true`.
My understanding is that the opposite scroll strategy should be used if
`y_flipped`, but since there is no way to enable this feature to test it
and I don't know if the feature is ever going to be reintroduced I
decided not to include it in this PR.
Release Notes:
- gpui: Add 'Nearest' scrolling strategy to 'UniformList'
Closes#35142
In addition to cleaning up the terminals, also stops the conversation.
Release Notes:
- Restoring a checkpoint now stops the agent conversation.
Reverts zed-industries/zed#42480
This panics on Nightly in cases where anchor might not be valid for that
snapshot. Taking it back before the cutoff.
Release Notes:
- N/A
Update `Vim.change_surround` in order to ensure that there's no
overlapping edits by keeping track of where the open string range ends
and ensuring that the closing string range start does not go lower than
the open string range end.
Closes#42316
Release Notes:
- Fix vim's change surrounds `cs` inserting spaces with quotes by
preventing overlapping edits
---------
Co-authored-by: dino <dinojoaocosta@gmail.com>
- switch the bot from looking at the `bug/crash` labels which we don't
use anymore to the Bug/Crash issue types which we do use
- shorten the period of time after which a bug is suspected to be stale
(with our pace they can indeed be outdated in 60 days)
- extend the grace period for someone to come around and say nope, this
problem still exists (people might be away for a couple of weeks).
Release Notes:
- N/A
This reverts commit 082b80ec89.
This broke clicking, e.g. in snippets like
```rs
let x = vec![
1, 2, //
3,
];
```
clicking between `2` and `,` is quite off now.
Release Notes:
- N/A
Fixes a regression caused by #42135 where LSP and DAP binaries weren't
being used from `PATH` env var
Now we absolutize the path if (path is relative AND (path has multiple
components OR path exists in worktree)).
- Relative paths with multiple components might not exist in the
worktree because they are ignored. Paths with a single component will at
least have an entry saying that they exist and are ignored.
- Relative paths with multiple components will never use the `PATH` env
var, so they can be safely absolutized
Release Notes:
- N/A
<img width="395" height="444" alt="Screenshot 2025-11-11 at 4 04 57 PM"
src="https://github.com/user-attachments/assets/8da68721-6e33-4d01-810d-4aa1e2f3402d"
/>
Discussed with @danilo-leal and we're going with the "it's checked in
both places" design!
Closes#40910
Release Notes:
- Recommended AI models now still appear in their normal category in
addition to "Recommended:"
Closes https://github.com/zed-industries/zed/issues/37087
This PR adds an icon button to the footer of the message editor enabling
to trigger and interact with the @-mention completions menu with the
mouse. This is a first step towards making other types of context you
can add in Zed's agent panel more discoverable. Next, I want to improve
the discoverability of images and selections, given that you wouldn't
necessarily know they work in Zed without a clear way to see them. But I
think that for now, this is enough to close the issue above, which had
lots of productive comments and discussion!
<img width="500" height="540" alt="Screenshot 2025-11-11 at 10 46 3@2x"
src="https://github.com/user-attachments/assets/fd028442-6f77-4153-bea1-c0b815da4ac6"
/>
Release Notes:
- agent: Added an icon button in the agent panel that allows to trigger
the @-mention menu (for adding context) now also with the mouse.
This PR also adds items within the "Add Agent" menu to:
1. Add more agent servers from extensions, opening up the extensions
page with "Agent Servers" already filtered
2. Go to the agent server + ACP docs to learn more about them
I feel like having them there is a nice way to promote this knowledge
from within the product and have users learn more about them.
<img width="500" height="540" alt="Screenshot 2025-11-11 at 10 46 3@2x"
src="https://github.com/user-attachments/assets/9449df2e-1568-44d8-83ca-87cbb9eefdd2"
/>
Release Notes:
- agent: Enabled uninstalled agent servers from the agent panel's
settings view.
Closes#42303
Ollama added tool call identifiers
(https://github.com/ollama/ollama/pull/12956) in its latest version
[v0.12.10](https://github.com/ollama/ollama/releases/tag/v0.12.10). This
broke our json schema and made all tool calls fail.
This PR fixes the schema and uses the Ollama provided tool call
identifier when available. We remain backwards compatible and still use
our own identifier with older versions of Ollama. I added a `TODO` to
remove the `Option` around the new field when most users have updated
their installations to v0.12.10 or above.
Note to reviewer: The fix to this issue should likely get cherry-picked
into the next release, since Ollama becomes unusable as an agent without
it.
Release Notes:
- Fixed tool calling when using the latest version of Ollama
Release Notes:
- N/A
According to
[microsoft/vscode#254689](https://github.com/microsoft/vscode/issues/254689),
the json.schemastore.org domain has been deprecated and should now use
www.schemastore.org (or schemastore.org) instead.
This PR updates all occurrences of the old domain within the Zed
codebase,
including code, documentation, and configuration files.
The auto update helper already removes these when successful, so these
will always fail in the common case.
Additional replaces a mutable const with a static as otherwise we'll
rebuild the job list on every access
Release Notes:
- N/A *or* Added/Fixed/Improved ...
Lychee is a [Rust based](https://lychee.cli.rs) async parallel link
checker.
I ran it against the codebase to suss out stale links and fixed those
up.
There's currently 2 remaining cases that I don't know how to resolve:
1. https://flathub.org/apps/dev.zed.Zed - nginx is giving a 502 bad
gateway
2.
https://github.com/zed-industries/zed/actions/workflows/ci.yml/badge.svg
- I don't want to mess with the CI pipeline in this PR.
Once again, I'll punt to the Docs Czar to see if this gets incorporated
into CI later.
---
## Running `lychee` locally:
```
cargo binstall -y lychee
lychee .
```
---
Release Notes:
- N/A
Signed-off-by: mrg <miguelraz@ciencias.unam.mx>
Closes#36376
Problem:
Multi-cursor edits/selections in multi-buffers view were jumping to
incorrect locations after toggling buffer folds. When users created
multiple selections across different buffers in a multi-buffer view
(like project search results) and then folded one of the buffers,
subsequent text insertion would either:
1. Insert text at wrong locations (like at the top of the first unfolded
buffer)
2. Replace the entire content in some buffers instead of inserting at
the intended cursor positions
3. Create orphaned selections that caused corruption in the editing
experience
The issue seems to happen because when a buffer gets folded in a
multi-buffer view, the existing selections associated with that buffer
become invalid anchor points.
Solution:
1. Selection Cleanup on Buffer Folding
- Added `remove_selections_from_buffer()` method that filters out all
selections from a buffer when it gets folded
- This prevents invalid selections from corrupting subsequent editing
operations
- Includes edge case handling: if all selections are removed (all
buffers folded), it creates a default selection at the start of the
first buffer to prevent panics
2. Unfolding buffers before editing
- Added `unfold_buffers_with_selections()` call in `handle_input()`
ensures buffers with active selections are automatically unfolded before
editing
- This helps in fixing an edge case (covered in the tests) where, if you
fold all buffers in a multi-buffer view, and try to insert text in a
selection, it gets unfolded before the edit happens. Without this, the
inserted text would override the entire buffer content.
- If we don't care about this edge case, we could remove this method. I
find it ok to add since we already trigger buffer unfolding after edits
with `Event::ExcerptsEdited`.
Release Notes:
- Fixed multi-cursor edits jumping to incorrect locations after toggling
buffer folds in multi-buffer views (e.g, project search)
- Multi-cursor selections now properly handle buffer folding/unfolding
operations
- Text insertion no longer occurs at the wrong positions when buffers
are folded during multi-cursor editing
- Eliminated content replacement bugs where entire buffer contents were
incorrectly overwritten
- Added safe fallback behavior when all buffers in a multi-buffer view
are folded
---------
Co-authored-by: Smit Barmase <heysmitbarmase@gmail.com>
Update how the editor's `select_*` methods work in order to respect the
`search.case_sensitive` setting, or to be overriden by the
`BufferSearchBar` search options.
- Update both the `SearchableItem` and `SearchableItemHandle` traits
with a new `set_search_is_case_sensitive` method that allows callers
to set the case sensitivity of the search
- Update the `BufferSearchBar` to leverage
`SearchableItemHandle.set_search_is_case_sensitive` in order to sync
its case sensitivity options with the searchable item
- Update the implementation of the `SearchableItem` trait for `Editor`
so as to store the argument provided to the
`set_search_is_case_sensitive` method
- Update the way search queries are built by `Editor` so as to rely on
`SearchableItem.set_search_is_case_sensitive` argument, if not `None`,
or default to the editor's `search.case_sensitive` settings
Closes#41070
Release Notes:
- Improved the "Select Next Occurrence", "Select Previous Occurrence"
and "Select All Occurrences" actions in order to respect the case
sensitivity search settings
---------
Co-authored-by: Conrad Irwin <conrad.irwin@gmail.com>
- Introduce a `default_range` field to `VimCommand`, to be optionally
used when no range is specified for the command
- Update `VimCommand.parse` to take into consideration the
`default_range`
- Introduce `CommandRange::buffer` to obtain the `CommandRange` which
corresponds to the whole buffer
- Update the `VimCommand` definitions for both `sort` and `sort i` to
default to the whole buffer when no range is specified
Closes#41750
Release Notes:
- Improved vim's `:sort` command to sort the buffer's content when no
selection is used
Adds a simple notification when cloning a repo using the integrated git
clone on Zed. Before this, the user had no feedback after starting the
cloning action.
Demo:
https://github.com/user-attachments/assets/72fcdf1b-fc99-4fe5-8db2-7c30b170f12f
Not sure about that icon I'm using for the animation, but that can be
easily changed.
Release Notes:
- Added notification when cloning a repo from zed
We've had several outages with a proximate cause of "vercel is
complicated",
and auto-update is considered a critical feature; so lets not use vercel
for
that.
Release Notes:
- Auto Updates (and remote server binaries) are now downloaded via
https://cloud.zed.dev instead of https://zed.dev. As before, these URLs
redirect to the GitHub release for actual downloads.
Similar to #42246, we'd like to avoid having Vercel on the critical
path.
https://zed.dev/install.sh is served from Cloudflare by intercepting a
route on that page, so this makes the shell-based install flow vercel independent.
Release Notes:
- `./script/install.sh` will now fetch assets via
`https://cloud.zed.dev/`
instead of `https://zed.dev`. As before it will redirect to GitHub
releases
to complete the download.
Closes https://github.com/zed-industries/zed/issues/42312
The issue here was that we assumed that context servers provided by
extensions would always need a config in the settings to be present when
actually the opposite was the case - context servers provided by
extensions are the only context servers that do not need a config to be
in place in order to be available in the UI.
Release Notes:
- Fixed an issue where context servers provided by extensions could not
be uninstalled if they were previously unconfigured.
This PR drops the `channel_messages` table and its
dependents—`channel_message_mentions` and `observed_channel_messages`—as
they are no longer used.
Release Notes:
- N/A
Applications can select a policy for when the app quits using the new
function `Application::with_quit_mode`:
- Only on explicit calls to `App::quit`
- When the last window is closed
- Platform default (former on macOS, latter everywhere else)
Release Notes:
- N/A
There was a TODO in `crates/settings/src/settings_content/theme.rs` to
make this rename.
This PR is just splitting off this change from
https://github.com/zed-industries/zed/pull/40035 to make reviewing that
one a bit easier since that PR is a bit more involved than expected.
Release Notes:
- N/A
Signed-off-by: Connor Tsui <connor.tsui20@gmail.com>
Document "any-typed" (`serde_json::Value`) "lsp" keys to include them in
json-language-server completions.
The vscode-json-languageserver seems to skip generically typed keys when
offering completion.
For this schema
```
"LspSettings": {
"type": "object",
"properties": {
...
"initialization_options": true,
...
}
}
```
"initialization_options" is not offered in the completion.
The effect is easy to verify by triggering completion inside:
```
"lsp": {
"basedpyright": {
COMPLETE HERE
```
<img width="797" height="215" alt="image"
src="https://github.com/user-attachments/assets/d1d1391c-d02c-4028-9888-8869f4d18b0f"
/>
By adding a documentation string the keys are offered even if they are
generically typed:
<img width="809" height="238" alt="image"
src="https://github.com/user-attachments/assets/9a072da9-961b-4e15-9aec-3d56933cbe67"
/>
---
Note: I did some cursory research of whether it's possible to make
vscode-json-languageserver change behavior without success. IMO, not
offering completions here is a bug (or at minimal should be
configurable)
---
Release Notes:
- N/A
---------
Co-authored-by: Kirill Bulatov <mail4score@gmail.com>
The "Option" key only exists on a Mac. On other operating systems, it is
always expected that the Alt key generates escaped characters.
Fixes https://github.com/zed-industries/zed/issues/40583
Release Notes:
- N/A
Closes ZED-1SV
Closes ZED-TG
Closes ZED-22G
Closes ZED-22J
This seems to fix the reported error there, but ultimately, this might
benefit from a test to reproduce. Hence, marking as draft for now.
Release Notes:
- Fixed a rare panic whilst wrapping lines.
Closes#42191
This PR adds support for relative line numbers in deleted hunks. Note
that this only applies in cases where there is a form of relative
numbering.
It also adds some tests for this functionality as well as missing tests
for other cases in line layouting that was previously untested.
Release Notes:
- Line numbers will now be shown in deleted git hunks if relative line
numbering is enabled
This PR creates a dedicated function for the agent panel message
editor's placeholder text so that we can wait for the agent
initialization to capture whether they support slash commands or not. On
the one (nice) hand, this allow us to stop matching agents by name and
make this a bit more generic. On the other (bad) hand, the "/ for
commands" bit should take a little second to show up because we can only
know whether an agent supports it after it is initialized.
This is particularly relevant now that we have agents coming from
extensions and for them, we would obviously not be able to match by
name.
Release Notes:
- agent: Fixed agent panel message editor's placeholder text by making
it more accurate as to whether agents support slash commands,
particularly those coming from extensions.
This hopefully resolves the lingering test failures on linux,
but also adds some logging just in case this isn't the problem...
Release Notes:
- N/A
---------
Co-authored-by: Ben Kunkle <ben@zed.dev>
Closes#41214
Release Notes:
- Added support for relative paths in LSP and DAP binaries
---------
Co-authored-by: Cole Miller <cole@zed.dev>
Co-authored-by: Julia Ryan <juliaryan3.14@gmail.com>
Closes https://github.com/zed-industries/zed/issues/42356
This PR fixes the history view losing focus by simply always displaying
the search editor. I don't think it's too weird to not have it when it's
empty, and it also ends up matching how regular pickers work.
Release Notes:
- agent: Fixed a bug where navigating the agent panel with the keyboard
wouldn't work if you visited the history view and it was empty/had no
entries.
Update `GitStore.on_buffer_store_event` so that, when a
`BufferStoreEvent::BufferChangedFilePath` event is received, we check if
there's any diff state for the buffer and, if so, update it according to
the new file path, in case the file exists in the repository.
Closes#40499
Release Notes:
- Fixed issue with git diff tracking when updating a buffer's file from
an untracked to a tracked file
We'll now cache LLM responses at the request level (by hash of
URL+contents) for both context and prediction. This way we don't need to
worry about mistakenly using the cache when we change the prompt or its
components.
Release Notes:
- N/A
---------
Co-authored-by: Oleksiy Syvokon <oleksiy.syvokon@gmail.com>
New error variants were stabilized in 1.83, and this might've led to us
mis-handling not-a-directory errors.
Co-authored-by: Dino <dino@zed.dev>
Release Notes:
- N/A
Co-authored-by: Dino <dino@zed.dev>
Closes#42178
Now it's consistent with the DateAndTime path which already does
timezone conversion.
- **Future Work**
Happy to tackle the TODO in `time_format.rs` about implementing native
Windows APIs for proper localized formatting (similar to macOS's
`CFDateFormatter`) as a follow-up.
Release Notes:
- agent: Fixed the thread history item timestamp, which was being shown
in GMT instead of in the user's local timezone on Windows.
I ran [proselint](https://github.com/amperser/proselint) (recommended by
cURL author [Daniel
Stenberg](https://daniel.haxx.se/blog/2022/09/22/taking-curl-documentation-quality-up-one-more-notch/))
against all the `.md` files in the codebase to see if I could fix some
easy typos.
The tool is noisier than I would like and picking up the overrides to
the default config in a `.proselintrc.json` was much harder than I
expected.
There's many other small nits [1] that I believe are best left to your
docs czar whenever they want to consider incorporating a tool like this
into big releases or CI, but these seemed like small wins for now to
open a conversation about a tool like proselint.
---
[1]: Such nits include
- incosistent 1 or 2 spaces
- "color" vs "colour"
- ab/use of `very`
- awkward or superfluous phrasing.
Release Notes:
- N/A
Signed-off-by: mrg <miguelraz@ciencias.unam.mx>
Extract some of the improvements from to the unified diff prompt from
https://github.com/zed-industries/zed/pull/42171 and adds some other
about how context work to improve the reliability of predictions.
We also now strip the `<|user_cursor|>` marker if it appears in the
output rather than failing.
Release Notes:
- N/A
---------
Co-authored-by: Max Brunsfeld <maxbrunsfeld@gmail.com>
This change adds support for closing a system window tabs by pressing
the middle mouse button.
It improves tab management UX by matching common tab behavior.
Release Notes:
- Added support for closing system window tabs with middle mouse click.
Verified that this works locally. I modeled it after how basedpyright
and pyright work. Here is a screenshot of what it looks like (issue has
screenshots of the old state):
<img width="593" height="258" alt="Screenshot 2025-11-07 at 2 40 50 PM"
src="https://github.com/user-attachments/assets/5d2371fc-360b-422f-ba59-0a95f2083c87"
/>
Closes#42232
Release Notes:
- python/ty: Code completion menu now shows packages that will be
imported when a given entry is accepted.
In my local setup, I always enforce git-commit signing with GPG/SSH
which automatically enforces `git commit -S` when committing. This
changeset will now show a modal to the user for them to specify the
passphrase (if any) so that they can unlock their private key for
signing when committing in Zed.
<img width="1086" height="948" alt="Screenshot 2025-11-07 at 11 09
09 PM"
src="https://github.com/user-attachments/assets/ac34b427-c833-41c7-b634-8781493f8a5e"
/>
Release Notes:
- Handle automatic git-commit signing by presenting the user with an
askpass modal
I wanted to be able to work offline, so I made it a little bit more
convenient to point zeta2 at ollama.
* For zeta2, don't require that request ids be UUIDs
* Add an env var `ZED_ZETA2_OLLAMA` that sets the edit prediction URL
and model id to work w/ ollama.
Release Notes:
- N/A
Closes [#41674](https://github.com/zed-industries/zed/issues/41674)
Description:
Creating a branch from a base requires switching to the base branch
first, then creating the new branch and checking out to it, which
requires multiple operations.
Add base_branch parameter to create_branch to allow a new branch from a
base branch in one operation which is synonymous to the command `git
switch -c <new-branch> <base-branch>`.
Below is the video after solving the issue:
(`master` branch is the default branch here, and I create a branch
`new-branch-2` based off the `master` branch. I also show the error
which used to appear before the fix.)
[Screencast from 2025-11-07
05-14-32.webm](https://github.com/user-attachments/assets/d37d1b58-af5f-44e8-b867-2aa5d4ef3d90)
Release Notes:
- Fixed the branch-picking error by replacing multiple sequential switch
operations with just one switch operation.
Signed-off-by: ayu-ch <ayu.chandekar@gmail.com>
We can always include symbols, since we either include a ResourceLink to
the symbol (when `PromptCapabilities::embedded_context = false`) or a
Resource (when `PromptCapabilities::embedded_context = true`)
Release Notes:
- Fixed an issue where symbols could not be included when using specific
ACP agents
This PR adds a new component to the `language_models` crate called
`ConfiguredApiCard`:
<img width="500" height="420" alt="Screenshot 2025-11-09 at 2 07@2x"
src="https://github.com/user-attachments/assets/655ea941-2df8-4489-a4da-bba34acf33a9"
/>
We were previously recreating this component from scratch with regular
divs in all LLM providers render function, which was redundant as they
all essentially looked the same and didn't have any major variations
aside from labels. We can clean up a bunch of similar code with this
change, which is cool!
Release Notes:
- N/A
Improve the layout and text display of API key configuration in multiple
language model providers to ensure proper text wrapping and ellipsis
handling when API URLs are long.
Before:
<img width="320" alt="image"
src="https://github.com/user-attachments/assets/2f89182c-34a0-4f95-a43a-c2be98d34873"
/>
After:
<img width="320" alt="image"
src="https://github.com/user-attachments/assets/09bf5cc3-07f0-47bc-b21a-d84b8b1caa67"
/>
Changes include:
- Add proper flex layout with overflow handling
- Replace truncate_and_trailoff with CSS text ellipsis
- Ensure consistent UI behavior across all providers
Release Notes:
- Improved API key configuration display in language model settings
Fixes ZED-2CQ
We were doing the binary search by buffer points, but due to await
points within this function we could end up mixing points of differing
buffer versions.
Release Notes:
- N/A *or* Added/Fixed/Improved ...
- Enable Alt+Numpad input
- For this to be effective, the default keybindings for Alt+{Number}
will need to be unbound. This won't be needed once we gain the ability
to differentiate numpad digit keys from alphanumeric digit keys.
- Fixes https://github.com/zed-industries/zed/issues/40699
- Fix a number of edge cases with dead keys
Release Notes:
- N/A
Closes https://github.com/zed-industries/zed/issues/42276
This fixes the fact that the `AddSelectionToThread` action was visible
when `disable_ai` was true, as well as it improves its display by making
it either disabled or hidden when there are no selections in the editor.
I also ended up removing it from the app menu simply because making it
observe the `disable_ai` setting would be a bit more complex than I'd
like at the moment, so figured that, given I'm also now adding it to the
toolbar selection menu, we could do without it over there.
Release Notes:
- Fixed the `AddSelectionToThread` action showing up when `disable_ai`
is true
- Improved the `AddSelectionToThread` action display by only making it
available when there are selections in the editor
Follow up #40736
Clean up `CodeBlockRenderer::Custom` related rendering per the previous
PR
[comment](https://github.com/zed-industries/zed/pull/40736#issuecomment-3503074893).
Additional note here:
1. The `Custom` variant in the enum `CodeBlockRenderer` will become not
useful since cleaning all code related to the custom rendering logic.
2. Need to further review the usage of code block `metadata` field in
`MarkdownTag::CodeBlock` enum.
I would like to have the team further review my note above so that we
can make sure it will be safe to clean it up and will not affect any
potential future features will be built on top of it. Thank you!
Release Notes:
- N/A
## Summary
Adds explanations for what each type of scrollbar indicator visually
represents in the editor.
## Description
This PR addresses the issue where users didn't understand what the
colored marks on the scrollbar mean. The existing documentation
explained how to toggle each type of mark on/off, but didn't explain
what they actually represent.
This adds a brief, clear explanation after each scrollbar indicator
setting describing what that indicator shows (e.g., "Git diff indicators
appear as colored marks showing lines that have been added, modified, or
deleted compared to the git HEAD").
## Fixes
Closes#31794
## Test Plan
- Documentation follows the existing style and format of
`docs/src/configuring-zed.md`
- Each explanation is concise and immediately follows the setting
description
- Language is clear and user-friendly
Release Notes:
- N/A
Since we removed the filtering step during context gathering, we want
the model to perform more targeted searches. This PR tweaks search tool
schema allowing the model to search within syntax nodes such as `impl`
blocks or methods.
This is what the query schema looks like now:
```rust
/// Search for relevant code by path, syntax hierarchy, and content.
#[derive(Debug, Clone, Serialize, Deserialize, JsonSchema)]
pub struct SearchToolQuery {
/// 1. A glob pattern to match file paths in the codebase to search in.
pub glob: String,
/// 2. Regular expressions to match syntax nodes **by their first line** and hierarchy.
///
/// Subsequent regexes match nodes within the full content of the nodes matched by the previous regexes.
///
/// Example: Searching for a `User` class
/// ["class\s+User"]
///
/// Example: Searching for a `get_full_name` method under a `User` class
/// ["class\s+User", "def\sget_full_name"]
///
/// Skip this field to match on content alone.
#[schemars(length(max = 3))]
#[serde(default)]
pub syntax_node: Vec<String>,
/// 3. An optional regular expression to match the final content that should appear in the results.
///
/// - Content will be matched within all lines of the matched syntax nodes.
/// - If syntax node regexes are provided, this field can be skipped to include as much of the node itself as possible.
/// - If no syntax node regexes are provided, the content will be matched within the entire file.
pub content: Option<String>,
}
```
We'll need to keep refining this, but the core implementation is ready.
Release Notes:
- N/A
---------
Co-authored-by: Ben <ben@zed.dev>
Co-authored-by: Max <max@zed.dev>
Co-authored-by: Max Brunsfeld <maxbrunsfeld@gmail.com>
#42021 Made clicking on an excerpt title toggle it. This PR brings back
the old behavior if a user is pressing the Alt key when clicking on an
excerpt title.
Release Notes:
- N/A
---------
Co-authored-by: Remco Smits <djsmits12@gmail.com>
This is a follow up to #41482. When running `script/bundle-mac`, it will
upload debug symbols to Sentry if you have a `$SENTRY_AUTH_TOKEN` set. I
happen to have one set, so this script was trying to generate and upload
those. Whoops! This change skips the upload entirely if you're running a
local install.
Release Notes:
- N/A
Closes#41969
This was caused because scope names weren't being truncated unlike the
other type of variable list entries.
Release Notes:
- debugger: Fix bug where minimizing the width of the variable list
would cause scope names to overlap
Co-authored-by: Remco Smits <djsmits12@gmail.com>
When rust-analyzer is still loading the cargo project it tends to error
out on most lsp requests with `content modified`. This pollutes our
logs.
Release Notes:
- N/A *or* Added/Fixed/Improved ...
Technically these should not be possible to hit, but sentry says
otherwise. Turning these into errors should give us more information
than the abort due to unwinding across ffi boundaries.
Fixes ZED-321
Release Notes:
- N/A *or* Added/Fixed/Improved ...
Second take on https://github.com/zed-industries/zed/pull/37765.
This PR adds support for styling elements (**b**, **strong**, **em**,
**i**, **ins**, **del**), but also allow you to show the styling text
inline with the current text.
This is done by appending all the up-following text into one text chunk
and merge the highlights from both of them into the already existing
chunk. If there does not exist a text chunk, we will create one and the
next iteration we will use that one to store all the information on.
**Before**
<img width="483" height="692" alt="Screenshot 2025-11-06 at 22 08 09"
src="https://github.com/user-attachments/assets/6158fd3b-066c-4abe-9f8e-bcafae85392e"
/>
**After**
<img width="868" height="300" alt="Screenshot 2025-11-06 at 22 08 21"
src="https://github.com/user-attachments/assets/4d5a7a33-d31c-4514-91c8-2b2a2ff43e0e"
/>
**Code example**
```html
<p>some text <b>bold text</b></p>
<p>some text <strong>strong text</strong></p>
<p>some text <i>italic text</i></p>
<p>some text <em>emphasized text</em></p>
<p>some text <del>delete text</del></p>
<p>some text <ins>insert text</ins></p>
<p>Some text <strong>strong text</strong> more text <b>bold text</b> more text <i>italic text</i> more text <em>emphasized text</em> more text <del>deleted text</del> more text <ins>inserted text</ins></p>
<p><a href="https://example.com">Link Text</a></p>
<p style="text-decoration: underline;">text styled from style attribute</p>
```
cc @bennetbo
**TODO**
- [x] add tests for styling nested text that should result in one merge
Release Notes:
- Markdown Preview: Added support for `HTML` styling elements
---------
Co-authored-by: Bennet Bo Fenner <bennetbo@gmx.de>
Closes#40097
When multiple files are added sequentially to the agent panel, the
request JSON incorrectly includes "text" elements containing only
spaces. These empty elements cause the Zhipu AI API to return a "text
cannot be empty" error.
The fix filters out any "text" elements that are empty or contain only
whitespaces.
UI state when the error occurs:
<img width="300" alt="Image"
src="https://github.com/user-attachments/assets/c55e5272-3f03-42c0-b412-fa24be2b0043"
/>
Request JSON (causing the error):
```
{
"model": "glm-4.6",
"messages": [
{
"role": "system",
"content": "<<CUT>>"
},
{
"role": "user",
"content": [
{
"type": "text",
"text": "[@1.txt](zed:///agent/file?path=C%3A%5CTemp%5CTest%5C1.txt)"
},
{ "type": "text", "text": " " },
{
"type": "text",
"text": "[@2.txt](zed:///agent/file?path=C%3A%5CTemp%5CTest%5C2.txt)"
},
{ "type": "text", "text": " describe" },
```
Release Notes:
- Fixed an issue when an OpenAI request contained whitespace-only text content
Co-authored-by: Bennet Bo Fenner <bennetbo@gmx.de>
### Summary
Restore the agent pane’s code-block horizontal scrollbar for easier
scrolling without trackpad and preserve individual scroll state across
multiple code blocks.
### Motivation
Addresses https://github.com/zed-industries/zed/issues/34224, where
agent responses with wide code snippets couldn’t be scrolled
horizontally in the panel. Previously there is no visual effect for
scrollbar to let the user move the code snippet and it was not obviously
to use trackpad or hold down `shift` while scrolling. This PR will
ensure the user being able to only use their mouse to drag the
horizontal scrollbar to show the complete line when the code overflow
the width of code block.
### Changes
- Support auto-hide horizontal scrollbar for rendering code block in
agent panel by adding scrollbar support in markdown.rs
- Add `code_block_scroll_handles` cache in
_crates/markdown/src/markdown.rs_ to give each code block a persistent
`ScrollHandle`.
- Wrap rendered code blocks with custom horizontal scrollbars that match
the vertical scrollbar styling and track hover visibility.
- Retain or clear scroll handles based on whether horizontal overflow is
enabled, preventing leaks when the markdown re-renders.
### How to Test
1. Open the agent panel, request code generation, and ensure wide
snippets show a horizontal scrollbar on hover.
3. Scroll horizontally, navigate away (e.g., change tabs or trigger a
re-render), and confirm the scroll position sticks when returning.
5. Toggle horizontal overflow styling off/on (if applicable) and verify
scrollbars appear or disappear appropriately.
### Screenshots / Demos (if UI change)
https://github.com/user-attachments/assets/e23f94d9-8fe3-42f5-8f77-81b1005a14c8
### Notes for Reviewers
- This is my first time contribution for `zed`, sorry for any code
patten inconsistency. So please let me know if you have any comments and
suggestions to make the code pattern consistent and easy to maintain.
- For now, the horizontal scrollbar is not configurable from the setting
and the style is fixed with the same design as the vertical one. I am
happy to readjust this setting to fit the needs.
- Please let me know if you think any behaviors or designs need to be
changed for the scrollbar.
- All changes live inside _crates/markdown/src/markdown.rs_; no API
surface changes.
Closes#34224
### Release Notes:
- AI: Show horizontal scroll-bars in wide markdown elements
Closes#40576
This PR makes Conda activation configurable and transparent by adding a
`terminal.detect_venv.on.conda_manager` setting (`"auto" | "conda" |
"mamba" | "micromamba"`, default `"auto"`), updating Python environment
activation to honor this preference (or the detected manager executable)
and fall back to `conda` when necessary.
The preference is passed via `ZED_CONDA_MANAGER` from the terminal
settings, and the activation command is built accordingly (with proper
quoting for paths). Changes span
`zed/crates/terminal/src/terminal_settings.rs` (new `CondaManager` and
setting), `zed/crates/project/src/terminals.rs` (inject env var),
`zed/crates/languages/src/python.rs` (activation logic), and
`zed/assets/settings/default.json` (document the setting). Default
behavior remains unchanged for most users while enabling explicit
selection of `mamba` or `micromamba`.
Release Notes:
- Added: terminal.detect_venv.on.conda_manager setting to choose the
Conda manager (auto, conda, mamba, micromamba). Default: auto.
- Changed: Python Conda environment activation now respects the
configured manager, otherwise uses the detected environment manager
executable, and falls back to conda.
- Reliability: Activation commands quote manager paths to handle spaces
across platforms.
- Compatibility: No breaking changes; non-Conda environments are
unaffected; remote terminals are supported.
---------
Co-authored-by: Lukas Wirth <me@lukaswirth.dev>
Co-authored-by: Lukas Wirth <lukas@zed.dev>
Supersedes https://github.com/zed-industries/zed/pull/39910
At some point, these two (`index_for_x` and `closest_index_for_x`)
methods where separated out and some code paths used one, while other
code paths took the other. That said, their behavior is almost
identical:
- `index_for_x` computes the index behind the pixel offset, and returns
`None` if there's an overshoot
- `closest_index_for_x` computes the nearest index to the pixel offset,
taking into account whether the offset is over halfway through or not.
If there's an overshoot, it returns the length of the line.
Given these two behaviors, `closest_index_for_x` seems to be a more
useful API than `index_for_x`, and indeed the display map and other core
editor features use it extensively. So this PR is an experiment in
simply replacing one behavior with the other.
Release Notes:
- Improved the accuracy of mouse selections in Markdown
Release Notes:
- N/A
---
https://github.com/user-attachments/assets/d46b77ae-88ba-43da-93ad-3656a7fecaf9
The system menu is only support for macOS, so here just modify the macOS
platform special code.
The Windows, Linux used `ApplicationMenu`, I have already added
`checked` option to Zed's ContextMenu.
Then later when this PR merged, we can improve "View" menu to show check
state to panels (Project Panel, Outline Panel, ...).
* Fix a panic that happened because we lost the
`ContextRetrievalStarted` debug message, so we didn't assign `t0`.
* Write the edit prediction response log file as a markdown file
containing the text, not a JSON file. We mostly always want the text
content.
Release Notes:
- N/A
If we are in a remote session with the remote dropped, this path is very
much reachable if the call to this function got queued up in a task.
Fixes ZED-124
Release Notes:
- N/A *or* Added/Fixed/Improved ...
Previously, staging a large file in the git panel would block the UI
items until that operation finished. This is due to the fact that
staging is a git op that is locked globally by git (per repo) meaning
only one op that is modifying the git index can run at any one time. In
order to make the UI snappy while letting any pending git staging jobs
to finish in the background, we track their progress via `PendingOps`
indexed by git entry path. We have already had a concept of pending
operations however they existed at the UI layer in the `GitPanel`
abstraction. This PR moves and augments `PendingOps` into the model
`Repository` in `git_store` which seems like a more natural place for
tracking running git jobs/operations. Thanks to this, pending ops are
now stored in a `SumTree` indexed by git entry path part of the
`Repository` snapshot, which makes for efficient access from the UI.
Release Notes:
- Improved UI responsiveness when staging/unstaging large files in the
git panel
* Allow expressing alternative possible context fetches in `Expected
Context` section
* Allow marking a subset of lines as "required" in `Expected Context`.
We still need to improve how we display the results. I've removed the
context pass/fail pretty printing for now, because it would need to be
rethought to work with the new structure, but for now I think we should
focus on getting basic predictions to run. But this is progress toward a
better structure for eval examples.
Release Notes:
- N/A
---------
Co-authored-by: Oleksiy Syvokon <oleksiy.syvokon@gmail.com>
Co-authored-by: Ben Kunkle <ben@zed.dev>
Co-authored-by: Agus Zubiaga <agus@zed.dev>
Our new linux runners don't have powershell installed which causes the
`release-winget` job to fail. This simply runs that step on windows
instead.
Release Notes:
- N/A
Adds support for opening and displaying images in remote projects. The
server streams image data to the client in chunks, where the client then
reconstructs the image and displays it. This change includes:
- Adding `image` crate as a dependency for remote_server
- Implementing `ImageStore` for remote access
- Creating proto definitions for image-related messages
- Adding handlers for creating images for peers
- Computing image metadata from bytes instead of reading from disk for
remote images
Closes#20430Closes#39104Closes#40445
Release Notes:
- Added support for image preview in remote sessions.
- Fixed#39104
<img width="982" height="551" alt="image"
src="https://github.com/user-attachments/assets/575428a3-9144-4c1f-b76f-952019ea14cc"
/>
<img width="978" height="547" alt="image"
src="https://github.com/user-attachments/assets/fb58243a-4856-4e73-bb30-8d5e188b3ac9"
/>
---------
Co-authored-by: Julia Ryan <juliaryan3.14@gmail.com>
Agents running in extensions need to have a root directory of the
extension's dir for installation and authentication, but *not* for the
conversation itself - otherwise the agent is running things like
terminal commands in the wrong dir.
Release Notes:
- Fixed Agent Server extensions having the current working directory of
the extension rather than the project
Closes https://github.com/zed-industries/zed/issues/41407
This PR fixes the issues that caused #41407 to be reverted in #42008.
Namely that the action context didn't take into account if a snippet
could move backwards or forwards, and the action shared the same key
mapping as `editor::MoveToPreviousWordStart` and
`editor::MoveToNextWordEnd`.
I changed the default key mapping for the move to snippet tabstop to tab
and shift-tab to match the default behavior of other editors.
Release Notes:
- Editor: Add actions to move between snippet tabstop positions
I really need this for embedded development in IDF and Zephyr, where the
chip vendors sometimes provide there own specialized version of the
tools, and I need to direct zed to use these.
The current GDB adapter only supports the gdb it find in the normal
search path, and it also seems like we where not able to transfer gdb
specific startup arguments (only `-i=dap` is set) .
In order to fix this I (semi wipe using GPT-4.1) expanded the GDB
adapter with 2 new config options :
* **gdb_path** holds a full path to the gdb executable, for now only
full path or relative to cwd
* **gdb_args** an array holding additional arguments given to gdb on
startup
It seemed to me, like the `env` config did not transferred to gdb, so
this is added to.
I have tested this locally, and it seems to work not only compile :-)
Release Notes:
debugger: Adds gdb_path and gdb_args to gdb debug adapter options
debugger: Fix bug where gdb debug sessions wouldn't inherit the shell
environment from Zed
---------
Co-authored-by: Anthony <anthony@zed.dev>
Given that when we lose our devices unrecoverably we will panic anyways,
might as well do so eagerly which makes it clearer.
Additionally this PR replaces all uses of `ManuallyDrop` with `Option`,
as otherwise we need to do manual bookkeeping of what is and isn't
initialized when we try to recover devices as we can bail out halfway
while recovering. In other words, the code prior to this was fairly
unsound due to freely using `ManuallyDrop::drop`.
Fixes ZED-1SS
Release Notes:
- N/A *or* Added/Fixed/Improved ...
Fix bundled file persistence by introducing SerializationMode enum
Closes: #38094
What's the issue?
Opening bundled files like Default Key Bindings
(zed://settings/keymap-default.json) was causing SQLite foreign key
constraint errors. The editor was trying to save state for these
read-only assets just like regular files, but since bundled files don't
have database entries, the foreign key constraint would fail.
The fix
Replaced the boolean serialize_dirty_buffers flag with a type-safe
SerializationMode enum:
```rust
pub enum SerializationMode {
Enabled, // Regular files persist across sessions
Disabled, // Bundled files don't persist
}
```
This prevents serialization at the source: workspace_id() returns None
for disabled editors, serialize() bails early, and should_serialize()
returns false. When opening bundled files, we set the mode to Disabled
from the start, so they're treated as transient views that never
interact with the persistence layer.
Changes
- editor.rs: Added SerializationMode enum and updated serialization
methods to respect it
- items.rs: Guarded should_serialize() to prevent disabled editors from
being serialized
- zed.rs: Set SerializationMode::Disabled in open_bundled_file()
Result
Bundled files open cleanly without SQLite errors and don't persist
across workspace reloads (expected behavior). Regular file persistence
remains unaffected.
Release Notes: Fixed SQLite foreign key constraint errors when opening
bundled files like Default Key Bindings.
---------
Co-authored-by: MrSubidubi <finn@zed.dev>
Now that agent servers are a thing, this is the primary and easiest way
to quickly add more agents to Zed, without touching any settings JSON
file. :)
Release Notes:
- N/A
Improves formatting consistency across various docs, fixes some typos,
and adds a missing `debug_assert_paint` to `Window::on_action` and
`Window::on_action_when`.
Release Notes:
- N/A
Closes#41850
When digging into this I figured out that basically what was going on is
in the history of the file finder it doesn't update the name of the file
duplicated because when you duplicate a file it's named automatically
with `filename copy` and so this filename was added to the history but
not updated so once you wanted to go back into this file it was not part
of file finder displayed history anymore because this file doesn't exist
anymore but the entity id remains the same.
I was also to reproduce this bug when just renaming a file.
Release Notes:
- Fixed: Display duplicated file in file finder history
---------
Signed-off-by: Benjamin <5719034+bnjjj@users.noreply.github.com>
Co-authored-by: Conrad Irwin <conrad.irwin@gmail.com>
Co-authored-by: Lukas Wirth <me@lukaswirth.dev>
Closes#41975.
This change adjusts some of the ranges which were incorrectly labeled or
excluded characters. The new ranges include three codepoints which are
not assigned in Nerd Fonts. However, one of these codepoints were
already included prior to this change. These codepoints are:
- U+E0C9, between the two ice separators
- U+E0D3, between the two trapezoid separators. The ranges prior to this
PR already included this one.
- U+E0D5, between the trapezoid separators and the inverted triangle
separators
I included these so as to not overcomplicate the ranges by
cherry-picking the defined codepoints. That being said, if we're okay
with this and an additional unassigned codepoint (U+E0CB, between ice
separators and honeycomb separators) being included then a simple range
from 0xE0B0 to 0xE0D7 nicely includes all of the Powerline characters.
I wasn't sure how to write tests for this so I just added two characters
to the existing tests which were previously not covered lol. All of the
Powerline characters can be seen
[here](https://www.nerdfonts.com/cheat-sheet) by searching `nf-pl`.
Release Notes:
- Fixed certain Powerline characters incorrectly having terminal
contrast adjustment applied.
- Updated `blame_ui.rs`, `branch_picker.rs`, `commit_tooltip.rs`, and
`commit_view.rs` to replace the previous timestamp formatting with
`chrono` for better accuracy in local time representation.
- Introduced `chrono::Local::now().offset().local_minus_utc()` to obtain
the local offset for timestamp formatting.
Closes#40878
Release Notes:
- Improved timestamp handling in various Git UI components for enhanced
user experience.
- Clarify about first-party supported features in external agents
- Create new section for selection as context for higher visibility
- Add keybindings for agent profiles
- Fix outdated setting using `assistant` instead of `agent`
- Add keybinding for accessing the rules library
Release Notes:
- N/A
Part of #11043.
Codeberg is a public instance of Forgejo, as confirmed by the API
documentation at https://codeberg.org/api/swagger. Therefore, I renamed
the related component from codeberg to forgejo and added codeberg.org as
a public instance.
Furthermore, to optimize request speed for the commit API, I set
`stat=false&verification=false&files=false`.
<img width="1650" height="1268" alt="CleanShot 2025-11-03 at 19 57
06@2x"
src="https://github.com/user-attachments/assets/c1b4129e-f324-41c2-86dc-5e4f7403c046"
/>
<br/>
<br/>
Regarding Gitea Support:
Forgejo is a fork of Gitea, and their APIs are currently identical
(e.g., for getting avatars). However, to future-proof against potential
API divergence, I decided to treat them as separate entities. The
current gitea implementation is essentially a copy of the forgejo file
with the relevant type names and the public instance URL updated.
Release Notes:
- Added Support for Forgejo and Gitea avatars in git blame
Release Notes:
- N/A
When I was implementing Input, I often used `TextRun`, but `background`,
`underline` and `strikethrough` were often not used.
So make change to simplify it.
Closes#36206
Disclaimer: I did use AI for help to end up with this proposed solution.
😅
## Observed behavior of native apps on macOS (like Safari)
I first did a quick research on how Safari behaves on macOS, and here's
what I have found:
1. Safari seems to position new windows with an offset based on the
currently active window
2. It keeps opening new windows with an offset until the new window
cannot fit the display bounds horizontally, vertically or both.
3. When it cannot fit horizontally, the new window opens at x=0
(y=active window's y)
4. When it cannot fit vertically, the new window opens at y=0 (x=active
window's x)
5. When it cannot fit both horizontally and vertically, the new window
opens at x=0 and y=0 (top left).
6. At any moment if I activate a different Safari window, the next new
window is offset off of that
7. If I resize the active window and open a new window, the new window
has the same size as the active window
So, I implemented the changes based on those observations.
I am not sure if touching `gpui/src/window.rs` is the way to go. I am
open to feedback and direction here.
I am also not sure if making my changes platform (macOS) specific, is
the right thing to do. I reckoned that Linux and Windows have different
default behaviors, and the original issue mentioned macOS. But,
likewise, I am open to take a different approach.
## Tests
I haven't included tests for such change, as it seems to me a bit
difficult to properly test this, other than just doing a manual
integration test. But if you would want them for such a change, happy to
try including them.
## Alternative approach
I also did some research on macOS native APIs that we could use instead
of trying to make the calculations ourselves, and I found
`NSWindow.cascadeTopLeftFromPoint` which seems to be doing exactly what
we want, and more. It probably takes more things into consideration and
thus it is more robust. We could go down that road, and add it to
`gpui/src/platform/mac/window.rs` and then use it for new window
creation. Again, if that's what you would do yourselves, let me know and
I can either change the implementation here, or open a new pull request
and let you decide which one would you would like to pursue.
## Video showing the behavior
https://github.com/user-attachments/assets/f802a864-7504-47ee-8c6b-8d9b55474899🙇♂️
Release Notes:
- Improved macOS new window stacking
- On macOS, pasting now inserts the actual file path when the clipboard
contains a file URL (public.file-url/public.url)
- Terminal paste remains text-only; no temp files or data URLs are
created. If only raw image bytes exist on the clipboard, paste is a
no-op.
- Scope: macOS only; no dependency changes.
- Added a test (test_file_url_converts_to_path) that verifies URL→path
conversion using a unique pasteboard.
Release Notes:
- Improved pasting on macOS: now inserts the actual file path when the
clipboard contains a file URL (enables image paste support for Claude
Code)
On macOS, the Function key is reserved for system use and should not be
used in application code.
This commit updated keystroke matching and key event handling to ignore
the Function key modifier while users are typing or pressing
keybindings.
For some keyboards with compact layout (like my 65% keyboard), there is
no separated backtick key. Esc and it shares the same physical key. To
input backtick, users may press `Fn-Esc`. However, macOS will still
deliver events with Fn key modifier to applications. Cocoa framework can
handle this correctly, which typically ignore the Fn directly. GPUI
should also follow the same rule, otherwise, the backtick key on those
keyboards won't work.
Release Notes:
- Fixed a bug where typing fn-\` on macOS would not insert a `.
This makes it possible to do login via things like `cmd: "node", args:
["my-node-file.js", "login"]`
Also, that command will now use Zed's managed `node` instance.
Release Notes:
- ACP extensions can now run terminal login commands using relative
paths
Closes#41471
We were killing the crash handler when it received a second copy of any
of the messages, but this GPU specs one is sent on each new window
rather than once at startup. We could gate the sending to only happen
once, but it's simpler to just allow multiple gpu specs messages.
Release Notes:
- N/A
## Summary
Fixes#36754
This PR fixes an issue where LSPs fail to spawn after the crash handler
is initialized.
## Problem
After PR #35263 added minidump crash reporting, some users experienced
LSP spawn failures. The issue manifests as:
- LSPs fail to spawn with no clear error messages
- The problem only occurs after crash handler initialization
- LSPs work when a debugger is attached, revealing a timing issue
### Root Cause
The crash handler installs Mach exception ports for minidump generation.
Due to a timing issue, child processes inherit these exception ports
before they're fully stabilized, which can block child process spawning.
## Solution
Reset exception ports in child processes using the `pre_exec()` hook,
which runs after `fork()` but before `exec()`. This prevents children
from inheriting the parent's crash handler exception ports.
### Implementation
- Adds macOS-specific implementation of `new_smol_command()` that resets
exception ports before exec
- Calls `task_set_exception_ports` to reset all exception ports to
`MACH_PORT_NULL`
- Graceful error handling: logs warnings but doesn't fail process
spawning if port reset fails
Release Notes:
- Fixed LSPs failing to spawn on some macOS systems
---------
Co-authored-by: Julia Ryan <juliaryan3.14@gmail.com>
The Alt+Numpad buffer that's maintained by the input stack is getting
corrupted, leading to garbage characters being inserted on keystrokes
like Alt+Up. Disable the automatic handling of Alt+Numpad for now until
the cause of this corruption is understood. The Alt+Numpad input did not
work anyway, so this does not regress anything.
Release Notes:
- windows: Fixed corrupted characters being inserted when Alt is pressed
(preview only)
Release Notes:
Updated how clicking on multi-buffer headers works to provide better
control and prevent unexpected navigation:
Clicking the header now collapses/expands the file section instead of
opening the file.
Opening files can be done by clicking the filename or the "Open file"
button on the right side of the header.
Existing shortcuts continue to work: use the left chevron to collapse or
your keyboard shortcut to jump to the file
**Demo:**
https://github.com/user-attachments/assets/dca9ccc5-bd98-416c-97af-43b4e4b2f903
Reverts zed-industries/zed#41466
This PR would add "in_snippet" context when there wasn't a completion
menu visible, causing some actions to not be hit.
Release Note:
- N/A
This PR changes the loading/generating indicator when in the "waiting
for tool call confirmation" state so that's a bit more visible and
discernible as needing your attention, as opposed to a regular
generating state.
<img width="400" alt="Screenshot 2025-11-05 at 10 46@2x"
src="https://github.com/user-attachments/assets/88adbf97-20fb-49c4-9c77-b0a3a22aa14e"
/>
Release Notes:
- agent: Improved the "waiting for confirmation" state visibility so
that you more rapidly know the agent is waiting for you to act.
Mostly just removing "thread" from all external agent menu items; I
think we can do without it and it already becomes much better/cleaner.
Release Notes:
- N/A
I am using an Azure OpenAI instance since that is what is provided at
work and with how they have it setup not all responses contain a delta,
which lead to errors and truncated responses. This is related to how
they are filtering potentially offensive requests and responses. I don't
believe this filter was made in-house, instead I believe it is provided
by Microsoft/Azure, so I suspect this fix may help other users.
Release Notes:
- N/A
Co-authored-by: Bennet Bo Fenner <bennetbo@gmx.de>
This brings the documentation on Java in line with the much changed
reality of the Java extension.
Note that the correctness of this is contingent on
https://github.com/zed-industries/extensions/pull/3745 being merged.
Release Notes:
- N/A
Closes#40632
**TL;DR:** The `wrap selections in tag` action was unavailable in ERB
files, even when the cursor was positioned in HTML content (outside of
Ruby code blocks). This happened because `syntax_layer_at()` incorrectly
returned the Ruby language for positions that were actually in HTML.
**NOTE:** I am not familiar with that part of Zed so it could be that
the fix here is completely incorrect.
Previously, `syntax_layer_at` incorrectly reported injected languages
(e.g., Ruby in ERB files) even when the cursor was in the base language
content (HTML). This broke actions like `wrap selections in tag` that
depend on language-specific configuration.
The issue had two parts:
1. Missing start boundary check: The filter only checked if a layer's
end was after the cursor (`end_byte() > offset`), not if it started
before, causing layers outside the cursor position to be included. See
the `BEFORE` video: when I click on the HTML part it reports `Ruby`
language instead of `HTML`.
2. Wrong boundary reference for injections: For injected layers with
`included_sub_ranges` (like Ruby code blocks in ERB), checking the root
node boundaries returned the entire file range instead of the actual
injection ranges.
This fix:
- Adds the containment check using half-open range semantics [start,
end) for root node boundaries. That ensures proper reporting of the
detected language when a cursor (`|`) is located right after the
injection:
```
<body>
<%= yield %>|
</body>
```
- Checks `included_sub_ranges` for injected layers to determine if the
cursor is actually within an injection
- Falls back to root node boundaries for base layers without sub-ranges.
This is the original behavior.
Fixes ERB language support where actions should be available based on
the cursor's actual language context. I think that also applies to some
other template languages like HEEX (Phoenix) and `*.pug`. On short
videos below you can see how I navigate through the ERB template and the
terminal on the right outputs the detected language if you apply the
following patch:
```diff
diff --git i/crates/editor/src/editor.rs w/crates/editor/src/editor.rs
index 15af61f5d2..54a8e0ae37 100644
--- i/crates/editor/src/editor.rs
+++ w/crates/editor/src/editor.rs
@@ -10671,6 +10671,7 @@ impl Editor {
for selection in self.selections.disjoint_anchors_arc().iter() {
if snapshot
.language_at(selection.start)
+ .inspect(|language| println!("Detected language: {:?}", language))
.and_then(|lang| lang.config().wrap_characters.as_ref())
.is_some()
{
```
**Before:**
https://github.com/user-attachments/assets/3f8358f4-d343-462e-b6b1-3f1f2e8c533d
**After:**
https://github.com/user-attachments/assets/c1b9f065-1b44-45a2-8a24-76b7d812130d
Here is the ERB template:
```
<!DOCTYPE html>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<style>
/* Email styles need to be inline */
</style>
</head>
<body>
<%= yield %>
</body>
</html>
```
Release Notes:
- N/A
Hi, this is a follow-up change for
https://github.com/zed-industries/zed/pull/41754 I think it important to
keep existing things working. So add notes to the Ruby extension doc
about enabling Ruby LSP for ERB files as well. Thanks!
Release Notes:
- N/A
Works around an issue, which can be reproduced in the following program:
```rs
use windows::Win32::UI::Input::KeyboardAndMouse::{GetKeyboardState, VK_CONTROL};
fn main() {
let mut keyboard_state = [0u8; 256];
unsafe {
GetKeyboardState(&mut keyboard_state).unwrap();
}
let ctrl_down = (keyboard_state[VK_CONTROL.0 as usize] & 0x80) != 0;
println!("Is Ctrl down: {ctrl_down}");
}
```
In debug mode, this program prints the correct answer. In release mode,
it always prints false. The optimizer appears to think that
`keyboard_state` isn't mutated and remains zeroed, and folds the
`modifier_down` comparisons to `false`.
Release Notes:
- N/A
As discussed with @benbrandt and @mikayla-maki:
* We now tell ACP clients we support the nonstandard `terminal-auth`
`_meta` field for terminal-based authentication
* In the future, we anticipate ACP itself supporting *some* form of
terminal-based authentication, but that hasn't been designed yet or gone
through the RFD process
* For now, this unblocks terminal-based auth
Release Notes:
- Added experimental terminal-based authentication to ACP support
This has been possible in the inline assistant for ages now and maybe
you didn't know because we didn't say anything about it! This PR fixes
that by including that you can @-mention context on it the same you can
in the agent panel.
Release Notes:
- N/A
Closes #ISSUE
More accurately map localhost to `127.0.0.1`. Previously we would
lowercase and simply replace all instances of localhost inside of the
URL string, meaning query parameters, username, password etc. could not
contain the string `localhost` or contain uppercase letters without
getting modified. Added a test ensuring the mapping logic works. The
previous implementation would fail this new test.
Release Notes:
- Improved the behavior of mapping `localhost` to `127.0.0.1` when
passing configured proxy urls to `node`
### Summary
This PR changes `gpui/build.rs` to look up the Windows SDK directory in
the registry instead of falling back to a hard-coded path.
---
### Problem
Currently, building `gpui` on Windows requires `fxc.exe` to be in `PATH`
or at a predefined location (unless `GPUI_FXC_PATH` is set). This
requires to maintain a certain build environment with proper paths/vars
or to install the specific SDK version.
It is possible to find the SDK automatically using the registry keys it
creates upon installation. Specifically in
`SOFTWARE\\WOW6432Node\\Microsoft\\Microsoft SDKs\\Windows\\v10.0`
branch there are:
* `InstallationFolder` telling the SDK installation location;
* `ProductVersion` telling the SDK version in use.
These keys provide enough information to locate the SDK binaries, with
added robustness:
* handles non-standard SDK installation path;
* deterministically selects the latest SDK when multiple versions are
present.
---
### Changes Made
* **Updated `crates/gpui/build.rs`**:
* added dependency on `winreg`
* introduced `find_latest_windows_sdk_binary()` helper
* updated fallback logic to use registry lookup
This PR only changes the fallback location, and does not touch the
established environment-based workflow.
Release Notes:
- N/A
---
### Impact
Reduces manual configuration needed to build GPUI on Windows.
---------
Co-authored-by: John Tur <john-tur@outlook.com>
Closes#41457#41806#41801
Copilot started using `node:sqlite` module which is an experimental
feature between node v22-v23 (stable in v24). The fix was passing in the
experimental flag when Zed starts the copilot LSP.
I tested this with v20.19.5 and v24.11.0. The fix got v20.19 working and
didn't affect v24.11 which was already working.
Release Notes:
- AI: Fix Github Copilot edit predictions failing to start
Closes#41774
Release Notes:
- settings_ui: Fixed an integer underflow panic when attempting to hit
the `-` sign on settings item that take delays in milliseconds
`ICustomDestinationList::AppendCategory` rejects an empty `IObjectArray`
and returns an `E_INVALIDARG` error. Error propagated and caused an
early-return from `update_jump_list()`.
<img width="1628" height="540" alt="image"
src="https://github.com/user-attachments/assets/f8143297-c71e-42a1-a505-66cd77dfa599"
/>
Release Notes:
- N/A
- lsp: Fix dynamic registration of diagnostic capabilities not taking
effect when an initial capability is not specified
Gist of the issue lies within use of .get_mut instead of .entry. If we
had not created any dynamic capability beforehand, we'd miss a
registration, essentially
- **Determine whether to update remote caps in a smarter manner**
Release Notes:
- Fixed document diagnostics with Ty language server.
Closes#41533
Both of the issues in the release notes that are fixed in this PR, were
caused by incorrect usage of the `window.use_state` API.
The first issue was caused by calling `window.use_state` in a render
helper, resulting in the element ID used to share state being the same
across different pages, resulting in the state being re-used when it
should have been re-created. The fix for this was to move the
`window.state` (and rendering logic) into a `impl RenderOnce` component,
so that the IDs are resolved during the render, avoiding the state
conflicts.
The second issue is caused by using a `move` closure in the
`window.use_state` call, resulting in stale closure values when the
window state is re-used.
Release Notes:
- settings_ui: Fixed an issue where some dropdown menus would show
options from a different dropdown when clicked
- settings_ui: Fixed an issue where attempting to change a setting in a
dropdown back to it's original value after changing it would do nothing
This PR implements the `zeta-cli eval` command. It will:
- Run the edit prediction model if there are no cached results
- Compute precision/recall/F1 for context retrieval at the line level:
every retrieved line of context is counted as a true positive (correct
retrieval), false positive (retrieved something that was not expected),
or false negative (didn't retrieve an expected line)
- Compute similar metrics for edit predictions
- Pretty-print results, highlighting the difference between actual and
expected when printing to tty
Other changes:
- `zeta-cli predict` accepts a `--format` argument with options `md`,
`json`, `diff`
- Code restructure
Release Notes:
- N/A
---------
Co-authored-by: Piotr Osiewicz <24362066+osiewicz@users.noreply.github.com>
Co-authored-by: Agus Zubiaga <agus@zed.dev>
- Adds a new action `git::PullRebase` which adds `--rebase` in the final
command invoked by existing Git-Pull implementation.
- Includes the new action in "Fetch/Push" button in the Git Panel
(screenshot below)
- Adds key-binding for `git::PullRebase` in all three platforms,
following the existing key-binding patterns (`ctrl-g shift-down`)
- Update git docs to include the new action.
Sidenote: This is my first ever OSS contribution
Screenshot:
<img width="234" height="215" alt="image"
src="https://github.com/user-attachments/assets/713d068f-5ea5-444f-8d66-444ca65affc8"
/>
---
Release Notes:
- Git: Added `git: pull rebase` for running `git pull --rebase`.
If I understand this correctly: The `active_repo_id` uses
`get_or_insert_with`, which makes it dependent on the `RepositoryAdded`
event sequence. To ensure correct initialization of the `active_repo_id`
on the remote side, the first local `RepositoryAdded` event must
synchronously send an `UpdateRepository` to `updates_tx`.
Closes#30694
Release Notes:
- Fixed incorrect default repository selection when using remote
Update the `editor::Editor.handle_modifiers_changed` method to ensure
that the `editor::Editor.update_edit_prediction_preview` method is
called even if edit prediction preview is disabled, if there's an active
edit prediction preview.
Without this change it was possible for users to get into a state where
holding the modifiers to show the prediction were part of the modifiers
used to disable edit prediction. When that keybinding was used, edit
prediction would be disabled, but the edit prediction preview would
remain as active, so the context menu for the editor would never be
shown again, as the editor would assume it was still showing the edit
prediction preview.
Closes#40056
Release Notes:
- Fixed a bug that could cause the completions menu to stop being show
when edit predictions were disabled
---------
Co-authored-by: dino <dinojoaocosta@gmail.com>
## Add relative line numbers on wrapped lines, take 2
This is a rework of https://github.com/zed-industries/zed/pull/39268
that excludes
e7096d27a6.
This commit introduced some line number rendering issues as described in
https://github.com/zed-industries/zed/issues/41422.
While @ConradIrwin suggested we try to pass in the buffer rows from the
calling method instead of the snapshot, that
appears to have had unintended consequences and I don't think the two
calculations were intended to do the same thing. Hence, this PR has
removed those changes.
This PR also includes the migration fix originally done by @MrSubidubi
in https://github.com/zed-industries/zed/pull/41351.
## Original PR description and release notes.
**Problem:** Current relative line numbering creates a mismatch with
vim-style navigation when soft wrap is enabled. Users must mentally
calculate whether target lines are wrapped segments or logical lines,
making `<n>j/k` navigation unreliable and cognitively demanding.
**How things work today:**
- Real line navigation (`j/k` moves by logical lines): Requires
determining if visible lines are wrapped segments before jumping. Can't
jump to wrapped lines directly.
- Display line navigation (`j/k` moves by display rows): Line numbers
don't correspond to actual row distances for multi-line jumps.
**Proposed solution:** Count and number each display line (including
wrapped segments) for relative numbering. This creates direct
visual-to-navigational correspondence, where the relative number shown
always matches the `<n>j/k` distance needed.
**Benefits:**
- Eliminates mental overhead of distinguishing wrapped vs. logical lines
- Makes relative line numbers consistently actionable regardless of wrap
state
- Preserves intuitive "what you see is what you navigate" principle
- Maintains vim workflow efficiency in narrow window scenarios
Also explained and discussed in
https://github.com/zed-industries/zed/discussions/25733.
Release Notes:
- Added support for counting wrapped lines as relative lines and for
displaying line numbers for wrapped segments. Changes
`relative_line_numbers` from a boolean to an enum: `enabled`,
`disabled`, or `wrapped`.
This PR adds the ability to configure which files are considered
"hidden" in the project panel and toggle their visibility with a
keyboard shortcut. Previously, the editor hardcoded dotfiles as hidden -
now users can customize the pattern and quickly show/hide them.
### Release Notes
- Added `project_panel::ToggleHideHidden` action with keyboard shortcuts
to toggle visibility of hidden files
- Added configurable `hidden_files` setting to customize which files are
marked as hidden (defaults to `**/.*` for dotfiles)
### Motivation
This change allows users to:
1. Quickly toggle hidden file visibility with a keyboard shortcut
2. Customize which files are considered "hidden" beyond just dotfiles
3. Better organize their project panel by hiding build artifacts, logs,
or other generated files
### Usage
**Toggle hidden files:**
- **macOS:** `cmd-alt-.`
- **Linux:** `ctrl-alt-.`
- **Windows:** `ctrl-alt-.`
**Customize patterns in settings:**
```json
{
"hidden_files": ["**/.*", "**/*.tmp", "**/build/**"]
}
```
### Changes
**Core Implementation:**
- Added `hidden_files` setting (defaults to `**/.*` to match current
dotfile behavior)
- Replaced hardcoded `name.starts_with('.')` logic with configurable
pattern matching using `PathMatcher`
- Hidden status propagates through directory hierarchies (if a directory
is hidden, all children inherit that status)
**User-Facing:**
- Added `ToggleHideHidden` action in the project panel
- Added keyboard shortcuts for all platforms
- Added settings UI entry for configuring `hidden_files` patterns
**Testing:**
- Added comprehensive test coverage validating default behavior, custom
patterns, propagation, and settings changes
### Implementation Notes
- Uses `PathMatcher` for efficient glob matching
- Settings changes automatically trigger worktree re-indexing
- No breaking changes - defaults maintain current behavior (hiding
dotfiles)
---
**Disclaimer:** This was implemented with a fair amount of copy/paste
(particularly the gitignore handling), trial and error, and a healthy
dose of Claude.
### Screenshots
**Project Panel with hidden files visible:**
<img width="1368" height="935" alt="Screenshot 2025-10-30 at 3 15 53 AM"
src="https://github.com/user-attachments/assets/1cbe90ce-504c-4f9b-bca8-bef02ab961be"
/>
**Project Panel with hidden files hidden:**
<img width="1363" height="917" alt="Screenshot 2025-10-30 at 3 16 07 AM"
src="https://github.com/user-attachments/assets/9297f43e-98c7-4b19-be8f-3934589d6451"
/>
**Toggle action in command palette:**
<img width="565" height="161" alt="Screenshot 2025-10-30 at 3 17 26 AM"
src="https://github.com/user-attachments/assets/4dc9e7b6-9c29-4972-b886-88d8018905da"
/>
Release Notes:
- Added the ability to configure glob patterns for files treated as
hidden in the project panel using the `hidden_files` setting.
- Added an action `project panel: toggle hidden files` to quickly show
or hide hidden files in the project panel.
---------
Co-authored-by: Smit Barmase <heysmitbarmase@gmail.com>
Closes#39037
Previously, the code split the `**/.env` glob in `file_scan_inclusions`
into two sources for the `PathMatcher`: `["**", "**/.env"]`. This
approach works for directories, but including `**` will match all
directories and their files. To address this, I now select the
appropriate `PathMatcher` using only `**/.env` when specifically
targeting a file to determine whether to include it in the file finder.
Release Notes:
- Fixed: respect `.gitignore` and `file_scan_inclusions` settings with
`**` in glob for file finder
---------
Signed-off-by: Benjamin <5719034+bnjjj@users.noreply.github.com>
Co-authored-by: Julia Ryan <juliaryan3.14@gmail.com>
- Update `vim::object::find_mini_delimiters` in order to filter out the
ranges before calling `vim::object::cover_or_next`, ensuring that the
provided ranges are converted from multibuffer space into buffer
space.
- Remove the `range_filter` from `vim::object::cover_or_next` was the
`find_mini_delimiters` function is the only caller and no longer uses
it
Closes#41346
Release Notes:
- Fixed a crash that could occur when using `vim::MiniQuotes` and
`vim::MiniBrackets` in a multibuffer
Prior to this change we would always resolve envs when spawning a new
terminal window based on the inherited CLI environment. This works fine
as long as we open a new Zed instance in the terminal when using it
locally only. When using Zed connected to a remote server, it would not
be meaningful however. WIth this change, we correctly ping the remote
for the project-local envs and use that instead. This change should also
fix a pesky issue when updating Zed - after Zed restarts, opening a new
terminal window will not run `direnv` for example.
Release Notes:
- N/A
Related discussions #26084
Worktree creations are implemented similar to how branch creations are
handled on the branch picker (the user types a new name that's not on
the list and a new entry option appears to create a new branch with that
name).
https://github.com/user-attachments/assets/39e58983-740c-4a91-be88-57ef95aed85b
With this picker you have a few workflows:
- Open the picker and type the name of a branch that's checked out on an
existing worktree:
- Press enter to open the worktree on a new window
- Press ctrl-enter to open the worktree and replace the current window
- Open the picker and type the name of a new branch or an existing one
that's not checked out in another worktree:
- Press enter to create the worktree and open in a new window. If the
branch doesn't exists, we will create a new one based on the branch you
have currently checked out. If the branch does exists then we create a
worktree with that branch checked out.
- Press ctrl-enter to do everything on the previous point but instead,
replace the current window with the new worktre.
- Open the picker and type the name of a new branch or an existing one
that's not checked out in another worktree:
- If a default branch is detected on the repo, you can create a new
worktree based on that branch by pressing ctrl-enter or
ctrl-shift-enter. The first one will open a new window and the last one
will replace the current one.
Note: If you preffer to not use the system prompt for choosing a
directory, you can set `"use_system_path_prompts": false` in zed
settings.
Release Notes:
- Added git worktree picker to open a git worktree on a new window or
replace the current one
- Added git worktree creation action
---------
Co-authored-by: Cole Miller <cole@zed.dev>
Making the profile management modal accessible through the agent panel
additional options menu as well. And in the process, adjusting the menu
keybinding that was getting conflicted with something else.
Release Notes:
- N/A
This PR makes the agent panel's configuration view use the icon from an
external agent that comes directly from the extension, as well as some
other clean ups.
Release Notes:
- N/A
We see `test_extension_store_with_test_extension` hang in untarring the
WASI SDK some times.
In lieu of trying to debug the problem, let's try shelling out for now
in the hope that the test becomes more reliable.
There's a bit of risk here because we're using async-tar for other
things (but probably not 300Mb tar files...)
Assisted-By: Zed AI
Closes #ISSUE
Release Notes:
- N/A
This PR adds a `zeta zeta2 predict` subcommand that takes an edit
prediction example markdown file as an argument, and performs zeta2's
prediction, showing the retrieved context and the predicted edit.
* [x] Apply uncommitted diff to get repo into the right state.
* [x] Apply edits in edit history
* [x] Display predicted edits as unified diff, regardless of model
output format
Release Notes:
- N/A
---------
Co-authored-by: Agus Zubiaga <agus@zed.dev>
Co-authored-by: Piotr Osiewicz <24362066+osiewicz@users.noreply.github.com>
Co-authored-by: Ben Kunkle <ben.kunkle@gmail.com>
A user on Discord requested this feature:
https://discord.com/channels/869392257814519848/1434188637389717556/1434188637389717556
I added a scrollbar setting called `completion_menu_scrollbar` to the
completion menu and defaulted it to "Never" to match past behavior.
Release Notes:
- editor: Add `editor.completion_menu_scrollbar` setting to show a
scrollbar in the completion menu
Closes #ISSUE: reported on X by user.
Release Notes:
- Made it so that the default value for the "remove trailing whitespace
on save" setting in Markdown is false, to fix cases where the removed
trailing whitespace had syntactic meaning
Noticed this whilst testing the Docker debugger. I randomly scrolled the
console off screen and was confused briefly as to why this was the case.
Release Notes:
- The debugger query console will no longer needlessly overscroll.
One of the reasons we didn't spot that we were missing the telemetry env
vars for the production builds was that nightly (which was working) had
its own set of build steps. This re-uses those and pushes the env vars
down from the workflow to the job.
It also fixes nightly releases to upload all-in-one go so that all
platforms update in sync.
Closes#41655
Release Notes:
- N/A
The button could not be clicked whenever the editor was currently not
focused. This PR fixes this and also registers the action on a more
global level, similar to how this is done for all the other agent
actions.
Release Notes:
- Fixed an issue where the `Expand message editor` button would not work
in agent threads if the message editor was not focused.
The Ruby extension uses the `solargraph`
language server by default for Ruby files.
However, when a user opens any ERB file,
the extension automatically starts the Ruby LSP.
This affects developers because
they do not expect the Ruby LSP to be running.
Closes https://github.com/zed-extensions/ruby/issues/172
Release Notes:
- N/A
Escape special characters (&, <, >, ", ') in the title attribute of
TextThreadContext's XML output to prevent malformed XML when titles
contain these characters.
Resolves TODO at context.rs:629
Release Notes:
- N/A
Signed-off-by: Xiaobo Liu <cppcoffee@gmail.com>
Co-authored-by: Bennet Bo Fenner <bennetbo@gmx.de>
Closes https://github.com/zed-extensions/java/issues/108
Previously, when language servers dynamically register completion
capabilities with trigger characters for completions (hello JDTLS), this
would not get updated in buffers for that language server that were
already open. This change is to find open buffers for the language
server and update the trigger characters in each of them when the new
capability is being registered.
Release Notes:
- N/A
Prior we were only updating the diagnostics pane when it is either
unfocued, saved or when a disk based diagnostic run finishes (aka cargo
check). The reason for this is simple, we do not want to take away the
excerpt under the users cursor while they are typing if they manage to
fix the diagnostic. Additionally we need to prevent dropping the changed
buffer before it is saved.
Delaying updates was a simple way to work around these kind of issues,
but comes at a huge annoyance that the diagnostics pane is not actually
reflecting the current state of the world but some snapshot of it
instead making it less than ideal to work within it for languages that
do not leverage disk based diagnostics (that is not rust-analyzer, and
even for rust-analyzer its annoying).
This PR changes this. We now always live update the view but take care
to retain unsaved buffers as well as buffers that contain a cursor in
them (as well as some other "checkpoint" properties).
Release Notes:
- Improved diagnostics pane to live update when editing within its
editor
Closes#41593
From what I understand the order of captures inside tree-sitter query
files matters, and the last capture will win. `?` and `:` are captured
by both `@operator` and `@punctuation.delimiter`.So in order for the
ternary operator to win it should live after `@punctuation.delimiter`.
Before:
<img width="298" height="32" alt="Screenshot 2025-10-31 at 17 41 21"
src="https://github.com/user-attachments/assets/af376e52-88be-4f62-9e2b-a106731f8145"
/>
After:
<img width="303" height="39" alt="Screenshot 2025-10-31 at 17 41 33"
src="https://github.com/user-attachments/assets/9a754ae9-0521-4c70-9adb-90a562404ce8"
/>
Release Notes:
- Fixed an issue where the ternary operator symbols in TypeScript would
not be highlighted as operators.
Sometimes, inside the edit agent, Sonnet thinks that it's doing a tool
call and closes its response with `</parameter></invoke>` instead of
properly closing </new_text>.
A better but more labor-intensive way of fixing this would be switching
to streaming tool calls for LLMs that support it.
Closes#39921
Release Notes:
- Fixed Sonnet's regression with inserting `</parameter></invoke>`
sometimes
This PR makes it clearer that you can click on the file path to open the
corresponding file in the agent panel's "edit bar", which is the element
that shows up in the panel as soon as agent-made edits happen.
Release Notes:
- agent panel: Improved the "go to file" affordance in the edit bar.
When we introduced the ACP-based agent panel, the condition that the
"review" | "reject" | "keep" buttons observed to be displayed got
mismatched between the panel and the pane (when in the single file
review scenario). In the panel, the buttons appear as soon as there are
changed buffers, whereas in the pane, they appear when response
generation is done.
I believe that making them appear at the same time, observing the same
condition, is the desired behavior. Thus, I think the panel behavior is
more correct, because there are loads of times where agent response
generation isn't technically done (e.g., when there's a command waiting
for permission to be run) but the _file edit_ has already been performed
and is in a good state to be already accepted or rejected.
So, this is what this PR is doing; effectively removing the "generating"
state from the agent diff, and switching to `EditorState::Reviewing`
when there are changed buffers.
Release Notes:
- Improved agent edit single file reviews by making the "reject" and
"accept" buttons appear at the same time.
Some housekeeping updates:
- Update hardcoded actions/keybindings so they're pulled from the repo
- Mention settings window when useful
- Add more info about agent panel's font size
- Break sentences in individual lines
Release Notes:
- N/A
These have been migrated to the README.md
[here](https://github.com/zed-industries/release_notes). These don't
need to be public. Putting them in the same repo where we draft
(`release_notes`) means less jumping around and allows us to include
additional information we might not want to make public.
Release Notes:
- N/A
Fixes the Debugpy toolchain detection bug in #40324
When detecting what toolchain (venv) to use in the Debugpy configuration
stage, we used to only base it off of the current working directory
argument passed to the config. This is wrong behavior for cases like
mono repos, where the correct virtual environment to use is nested in
another folder.
This PR fixes this issue by adding the program and module fields as
fallbacks to check for virtual environments. We also added support for
program/module relative paths as well when cwd is not None.
Release Notes:
- debugger: Improve mono repo virtual environment detection with Debugpy
---------
Co-authored-by: Remco Smits <djsmits12@gmail.com>
Adds a `convert-example` subcommand to the zeta cli that converts eval
examples from/to `json`, `toml`, and `md` formats.
Release Notes:
- N/A
---------
Co-authored-by: Max Brunsfeld <maxbrunsfeld@gmail.com>
Release Notes:
- N/A
---
Previously, agent markdown rendering used hardcoded font sizes
(TextSize::Default and TextSize::Small) which ignored the
agent_ui_font_size and agent_buffer_font_size settings. This updates the
markdown style to respect these settings.
This pull request adds support for customizing the font size of code
blocks in agent responses, making it possible to set a distinct font
size for code within the agent panel. The changes ensure that if the new
setting is not specified, the font size will fall back to the agent UI
font size, maintaining consistent appearance.
(I am a frontend developer without any Rust knowledge so this is
co-authored with Claude Code)
**Theme settings extension:**
* Added a new `agent_buffer_code_font_size` setting to
`ThemeSettingsContent`, `ThemeSettings`, and the default settings JSON,
allowing users to specify the font size for code blocks in agent
responses.
[[1]](diffhunk://#diff-a3bba02a485aba48e8e9a9d85485332378aa4fe29a0c50d11ae801ecfa0a56a4R69-R72)
[[2]](diffhunk://#diff-aed3a9217587d27844c57ac8aff4a749f1fb1fc5d54926ef5065bf85f8fd633aR118-R119)
[[3]](diffhunk://#diff-42e01d7aacb60673842554e30970b4ddbbaee7a2ec2c6f2be1c0b08b0dd89631R82-R83)
* Updated the VSCode import logic to recognize and import the new
`agent_buffer_code_font_size` setting.
**Font size application in agent UI:**
* Modified the agent UI rendering logic in `thread_view.rs` to use the
new `agent_buffer_code_font_size` for code blocks, and to fall back to
the agent UI font size if unset.
[[1]](diffhunk://#diff-f73942e8d4f8c4d4d173d57d7c58bb653c4bb6ae7079533ee501750cdca27d98L5584-R5584)
[[2]](diffhunk://#diff-f73942e8d4f8c4d4d173d57d7c58bb653c4bb6ae7079533ee501750cdca27d98L5596-R5598)
* Implemented a helper method in `ThemeSettings` to retrieve the code
block font size, with fallback logic to ensure a value is always used.
* Updated the settings application logic to propagate the new code block
font size setting throughout the theme system.
### Example Screenshots


---------
Co-authored-by: Danilo Leal <daniloleal09@gmail.com>
Currently Zed only displays agent notifications (e.g. when the agent
completes a task) if the user has switched apps and Zed is not in the
foreground. This adds PR supports the scenario where the agent finishes
a long-running task and the user is busy coding within Zed on something
else.
Releases Note:
- If agent notifications are turned on, they will now also be displayed
when the agent panel is hidden, in complement to them showing when the
Zed window is in the background.
---------
Co-authored-by: Danilo Leal <daniloleal09@gmail.com>
Closes#41458
Dynamically position mode selector tooltip to prevent clipping.
Position tooltip on the right when panel is docked left, otherwise on
the left. This ensures the tooltip remains visible regardless of panel
position.
**Note:** The tooltip currently vertically aligns with the bottom of the
menu rather than individual items. Would be great if it can be aligned
with the option it explains. But this doesn't seem trivial to me to
implement and not sure if it's important enough atm?
Before:
<img width="431" height="248" alt="Screenshot 2025-10-30 at 22 21 09"
src="https://github.com/user-attachments/assets/073f5440-b1bf-420b-b12f-558928b627f1"
/>
After:
<img width="632" height="158" alt="Screenshot 2025-10-30 at 17 26 52"
src="https://github.com/user-attachments/assets/e999e390-bf23-435e-9df0-3126dbc14ecb"
/>
<img width="685" height="175" alt="Screenshot 2025-10-30 at 17 27 15"
src="https://github.com/user-attachments/assets/84efca94-7920-474b-bcf8-062c7b59a812"
/>
Release Notes:
- Improved the agent panel's mode selector by preventing it to go
off-screen in case the panel is docked to the left.
Currently, if a commit operation takes some time, there's no visual
feedback in the UI that anything's happening.
This PR changes the colour of the text on the button to the
`Color::Disabled` colour when a commit operation is pending.
Release Notes:
- Improved UI feedback when a commit is in progress
---------
Co-authored-by: Danilo Leal <daniloleal09@gmail.com>
Closes#38345, #34882, #33280
Debugpy has four distinct configuration scenarios, which are:
1. launch
2. attach with process id
3. attach with listen
4. attach with connect
Spawning Debugpy directly works with the first three scenarios but not
with "attach with connect". Which requires host/port arguments being
passed in both with an attach request and when starting up Debugpy. This
PR passes in the right arguments when spawning Debugpy in an attach with
connect scenario, thus fixing the bug.
The VsCode extension comment that explains this:
98f5b93ee4/src/extension/debugger/adapter/factory.ts (L43-L51)
Release Notes:
- debugger: Fix Python attach-based sessions not working with `connect`
or `port` arguments
Currently, this only applies to long-running individually selected
unstaged files in the git panel. Next up I would like to make this work
for `Stage All`/`Unstage All` however this will most likely require
pushing `PendingOperation` into `GitStore` (from the `GitPanel`).
Release Notes:
- N/A
We missed making extensions that provide agent servers fill the
`provides` field with `agent-servers`, and thus, filtering for this type
of extension in both the app and site wouldn't return anything.
Release Notes:
- N/A
Just tidying it up by removing the unnecessary eye icon buttons in all
list items and adding that action in the form of a button in the footer,
closer to all other actions. Also reordering the footer buttons so that
the likely most common action is in the far right.
Release Notes:
- N/A
Given agent servers will soon be a thing, I'm adding Claude Code, Gemini
CLI, and Codex CLI as included agents in case anyone comes first to
search them as extensions before looking up on the agent panel.
Release Notes:
- N/A
Closes#17524
This PR adds a button to the bottom right corner of the ollama settings
ui. It resets the available ollama models, also resets the "Connected"
state in the process. This means it can be used to check if the
connection is still valid as well. It's a question whether we should
clear the available models on ALL `fetch_models` calls, since these only
happen during auth anyway.
Ollama is a local model provider which means clicking the refresh button
often only flashes the "not connected" state because the latency of the
request is so low. This accentuates changes in the UI, however I don't
think there's a way around this without adding some rather cumbersome
deferred ui updates.
I've attached the refresh button to the "Connected" `ButtonLike`, since
I don't think automatic UI spacing should separate these elements. I
think this is okay because the "Connected" isn't actually something that
the user can interact with.
Before:
<img width="211" height="245" alt="image"
src="https://github.com/user-attachments/assets/ea90e24a-b603-4ee2-9212-2917e1695774"
/>
After:
<img width="211" height="250" alt="image"
src="https://github.com/user-attachments/assets/be9af950-86a2-4067-87a0-52034a80a823"
/>
Alternative approach: There was also a suggestion to simply add a entry
to the command palette, however none of the other providers have this
ability currently either so I went with this approach. The current
approach also makes it more discoverable to the user.
Release Notes:
- Added a button for refreshing available ollama models
---------
Co-authored-by: Bennet Bo Fenner <bennetbo@gmx.de>
Closes#41478
Release Notes:
- Fixed#41478
<img width="459" height="916" alt="Screenshot 2025-10-29 at 1 31 26 PM"
src="https://github.com/user-attachments/assets/1d5b9fdf-9800-44e4-bdd5-f0964f93625f"
/>
> caused by using haiku 4.5 from the anthropic provider and then
swapping to sonnet 3.7 through zed, doing this does mess with prompt
caching but a model swap already invalidates that so it shouldn't have
any cost impact on end users
Update the behavior of the `zed_actions::agent::AddSelectionToThread`
action so that, after the selecitons are added to the current thread,
the editor automatically scrolls to the cursor's position, fixing an
issue where the inserted selection's UI component could wrap the cursor
to the next line below, leaving it outside the viewable area.
Closes#39694
Release Notes:
- Improved the `agent: add selection to thread` action so as to
automatically scroll to the cursor's position after selections are
inserted
Update `Vim::activate` to ensure that the `Vim.focused` method is only
called if the associated editor is also focused.
This ensures that the `VimEvent::Focused` event is only emitted when the
editor is actually focused, preventing a bug where, after starting Zed,
Vim's mode indicator would show that the mode was `Insert` even though
it was in `Normal` mode in the main editor.
Closes#41353
Release Notes:
- Fixed vim's mode being shown as `Inserted` right after opening Zed
Co-authored-by: Conrad Irwin <conrad.irwin@gmail.com>
When rerunning a task, our process id fetching seems to sometimes return
the previous terminal's process id when respawning the task, causing us
to kill the new terminal once the previous one drops as we spawn a new
one, then drop the old one. This results in rerun sometimes spawning a
blank task as the terminal immediately exits. The fix here is simple, we
actually want to kill the process running inside the terminal process,
not the terminal process itself when we exit in the terminal.
No relnotes as this was introduced yesterday in
https://github.com/zed-industries/zed/pull/41562
Release Notes:
- N/A *or* Added/Fixed/Improved ...
Closes#41125
Release Notes:
- Fixed `SwitchToHelixNormalMode` to keep selection
- Added default keybinds for `SwitchToHelixNormalMode` when in Helix
mode
- Update `vim::normal::Vim.normal_replace` to work with more than one
character
- Add `vim::replace::Vim.paste_replace` to handle pasting the
clipboard's contents while in replace mode
- Update vim's handling of the `editor::actions::Paste` action so that
the `paste_replace` method is called when vim is in replace mode,
otherwise it'll just call the regular `editor::Editor.paste` method
Closes#41378
Release Notes:
- Improved pasting while in Vim's Replace mode, ensuring that the Zed
replaces the same number of characters as the length of the contents
being pasted
This PR fixes breakpoint icon alignment to also be at the end of a
rendered entry and enables editing breakpoint qualities when there's no
active session.
The alignment issue was caused by some icons being invisible, so the
layout phase always accounted for the space they would take up. Only
laying out the icons when they are visible fixed the issue.
#### Before
<img width="1014" height="316" alt="image"
src="https://github.com/user-attachments/assets/9a9ced06-e219-4d9d-8793-6bdfdaca48e8"
/>
#### After
[
<img width="502" height="167" alt="Screenshot 2025-10-30 at 3 21 17 PM"
src="https://github.com/user-attachments/assets/23744868-e354-461c-a940-9b6812e1bcf4"
/>
](url)
Release Notes:
- Breakpoint list: Allow adding conditions, logs, and hit conditions to
breakpoints when there's no active session
Closes#40360
This PR added heuristics to determine what variable/breakpoint list
entry has the longest width when rendered. I added this in so the
uniform list would correctly determine which item has the longest width
and use that to calculate the scrollbar size.
The heuristic can be off if a non-mono space font is used in the UI; in
most cases, it's more than accurate enough though.
Release Notes:
- debugger: Add horizontal scroll bars to variable list, memory view,
and breakpoint list
---------
Co-authored-by: MrSubidubi <dev@bahn.sh>
When doing a project wide search in zed on windows for `hang`, zed
starts to freeze for a couple seconds ultimately starting to error with
`Not enough quota is available to process this command.` when
dispatching windows messages. The cause for this is that we simply
overload the windows message pump due to the sheer amount of foreground
tasks we spawn when we populate the project search.
This PR is an attempt at reducing this.
Release Notes:
- Reduced hangs and stutters in large project file searches
This ensures the thread summary is treated as a tracked mention with
accessible context.
Changes:
- Fixed `MessageEditor::insert_thread_summary()` to use proper mention
URI format
- Added test coverage to verify the fix
Release Notes:
- Fixed an issue where "New From Summary" was not properly inserting
thread summaries as contextual mentions when creating new threads.
Thread summaries are now inserted as proper mention URIs.
Attempt 2 for https://github.com/zed-industries/zed/pull/40774
We were spawning the process on the foreground thread before which can
block an arbitrary amount of time. Likewise we no longer block
deserialization on the terminal loading.
Release Notes:
- Improved startup time on systems with slow process spawning
capabilities
Adds an action to open the notes for the currently selected channel in
the collab panel, which is mapped to `alt-enter` in all platforms.
Release Notes:
- collab: Add `collab_panel::OpenSelectedChannelNotes` action
(`alt-enter` by default)
Add default keybinding for `pane::SplitRight` in the `Terminal` context
for all platforms.
Closes #ISSUE
Release Notes:
- Added VS Code's terminal split keybindings (`cmd` on MacOS,
`ctrl-shift-5` on Windows and Linux)
---------
Co-authored-by: dino <dinojoaocosta@gmail.com>
I just pulled and ran a local build via `script/bundle-mac -l -i` but
found that the resulting bundle wasn't installed as expected. (me:
"ToggleAllDocks!! Wait! Where is it?!") Looking into, it looks like the
`-l` flag was removed in #41392, leaving the `$local_only` var orphaned,
which then left the `-i/$local_install` flag unreachable. I suspect that
this was unintentional, so this PR re-adds the `-l/$local_only` flag to
`script/bundle-mac`.
I ran the build again and confirmed that local install seemed to work as
expected. (ie "ToggleAllDocks!! 🎉")
While here, I also removed the last reference to `$local_arch`, because
all other references to that were removed in #41392.
/cc @osiewicz
Release Notes:
- N/A
---------
Co-authored-by: Conrad Irwin <conrad.irwin@gmail.com>
We'll now perform all searches from the context model concurrently, and
combine queries for the same glob into one reducing the total number of
project searches.
For better readability, the debug context view now displays each
top-level regex alternation individually, grouped by its corresponding
glob:
<img width="1592" height="672" alt="CleanShot 2025-10-29 at 19 56 03@2x"
src="https://github.com/user-attachments/assets/f6e8408e-09d6-4e27-ba11-a739a772aa12"
/>
Release Notes:
- N/A
Closes https://github.com/zed-industries/zed/issues/39104
This fixes an issue where the preview would not work for remote buffers
in the process.
Release Notes:
- Fixed an issue where the SVG preview would not work in remote
scenarios.
- The SVG preview will now rerender on every keypress instead of only on
saves.
Closes#41180
When using the fallback prompt renderer (default on Wayland), clicks
would bleed through into underlying windows. When the click happens to
hit a button that creates a prompt, it drops the
`RenderablePromptHandle` which is contained within `Window`, causing the
`Receiver` which returns the index of the clicked `PromptButton` to
return `Err(Canceled)` even though a button was pressed.
This bug appears in the GPUI `window.rs` example, which can be ran using
`cargo run -p gpui --example window`. MacOS has a native
`PromptRenderer` and thus needs additional code to be adjusted to be
able to reproduce the issue.
Release Notes:
- N/A *or* Added/Fixed/Improved ...
Release Notes:
- settings_ui: Added the ability to copy a link to a given setting,
allowing users to quickly open the settings window at the correct
location in a faster way.
---------
Co-authored-by: cameron <cameron.studdstreet@gmail.com>
Co-authored-by: Ben Kunkle <ben@zed.dev>
Added a "Clear Messages" button to the ACP logs toolbar that removes all
messages.
## Motivation
When debugging ACP protocol implementations, the message list can become
cluttered with old messages. This feature allows clearing all messages
with a single click to start fresh, making it easier to focus on new
interactions without closing and reopening the ACP logs view.
Release Notes:
- N/A
This reintroduces `layer_shell` support after #32651 was reverted. On
top of that, it allows setting options for the created surface,
restricts the enum variant to the `wayland` feature, and adds an example
that renders a clock widget using the protocol.
I've renamed the `WindowKind` variant to `LayerShell` from `Overlay`,
since the protocol can also be used to render wallpapers and such, which
doesn't really fit with the word.
Things I'm still unsure of:
- We need to get the layer options types to the user somehow, but
nothing from the `platform::linux` crate was exported, I'm assuming
intentionally. I've kept the types inside the module (instead of doing
`pub use layer_shell::*` to not pollute the global namespace with
generic words like `Anchor` or `Layer` Let me know if you want to do
this differently.
- I've added the options to the `WindowKind` variant. That's the only
clean way I see to supply them when the window is created. This makes
the kind no longer implement `Copy`.
- The options don't have setter methods yet and can only be defined on
window creation. We'd have to make fallible functions for setting them,
which only work if the underlying surface is a `layer_shell` surface.
That feels un-rust-y.
CC @zeroeightysix
Thanks to @wuliuqii, whose layer-shell implementation I've also looked
at while putting this together.
Release Notes:
- Add support for the `layer_shell` protocol on wayland
---------
Co-authored-by: Ridan Vandenbergh <ridanvandenbergh@gmail.com>
Closes#41407
This solves a problem where users couldn't navigate between snippet
tabstops while the completion menu was open.
I named the action {Next, Previous}SnippetTabstop instead of Placeholder
to be more inline with the LSP spec naming convention and our codebase
names.
Release Notes:
- Editor: Add actions to move between snippet tabstop positions
Closes https://github.com/zed-industries/zed/issues/38558
The bug occurred because TabStopCursor chunk_position.1 is bounded
between 0 and 128. The fix for this was changing the bound to 0 and 127.
This also allowed me to simplify some of the tab stop cursor code to be
a bit faster (less branches and unbounded shifts).
Release Notes:
- N/A
This happens quite often with cargo based diagnostics which may spawn
several lines (sometimes the entire screen), forcing the user to scroll
up to the start of the diagnostic just to see the hover message is not
great.
Release Notes:
- Fixed diagnostics hovers not working if the diagnostic spans out of
view
Just for parity with vim. Also prevents these toggles from having both
enabled at the same time as that is a buggy state.
Release Notes:
- Added command to toggle helix mode
Closes#41422
This completely broke line numbering as described in the linked issue
and scrolling up does not have the correct numbers any more.
Release Notes:
- NOTE: The `relative_line_numbers` change
(https://github.com/zed-industries/zed/pull/39268) was reverted and did
not make the release cut!
Closes#41219
Release Notes:
- Updated docs to use `==` instead of `=` in keymap context.
Hopefully I'm not mistaken here, but I think the docs have a bug in them
Reverts zed-industries/zed#41384
The branch-protection rules work much better when there is a Job that
runs every time and can be depended on to pass, we no longer have this.
Release Notes:
- N/A
- Declare UAC support. This will prevent Windows from flagging
`auto_update_helper.exe` as a legacy setup program that needs to run as
administrator.
- Declare support for Windows 10. This will stop Windows from applying
various application compatibility profiles.
The UAC policy is not really appropriate to apply to all GPUI
applications (e.g. an installer written in GPUI may want to declare
itself as `requireAdministrator` instead of `asInvoker`). I tried
splitting this into a Zed.exe-only manifest and enabling manifest file
merging, but I ran out of my time-box. We can fix this later if this is
flagged by GPUI users.
Release Notes:
- N/A
Follow up for: #41304
Splits CI tests (cherry-picks and PRs only for now) into separate
workflows using `gh-workflow`. Includes a couple restructures to
- run more things in parallel
- remove our previous shell script based checking to filter tests based
on files changed, instead using the builtin `paths:` workflow filters
Splitting the docs/style/rust tests & checks into separate workflows
means we lose the complete summary showing all the tests in one view,
but it's possible to re-add in the future if we go back to checking what
files changed ourselves or always run everything.
Release Notes:
- N/A *or* Added/Fixed/Improved ...
---------
Co-authored-by: Conrad <conrad@zed.dev>
Release Notes:
- Remove Windows/Linux from Getting Started
- Consolidate download & system into new Installation page
- Move Remote Dev out of Windows and into Remote Development
- Add Uninstall page
- Add updates page
- Remove addl learning materials from intro
Thread stacks in rust by default have 2 megabytes of stack which for
sumtrees (or ropes in this case) can easily be exceeded depending on the
workload.
Release Notes:
- Fixed stack overflows when constructing large ropes
This PR hides the worktree root name from the path prefix displayed when
you @-mention a file or directory in the agent panel. Given the tight UI
real state we have, I believe that having the project name in there is
redundant—the project you're in is already displayed in the title bar.
Not only it was the very first word you'd see after the file's name, but
it also made the path longer than it needs to. A bit of a design clean
up here :)
(PS: We still show the project name if there are more than one in the
same workspace.)
Release Notes:
- N/A
This PR adds a setting to prevent projects from being shared in public
channels.
This can be enabled by adding the following to the project settings
(`.zed/settings.json`):
```json
{
"prevent_sharing_in_public_channels": true
}
```
This will then disable the "Share" button when not in a private channel:
<img width="380" height="115" alt="Screenshot 2025-10-28 at 2 28 10 PM"
src="https://github.com/user-attachments/assets/6761ac34-c0d5-4451-a443-adf7a1c42bcd"
/>
Release Notes:
- collaboration: Added a `prevent_sharing_in_public_channels` project
setting for preventing projects from being shared in public channels.
Was previously sending all of the tools to the LLM on the first message
of a conversation regardless of the selected agent profile. This added
extra context, and tended to create scenarios where the LLM would
attempt to use the tool and it would fail since it was not available.
To reproduce, create a new conversation where you ask the Minimal mode
which tools it has access to, or try to write to a file.
Release Notes:
- Fixed an issue in the agent where all tools would be presented as
available even when using the `Minimal` profile
---------
Co-authored-by: Bennet Bo Fenner <bennetbo@gmx.de>
Symbol completions in the context picker now show "SymbolName
filename.txt L123" instead of just "SymbolName". This helps distinguish
between symbols with the same name in different files.
## Motivation
I noticed that the message prompt editor only showed symbol names
without any context, making it hard to use in large projects with many
symbols sharing the same name. The inline prompt editor already includes
file context for symbol completions, so I brought that same UX
improvement to the message prompt editor. I've decided to match the
highlighting style with directory completion entries from the message
editor.
## Changes
- Extract file name from both InProject and OutsideProject symbol
locations
- Add `build_symbol_label` helper to format labels with file context
- Update test expectation for new label format
## Screenshots
Inline Prompt Editor
<img width="843" height="334" alt="Screenshot 2025-10-17 at 17 47 52"
src="https://github.com/user-attachments/assets/16752e1a-0b8c-4f58-a0b2-25ae5130f18c"
/>
Old Message Editor:
<img width="466" height="363" alt="Screenshot 2025-10-17 at 17 31 44"
src="https://github.com/user-attachments/assets/900659f3-0632-4dff-bc9a-ab2dad351964"
/>
New Message Editor:
<img width="482" height="359" alt="Screenshot 2025-10-17 at 17 31 23"
src="https://github.com/user-attachments/assets/bf382167-f88b-4f3d-ba3e-1e251a8df962"
/>
Release Notes:
- Added file names and line numbers to symbol completions in the agent
panel
To help make our GitHub Actions easier to understand, we're planning to
split the existing `ci.yml` into three separate workflows:
* run_bundling.yml (this PR)
* run_tests.yml
* make_release.yml
To avoid the duplication that this might otherwise cause, we're planning
to write the workflows with gh-workflow, and use rust instead of
encoding logic in YAML conditions.
Release Notes:
- N/A
---------
Co-authored-by: Ben Kunkle <ben@zed.dev>
Closes#40884
- Make IOPub task return a `Result`
- Create a monitoring task that watches over IOPub, Control, Routing and
Shell tasks.
- If any of these tasks fail, report the error with `kernel_errored()`
(which is already used to report process crashes)
https://github.com/user-attachments/assets/3125f6c7-099a-41ca-b668-fe694ecc68b9
This is not perfect. I did not have time to look into this but:
- When such errors happen, the kernel should be shut down.
- The kernel should no longer appear as online in the UI
But at least the user is getting feedback on what went wrong.
Release Notes:
- Jupyter client errors are now surfaced in the UI (#40884)
After #38882 we were always including file/directory mentions as
`zed:///agent/file?path=a/b/c.rs`.
However, for most resource links (files/directories/symbols/selections)
we want to use a common format, so that ACP servers don't have to
implement custom handling for parsing `ResourceLink`s coming from Zed.
This is what it looks like now:
```
[@index.js](file:///Users/.../projects/reqwest/examples/wasm_github_fetch/index.js)
[@wasm](file:///Users/.../projects/reqwest/src/wasm)
[@Error](file:///Users/.../projects/reqwest/src/async_impl/client.rs?symbol=Error#L2661:2661)
[@error.rs (23:27)](file:///Users/.../projects/reqwest/src/error.rs#L23:27)
```
Release Notes:
- N/A
---------
Co-authored-by: Cole Miller <cole@zed.dev>
Closes https://github.com/zed-industries/zed/issues/41334
This comes down to a caching issue..
Release Notes:
- Fixed an issue where the scrollbar track color would not update in
case the theme was changed.
The current Jetbrains keymap has `ctrl-shift-f12` set to
`CloseAllDocks`. On Jetbrains IDEs this hotkey actually toggles the
docks, which is very convenient: You press it once to hide all docks and
just focus on the code, and then you can press it again to toggle your
docks right back to how they were. Unlike `CloseAllDocks`, a toggle
means the editor needs to remember the previous docks state so this
necessitated some code changes.
Release Notes:
- Added a `Toggle All Docks` editor action and updated the keymaps to
use it
By default, the uninstaller will only delete files that were written by
the original installer. When users upgrade Zed, these new
OpenConsole.exe files will have been written by auto_upgrade_helper, not
the installer. Force them to be deleted on uninstall, so they do not
hang around.
Release Notes:
- N/A
The tab switcher render matches calls each workspace item's
`Item::tab_content` function that can return an element of variable
size. Because the tab switcher was using a uniform list under the hood,
this would cause spacing issues when tab_contents elements had different
sizes.
The fix is by changing the picker to use a material list under the hood.
Release Notes:
- N/A
## Description
Fixes the copy button functionality in REPL interactive mode error
output sections.
When executing Python code that produces errors in the REPL (e.g.,
`NameError`), the copy button in the error output section was
unresponsive. The stdout/stderr copy button worked correctly, but the
error traceback section copy button had no effect when clicked.
Fixes#40207
## Changes
Modified the following:
src/outputs.rs: Fixed context issues in render_output_controls by
replacing cx.listener() with simple closures, and added custom button
implementation for ErrorOutput that copies/opens the complete error
(name + message + traceback)
src/outputs/plain.rs: Made full_text() method public to allow access
from button handlers
src/outputs/user_error.rs: Added Clone derive to ErrorView struct and
removed a couple pieces of commented code
## Why This Matters
The copy button was clearly broken and it is useful to have for REPL
workflows. Users could potentially need to copy error messages for a
variety of reasons.
## Testing
See attached demo for proof that the fix is working as intended. (this
is my first ever commit, if there are additional test cases I need to
write or run, please let me know!)
https://github.com/user-attachments/assets/da158205-4119-47eb-a271-196ef8d196e4
Release Notes:
- Fixed copy button not working for REPL error output
Replace the binary search approach with a more efficient partition_point
method for checking selection overlaps. This eliminates the need to
collect and sort selection ranges separately, reducing memory allocation
and improving performance when handling multiple selections.
Release Notes:
- N/A
Signed-off-by: Xiaobo Liu <cppcoffee@gmail.com>
This change adds two things to our remote server build
process:
1. It now checks if all required tooling is installed before using it or installing it on demand. This includes checks for `rustup` and `cargo-zigbuild` in your `PATH`.
2. Next, if `ZED_BUILD_REMOTE_SERVER` contains `musl` and `ZED_ZSTD_MUSL_LIB`
is set, we will pass its value (the path) to `cargo-zigbuild` as `-C
link-arg=-L{path}`.
Release Notes:
- N/A
The `wrap selections in tag` action currently did not take line_mode
into account, which means when selecting lines with `shift-v`, the
start/end tags would be inserted into the middle of the selection (where
the cursor sits)
https://github.com/user-attachments/assets/a1cbf3da-d52a-42e2-aecf-1a7b6d1dbb32
This PR fixes this behaviour by checking if the selection uses line_mode
and then adjusting start and end points accordingly.
NOTE: I looked into amending the test cases for this, but I am unsure
how to express line mode with range markers. I would appreciate some
guidance on this and then I am happy to add test cases.
After:
https://github.com/user-attachments/assets/a212c41f-b0db-4f50-866f-fced7bc677ca
Release Notes:
- Fixed `Editor: wrap selection in tags` when in vim visual line mode
---------
Co-authored-by: Conrad Irwin <conrad.irwin@gmail.com>
Release Notes:
- Pane key context now includes 'buffer_search_deployed' identifier
The goal of this PR is to add a new identifier in the key context that
will let the user target when the BufferSearchBar is deployed even if
they are not focused on it.
requested in #36930
Same rational as #40454 this will allow users to make more flexible
keybindings, by including some additional information higher up the key
context tree.
i thought adding this context to `Pane` seemed more appropriate than
`Editor` since `Terminal` also has a `BufferSearchBar`; however, I ran
into some import issues between BufferSearchBar, Search, Pane, and
Workspace which made it difficult to implement adding this context
directly inside `Pane`'s render function.
instead i added a new method called `contributes_context` to
`ToolbarItem` which will allow any toolbar item to add additional
context to the `Pane` level, which feels like it might come in handy.
here are some screen shots of the context being displayed in the Editor
and the Terminal
<img width="1653" height="1051" alt="Screenshot 2025-10-25 at 14 34 03"
src="https://github.com/user-attachments/assets/21c5b07a-8d36-4e0b-ad09-378b12d2ea38"
/>
<img width="1444" height="1167" alt="Screenshot 2025-10-25 at 12 32 21"
src="https://github.com/user-attachments/assets/86afe72f-b238-43cd-8230-9cb59fb93b2c"
/>
**Problem:** Current relative line numbering creates a mismatch with
vim-style navigation when soft wrap is enabled. Users must mentally
calculate whether target lines are wrapped segments or logical lines,
making `<n>j/k` navigation unreliable and cognitively demanding.
**How things work today:**
- Real line navigation (`j/k` moves by logical lines): Requires
determining if visible lines are wrapped segments before jumping. Can't
jump to wrapped lines directly.
- Display line navigation (`j/k` moves by display rows): Line numbers
don't correspond to actual row distances for multi-line jumps.
**Proposed solution:** Count and number each display line (including
wrapped segments) for relative numbering. This creates direct
visual-to-navigational correspondence where the relative number shown
always matches the `<n>j/k` distance needed.
**Benefits:**
- Eliminates mental overhead of distinguishing wrapped vs. logical lines
- Makes relative line numbers consistently actionable regardless of wrap
state
- Preserves intuitive "what you see is what you navigate" principle
- Maintains vim workflow efficiency in narrow window scenarios
Also explained an discussed in
https://github.com/zed-industries/zed/discussions/25733.
Release Notes:
Release Notes:
- Added support for counting wrapped lines as relative lines and for
displaying line numbers for wrapped segments. Changes
`relative_line_numbers` from a boolean to an enum: `enabled`,
`disabled`, or `wrapped`.
---------
Co-authored-by: Conrad Irwin <conrad.irwin@gmail.com>
If you set `{"basedpyright": {"analysis": {"typeCheckingMode":
"off"}}}`, you will notice that it doesn't actually work, but
`{"basedpyright.analysis": {"typeCheckingMode": "off"}}` does.
Made the change on how the default is being set.
Release Notes:
- N/A
The bug occurred because `smol::process::Command::from(_)` doesn't set
the correct fields for stdio markers. So moving the stdio configuration
after converting to a `smol` command fixed the issue.
I added the `std::process::Command::{stdout, stderr, stdin}` functions
to our disallowed list in clippy to prevent any bugs like this appearing
in the future.
Release Notes:
- N/A
This isn't quite right yet, as a proper solution would remember the
input modality at the moment of focus change, rather than at painting
time. But this gets us close enough for now.
Release Notes:
- N/A
## Summary
- Document the `stable`/`preview`/`nightly` top-level keys that let
users scope settings overrides per release channel.
- Provide an example `settings.json` snippet and call out that overrides
replace array values rather than merging them.
- Mention that UI-driven changes edit the root config so per-channel
blocks might need manual updates.
## Testing
- Not run (docs only).
Fixes#40458.
Release Notes:
- N/A
---------
Co-authored-by: MrSubidubi <finn@zed.dev>
```json
"edit_predictions": {
"codestral": {
"api_url": "https://codestral.mistral.ai",
"model": "codestral-latest",
"max_tokens": 150
}
},
```
Release Notes:
- Added support for changing the Codestral endpoint. This was discussed
at #34371.
---------
Co-authored-by: Bennet Bo Fenner <bennetbo@gmx.de>
Introduce a new `prefer_focused_window` field to the
`workspace::OpenOptions` struct that, when provided, will make it so
that Zed opens the provided path in the currently focused window.
This will now automatically be set to true when the `--wait` flag is
used with the CLI.
Closes#40551
Release Notes:
- Improved the `--wait` flag in Zed's CLI so as to always open the
provided file in the currently focused window
---------
Co-authored-by: Conrad Irwin <conrad.irwin@gmail.com>
Closes https://github.com/zed-industries/zed/issues/41168
This PR adds both Tailwind CSS and Ruff (linter for Python) as built-in
features; a banner mentioning this should show up now for these two when
searching for them in the extensions UI.
There will also be a corresponding zed.dev site PR adding a "Ruff is
built-in" card to the zed.dev/extensions page.
Release Notes:
- N/A
We were not actually using `paths::agent_servers` and were manually
constructing the path to the `external_agents` folder in a few places.
Release Notes:
- N/A
Using compiler explorer I saw that the compiler wasn't clever enough to
optimise away the branches in the masking code. I thought the compiler
would have a better chance if we always branched, which [turned out to
be the case](https://godbolt.org/z/PM594Pz18).
Running the benchmarks the biggest benefit I saw was:
```
push/65536 time: [2.9067 ms 2.9243 ms 2.9417 ms]
thrpt: [21.246 MiB/s 21.373 MiB/s 21.502 MiB/s]
change:
time: [-8.3452% -7.2617% -6.2009%] (p = 0.00 < 0.05)
thrpt: [+6.6108% +7.8303% +9.1050%]
Performance has improved.
```
But I did also see some regressions:
```
slice/4096 time: [66.195 µs 66.815 µs 67.448 µs]
thrpt: [57.915 MiB/s 58.464 MiB/s 59.012 MiB/s]
change:
time: [+3.7131% +5.1698% +6.6971%] (p = 0.00 < 0.05)
thrpt: [-6.2768% -4.9157% -3.5802%]
Performance has regressed.
```
Release Notes:
- N/A
Fixes https://github.com/zed-industries/zed/issues/41260
After experimenting and reading through the implementation of OpenSSH
stack on Windows, it looks like batch mode precludes use of passwords.
In the listing
b8c08ef9da/sshconnect2.c (L417),
the last field of each `Authmode` struct is a pointer to the config
value that *disables* that particular mode. In this case, `keyboard`
(interactive) and `password` modes are both disabled if batch mode is
used. We should therefore fall back to `scp` if `sftp` fails rather than
to fail outright.
Release Notes:
- N/A
Closes#40898
Release Notes:
- Fixed an issue where attempting to add or update a key binding in the
keymap editor with an empty `keymap.json` file would fail
Closes https://github.com/zed-industries/zed/issues/41267
The only downside would be the fact that a Zed window will appear behing
the version modal, but this is a limitation for all "window-less"
actions currently.
Release Notes:
- Made "About Zed" menu entry to work when all Zed windows are closed
Updates to acp crate 0.7, which allows us to send information about the
client to the Agent.
In the future, we can also use the AgentInfo on the response for
internal metrics.
Release Notes:
- N/A
Fixes a regression introduced in
https://github.com/zed-industries/zed/pull/39857. As for the exact
reason this causes this issue I am not yet sure will investigate (as per
the todos in code)
Fixes ZED-23R
Release Notes:
- N/A *or* Added/Fixed/Improved ...
Previously, the hover popover delay was implemented using two
overlapping timers, which caused the minimum delay to always be at least
HOVER_REQUEST_DELAY_MILLIS, regardless of the hover_popover_delay
setting.
This change updates the logic to wait for hover_popover_delay only,
ensuring the total delay is always equals to hover_popover_delay . As a
result, the hover popover now appears after the intended delay, matching
the user's configuration more accurately.
Release Notes:
- Improved hover popover respecting settings delay correctly
This PR fixes some instances where we were displaying action names in
quotes instead of in backticks.
Also fixed some mentions of using an action to open the settings file,
as this has changed after the release of the settings UI.
Release Notes:
- N/A
When trying to split and clone a non clone-able workspace item we now
attempt split and move instead of doing nothing. Additionally we disable
the split menu buttons if we can't split the active item at all.
Release Notes:
- Improved handling of unsplittable panes
We only use it a handful of times and the default amount of threads
(logical cpu core number) its spawns is overkill for this. This also
gives the threads names oppose to being labeled `<unknown>`
Release Notes:
- N/A *or* Added/Fixed/Improved ...
The issues is that the closure supplied to `request_measured_layout`
could be run multiple times with differing `known_dimensions`. This in
turn will mean we truncate the font runs once, inserting a multibyte
char at the end but then in the next iteration use those truncated runs
for possible the original untruncated string which has multibyte
characters overlapping the now truncated run end resulting in a faulty
utf8 boundary index.
Solution to this is simple, truncate a clone of the runs when needed
instead of modifying the original.
Fixes https://github.com/zed-industries/zed/issues/36925
Fixed ZED-2FF
Fixes ZED-2KM
Fixes ZED-2KK
Fixes ZED-1FF
Fixes ZED-255
Fixes ZED-2JD
Fixes ZED-2FX
Fixes ZED-2K2
Fixes ZED-2JX
Fixes ZED-2GE
Fixes ZED-2FC
Fixes ZED-2GD
Fixes ZED-2HY
Fixes ZED-2HR
Fixes ZED-2FN
Fixes ZED-2GT
Fixes ZED-2FK
Fixes ZED-2EY
Fixes ZED-27E
Fixes ZED-272
Fixes ZED-2EM
Fixes ZED-2CC
Fixes ZED-29V
Fixes ZED-25B
Fixes ZED-257
Fixes ZED-24R
Fixes ZED-24Q
Fixes ZED-23Z
Fixes ZED-227
Release Notes:
- Fixed a crash in text shaping when truncating rendered text
We've been seeing a lot of weird constant rebuilds recently with
rust-anaylzer's check, either with cargo thinking build scripts are too
new timestamp wise or all fingerprints having gone missing somehow
(???). Reading through some related bug reports hints at disabling
incremental potentially working around this for now so let's test that
out
cc https://github.com/rust-lang/cargo/issues/16104
Release Notes:
- N/A *or* Added/Fixed/Improved ...
Split out from https://github.com/zed-industries/zed/pull/40774 to
reduce the size of the reland of that PR (once I figure out the cause of
the issue)
Release Notes:
- N/A *or* Added/Fixed/Improved ...
Adds debugger inline values support for JavaScript, TypeScript, and TSX languages.
Release Notes:
- debugger: Add inline value support for Javascript, TypeScript, and TSX
---------
Co-authored-by: Anthony <anthony@zed.dev>
1. Settings Viewed: Whenever someone opens or refocus the settings ui
via an action
2. Settings Closed: When the settings ui window is closed
3. Settings Navigation Clicked: The category and subcategory that a user
clicked on
4. Settings Error Shown: Whenever an error banner shows up
5. Settings Changed: The setting a user changed through the UI
cc: @katie-z-geer
Release Notes:
- N/A
This PR allows you to define `align="right"` for example to change the
default alignment on **HTML** table columns. This PR also refactors
where we store the alignments in order to make it so you can define it
column based instead of only row based.
See that the `Revenue` column is left aligned instead of the default
`centered`.
**Result**
<img width="1161" height="177" alt="Screenshot 2025-10-25 at 11 01 38"
src="https://github.com/user-attachments/assets/94bda4f0-00c1-4726-a3bd-99b3f2573ef5"
/>
**Code example**
```HTML
<table>
<tr>
<th rowspan="2">Region</th>
<th colspan="2" align="left">Revenue</th>
<th rowspan="2">Growth</th>
</tr>
<tr>
<th>Q2 2024</th>
<th>Q3 2024</th>
</tr>
<tr>
<td>North America</td>
<td>$2.8M</td>
<td>$2.4B</td>
<td>+85,614%</td>
</tr>
<tr>
<td>Europe</td>
<td>$1.2M</td>
<td>$1.9B</td>
<td>+158,233%</td>
</tr>
<tr>
<td>Asia-Pacific</td>
<td>$0.5M</td>
<td>$1.4B</td>
<td>+279,900%</td>
</tr>
</table>
```
Release Notes:
- markdown preview: Add support for `HTML` table column `align`
attribute
Follow-up: https://github.com/zed-industries/zed/pull/39898
Right now, we don't fill the empty column when the current row count is
less than the max row count. This PR fixes that by filling it with an
empty cell. So the table columns don't flow in the wrong direction, as
you can see inside the first screenshot.
**Before**
<img width="1095" height="182" alt="Screenshot 2025-10-24 at 16 09 02"
src="https://github.com/user-attachments/assets/e3abf24e-c190-4bd7-b43a-39f2f01ecd1c"
/>
**After**
<img width="1165" height="178" alt="Screenshot 2025-10-24 at 16 19 17"
src="https://github.com/user-attachments/assets/427c25f9-82a7-498b-a1a2-d71e4c288fe5"
/>
**Code example**
```html
<table>
<tr>
<th rowspan="2">Region</th>
<th colspan="2">Revenue</th>
<th rowspan="2">Growth</th>
</tr>
<tr>
<th>Q2 2024</th>
<th>Q3 2024</th>
</tr>
<tr>
<td>North America</td>
<td>$2.8M</td>
<td>$2.4B</td>
<td>+85,614%</td>
<td>+99%</td> // extra column here
</tr>
<tr>
<td>Europe</td>
<td>$1.2M</td>
<td>$1.9B</td>
<td>+158,233%</td>
</tr>
<tr>
<td>Asia-Pacific</td>
<td>$0.5M</td>
<td>$1.4B</td>
<td>+279,900%</td>
</tr>
</table>
```
**Note** there are no release notes, as the previous PR didn't get
released yet.
Release Notes:
- N/A
Some information in the GDScript documentation page was outdated (like
it still treats Zed if it was a macOS exclusive app) or some details
were missing.
- The `zed-gdscript` URL has been updated with the new owner.
- Pre-requisites added (with netcat included).
- Godot installation steps removed, it's now listed in the
pre-requisites.
- Setup steps simplified and reworded.
The note at the bottom was removed as I didn't see the issue in my end.
Release Notes:
- N/A
## Overview
- document how to keep a per-user debug.json so global launch tasks show
up everywhere (Fixes#39849)
- sanitize REPL terminal text before copying so error blocks can be
copied and opened in buffers (Fixes#40207)
## Design Decisions
- reused the existing user debug file (paths::debug_scenarios_file) and
pointed docs at the zed::OpenDebugTasks command to stay aligned with the
settings UX
- extract a sanitize helper inside TerminalOutput::full_text to strip
\r/null padding while keeping indentation intact, then join the cleaned
lines so clipboard and buffers get readable text
## Testing
- Not run (cargo is unavailable in this environment)
Fixes#39849.
Fixes#40207.
Add support for GithubCopilot /responses endpoint. This gives the
copilot chat provider the ability to use the new GPT-5 codex model and
any other model that lacks support for /chat/copmletions endpoint.
Closes#38858
Release Notes:
- Add support for GithubCopilot /responses endpoint.
# Added
1. copilot_response.rs that has the /response endpoint types
2. uses response endpoint if model does not support /chat/completions.
3. new into_copilot_response() to map LanguageCompletionEvents to
Request.
4. new map_stream() to map response stream event to
LanguageCompletionEvents and tests.
5. Fixed a bug where trying to parse response for non streaming for
/chat/completion was failing
# Notes
There is a pr open - https://github.com/zed-industries/zed/pull/39989
for adding /response support for OpenAi and OpenAi compatible API.
Altough they share some similarities (copilot api seems to mirror openAi
directly) ive simplified some stuff and tried to keep it the same with
the vscode-chat implementation where possible. There might be a case for
code reuse but i think keeping them separate for now should be ok.
# Tool Calls
<img width="716" height="670" alt="Screenshot from 2025-10-15 17-12-30"
src="https://github.com/user-attachments/assets/14e88a52-ba8b-4209-8f78-73d15034b1e0"
/>
# Image
<img width="923" height="494" alt="Screenshot from 2025-10-21 02-02-26"
src="https://github.com/user-attachments/assets/b96ce97c-331e-45cb-b5b1-7aa10ed387b4"
/>
Very often, when I'm testing or playing around with the zoom feature,
including the agent panel, I find myself missing one quick action that
would bring everything back to normal. That's what `ResetAllZoom` does.
If you have customized your zoom level in all areas of Zed, that action
returns everything to its default state. Similarly, if you're playing
around with zoom just in the agent panel, `ResetAgentZoom` does the same
in that context.
Release Notes:
- Added the `ResetAllZoom` and `ResetAgentZoom ` actions, allowing to
return the zoom level across the whole app and/or just in the agent
panel to its default/original value.
Closes https://github.com/zed-industries/zed/issues/41094
This PR adds the `agent_buffer_font_size` settings to be scaled in the
same proportion as the agent panel's UI font size, which was the only
setting that was being accounted for. This is something that I forgot to
do when we broke down the agent panel's font size controls into these
two values.
Release Notes:
- agent: Fixed an issue where the agent panel's buffer and UI font size
wouldn't scale proportionally.
Closes#40589
Replaced `System::new_all()` with `System::new_with_specifics` to fetch
only essential process information and exclude non-main threads from the
process list
after fix:
<img width="641" height="474" alt="image"
src="https://github.com/user-attachments/assets/32335552-2f7a-4317-8c01-f37b2eadfdc1"
/>
Release Notes:
- Fix duplicate process entries in WSL debug attach list
Update `project::buffer_store::BufferStore.save_buffer_as` in order to
correctly update the `path_to_buffer_id` hash map, ensuring that the
currently open file's path is dissociated from the buffer's id, to
prevent the new buffer from being open when trying to open the original
file.
Closes#29783
Release Notes:
- Fixed issue where using `workspace: save as` would prevent users from
opening the original file from which the new file was created
---------
Co-authored-by: Piotr Osiewicz <24362066+osiewicz@users.noreply.github.com>
This PR removes the behavior that the number_field changes focus to the
previous element when using the decrement button.
I mainly noticed this while decreasing the tab-size of a language, since
it there closes the page...
Please note that I am unsure what if any purpose this code has.
I was unable to find a use case and since it is not present in the
`increment_handler` I guess it should never have been here
---
Release Notes:
* Fixed wrongly focus previous element on number_field decrement
Using the cool, [recently
added](https://github.com/zed-industries/zed/pull/40940) `focus-visible`
support in some components. This will be particularly nice in the
settings UI, as it will not display the focus styles if you're
navigating it with a pointer device as opposed to the keyboard.
Release Notes:
- N/A
Just got a new Windows machine and realized that the rules library empty
state was completly busted. Ended up also adding some little UI tweaks
to make it better for both Windows and Linux.
Release Notes:
- N/A
Closes#40351
The leak mainly showed up in the appearance page because it had a lot of
dropdown menus. The problem occurred because the drop-down menus were
creating a new entity on each frame instead of using the
`window.use_state...` API.
Release Notes:
- settings ui: Fixed memory leak in UI
---------
Co-authored-by: Mikayla Maki <mikayla.c.maki@gmail.com>
Set a TLS bit to skip invoking the crash handler when a detached thread
panics.
cc @P1n3appl3 - is this at odds with what we need the crash handler to
do?
May close#39289, cannot repro without a nightly build
Release Notes:
- Fixed extension panics crashing Zed on Linux
Co-authored-by: dino <dinojoaocosta@gmail.com>
Closes#40581
Release Notes:
- git: No longer save clean files when staging (to avoid triggering
unnecessary rebuilds in external file watchers like vite)
Closes https://github.com/zed-industries/zed/issues/38453
Current `Buffer` API only allows getting buffer text with `\n` line
breaks — even if the `\r\n` was used in the original file's text.
This it not correct in certain cases like LSP formatting, where language
servers need to have original document context for e.g. formatting
purposes.
Added new `Buffer` API, replaced all buffer LSP registration places with
the new one and added more tests.
Release Notes:
- Fixed ESLint linebreak-style errors by preserving line endings in LSP
communication
---------
Co-authored-by: Claude <noreply@anthropic.com>
Co-authored-by: Kirill Bulatov <kirill@zed.dev>
Previously we had `Context` and `ContextStore` in both `agent_ui` (used
to store context for the inline assistant) and `assistant_context` (used
for text threads) which is confusing.
This PR makes it so that the `assistant_context` concepts are now called
`TextThread*`, the crate was renamed to `assistant_text_thread`
Release Notes:
- N/A
This PR does two related things:
- First, it gets rid of the undifferentiated `RepositoryEvent::Updated`
in favor of three new events that have clearer definitions:
`BranchChanged`, `StashEntriesChanged`, and `StatusesChanged`. An
implication of this is that we no longer emit a `RepositoryEvent` unless
some git state changed; previously we would emit `RepositoryUpdated`
after doing a git status scan even if no statuses changed.
- Second, it changes the subscription strategy of the project diff to
make it update more robustly. Previously, the project diff only
subscribed to the `GitStore`, so it relied on getting a `GitStoreEvent`
when some buffer's diff hunks changed, even if the git status of the
buffer's file didn't change (e.g. a second hunk in a file that was
already modified). After this PR, it also subscribes to the individual
`BufferDiff` entities for buffers that have a git status, so the
`GitStore` is freed from that responsibility. This also fixes some real
cases where the previous strategy was not effective in keeping the
project diff up to date (captured in a test).
Release Notes:
- Fixed some cases where the project diff would fail to update in
response to git events.
We still see a bunch of panics here but the default slicing panic
doesn't tell which side of the range is bad
Release Notes:
- N/A *or* Added/Fixed/Improved ...
Before, inlay chunks were retrieved from the cache based on actualized
anchor ranges, but using an old buffer snapshot. Now, update all chunks
and snapshot to the actual before returning the applicable ones.
Follow-up of https://github.com/zed-industries/zed/pull/40183
Release Notes:
- N/A
- Added "ctrl-p" for selecting the previous menu item
- Added "ctrl-n" for selecting the next menu item
Closes#40619
Release Notes:
- Ctrl+P now moves to the previous result; Ctrl+N moves to the next.
This shrinks it from roughly a ~kilobyte to 8 byte, removing a bunch of
memmoves emitted by the compiler. Also `Arc`'s it instead of boxing as
we do clone it a couple times here and there, making that also a fair
bit cheaper
Release Notes:
- N/A *or* Added/Fixed/Improved ...
Fixes ZED-12D
`wasmtime_wasi` might call into tokio futures (to sleep for example)
which requires access to the tokio runtime. So we are required to run
these extensions in the tokio thread pool
Release Notes:
- Fixed extensions causing zed to occasionally panic
I made three significant changes in this PR.
1. `SettingsWindow::fetch_files` now creates
`SettingsUiFile::Project(..)` for any worktree that contains no project
settings.
2. `update_settings_file` now creates an empty settings file if a
worktree doesn't contain one.
3. `open_current_settings_file` also creates a settings file if the
current one doesn't exist.
Release Notes:
- settings ui: Enable editing project settings for worktrees that don't
have a project setting file.
This PR gets the `SettingsWindow` struct to subscribe to all
`Entity<Project>` events and any future project entities that are
created. When a project emits an event that signals a worktree has been
added or removed, the settings window refetches all settings files it
can find.
This fixes a bug where the settings ui would notice some project
settings that were created or opened after the `SettingsWindow` has been
initialized.
I also renamed `LOCAL` file mask to `PROJECT` to be inline with the
`SettingsFile` naming convention.
Release Notes:
- settings ui: Fix bug where project setting files wouldn't be detected
if they were created or opened after while an active settings window is
open
Using `shlex` unconditionally is dangerous as it assumes the underlying
shell is POSIX which is not the case for PowerShell, CMD, or Nushell.
Therefore, whenever we want to quote the args we should utilise our
helper `util::shell::ShellKind::try_quote` which takes into account
which shell is being used to actually exec/spawn the invocation.
Release Notes:
- N/A
---------
Co-authored-by: Lukas Wirth <me@lukaswirth.dev>
This is a refactoring PR to simplify our environment loading code by:
- Getting rid of `EnvironmentErrorMessage` in favor of using
`anyhow::Result` everywhere, with a separate `mpsc` channel to
communicate statuses that will be shown in the activity indicator
- Inlining some functions that were only called once to reduce
indirection
- Removing the separate `direnv` module
Release Notes:
- N/A
Don't prepend the worktree root when using an absolute path from
`Worktree::which`, since that does the wrong thing when running in
wasmtime given two Windows absolute paths. Also don't pass this path to
`node`, since when npm installed it's a sh/cmd wrapper not a JS file.
Part of #39153, also needs a fix on the vscode-langservers-extracted
side (missing shebang for the vscode-html-language-server script).
Release Notes:
- Fixed Zed failing to run the HTML language server in some cases.
Just tidying this up a bit. Really have to fix this Banner component at
some point 😅 Having to add some spacing hacks to make it perfect here
that are not ideal and should be baked into the component.
Release Notes:
- N/A
Now that we have two surface areas that open as separate windows, it's
important they're consistent with one another. This PR make the settings
UI and rules library windows more similar by having them use the same
minimum window size and similar styles for their navbar given they have
fundamentally the same design (nav on the left and content on the
right).
Release Notes:
- N/A
<img width="335" height="236" alt="image"
src="https://github.com/user-attachments/assets/5e09e9ed-f0f3-48df-ac22-032edfc6c114"
/>
Release Notes:
This PR fixes inconsistent use of trailing ellipsis (…) in the MCP
Server menu.
Previously, some menu items (like Add Custom Server…) used hardcoded
ellipses even though they didn’t trigger additional dialogs or steps.
This change removes unnecessary ellipses to align with standard UI/UX
conventions used across Zed’s menus.
---------
Co-authored-by: Danilo Leal <67129314+danilo-leal@users.noreply.github.com>
Follow-up: https://github.com/zed-industries/zed/pull/34655
We should use an opaque fallback color for `panel.overlay_hover`. This
helps when a custom theme doesn’t provide it, nor `element.hover`. For
example, VSCode’s default modern dark theme doesn’t include an
`element.hover` color after import.
Release Notes:
- Fixed an issue where the project panel’s sticky entry could appear
transparent on hover with certain themes.
After clicking on the file drop-down and selecting a file, both the
selected file and the first drop-down entry would be the same file name
instead of overwriting a file name.
Release Notes:
- settings ui: Fix bug where duplicate file names showed in the header
files
Release Notes:
- agent: Improved the editing previous messages UX by focusing in the
agent panel's message editor after regenerating a prompt, instead of
moving focus to the nearest regular buffer.
Closes#39172
This refactors when we resolve UI keybindings in an effort to reduce
flickering whilst painting these: Previously, we would always resolve
these upon creating the binding. This could lead to cases where the
corresponding context was not yet available and no binding could be
resolved, even if the binding was then available on the next presented
frame. Following that, on the next rerender of whatever requested this
keybinding, the keybind for that context would then be found, we would
render that and then also win a layout shift in that process, as we went
from nothing rendered to something rendered between these frames.
With these changes, this now happens less often, because we only look
for the keybinding once the context can actually be resolved in the
window.
| Before | After |
| --- | --- |
|
https://github.com/user-attachments/assets/adebf8ac-217d-4c7f-ae5a-bab3aa0b0ee8
|
https://github.com/user-attachments/assets/70a82b4b-488f-4a9f-94d7-b6d0a49aada9
|
Also reduced cloning in the keymap editor in this process, since that
requiered changing due to this anyway.
Release Notes:
- Fixed some cases where keybinds would appear with a slight delay,
causing a flicker in the process
Closes https://github.com/zed-industries/zed/issues/40047
Closes https://github.com/zed-industries/zed/issues/24798
Closes https://github.com/zed-industries/zed/issues/24788
Before, each editor, even if it's the same buffer split in 2, was
querying for inlay hints separately, and storing the whole inlay hint
twice, in `Editor`'s `display_map` and its `inlay_hint_cache` fields.
Now, instead of `inlay_hint_cache`, each editor maintains a minimal set
of metadata (which area was queried by what task) instead, and all LSP
inlay hint data had been moved into `LspStore`, both local and remote
flavors store the data.
This allows Zed, as long as a buffer is open, to reuse the inlay hint
data similar to how document colors and code lens are now stored and
reused.
Unlike other reused LSP data, inlay hints data is the first one that's
possible to query by document ranges and previous version had issue with
caching and invalidating such ranges already queried for.
The new version re-approaches this by chunking the file into row ranges,
which are queried based on the editors' visible area.
Among the corresponding refactoring, one notable difference in inlays
display are multi buffers: buffers in them are not
[registered](https://microsoft.github.io/language-server-protocol/specifications/lsp/3.17/specification/#textDocument_didOpen)
in the language server until a caret/selection is placed inside their
excerpts inside the multi buffer.
New inlays code does not query language servers for unregistered
buffers, as servers usually respond with empty responses or errors in
such cases.
Release Notes:
- Reworked inlay hints to be less error-prone
---------
Co-authored-by: Lukas Wirth <lukas@zed.dev>
Co-authored-by: dino <dinojoaocosta@gmail.com>
Co-authored-by: Lukas Wirth <me@lukaswirth.dev>
In practice this just hides the web search tool when not using the Zed
provider
Release Notes:
- Fixed an issue where the web search tool would show up in the profile
selector even when not using a model via Zed Pro
Closes#40874
Release Notes:
- Fixed an issue where migrating settings after v0.208.5+ would
spuriously enable prettier. This fix only affects those who have not
updated or migrated yet. For those who have already updated to version
v0.208.5 or later, placing `"formatter": []` in your settings in the
affected languages will fix the issue.
---------
Co-authored-by: Mikayla <mikayla@zed.dev>
This PR switches us back to the upstream version of `async-tar` and
upgrades to v0.5.1.
This version has the patch we need:
0c18195639.
Release Notes:
- N/A
Closes https://github.com/zed-industries/zed/issues/39837
This PR adds support for `colspan` feature that is only supported for
HTML tables. I also fixed an edge case where the right side border was
not applied because it didn't match the total column count.
**Before**
<img width="725" height="179"
alt="499166907-385cc787-fc89-4e6d-bf06-c72c3c0bd775"
src="https://github.com/user-attachments/assets/69586053-9893-4c92-aa89-7830d2bc7a6d"
/>
**After**
<img width="1165" height="180" alt="Screenshot 2025-10-21 at 22 51 55"
src="https://github.com/user-attachments/assets/f40686e7-d95b-45a6-be42-e226e2f77483"
/>
```html
<table>
<tr>
<th rowspan="2">Region</th>
<th colspan="2">Revenue</th>
<th rowspan="2">Growth</th>
</tr>
<tr>
<th>Q2 2024</th>
<th>Q3 2024</th>
</tr>
<tr>
<td>North America</td>
<td>$2.8M</td>
<td>$2.4B</td>
<td>+85,614%</td>
</tr>
<tr>
<td>Europe</td>
<td>$1.2M</td>
<td>$1.9B</td>
<td>+158,233%</td>
</tr>
<tr>
<td>Asia-Pacific</td>
<td>$0.5M</td>
<td>$1.4B</td>
<td>+279,900%</td>
</tr>
</table>
```
**TODO**:
- [x] Add tests for rending logic
- [x] Test all the tables again
cc @bennetbo
Release Notes:
- Markdown: Added support for `colspan` and `rowspan` for HTML tables
---------
Co-authored-by: Zed AI <ai@zed.nl>
Co-authored-by: Anthony Eid <hello@anthonyeid.me>
Hello,
I am having a great time setting up the editor, but with a few problems
related to the Emacs keymap.
In this PR I have compiled changes in the default `emacs.json` that I
believe make the onboarding smoother for incoming emacs users.
This includes points that may need further discussion and some breaking
changes, although nothing that cannot be reverted with a quick
`keymap.json` overwrite.
(Please let me know if it is better to split up the PR)
### 1. Avoid fallbacks to the default keymap
all platforms:
- `ctrl-g` activating `go_to_line::Toggle` when there is nothing to
cancel
linux / windows:
- `ctrl-x` activating `editor::Cut` on the 1 second timeout
- `ctrl-p` activating `file_finder::Toggle` when the cursor is on the
first character of the buffer
- `ctrl-n` activating `workspace::NewFile` when the cursor is on the
last character of the buffer
### 2. Make all move commands operate on full words
In the current Zed implementation some commands run on full words and
others on subwords.
Although ultimately a matter of user preference, I think it is sensible
to use full words as the default, since that is what is shipped with
emacs.
### ~~3. Cancel selections after copy/cut commands~~ Moved to #40904
Canceling the selection is the default emacs behavior, but the way to
achieve it might need some brushing.
Currently I am using `workspace::SendKeystrokes` to copy ->
cancel(`ctrl-g`), but this has the following problems:
- can only be used in the main buffer (since `editor::Cancel` would
typically close secondary buffers)
- may cause problems downstream if the user overwrites the `ctrl-g`
binding
### ~~4. Replace killring with normal cut/paste commands~~ Moved to
#40905
Ideally Zed would support emacs-like killrings (#25270 and #22490).
However, I understand that making an emacs emulator is not a project
goal, and the Zed team should have a bunch of tasks with higher
priority.
By using a unified clipboard and standard cut/paste commands, we can
provide an experience that is closer to the out-of-the-box emacs
behavior (#33351) while also avoiding some pitfalls of the current
killring implementation (#28715).
### 5. Promote some bindings to workspace commands
- `alt-x` as `command_palette::Toggle`
- `ctrl-x b` and `ctrl-x ctrl-b` as `tab_switcher::Toggle`
---
Release Notes:
- emacs: Fixed a problem where keys would fallback to their default
keymap binding on certain conditions
- emacs: Changed `alt-f` and `alt-b` to operate on full words, as in the
emacs default
- emacs: `alt-x`, `ctrl-x b`, and `ctrl-x ctrl-b` are now Workspace
bindings
Re-lands https://github.com/zed-industries/zed/pull/40719, fixes the
bugs that were discovered with it and improves some more stuff in that
area
Release Notes:
- Fixed a rare issue where the extension page would stutter while
scrolling.
---------
Co-authored-by: Agus Zubiaga <agus@zed.dev>
This PR renames the `agent::QuoteSelection` to
`agent::AddSelectionToThread` _and_ adds it as a menu item in both the
right-click context menu within regular buffers as well as the
"Selection" app menu.
We've received feedback in the past about how hard to discover this
feature is, and after watching [the Syntax podcast
crew](https://www.youtube.com/watch?v=bRK3PeVFfVE) recently struggle
with doing so—and then naturally looking for it in the context menu and
not finding it—it felt like time to push a change. I think the rename +
the availability in these places could help bringing it to surface more.
The same action can be done in Cursor through the `cmd-l` keybinding,
but in Zed, that triggers `editor::SelectLine`, which I don't want to
override by default. However, if you're using Cursor's keymap, then
`cmd-l` does trigger this action, as expected.
<img width="500" height="1812" alt="Screenshot 2025-10-22 at 12 01@2x"
src="https://github.com/user-attachments/assets/dfc2c41c-8d0a-4a1a-8ea1-1bd5d1aa1171"
/>
Release Notes:
- agent: Improves discoverability of the previously called "quote
selection" action—which allows to add a text selection in a buffer as
context within the agent panel—by renaming it to "add selection to
thread" and making it available from the right-click editor context menu
as well as the "Selection" app menu.
The suggested `→` appears tiny, and almost looks like just a dot on my
monitor, and I got quite confused for a while thinking the
`whitespace_map.tab` setting wasn't working properly.
<img width="630" height="105" alt="Image"
src="https://github.com/user-attachments/assets/98feced2-39b3-4734-83e4-b4573b4e52c2"
/>
I think it would be really helpful if `⟶` was suggested instead since
that displays properly.
<img width="625" height="104" alt="Image"
src="https://github.com/user-attachments/assets/176886ab-cf88-4079-90a8-91a8e8182092"
/>
---
I am using `Fira Code` as my font on windows, however when I remove that
config to get the default font, it also still appears the same size. So
I don't believe this is just a font issue on my machine.
Thought I am using Windows, so I would be willing to believe this a
render issue specific to windows
Release Notes:
- N/A
Reverts zed-industries/zed#40719
This unveiled some bigger issues with the UniformList size computations,
which are more crucial than what was fixed here.
Release Notes:
- NOTE: BUGFIX "Fixed a rare issue where the extension page would
stutter while scrolling." was reverted due to some other issues
This simplifies some code and is also more correct in some others (I
believe some of these might've overflowed causing panics in sentry)
Release Notes:
- N/A *or* Added/Fixed/Improved ...
Closes#37726
Release Notes:
- Fixed an issue where the buffer would not regain focus when clicked
while a filename edit was in progress in the project panel.
---------
Co-authored-by: Smit Barmase <heysmitbarmase@gmail.com>
Should be merged with
https://github.com/zed-industries/extensions/pull/3584, which adds
`slang-server` as a new language server, but should be disabled by
default due to an issue with it not initializing on Windows and being a
relatively new language server in general.
Release Notes:
- N/A
Currently running `cargo update` on Zed will break the collab crate
because the versions of sea-orm and sea-orm-macros will not match. This
results in a bunch of noisy warnings from rust-analyzer.
Release Notes:
- N/A
Fixes a bug in https://github.com/zed-industries/zed/pull/39928
The bug caused all completions to appear in bold-face
Release Notes:
- Fixed a bug where bold-face font was applied to the wrong characters
in items in the autocomplete menu
Co-authored-by: Mikayla Maki <mikayla.c.maki@gmail.com>
In remote connections, we don't detect whether trashing is possible and
generally shouldn't assume it is. This also fixes up some incomplete
logic that was attempting to do that.
Closes#39212
Release Notes:
- No longer show trash option in remote projects
In the process of adding pickers for the theme and icon themes fields in
the settings UI, I felt like there was an improvement opportunity in
regards to where some of these components are stored. The `ui_input`
crate originally was meant only for the text field-like component, which
couldn't be in the regular `ui` crate due to the dependency with
`editor`. Given we had also added the number field there—which is
similar in also having the same dependency—it made sense to think of
this crate more like a home for form-like components rather than for
only one component.
However, we were also storing some settings UI-specific stuff in that
crate, which didn't feel right. So I ended up creating a new directory
within the `settings_ui` for components and moved all the pickers and
the custom input field there. I think this makes it for a cleaner
structure.
Release Notes:
- settings_ui: Added the ability to search for theme and icon themes in
their respective fields.
Follows on from https://github.com/zed-industries/zed/pull/39949.
Again I'm not 100% sure of the intent but I think this is a fix:
`generate_random_string(rng, 4096)` would previously give you a string
of 4096 *chars* which could be anywhere between 4kB and 16kB in bytes.
This seems probably not what was intended, because Ropes generally work
in bytes not chars, including for the offsets used to index into them.
This seems to possibly cause a _regression_ in benchmark performance,
which is surprising because it should generally cause smaller test data.
But, possibly it's doing better at exercising different paths?
cc @mrnugget
Release Notes:
- N/A
This means that existence of activation scripts for venv/virtualenv will
be checked locally either on the host if editing locally, or the remote
by the remote proxy if editing a remote project.
Closes https://github.com/zed-industries/zed/issues/40263
Release Notes:
- N/A
Closes#40748
This PR improves the Centered Layout Padding in settings ui by limiting the numeric stepper to be within valid values and adding a custom schema generated to improve the JSON LSP completions and warnings when editing the setting field manually.
Release Notes:
- settings ui: limit stepper increment for centered padding between 0 and 0.4 and increment by 0.05 now
---------
Co-authored by: Anthony Eid <anthony@zed.dev>
We document the location of the log file in many places, we should just
make it easy to open directly within your file browser. The one thing
here is naming. We use dynamic naming for "reveal" actions in the
project panel, to reflect the right file manager name per OS, but for a
command palette action, I dont think we want to have dynamic code for
the action name, just going with finder at the moment.
Release Notes:
- Added a `zed: reveal log in file manager` action to the command
palette.
- Improves the UI for subfields of dynamic items
- Makes description writing more consistent (add period at the end of
every sentence, fix capitalization of proper names, ensure description
is always in sentence case)
- Other small details, mostly around spacing/padding
Release Notes:
- N/A
Hopefully, this will make the install/configure/uninstall buttons in the
right stand out a bit more and make their presence a bit more obvious
for newcomers.
| Before | After |
|--------|--------|
| <img width="1938" height="1276" alt="Screenshot 2025-10-21 at 10
58@2x"
src="https://github.com/user-attachments/assets/b76115e1-0be2-4d5b-a677-525663d86c7c"
/> | <img width="1938" height="1276" alt="Screenshot 2025-10-21 at 10
53@2x"
src="https://github.com/user-attachments/assets/9e563b71-b11a-4b69-b687-c0b469ca4eec"
/> |
Release Notes:
- Increased affordance of the download button in each extension card in
the extensions page.
Just wanted a single location to point people to for telling them where
to find their log file. I left duplicate text in GitHub Issue templates,
as it seems annoying to have to follow a link when making an issue.
Release Notes:
- N/A
Closes#40608
Release Notes:
- settings_ui: Fixed an issue where tabbing to the nav bar from the
search bar while the nav bar was scrolled would result in the first
_visible_ nav entry being selected, instead of the literal first nav
entry
- settings_ui: Fixed an issue where scrolling the selected nav entry off
screen would cause the keyboard shortcut hint for the focus nav / focus
content binding to dissapear
- settings_ui: Fixed an issue where text input controls could not be
focused via the keyboard
Release Notes:
- Improved text color in LSP document color highlight.
----
Because highlight ranges are implemented using a paint background,
there's no way to control the text color.
I've been thinking about this problem for a long time, want to solve it.
~~Today, I come up with a new idea. Re-rendering the document color text
at the top should solve this problem.~~
#### Update 10/6:
> The previous version is not good, when we have soft wrap text, that
version will not work correct.
Now use exists `bg_segments_per_row` feature to fix text color.
## Before
<img width="563" height="540" alt="image"
src="https://github.com/user-attachments/assets/99722253-0cab-4d2a-a5d1-7f28393bcaed"
/>
## After
<img width="544" height="527" alt="image"
src="https://github.com/user-attachments/assets/a1bf6cdb-0e9c-435d-b14a-6ee9159a63d9"
/>
It keeps popping up in my project searches ... This prevents that. Not
like we are planning on editing that file again.
Release Notes:
- N/A *or* Added/Fixed/Improved ...
In an attempt to figure out what's wrong with `point_to_buffer_offset`
for crash https://github.com/zed-industries/zed/issues/40453. We want to
know which branch among these two is the bad one.
Release Notes:
- N/A
Co-authored-by: Lukas Wirth <lukas@zed.dev>
We were spawning the process on the foreground thread before which can
block an arbitrary amount of time. Likewise we no longer block
deserialization on the terminal loading.
Release Notes:
- Improved startup time on systems with slow process spawning
capabilities
The `vim::visual::Vim.visual_block_motion` method was recently updated
(https://github.com/zed-industries/zed/pull/39355) in order to jump
between buffer rows instead of display rows. However, with this now
being the case, the `break` condition was never met when the motion was
horizontal rather than vertical and soft wrapped lines were used. As
such, this commit udpates the condition to ensure it's always reached,
preventing the hanging from happening.
Release Notes:
- Fixed hang in Vim's visual block motions when updating selections
---------
Co-authored-by: Piotr Osiewicz <24362066+osiewicz@users.noreply.github.com>
I noticed we had some typos that were getting through CI, but it looks
like the new version of `typos` catches them. So I updated it and fixed
them.
Release Notes:
- N/A
Adds a way to submit feedback about a zeta2 prediction from the
inspector. The telemetry event includes:
- project snapshot (git + unsaved buffer state)
- the full request and response
- user feedback kind and text
Release Notes:
- N/A
I did not bump it for Linux as some machines have smaller disks (~300GB
or so); with Mac, we have at least 1TB on all of our boxes
Release Notes:
- N/A
Following a conversation with the maintainer/owner of
kotlin-language-server, he recommended switching to the official
language server, which is better in many aspects and also more actively
maintained.
Release Notes:
- Made the official Kotlin Language Server the default language server
for Kotlin.
This fixes an issue where we would search for the hovered diff hunk
based on the mouse hit test computed during (or prior) editor paint
instead of the mouse hit test computed prior to the mouse event
invocation.
That in turn could lead to cases where moving the mouse from the editor
to the project panel and then clicking a file shortly after would expand
a diff hunk when actually nothing should happen in that case.
Release Notes:
- Fixed an issue where diff hunks would sometimes erroneously toggle
upon mouse clicks.
I maintain this repository that contains several developer tools like
- ghostty
- zig
- yazi
all of them are updated usually the same day as upstream.
Release Notes:
- N/A
Closes #ISSUE
it is was still in
[discussion](https://github.com/zed-industries/zed/discussions/37983)
Release Notes:
- Added: `--reuse` (`-r`) CLI flag to replace the workspace in an
existing window instead of opening a new one
This PR adds a new `--reuse` (`-r`) CLI flag that allows users to
replace the workspace in an existing Zed window instead of opening a new
one or adding files to the current workspace.
### What it does
The `--reuse` flag finds an available local workspace window and
replaces its workspace with the newly specified paths. This provides a
third workspace opening mode alongside the existing `--add` and `--new`
flags.
### Implementation Details
- **CLI Flag**: Added `--reuse` (`-r`) flag with proper mutual exclusion
with `--add` and `--new`
- **Window Replacement**: Uses the existing `replace_window` option in
`workspace::OpenOptions`
- **Window Selection**: Reuses the first available local workspace
window
- **Fallback Behavior**: When no existing windows are found, creates a
new window
- **Test Coverage**: Added comprehensive test for the reuse
functionality
### Behavior
- `zed -r file.txt` - Replaces the workspace in an available window with
`file.txt`
- If no windows are open, creates a new window (same as default
behavior)
- Mutually exclusive with `-a/--add` and `-n/--new` flags
- Works with multiple files and directories
### Files Changed
- `crates/cli/src/cli.rs` - Added `reuse` field to `CliRequest::Open`
- `crates/cli/src/main.rs` - Added CLI argument definition and parsing
- `crates/zed/src/zed/open_listener.rs` - Implemented reuse logic and
added tests
- `crates/zed/src/zed/windows_only_instance.rs` - Updated for Windows
compatibility
### Testing
- ✅ Unit tests pass
- ✅ Manual testing confirms expected behavior:
- Works when no windows are open
- Replaces workspace in existing window
- Maintains compatibility with existing `-a` and `-n` flags
- Proper help text display
## Manual testing
#### In this first video we do a couple of tests:
* **1**: What happens if we use the -r flag when there are no windows
open?
- works as expected. It opens the files in a new window.
* **2**: Does it work as expected if there is already a window open.
Does it overrides the workspace?
- yes it does. When opening a different file it overrides the current
window instead of creating a new one.
* **3**: Does the -n flag still works as expected?
- yes, it creates the project in a new window
* **4**: What about the -a flag?
- yes, on the last accessed page
* **5**: we do the replace command. It overrides the first opened
window, do we want this behavior?
- It is good enough that it overrides one of the opened windows with the
new project. It still makes the user automatically go to the window with
the specified files
* **6**: we use the -r command again replacing the workspace with a new
one.
- this indeed worked as expected
https://github.com/user-attachments/assets/f1cd7f4b-f4af-4da2-a755-c0be7ce96c0d
#### In here the we check how the --help flag now displays the new
command. (Description was later updated)
https://github.com/user-attachments/assets/a8a7a288-d926-431b-a9f9-a8c3d909a2ec
Closes#39901
I'm unsure as to which direction the team wants to go with this, but
this is the behavior of VSCode which is what this feature is based off
so i'm going with this.
Changes:
1. Introduced a new argument to the `new` method on the Pane called
`ignore_max_tabs` that forces the `max_tabs` to None if it's true.
2. Added a new test `test_bypass_max_tabs_limit`.
Release Notes:
- Fixed: `max_tabs` Setting affecting the terminal pane.
---------
Co-authored-by: Joseph T. Lyons <JosephTLyons@gmail.com>
This is needed for #38914 and seems generally useful to have for
contextual keybindings.
Release Notes:
- N/A
---------
Co-authored-by: David Kleingeld <davidsk@zed.dev>
Changes that I made:
- add "scrollbar.thumb.active_background" to all themes
- for dark themes: scrollbar.thumb.background is darker than hover (fg4
from palette for background and fg0 for hover)
- for light themes: scrollbar.thumb.background is lighter than hover
(fg4 for background and fg0 for hover like in dark theme case)
Those changes is consistent with VSCode gruvbox theme and other
applications.
For active_background I chose orange color, but we can use cyan color to
match vscode theme.
UPDATE: decided to use blue for active scrollbar as this color is used
as accent in other parts of gruvbox themes
Release Notes:
- Improved scrollbar colors for Gruvbox theme
---------
Co-authored-by: Danilo Leal <daniloleal09@gmail.com>
## 🎯 Description
Adds configurable window control buttons (minimize, maximize, close)
positioning for Linux, allowing users to choose between macOS-style
(left side) or Windows-style (right side) placement.
## ✨ Features
- New `title_bar.window_controls_position` setting with `"left"` and
`"right"` options
- Left positioning: macOS style (Close → Minimize → Maximize)
- Right positioning: Windows style (Minimize → Maximize → Close)
- Fixed transparent background issues for window controls
- Maintains consistent styling with Zed's theme
## 🔧 Technical Changes
### Settings System
- Added `WindowControlsPosition` enum in `settings_content.rs`
- Extended `TitleBarSettingsContent` with `window_controls_position`
field
- Updated `TitleBarSettings` to include the new configuration
### Title Bar Layout
- Modified `platform_title_bar.rs` to use setting for layout positioning
- Added conditional logic for `justify_start()` vs `justify_between()`
based on position
- Fixed transparent container background by adding `bg(titlebar_color)`
### Window Controls
- Updated `platform_linux.rs` to reorder buttons based on position
setting
- Changed button background from `ghost_element_background` to
`title_bar_background`
- Implemented proper button sequencing for both positions
## 🧪 How to Test
1. Add to your Zed settings:
```json
{
"title_bar": {
"window_controls_position": "left"
}
}
```
or
```json
{
"title_bar": {
"window_controls_position": "right"
}
}
```
2. Restart Zed
3. Verify buttons are positioned correctly
4. Check that background is not transparent
5. Test button functionality (minimize, maximize, close)
## �� Expected Behavior
- **Left position**: Buttons appear on the left side of the title bar in
Close → Minimize → Maximize order
- **Right position**: Buttons appear on the right side of the title bar
in Minimize → Maximize → Close order
- **Background**: Solid background matching Zed's theme (no
transparency)
## 🔍 Files Changed
- `crates/settings/src/settings_content.rs` - Added enum and setting
- `crates/title_bar/src/title_bar_settings.rs` - Updated settings struct
- `crates/title_bar/src/platform_title_bar.rs` - Modified layout logic
- `crates/title_bar/src/platforms/platform_linux.rs` - Updated button
ordering and styling
## 🎨 Design Rationale
This feature provides Linux users with the flexibility to choose their
preferred window control button layout, improving the user experience by
allowing them to match their desktop environment's conventions or
personal preferences.
## ✅ Checklist
- [x] Code compiles without errors
- [x] Settings are properly serialized/deserialized
- [x] Background transparency issues resolved
- [x] Button ordering works correctly for both positions
- [x] Layout adapts properly based on configuration
- [x] No breaking changes to existing functionality
## 🔗 Related
This addresses the need for customizable window control positioning on
Linux, providing consistency with user expectations from different
desktop environments.

Closes#40608
This fixes tabbing in both the settings ui nav bar and page content
going off screen instead of scrolling the focused element into a visible
view.
The bug occurred because `gpui::list` and `gpui::uniform_list` only
render visible elements, preventing non visible elements in a view from
having their focus handle added to the element tree. Thus making the tab
stop map skip over those elements because they weren't present.
The fix for this is scrolling to reveal non visible elements and then
focus the selected element on the next frame.
Release Notes:
- settings ui: Auto scroll to reveal items in navigation bar and window
when tabbing
---------
Co-authored-by: Ben Kunkle <ben@zed.dev>
A cherry-pick of
f5188d55fb
This fixes a hard-to-reproduce crash caused excerpts removal not
updating previous snapshot data after corresponding inlay data was
removed.
Same branch has a test:
8783a9eb4f
that does not fail on `main` due to different way inlays are queried, it
will be merged later.
Release Notes:
- N/A
Closes#5294
This PR adds a line ending indicator to the status bar, hidden by
default as discussed in
https://github.com/zed-industries/zed/issues/5294.
### Changes
- 8b063a22d8700bed9c93989b9e0f6a064b2e86cf add the indicator and
`status_bar.line_endings_button` setting.
- ~~9926237b709dd4e25ce58d558fd385d63b405f3b changes
`status_bar.line_endings_button` from a boolean to an enum:~~
<details> <summary> show details </summary>
- `always` Always show line endings indicator.
- `non_native` Indicate when line endings do not match the current
platform.
- `lf_only` Indicate when using unix-style (LF) line endings only.
- `crlf_only` Indicate when using windows-style (CRLF) line endings
only.
- `never` Do not show line endings indicator.
I know this many options might be overdoing it, but I was torn between
the pleasant default of `non_native` and the simplicity of `lf_only` /
`crlf_only`.
My thinking was if one is developing on a project which exclusively uses
one line-ending style or the other, it would be nice to be able to
configure no-indicator-in-the-happy-case behavior regardless of the
platform zed is running on. But I'm not really familiar with any
projects that use exclusively CRLF line endings in practice. Is this a
scenario worth supporting or just something I dreamed up?
</details>
- 01174191e4cf337069e7a31b0f0432ae94c52515 rename the action context for
`line ending: Toggle` -> `line ending selector: Toggle`.
When running the action in the command palette with the old name I felt
surprised to be greeted with an additional menu, with the new name it
feels more predictable (plus now it matches
`language_selector::Toggle`!)
### Future work
Hidden status bar items still get padding, creating inconsistent spacing
(and it kind of stands out where I placed the line-endings button):
<img alt="the gap after the indicator is larger than for other buttons"
src="https://github.com/user-attachments/assets/24a346d4-3ff6-4f7f-bd87-64d453c2441a"
/>
I started a new follow-up PR to address that:
https://github.com/zed-industries/zed/pull/39992
Release Notes:
- Added line ending indicator to the status bar (disabled by default;
enabled by setting `status_bar.line_endings_button` to `true`)
We very frequently move this in and out of the windows slot map on
`update_window_id` calls (and we call this a lot!). This alone showed up
as `memmove`s at roughly 1% perf in Instruments when scrolling a buffer
which makes sense, `Window` itself is 4kb in size. The fix is simple,
just box the `Window` instances, moving a pointer is cheap in
comparison.
Release Notes:
- N/A *or* Added/Fixed/Improved ...
I noticed that branch picker doesn't close until the checkout operation
is completed.
While normally it's not an issue, it becomes obvious if there are longer
running post checkout hooks. In that case selecting a branch makes it
feel like nothing has happened (there's a small indicator in the footer)
so it's possible to click it multiple times. Closing the modal before
the operation completes leads to the error modal saying `Failed to
change branch. entity released. Please try again.` even though the
checkout was successful.
The new behavior is to close the branch picker as soon as the branch is
selected. This also aligns with the existing behavior in `create_branch`
where `cx.emit(DismissEvent);` is called without waiting for
`repo.update`.
And as I mentioned before there an indicator in the footer saying `git
switch <branch_name>` with a spinner thingy.
I also added a check in the picker's `open` function where it first
checks if there's currently an active job and does not show the picker
in that case.
If this generally makes sense I can add the tests as well if needed.
P.S I checked how it works in VSCode and yes it also closes the branch
picker as soon as the branch is selected. The only difference is that
they show the loading indicator right next to the branch name (with a
new branch) but in our case the current branch and activity indicator
are located in different places.
<details><summary>Before</summary>
https://github.com/user-attachments/assets/adf08967-d908-45fa-b3f6-96f73d321262
</details>
<details><summary>After</summary>
https://github.com/user-attachments/assets/88c7ca41-7b39-42d6-a98b-3ad19da9317c
</details>
Release Notes:
- The branch picker now closes immediately after a branch is selected,
instead of waiting for the branch switch to complete.
Closes#39865
Release Notes:
- Fixed file finder display when searching for files in history if you
had several worktrees opened in a workspace. It now displays the
worktree root name to avoid confusion if you have several files with
same name in different worktrees.
---------
Signed-off-by: Benjamin <5719034+bnjjj@users.noreply.github.com>
Closes #ISSUE
Adds a `Maybe<T>` type to `settings_content`, that makes the distinction
between `null` and omitted settings values explicit. This unlocks a few
more settings in the settings UI
Release Notes:
- N/A *or* Added/Fixed/Improved ...
We were dropping the entities once we created the buffers, so the weak
entities could never be upgraded. This treats new locations we see the
same as we would for a read/write call and stores the entity so that we
can follow like we normally would.
Release Notes:
- acp: Fix following not working with certain tool calls.
I love keybindings.
I spend way to much time thinking about them.
I also REALLY like working in Zed.
so far, however, I have found the key context system in Zed to be less
flexible than in VSCode.
the HUGE context that is available in VSCode helps you create
keybindings for very specific targeted scenarios.
the tree like structure of the Zed key context means you loose some
information as focus moves throughout the application.
For example, it is not currently possible to create a keybinding in the
editor that will only work when one of the Docks is open, or if a
specific dock is open.
this would be useful in implementing solutions to ideas like #24222
we already have an action for moving focus to the dock, and we have an
action for opening/closing the dock, but to my knowledge (very limited
lol) we cannot determine if that dock *is open* unless we are focused on
it.
I think it is possible to create a more flexible key binding system by
adding more context information to the higher up context ancestors.
while:
```
Workspace right_dock=GitPanel
Dock
GitPanel
Editor
```
may seem redundant, it actually communicates fundamentally different
information than:
```
Workspace right_dock=GitPanel
Pane
Editor
```
the first says "the GitPanel is in the right hand dock AND IT IS
FOCUSED",
while the second means "Focus is on the Editor, and the GitPanel just
happens to be open in the right hand dock"
This change adds a new set of identifiers to the `Workspace` key_context
that will indicate which docks are open and what is the specific panel
that is currently visible in that dock.
examples:
- `left_dock=ProjectPanel`
- `bottom_dock=TerminalPanel`
- `right_dock=GitPanel`
in my testing the following types of keybindings seem to be supported
with this change:
```jsonc
// match for any value of the identifier
"context": "Workspace && bottom_dock"
"context": "Workspace && !bottom_dock"
// match only a specific value to an identifier
"context": "Workspace && bottom_dock=TerminalPanel"
// match only in a child context if the ancestor workspace has the correct identifier
"context": "Workspace && !bottom_dock=DebugPanel > Editor"
```
some screen shots of the context matching in different circumstances:
<img width="2032" height="1167" alt="Screenshot 2025-10-16 at 23 20 34"
src="https://github.com/user-attachments/assets/116d0575-a1ae-4577-95b9-8415cda57e52"
/>
<img width="2032" height="1167" alt="Screenshot 2025-10-16 at 23 20 57"
src="https://github.com/user-attachments/assets/000fdbb6-80bd-46e9-b668-f4b54ab708d2"
/>
<img width="2032" height="1167" alt="Screenshot 2025-10-16 at 23 21 37"
src="https://github.com/user-attachments/assets/7b1c82da-b82f-4e14-a97c-3cd0e71bbca0"
/>
<img width="2032" height="1167" alt="Screenshot 2025-10-16 at 23 21 52"
src="https://github.com/user-attachments/assets/1fd4b65a-09f7-47a9-a9b7-fdce4252aec3"
/>
<img width="2032" height="1167" alt="Screenshot 2025-10-16 at 23 22 38"
src="https://github.com/user-attachments/assets/f4c2ac5c-e6f9-4e0e-b683-522b237e3328"
/>
the persistent_name values for `ProjectPanel` and `OutlinePanel` needed
to be updated to not have a space in them in order to pass the
`Identifier` check. all the other Panels already had names that did not
include spaces, so it just makes these conform with the other ones.
I think this is a great place to start with adding more context
identifiers and i think this type of additional information will make it
possible to create really dynamic keybindings!
Release Notes:
- Workspace key context now includes the state of the 3 docks
Reduces peak stack usage in these functions and should generally be a
bit performant.
Display map benchmark results
```
To tab point/to_tab_point/1024
time: [531.40 ns 532.10 ns 532.97 ns]
change: [-2.1824% -2.0054% -1.8125%] (p = 0.00 < 0.05)
Performance has improved.
Found 1 outliers among 100 measurements (1.00%)
1 (1.00%) high severe
To fold point/to_fold_point/1024
time: [530.81 ns 531.30 ns 531.80 ns]
change: [-2.0295% -1.9054% -1.7716%] (p = 0.00 < 0.05)
Performance has improved.
Found 3 outliers among 100 measurements (3.00%)
2 (2.00%) high mild
1 (1.00%) high severe
```
Release Notes:
- N/A *or* Added/Fixed/Improved ...
Continues the work from #35927 to add a git diff view for stash entries.
[Screencast From 2025-09-17
19-46-01.webm](https://github.com/user-attachments/assets/ded33782-adef-4696-8e34-3665911c09c7)
Stash entries are [represented as
commits](https://git-scm.com/docs/git-stash#_discussion) except they
have up to 3 parents:
```
.----W (this is the stash entry)
/ /|
-----H----I |
\|
U
```
Where `H` is the `HEAD` commit, `I` is a commit that records the state
of the index, and `U` is another commit that records untracked files
(when using `git stash -u`).
Given this, I modified the existing commit view struct to allow loading
stash and commits entries with git sha identifier so that we can get a
similar git diff view for both of them.
The stash diff is generated by comparing the stash commit with its
parent (`<commit>^` or `H` in the diagram) which generates the same diff
as doing `git stash show -p <stash entry>`. This *can* be
counter-intuitive since a user may expect the comparison to be made
between the stash commit and the current commit (`HEAD`), but given that
the default behavior in git cli is to compare with the stash parent, I
went for that approach.
Hoping to get some feedback from a Zed team member to see if they agree
with this approach.
Release Notes:
- Add git diff view for stash entries
- Add toolbar on git diff view for stash entries
- Prompt before executing a destructive stash action on diff view
- Fix commit view for merge commits (see #38289)
Add new `workspace::NewFileSplit` action which expects a
`SplitDirection` argument, allowing users to programmatically control
the direction of the split in keymaps, for example:
```json
{
"context": "Editor",
"bindings": {
"ctrl-s ctrl-h": ["workspace::NewFileSplit", "left"],
"ctrl-s ctrl-j": ["workspace::NewFileSplit", "down"],
"ctrl-s ctrl-k": ["workspace::NewFileSplit", "up"],
"ctrl-s ctrl-l": ["workspace::NewFileSplit", "right"]
}
}
```
Release Notes:
- Added `workspace::NewFileSplit` action, which can be used to
programmatically split the editor in the provided direction.
Co-authored-by: Rian Drake <rian.drake@rocketwerkz.com>
Co-authored-by: dino <dinojoaocosta@gmail.com>
This is an in-progress work on changing how task scheduler affects
performance of project search. Instead of relying on tasks being
executed at a discretion of the task scheduler, we want to experiment
with having a set of "agents" that prioritize driving in-progress
project search matches to completion over pushing the whole thing to
completion. This should hopefully significantly improve throughput &
latency of project search.
Release Notes:
- Improved project search performance
---------
Co-authored-by: Smit Barmase <smit@zed.dev>
Co-authored-by: Smit Barmase <heysmitbarmase@gmail.com>
Release Notes:
- Added comment language injections for builtin languages. This enables
highlighting of `TODO`s and similar notes with the comment extension
installed.
Signed-off-by: Donnie Adams <donnie@thedadams.com>
Related to #9461, inspired by #39683
`await` and `yield` both seem somewhat debatable on whether they should
be considered the be control flow keywords.
For now I went with:
- `await`: no – The control flow effect of `await` is at a level does
not seem relevant for syntax highlighting.
- `yield`: yes – `yield` directly affects the output of a generator, and
is also included for consistency with Rust (#39683).
Happy to change these either direction.
<img width="1151" height="730" alt="SCR-20251008-izus"
src="https://github.com/user-attachments/assets/533ea670-863a-4c5c-aaa5-4a9bfa0bf0dd"
/>
---
Release Notes:
- Improved granularity of keyword highlighting for JS/TS/TSX: Themes can
now specify `keyword.control` for control flow keywords like `if`,
`else`, `return`, etc.
Adding this content after seeing people ask about how to make MCP
servers installed from Zed be picked up by external agents. At the
moment, this varies depending on the agent, and felt relevant to be
documented.
Release Notes:
- N/A
- Notable change is the use of a newtype for `ReplicaId`
- Fixes `WorktreeStore::create_remote_worktree` creating a remote
worktree with the local replica id, though this is not currently used
- Fixes observing the `Agent` (that is following the agent) causing
global clocks to allocate 65535 elements
- Shrinks the size of `Global` a bit. In a local or non-collab remote
session it won't ever allocate still.
Release Notes:
- N/A *or* Added/Fixed/Improved ...
Let's say you run this:
```
cd ~/proj-a
zed ~/proj-b
```
The `zed` process will execute with `current_dir() = ~/proj-a`, but a
`worktree_root_path() = ~/proj-b`. The old detection was then checking
if the Yarn SDK was installed in `proj-a` to decide whether to set the
tsdk value or not. This was incorrect, as we should instead check for
the SDK presence inside `proj-b`.
Release Notes:
- Fixed the Yarn SDK detection when the Zed pwd is different from the
opened folder.
The page about PHP in the docs doesn’t explain how to use Xdebug. I had
a lof of trouble setting it up the first time, then recently had another
headache trying to get it to work again, because the value for `adapter`
had changed from `PHP` to `Xdebug`.
It’s likely that my example config isn’t perfect or has redundant stuff
or whatever, feel free to amend it.
I also took the liberty to set the Phpactor and Intelephense headings to
level 3 because I felt like they were part of "Choosing a language
server."
Release Notes:
- N/A
# Why
While working on recent PR I have spotted that "Stage" and "Unstage"
buttons in "Uncommited Changes" toolbar are always active, even when
there is no changes made locally.
<img width="1628" height="656" alt="Screenshot 2025-10-10 at 00 49 06"
src="https://github.com/user-attachments/assets/6bdb9ded-17c8-4f84-8649-b297162c1992"
/>
# How
Re-use already existing button states for managing the disabled state of
"Uncommited Changes" toolbar buttons when changeset is empty.
Release Notes:
- Added disabled state for "Uncommited Changes" toolbar buttons when
there are no changes present
# Preview
<img width="1728" height="772" alt="Screenshot 2025-10-10 at 08 40 14"
src="https://github.com/user-attachments/assets/ff41d852-974e-4ce1-9163-ecd30e17d5d8"
/>
Closes#37322
Uses SFTP if available, otherwise falls back to SCP for uploading files
and directories to remote. This fixes an issue on older macOS versions
where outdated SCP can throw an ambiguous target error.
Release Notes:
- Fixed an issue where extensions wouldn’t work when SSHing into a
remote from older macOS versions.
Though we ship with `basedpyright`, `ruff` and a few other laps for
python, we run them all at once.
Release Notes:
- Only enable `basedpyright` and `ruff` by default when opening Python
files. If you prefer one of the other.
Refactor the find_tab_group method to use the question mark operator for
cleaner error handling, replacing the explicit if-else pattern with a
more concise chained approach.
Release Notes:
- N/A
Signed-off-by: Xiaobo Liu <cppcoffee@gmail.com>
### Problem
On Windows, the right Alt key was not working in keybindings (e.g.,
`Ctrl+Right Alt+B`), while the left Alt key worked correctly. This was
due to overly aggressive AltGr detection that treated any `right Alt +
left Ctrl` combination as AltGr, even on US keyboards where AltGr
doesn't exist.
### Root Cause
Windows internally represents AltGr (Alt Graph) as `right Alt + left
Ctrl` pressed simultaneously. The previous implementation always
excluded this combination from being treated as regular modifier keys to
support international keyboards. However, this broke keybindings using
right Alt on US/UK keyboards where users expect right Alt to behave
identically to left Alt.
### Solution
Implemented keyboard layout-aware AltGr detection:
1. Added `uses_altgr()` method to `WindowsKeyboardLayout` that checks if
the current keyboard layout is known to use AltGr (German, French,
Spanish, Polish, etc.)
2. Modified `current_modifiers()` to only apply AltGr special handling
when the keyboard layout actually uses it
3. Added explicit checking for both `VK_LMENU` and `VK_RMENU` instead of
relying solely on the generic `VK_MENU`
### Behavior
- **US/UK keyboards**: Right Alt now works identically to left Alt in
keybindings. `Ctrl+Right Alt+B` triggers the same action as `Ctrl+Left
Alt+B`
- **International keyboards** (German, French, Spanish, etc.): AltGr
continues to work correctly for typing special characters and doesn't
trigger keybindings
- **All keyboards**: Both Alt keys are detected symmetrically, matching
the behavior of left/right Windows keys
### Testing
Manually tested on Windows with US keyboard layout:
- `Ctrl+Left Alt+B` triggers keybinding
- `Ctrl+Right Alt+B` triggers keybinding
- Both Alt keys work independently in keybindings
Release Notes:
- Fixed Right Alt key not working in keybindings on Windows
Release Notes:
- Fixed misplaced comma in the autoclose description from:
"when you type (, Zed will ...)"
to
"when you type, (Zed will ...)"
---------
Co-authored-by: Danilo Leal <daniloleal09@gmail.com>
`env_logger` defaults to only showing error-level logs, but we show
info-level logs and above for the main Zed process, so I think it makes
sense for the remote server to behave the same way.
Release Notes:
- N/A
Re-applies https://github.com/zed-industries/zed/pull/30840
This PR re-applies the initial
[PR](https://github.com/zed-industries/zed/pull/30840). As it was closed
because it was hard to land, because of the many conflicts. This PR
re-applies the changes for it.
In several cases we were creating multiple display_map
snapshots within the same root-level function call.
Creating a display_map snapshot is quite slow, and in some
cases we were creating the snapshot multiple times.
Release Notes:
- N/A
We've been considering removing workspace-hack for a couple reasons:
- Lukas ran into a situation where its build script seemed to be causing
spurious rebuilds. This seems more likely to be a cargo bug than an
issue with workspace-hack itself (given that it has an empty build
script), but we don't necessarily want to take the time to hunt that
down right now.
- Marshall mentioned hakari interacts poorly with automated crate
updates (in our case provided by rennovate) because you'd need to have
`cargo hakari generate && cargo hakari manage-deps` after their changes
and we prefer to not have actions that make commits.
Currently removing workspace-hack causes our workspace to grow from
~1700 to ~2000 crates being built (depending on platform), which is
mainly a problem when you're building the whole workspace or running
tests across the the normal and remote binaries (which is where
feature-unification nets us the most sharing). It doesn't impact
incremental times noticeably when you're just iterating on `-p zed`, and
we'll hopefully get these savings back in the future when
rust-lang/cargo#14774 (which re-implements the functionality of hakari)
is finished.
Release Notes:
- N/A
A small follow-up to the settings refactor of a few weeks ago to move
all the VSCode settings imports
to one place.
This should make it easier to spot missing imports, and easier to test
the importer.
Release Notes:
- N/A
It is now possible to configure logging level of CodeLLDB adapter via
envs specified in project settings like so:
```
{
"dap": {
"CodeLLDB": {
"envs": {
"RUST_LOG": "debug"
}
}
}
}
```
Release Notes:
- N/A
`MultiBuffer::anchor_in_excerpt` currently just wraps the given text
anchor in a multibuffer anchor. This allows one to get a multibuffer
anchor that points outside its excerpt which is basically never what one
wants. This PR now does a bounds check and returns `None` if the given
text anchor is not within the bounds of the excerpt.
Release Notes:
- N/A *or* Added/Fixed/Improved ...
Co-authored-by: Kirill Bulatov <kirill@zed.dev>
Closes #ISSUE
Includes the start of how we can get rid of most of the `.unimplemented`
"Edit in JSON" buttons in the settings UI. For now only Theme selection
is implemented, follow ups will add more settings
Release Notes:
- N/A *or* Added/Fixed/Improved ...
Fixes#40034
Release Notes:
- `ctrl-c` (when you have a selection) and `ctrl-v` are now bound to
copy and paste by default in the windows terminal.
Co-authored-by: John Tur <john-tur@outlook.com>
Close#35715
Release Notes:
- Fixed to wrap long URLs in editor.
<img width="836" height="740" alt="image"
src="https://github.com/user-attachments/assets/635ce792-5f19-4c76-b131-0d270d09b103"
/>
I remember when I was working on CJK line wrapping support in the early
days, I considered making `\` a line wrapping character, but for some
reason it was on the list of characters that were not allowed to wrap.
In reference to VS Code, it looks like `&`, `/`, `?` should wrap, so I
removed all of them.
---------
Co-authored-by: Mikayla Maki <mikayla@zed.dev>
This is a follow-up PR to
https://github.com/zed-industries/zed/pull/39609, and attempts to
address hidden status bar items still contributing to the layout and
creating extra spacing.

- 203cbd634bfb1489b8afa4952d9594615a956b77 Adds a `.none()` method to
the `gpui::Styled` helper trait, so that status items can set their
display type to none inside their `render` method.
- 249f06e3de63b0ab32814f20e7105d8e2b642f02 Applies `.none()` to all the
status items.
- ~~499f564906c88336608c81615b11ebc9ab43d832~~ At first I was adding an
`is_visible` method to the `StatusBarView` trait, which would be used to
skip status bar items which would just render an empty div anyway, but I
felt duplicating the conditions for hiding the buttons between the
status items `is_visible` and `render` methods could be an attraction
for bugs, so I tried to find another approach. This commit contains
those changes, reverted immediately (if the `is_visible` approach is
preferred I can bring it back!)
- f37cb75f0519ceea1f3e1cc4f97087a5cb34b0fd (bonus!) Adds a condition to
the vim mode indicator to avoid a leading space when there are no
pending keys.
Release Notes:
- N/A
Hello,
Thanks for the great work.
I am adding some more bindings for the emacs keymap:
- `command_palette::Toggle` as replacement for the emacs command
dispatcher
- other default aliases for existing move / delete commands
- e.g. `alt-left` to move to previous word and `alt-del` to delete it
- some missing `SelectTo` equivalents for move commands on selection
mode
Release Notes:
- Added bindings for the Emacs keymap
The built-in Tailwind language already maps `HTML+ERB` to `erb`, and it
seems that `Ruby` files work as well just from enabling the language
server, so we can remove the unnecessary mapping.
Release Notes:
- N/A
Follow-up after #40417, which should've fixed hangs.
smol::fs uses a separate threadpool, which is a bit yuck.
This PR also added a benchmark you can use to run a full worktree scan
(initial one, that is) for arbitrary worktree.. and refactored worktree
scanner to use async locks, as otherwise tests were deadlocking. :)
I've benchmarked it against Zed, Linux and Chromium and saw a ~60% drop
in initial worktree scan times across the board.
Release Notes:
- Significantly (3.3x speedup over the old implementation) improved
speed of Zed's worktree scanner, that's responsible for synchronizing
the state of your project with the state of files on hard drive.
---------
Co-authored-by: Smit Barmase <heysmitbarmase@gmail.com>
Using a seeded PRNG to produce consistent test data and reduce
variability makes sense.
However, the way it was used previously, by always cloning the RNG,
means that every generated string is the same, and every offset is the
same. After this change, the tested value stream should still be the same on
each run of the benchmark, but the values within each run will vary.
The `generate_random_text` measured in chars also seems possibly
inconsistent with later comments about it being a number of bytes.
Release Notes:
- N/A
This caused issues with #40172, as it made Zed execute and block on tad
few more background tasks. Parker is ~cheap to create, hence we should
be ok to just create it at the time it is needed.
Release Notes:
- N/A
---------
Co-authored-by: Cole Miller <cole@zed.dev>
Closes#40359
We were segfaulting when opening a UTF-8 file starting with a byte order
mark due to a mismatch in our UTF-16 indexing calculations caused by
Core Foundations `replace_str` stripping the BOM internally. This PR
fixes the crash by replacing one of our manual calculations by calling
the Core Foundations API to get the length of a string.
Release Notes:
- Fixed a crash on macOS when opening a file that starts with a UTF-8
byte order mark (BOM).
Co-authored-by: HactarCE <6060305+HactarCE@users.noreply.github.com>
# Why
While playing with new Settings UI I have spotted that changing font
weight requires a lot of clicks. This is also a bit more annoying due to
lack of ability to enter the desired value by hand.
# How
Adjust step values for Font Weight stepper, the default increment has
been changed from 10 to 50, to cover (defined in spec `950` weight)
which some fonts might use, small step has been changed from 5 to 10,
and large step from 50 to 100.
Release Notes:
- Adjusted default step values for number input UI element used for
changing Font Weight in Settings UI.
Closes#40334
This reverts the change made in #39983, and includes a replacement
migration that will transform formatter settings values consisting of
only `code_action` format steps into the previously deprecated
`code_actions_on_format` in an attempt to restore the behavior to what
it was before the migration that deprecated `code_actions_on_format`.
This PR will result in a modified order in the `code_actions_on_format`
setting if it existed, however the decision was made to explicitly
ignore this for now, as this PR is primarily targeting users who have
already had the deprecation migration run, and no longer have the
`code_actions_on_format` key
Release Notes:
- Fixed an issue with a settings migration that deprecated the
`code_actions_on_format` setting. The `code_actions_on_format` setting
has been un-deprecated, and affected users will have the bad migration
rolled back with an updated migration
---------
Co-authored-by: Cole Miller <cole@zed.dev>
Co-authored-by: Mikayla Maki <mikayla.c.maki@gmail.com>
Co-authored-by: HactarCE <6060305+HactarCE@users.noreply.github.com>
`vim::Substitute` is a little different from the helix behavior, so this
PR adds helix versions. The most important difference (for my usage, at
least) is that if you're selecting whole lines then helix drops the `\n`
from the selection (much like vim's lines mode, except that helix bases
this behavior on the selection instead of having a different mode).
Release Notes:
- N/A
Closes#33637Closes#37332
and solves part of
https://github.com/zed-industries/zed/discussions/33580#discussioncomment-14195506
This improves the "C" and "alt-C" actions to work like helix.
It also adds "," which removes all but the newest cursors. In helix the
one that's left would be the primary selection, but I don't think that
has an equivalent yet, so this simulates what would be the primary
selection if it was never cycled with "(" ")".
Release Notes:
- Improved multicursor creation and deletion in helix mode
---------
Co-authored-by: Jakub Konka <kubkon@jakubkonka.com>
Instead of producing multiple code blocks for each edit history event,
we now produce a continuous unified diff.
Release Notes:
- N/A
---------
Co-authored-by: Oleksiy Syvokon <oleksiy.syvokon@gmail.com>
Update the keybindings used in the default keymaps to better align with
VSCode's defaults, with the following changes:
* Windows & Linux
* `ctrl-enter` has been replaced by `ctrl-i` for
`assistant::InlineAssist`
* `ctrl-shift-space` maps to `editor::ShowSignatureHelp` instead of
`editor::ShowWordCompletions`
* MacOS
* `ctrl-enter` has been replaced by `cmd-i` for
`assistant::InlineAssist`
* `cmd-i` has been replaced by `cmd-shift-space` for
`editor::ShowSignatureHelp`
Closes#39278
Release Notes:
- Changed the keybinding for `assistant: inline assist` from
`ctrl-enter` to `ctrl-i` for both Linux and Windows, and `cmd-i` for
MacOS. If you'd like to restore the old behavior, update your keymap
file with:
```
{
"context": "!ContextEditor > Editor && mode == full",
"bindings": {
"ctrl-enter": "assistant::InlineAssist"
}
}
```
- Changed the action dispatched by `ctrl-shift-space` from
`editor::ShowWordCompletions` to `editor::ShowSignatureHelp` on both
Linux and Windows. If you'd like to restore the old behavior, update
your keymap file with:
``` {
"context": "Editor",
"bindings": {
"ctrl-shift-space": "editor::ShowWordCompletions"
}
}
```
- Changed the keybinding for `editor: show signature help` on MacOS from
`cmd-i` to `cmd-shift-space`. If you'd like to restore the old behavior,
update your keymap file with:
``` {
"context": "Editor",
"bindings": {
"cmd-i": "editor::ShowSignatureHelp"
}
}
```
---------
Co-authored-by: Agus Zubiaga <agus@zed.dev>
Closes#39786
Release Notes:
- Fixed: Settings popup no longer keeps the process alive when closing
Zed on Windows
---------
Co-authored-by: Anthony <anthony@zed.dev>
Co-authored-by: Joseph T. Lyons <JosephTLyons@gmail.com>
Closes#40270
Release Notes:
- Fixed an issue with the settings migration to flatten `code_actions`
format steps where comments would cause enabled code actions to be
omitted from the migrated settings. If you were effected, restoring the
settings file backup and allowing the migration to re-run will result in
a valid settings file
- Fixed an issue where automated settings and keymap file updates would
occasionally assume 4-space indentation
smol::fs uses a separate threadpool, which is a bit yuck.
This PR also added a benchmark you can use to run a full worktree scan
(initial one, that is) for arbitrary worktree.. and refactored worktree
scanner to use async locks, as otherwise tests were deadlocking. :)
I've benchmarked it against Zed, Linux and Chromium and saw a ~60% drop
in initial worktree scan times across the board.
Release Notes:
- Significantly (3.3x speedup over the old implementation) improved
speed of Zed's worktree scanner, that's responsible for synchronizing
the state of your project with the state of files on hard drive.
---------
Co-authored-by: Smit Barmase <heysmitbarmase@gmail.com>
- Add `skip_soft_wrap` field to both `AddSelectionAbove` and
`AddSelectionBelow` actions. When set to `true`, which is now
the default this will skip soft wrapped lines when extending the
selections.
- Move the `start_of_relative_buffer_row` function from the
`vim::motion` module to the `editor::display_map::DisplaySnapshot`
implementation as a method.
- Update the default behavior for both `editor: add selection above` and
`editor: add selection below` commands in order to skip over soft
wrapped lines by default, mirroring VS Code's default behavior.
- Update existing keymaps to specify this `skip_soft_wrap` value for
both `AddSelectionAbove` and `AddSelectionBelow` actions.
Closes#16979
Release Notes:
- Updated both the `editor: add selection above` and `editor: add
selection below` commands to ignore soft wrapped lines. If you wish to
restore the old behavior, add the following to your keymap file:
```
{
"context": "Editor",
"bindings": {
"cmd-alt-up": ["editor::AddSelectionAbove", { "skip_soft_wrap": false
}],
"cmd-alt-down": ["editor::AddSelectionBelow", { "skip_soft_wrap": false
}]
}
}
```
---------
Co-authored-by: Smit Barmase <heysmitbarmase@gmail.com>
Moves the Codex warning into the thread so that we can render it nicer,
as well as provide an option to open the folder in WSL.
Release Notes:
- N/A
---------
Co-authored-by: Bennet Bo Fenner <bennetbo@gmx.de>
`TaskDialogIndirect` may return `IDCANCEL` when the user quits the
dialog via escape or alt+f4, so we need to account for that.
Fixes ZED-25H
Release Notes:
- Fixed panic when hitting escape in dialogs on windows
Closes#40234
Release Notes:
- Added `open_file_on_paste` setting to configure auto opening of file
on paste in the project panel.
---------
Co-authored-by: Smit Barmase <heysmitbarmase@gmail.com>
### What does this PR do?
- Adds default keybindings `gt` for navigating to the next tab and `gT`
for navigating to the previous tab in markdown viewer mode
### Why do we need this change?
- While previewing markdown files, the default vim bindings (`gt` and
`gT`) do not work for navigating between tabs. These bindings work
everywhere else, which provides a non-consistent experience for the
user.
### How do we do this change?
- Update the vim mode bindings to explicitly add handling for this mode
---------
Co-authored-by: Conrad Irwin <conrad.irwin@gmail.com>
Release Notes:
- N/A
---
- Set `.SystemUIFont` as the GPUI default font.
- Add `Arial` to font fallback list.
- Add `Adwaita Sans` to default fallback list for Gnome.
- Move `Ubuntu` font to front of Gnome to make sure Ubuntu System takes
priority over `Ubuntu` font.
Our application get some crash report:
```
panicked at /Users/admin/.cargo/git/checkouts/zed-a70e2ad075855582/f1db3b4/crates/gpui/src/text_system.rs:150:9:
failed to resolve font 'Helvetica' or any of the fallbacks: Zed Plex Mono, Helvetica, Segoe UI, Cantarell, Ubuntu, Noto Sans, DejaVu Sans
```
This change to add `Arial` to fallback list, this font was included in
macOS and Windows.
Ref link (search "Arial"):
> Mac OS X (now known as [macOS](https://en.wikipedia.org/wiki/MacOS))
was the first Mac OS version to include Arial;
> https://en.wikipedia.org/wiki/Arial
- macOS Sequoia: https://support.apple.com/en-us/120414
- Windows 10:
https://learn.microsoft.com/en-us/typography/fonts/windows_10_font_list
- Gnome: https://developer.gnome.org/hig/guidelines/typography.html
Having the chevron to the side of the avatar is arguably unnecessary at
this point; most apps out there (Reddit, YouTube, etc.), including here
on GitHub, have the avatar without any icon, pointing to how there
doesn't seem to be a problem with knowing that there's a menu behind it.
Therefore, figured we could simplify the UI a bit more here.
This also looks better on platforms where the window controls are on the
right (Linux/Windows).
Release Notes:
- N/A
Making all triggers have the same style when the picker is open
(including changing the icon when the picker opens on top of the
trigger). Also removed the footer from the ACP model selector given
there's nothing to consider when that's the case; users can only
configure LLM providers when using Zed's built-in agent.
Release Notes:
- N/A
Updates #40212
v0.9.0 is now stable and contains the fix for the line endings bug, so
we can return to installing from the stable channel as usual. This also
bumps the minimum version on Windows to v0.9.0 so that anyone on v0.8.x
or v0.9.0-preview.4 will be upgraded automatically.
Release Notes:
- N/A
This PR improves the rendering performance of the Settings UI window by
using `gpui::list` to render only the visible contents of a settings
page, instead of rendering the full content of a page. This fixes a lag
that the editor page has in debug builds.
I also added a new field `measuring_behavior` to `ListState` that has
`Visible` and `Measured` variances. `Visible` only measures and caches
the bounds of visible items plus the overdraw pixel offset. `Measure`
will cache all items’ bounds on the first layout phase, which fixes
problems with the scrollbar size/position being miscalculated.
Release Notes:
- N/A
---------
Co-authored-by: Mikayla Maki <mikayla@zed.dev>
Co-authored-by: Ben Kunkle <ben@zed.dev>
This is the first towards better logs for adapter binaries. Next up I
intend to somehow allow `codelldb` adapter in Zed to permit simple log
level so that we can pass `RUST_LOG=level` when spawning the child
process.
Release Notes:
- N/A
Makes the dropdown trigger button styling consistent with the other
buttons and allows to add a tooltip in the trigger through the popover's
`trigger_with_tooltip` method.
Release Notes:
- N/A
Currently, using cmd-f or cmd-shift-f to search while a modal is active
(e.g. after cmd-t or cmd-p) doesn't do anything — you need to first
close the modal manually before initiating a search. This PR allows
these actions to run regardless of whether a modal is active.
Some context: VSCode lets you do this too, and for me it's quite common
to do a symbol search with cmd-t immediately followed by a regular
search with cmd-shift-f if I don't find what I'm looking for, so having
to close the modal first is slightly disruptive. cmd-t followed by cmd-p
does dismiss the project symbols modal in order to display the file
search modal, so it makes sense to me to also allow search actions to
dismiss an active modal.
Maybe this blunt fix has unintended consequences? If some types of
modals shouldn't be dismissed when running cmd-f, or some actions
shouldn't dismiss a currently active modal, then we'll have to go about
it differently.
Release Notes:
- Added the ability to run search actions when a modal is currently
active
We've been seeing the occasional `cannot seek backwards` panic within
`SelectionsCollection` without means to reproduce.
I believe the cause is one of the callers of
`MutableSelectionsCollection::select` not passing a well formed
`Selection` where `start > end`, so this PR enforces the invariant in
`select` by swapping the fields and setting `reversed` as required as
the other mutator functions already do that as well.
We could also just assert this instead, but it callers usually won't
care about this so its the less user facing annoyance to just fix this
invariant up internally.
Fixes ZED-253
Fixes ZED-ZJ
Fixes ZED-23S
Fixes ZED-222
Fixes ZED-1ZV
Fixes ZED-1SN
Fixes ZED-1Z0
Fixes ZED-10E
Fixes ZED-1X0
Fixes ZED-12M
Fixes ZED-1GR
Fixes ZED-1VE
Fixes ZED-13X
Fixes ZED-1G4
Release Notes:
- Fixed occasional panics when querying selections
Adds a new `NumberedLines` format which is similar to `MarkedExcerpt`
but each line is prefixed with its line number.
Also fixes a bug where contagious snippets wouldn't get merged.
Release Notes:
- N/A
---------
Co-authored-by: Michael Sloan <mgsloan@gmail.com>
Co-authored-by: Michael <michael@zed.dev>
We were clearing the message editor too early. We only want to clear the
message editor if we are going to short circuit and return early before
submitting.
Otherwise, the agents that can handle this themselves won't have the
ability to do so.
Release Notes:
- acp: Fix /logout not working for some agents
Windows not having a default shell does not matter here, we might still
have an environment from other means (by being spawned from the cli for
example).
Release Notes:
- N/A *or* Added/Fixed/Improved ...
No need to clutter the `--help` docs with default directories for
platforms other than the current one.
Release Notes:
- N/A
Co-authored-by: David Kleingeld <davidsk@zed.dev>
Follow-up to #39248
- Correctly forward ports over SSH, including the port from the debug
scenario's `url`
- Give the companion time to start up, instead of bailing if the first
connection attempt fails
Release Notes:
- Fixed not being able to launch a browser debugging session in an SSH
project.
We automatically delete a local workspace if the folders comprising it
no longer exist.
If a local workspace points to folders in the WSL filesystem, checking
whether those folders exist will make us wait for the WSL VM and file
server to boot up. This can block Zed startup for many seconds.
Supported scenarios use remote workspaces, so delete these local
workspaces to ensure that we don't try to access their folders on the
startup path.
Release Notes:
- N/A
Retrieval stats will now use polars to build a big data frame for
references with the cartesian product of LSP declarations and retrieved
declaration candidates (with all their score components) and rebuilds
the stats summary on top of it.
This data frame is written to a `.parquet` file, which we can load into
advanced analytics tools (such as Metabase), so we can explore our
scoring distributions and find ways to improve retrieval, and then train
the decision tree.
Release Notes:
- N/A
Fix issue where Zed would unconditionally override user's custom shell
with system default from passwd entry.
Closes https://github.com/zed-industries/zed/issues/40171
Release Notes:
- Fix issue where Zed would unconditionally override user's custom shell
with system default from passwd entry.
---------
Signed-off-by: Xiaobo Liu <cppcoffee@gmail.com>
Added a "Copy All Messages" button to the ACP logs toolbar that copies
all messages in the watched stream to the clipboard as structured JSON.
## Motivation
When troubleshooting ACP protocol implementations, it's helpful to
provide the entire message thread to an LLM for analysis. Previously, I
had to copy individual messages one at a time, which was tedious and
time-consuming. This feature allows copying the entire conversation
history in a single click.
Release Notes:
- Added: Copy All Messages button to ACP logs view
---------
Signed-off-by: Yordis Prieto <yordis.prieto@gmail.com>
Co-authored-by: Agus Zubiaga <agus@zed.dev>
This reverts commit f1db1f3a3c.
This seems to have affected the vertical positioning of text that
doesn't contain emojis in a way that was unintended.
Release Notes:
- N/A
Previously, if a tool call's output was just text, it would be collapsed
with no way to open it.
Now we track the collapsed cards instead of the expanded ones to allow
all tool calls to be expanded by default, and only collapse the ones
required by settings changes
Release Notes:
- acp: Fix tool call markdown output unintentionally being collapsed by
default
This moves some of the changes made in
https://github.com/zed-industries/zed/pull/39543 to the `publish_gpui`
script.
This PR also updates that script to use `gpui_` instead of `zed-` (where
possible)
Release Notes:
- N/A
This applies the same change as #39466 to the terminal codepath for
external agents.
Release Notes:
- N/A
Co-authored-by: Max Brunsfeld <maxbrunsfeld@gmail.com>
Fixes a bug mentioned in
https://github.com/zed-industries/zed/issues/38891
Release Notes:
- Fixed a bug where environment variables like `NODE_EXTRA_CA_CERTS`
were not loaded from the user's shell initialization scripts in WSL or
SSH remote projects.
Co-authored-by: Cole Miller <cole@zed.dev>
This PR fixes a bug where the review icon button wouldn't properly open
the review tab if you weren't focused in the agent panel's message
editor. The solution was to register the action also at the workspace
level.
Release Notes:
- agent: Fixed a bug where the review icon button wouldn't work to open
the review tab if focus weren't in the panel's message editor.
Fixes#39998
Debugpy and pylsp are installed in a Zed-global venv with pip. We need a
Python interpreter to create this venv when it doesn't exist and one of
these tools needs to be installed, and sometimes we attempt to use
`python3` from `$PATH`. This can cause issues on Windows, where out of
the box `python3` is a sort of shim that opens the Microsoft Store app.
This PR changes the debugpy installation path to create the Zed-global
venv using the Python interpreter from a venv in the project, and only
use python3 from `$PATH` if that fails. That matches how pylsp
installation already works. It also tightens up how we search for a
global Python installation by doing a basic sanity check (`python3 -c
'print(1 + 2)`) before accepting it, which should catch the Windows
shim.
Release Notes:
- windows: improved the behavior of Zed in situations where no global
Python installation exists.
Follow up for: #39983 and
https://github.com/zed-industries/zed/pull/40040#issuecomment-3393902691
Previously it was possible to have formatting done using prettier or
language server using `"formatter": "auto"` and specify code actions to
apply on format using the `"code_actions_on_format"` setting. However,
post #39983 this is no longer possible due to the removal of the
`"code_actions_on_format"` setting. To rectify this regression, this PR
makes it so that the `"auto"` and `"language_server"` strings that were
previously only allowed as top level values on the `"formatter"` key,
are now allowed as format steps like so:
```json
{
"formatter": ["auto", "language_server"]
}
```
Therefore to replicate the previous behavior using `"auto"` and
`"code_actions_on_format"` you can use the following configuration:
```json
{
"formatter": [{"code_action": ...}, "auto"]
}
```
Release Notes:
- N/A *or* Added/Fixed/Improved ...
Closes#36934
I'm still experiencing bugs with the
`DCompositionWaitForCompositorClock` API. Let's back out the support for
now until the fixes are identified and widely available.
`DwmFlush` does various things that aren't just waiting for VSync, so
it's not ideal, but it's not bad enough that it's worth a bigger
refactor right now.
Release Notes:
- N/A
There's a lot of AI settings that will require custom UI for them to be
part of the settings window, but many don't (simple booleans and
dropdown) and can be moved right away. In consequence, the whole
"General Settings" section in the agent panel's settings view can be
removed given all of those items are now part of the settings window.
Release Notes:
- N/A
Release Notes:
- settings ui: Navigating the settings navbar with arrow keys up and
down now also activates the page, allowing users to more quickly see the
content for a given page before moving focus to the page itself.
This applies the same fix as #39886 for Windows.
Previously we were using `GetLineMetrics` to determine the ascent and
descent values for each line. It seems like this has the same behavior
as `GetTypographicBounds` on macOS, which is to return the minimum
ascent and descent for the current state of the `TextLayout` object.
This causes the ascent/descent to be unstable when adding or removing an
emoji because a font fallback is triggered when an emoji is present on
the line.
The issue is fixed by switching to `font.GetMetrics` to get the ascent
and descent, which should always return stable values for the main font,
instead of changing when there's a fallback. This also should support
situations where we have multiple explicit fonts on the same line,
although that probably can't be triggered in Zed right now.
Release Notes:
- windows: Fixed a vertical shift in text layout when inserting or
removing an emoji.
Co-authored-by: Bennet Bo Fenner <bennetbo@gmx.de>
Closes#39614
The `ShellKind` struct is built on Windows' side, meaning that when
connecting to remotes, we fall back to PowerShell construction, even if
the shell program we are spawning is a unix program.
This broke tasks creation since we are using the shell kind to construct
args:
d04ac864b8/crates/project/src/terminals.rs (L149)
In normal terminals this only affected activation scripts (only place
where shell kind is used)
I don't have a Windows machine to test it, so I would appreciate any
help with testing!
Release Notes:
- Fixed an issue where tasks could not be executed in Windows WSL
---------
Signed-off-by: Marco Mihai Condrache <52580954+marcocondrache@users.noreply.github.com>
This relands https://github.com/zed-industries/zed/pull/37175 as
https://github.com/zed-industries/zed/pull/39886 fixed the jiggling
issue.
Currently when we render text with differing styles adjacently we might
form a ligature between the text, causing the ligature forming
characters to take on one of the two styles. This can especially become
confusing when a ligature is formed between actual text and inlay hints.
Annoyingly, the only ways to prevent this with core text is to either
render each run separately, or to insert a zero-width non-joiner to
force core text to break the ligatures apart, as it otherwise will merge
subsequent font runs of the same fonts.
We currently do layouting on a per line basis and it is unlikely we want
to change that as it would incur a lot of complexity and annoyances to
merge things back into a line, so this goes with the other approach of
inserting ZWNJ characters instead.
Note that neither linux nor windows seem to currently render ligatures,
so this only concerns macOS rendering at the moment.
Closes https://github.com/zed-industries/zed/issues/23194
Release Notes:
- Fixed ligatures forming between real text and inlay hints on macOS
Workspace diagnostics in Zed have a dedicated background task that
handles querying the language server based on workspace diagnostics
refresh requests issued by both Zed and language server itself.
We only spawned that task when language server declared support for
workspace diagnostics on boot-up. This made workspace diagnostics
unavailable
when a language server (say, Ty) declared support via a capability
registration.
Originally reported in
https://github.com/zed-industries/zed/issues/39144#issuecomment-3370320004
Release Notes:
- python: Fixed workspace diagnostics not working with Ty.
Closes https://github.com/zed-industries/zed/issues/40080
Follow-up to https://github.com/zed-industries/zed/pull/39720
We were already doing this for icon themes, but not for normal themes.
Issue here is that we would only update the `cx.theme()` on the next
frame. On mouse confirmation, we would override the theme and confirm it
on the same frame, yet the global would only be peropely updated on the
next frame and then instantly reset to the new settings file, which
would again be the old theme. This caused a flicker and the selection to
not persist.. Keyboard interactions worked still, because there would be
a rendered frame inbetween selection and confirmation.
Release Notes:
- N/A
The recent introduction of PathList removed some of the ordering logic
resulting in paths always being alphabetised.
This change restores the previous logic for sorting worktrees in a
project using the newer PathList type.
Closes#39934
Release Notes:
- Fixed manual worktree reordering
<details>
<summary>Screen recording of it retaining the order</summary>
https://github.com/user-attachments/assets/0197d118-6ea7-4d2d-8fec-c917fcb9d277
</details>
---------
Co-authored-by: MrSubidubi <finn@zed.dev>
Related #35948
Should document it.. re:
- Added documentation for Mesa GPU device selection using environment
variables
- Added instructions for XWayland fallback when using Wayland
Release Notes:
- N/A
---------
Co-authored-by: Finn Evers <finn.evers@outlook.de>
This PR primarily does two things:
- replace `serde_json::from_reader` with `serde_json::from_slice`, as
the latter is much much faster, even with loading the file into memory
first.
- runs the initial loading of themes and icon themes coming from
extensions in parallel instead of sequential.
Measuring the `eager_load_active_theme_and_icon_theme` method, this
drastically improves the speed at which this happens (tested this method
primarily with debug builds on my MacBook Pro, but the `Before`
measurement was also confirmed against a `release-fast` build):
- Before: ~260ms on average (in one run, it even took 600ms)
- After: ~20ms on average
Which reduces the time this method takes to load these by around ~92%.
Given that we block on this during the initial app startup, this should
drastically improve Zeds initial startup loading time. Yet, it also
improves responsiveness when installing theme extensions and trying
these.
I also replaced all other `serde_json::from_reader` implementations with
`serde_json::from_slice` and added the former to `disallowed_methods`,
given
https://github.com/serde-rs/json/issues/160#issuecomment-253446892.
Release Notes:
- Improved Zed startup speed when using themes provided by extensions
Replace O(n²) linear search with O(log n) binary search for checking
selection overlaps when finding next selection range. Pre-sort selection
ranges and use binary search to significantly improve performance when
working with many selections.
Release Notes:
- N/A
---------
Signed-off-by: Xiaobo Liu <cppcoffee@gmail.com>
Due to using anyhow here, we otherwise lose the relevant error and just
surface a fairly useless error message.
Intentionally not doing this for `extension.json` parsing since that is
deprecated.
Release Notes:
- N/A
This makes it easier to see the image bounds for images with transparent
backgrounds.
<img width="2560" height="1377" alt="png"
src="https://github.com/user-attachments/assets/e1555576-39a2-4240-b9d3-67574df76f0d"
/>
Release Notes:
- Updated image preview background checkboxes to match the actual image
size, making it easier to see the bounds of images with transparent
backgrounds.
Currently when extending a selection using shift-click, the selection
granularity (or `SelectMode`) is based on the click count when extending
the selection, not on the click count of the initial selection. For
example, selecting a word with double-click followed by shift-click uses
a character granularity:
https://github.com/user-attachments/assets/13c78bb9-9c31-45d4-97de-99c30c7425a7
This PR changes this behavior to be more in line with other editors that
I'm familiar with by preserving the granularity of the initial selection
(unless the extension has a higher click count, i.e. the behavior of a
single click selection by a shift-double-click extension is unchanged):
https://github.com/user-attachments/assets/92e69e95-7ea2-4f76-b0a4-e4b9efa1947b
Release Notes:
- Extending a selection using shift-click now preserves the
character/word/line granularity of the initial selection
---------
Co-authored-by: Lukas Wirth <lukas@zed.dev>
Closes#39216
Note that this affects all platforms, I'm just using the prefix to make
auto-cherry-picking easier.
Release Notes:
- Fixed shell commands run by agents failing to find installed programs
in some cases.
It looks like a `.is_local()` check got left in from the original
debugger implementation. I was able to view remote logs just fine after
removing it.
Release Notes:
- Fixed DAP logs being unviewable on remote projects.
Repro:
- Open a multibuffer
- Click on a line number to jump to the corresponding file
- Click the back button
- Click the forward button, nothing happens
- Click the forward button again, now it works
Double clicking the code to jump to the file (with
`"double_click_in_multibuffer": "open"`) doesn't exhibit this bug, so I
just changed the logic when clicking on a line number in a multibuffer
to match that behavior.
https://github.com/user-attachments/assets/31c0d64d-fdb8-44d6-b0f3-a337ca53de30
Release Notes:
- Fixed bug that could cause navigation to break when clicking on a line
number in a multibuffer
Closes#5185
Release Notes:
- Added an option to hide hidden files in the project panel by setting
`hide_hidden` in the project panel settings.
---------
Co-authored-by: Gaauwe Rombouts <gromdroid@gmail.com>
Co-authored-by: Gaauwe Rombouts <mail@grombouts.nl>
Includes improvements in button padding, ways we space elements out,
more consistent use of some components, and cleaning up redundant
buttons styles. Pretty much nothing changes in the design, though.
Release Notes:
- N/A
Closes#39974
Since the thumb hitboxes themselves do not propagate events, we need to
paint the normal parent hitbox on top of the other ones. This also
caused hover detection to fail, which caused the issue linked.
Release Notes:
- Fixed an issue where hovering scrollbars in hovers would dismiss
these.
Hi! In https://github.com/zed-extensions/ruby/issues/162 we renamed
embedded template languages:
- `HTML/ERB` to `HTML+ERB`
- `YAML/ERB` to `YAML+ERB`
- `JS/ERB` to `JS+ERB`
This pull request updates the Ruby extension documentation to reflect
that change. Thanks!
Release Notes:
- N/A
The previous code clones all the rope chunks, but the rope is passed by
value so the chunks are about to be dropped anyhow.
I thought this may slightly help performance but it has no very
noticeable effect, with a mix of small changes up and down probably
attributable to noise on my machine?
I wonder if the benchmarks might just not hit this path well? I'm
looking into that separately (see #39949, #39951), but this seemed clear
enough to be worth proposing by itself.
Incidentally it surprised me this did not generate a warning already,
but I think it's because we're taking only one field from the struct
that's about to be dropped:
https://github.com/rust-lang/rust-clippy/issues/7429.
<details>
```
Running benches/rope_benchmark.rs (target/release/deps/rope_benchmark-4c5c71666e7c1729)
push/4096 time: [362.58 µs 366.40 µs 370.69 µs]
thrpt: [10.538 MiB/s 10.661 MiB/s 10.773 MiB/s]
change:
time: [+0.0646% +1.2362% +2.4681%] (p = 0.04 < 0.05)
thrpt: [-2.4086% -1.2211% -0.0646%]
Change within noise threshold.
Found 10 outliers among 100 measurements (10.00%)
7 (7.00%) high mild
3 (3.00%) high severe
Benchmarking push/65536: Warming up for 3.0000 s
Warning: Unable to complete 100 samples in 5.0s. You may wish to increase target time to 8.4s, enable flat sampling, or reduce sample count to 50.
push/65536 time: [1.6185 ms 1.6353 ms 1.6557 ms]
thrpt: [37.747 MiB/s 38.219 MiB/s 38.616 MiB/s]
change:
time: [+1.9135% +2.9548% +3.9838%] (p = 0.00 < 0.05)
thrpt: [-3.8312% -2.8700% -1.8776%]
Performance has regressed.
Found 6 outliers among 100 measurements (6.00%)
5 (5.00%) high mild
1 (1.00%) high severe
append/4096 time: [1.1052 µs 1.1104 µs 1.1162 µs]
thrpt: [3.4177 GiB/s 3.4354 GiB/s 3.4516 GiB/s]
change:
time: [-2.5075% -0.3430% +1.5095%] (p = 0.76 > 0.05)
thrpt: [-1.4871% +0.3441% +2.5720%]
No change in performance detected.
Found 8 outliers among 100 measurements (8.00%)
7 (7.00%) high mild
1 (1.00%) high severe
append/65536 time: [12.404 µs 12.444 µs 12.487 µs]
thrpt: [4.8881 GiB/s 4.9049 GiB/s 4.9204 GiB/s]
change:
time: [-0.1408% +0.5573% +1.2016%] (p = 0.10 > 0.05)
thrpt: [-1.1874% -0.5542% +0.1410%]
No change in performance detected.
Found 5 outliers among 100 measurements (5.00%)
2 (2.00%) high mild
3 (3.00%) high severe
slice/4096 time: [32.963 µs 33.185 µs 33.466 µs]
thrpt: [116.72 MiB/s 117.71 MiB/s 118.51 MiB/s]
change:
time: [-6.4303% -5.1234% -3.6394%] (p = 0.00 < 0.05)
thrpt: [+3.7769% +5.4000% +6.8722%]
Performance has improved.
Found 2 outliers among 100 measurements (2.00%)
1 (1.00%) high mild
1 (1.00%) high severe
slice/65536 time: [668.67 µs 670.49 µs 672.65 µs]
thrpt: [92.916 MiB/s 93.215 MiB/s 93.469 MiB/s]
change:
time: [+0.0846% +0.5573% +1.0199%] (p = 0.02 < 0.05)
thrpt: [-1.0096% -0.5542% -0.0845%]
Change within noise threshold.
Found 10 outliers among 100 measurements (10.00%)
6 (6.00%) high mild
4 (4.00%) high severe
bytes_in_range/4096 time: [5.1513 µs 5.1594 µs 5.1674 µs]
thrpt: [755.95 MiB/s 757.12 MiB/s 758.31 MiB/s]
change:
time: [-4.9410% -4.2051% -3.3835%] (p = 0.00 < 0.05)
thrpt: [+3.5020% +4.3897% +5.1978%]
Performance has improved.
Found 4 outliers among 100 measurements (4.00%)
1 (1.00%) low mild
3 (3.00%) high severe
bytes_in_range/65536 time: [139.87 µs 140.17 µs 140.55 µs]
thrpt: [444.67 MiB/s 445.89 MiB/s 446.85 MiB/s]
change:
time: [-0.6267% -0.0474% +0.4635%] (p = 0.87 > 0.05)
thrpt: [-0.4614% +0.0475% +0.6306%]
No change in performance detected.
Found 9 outliers among 100 measurements (9.00%)
7 (7.00%) high mild
2 (2.00%) high severe
chars/4096 time: [1.0243 µs 1.0250 µs 1.0257 µs]
thrpt: [3.7190 GiB/s 3.7217 GiB/s 3.7243 GiB/s]
change:
time: [+4.0106% +4.5396% +5.3062%] (p = 0.00 < 0.05)
thrpt: [-5.0388% -4.3425% -3.8559%]
Performance has regressed.
Found 10 outliers among 100 measurements (10.00%)
2 (2.00%) high mild
8 (8.00%) high severe
chars/65536 time: [17.540 µs 17.576 µs 17.614 µs]
thrpt: [3.4652 GiB/s 3.4727 GiB/s 3.4797 GiB/s]
change:
time: [+2.5201% +3.3922% +4.1639%] (p = 0.00 < 0.05)
thrpt: [-3.9974% -3.2809% -2.4581%]
Performance has regressed.
Found 7 outliers among 100 measurements (7.00%)
4 (4.00%) high mild
3 (3.00%) high severe
clip_point/4096 time: [58.857 µs 59.162 µs 59.490 µs]
thrpt: [65.662 MiB/s 66.026 MiB/s 66.368 MiB/s]
change:
time: [+1.6900% +2.8088% +3.8521%] (p = 0.00 < 0.05)
thrpt: [-3.7092% -2.7321% -1.6619%]
Performance has regressed.
Found 3 outliers among 100 measurements (3.00%)
3 (3.00%) high mild
clip_point/65536 time: [1.8609 ms 1.8633 ms 1.8660 ms]
thrpt: [33.494 MiB/s 33.543 MiB/s 33.585 MiB/s]
change:
time: [+0.0577% +0.2579% +0.4495%] (p = 0.01 < 0.05)
thrpt: [-0.4474% -0.2572% -0.0577%]
Change within noise threshold.
Found 5 outliers among 100 measurements (5.00%)
3 (3.00%) high mild
2 (2.00%) high severe
point_to_offset/4096 time: [19.246 µs 19.287 µs 19.331 µs]
thrpt: [202.07 MiB/s 202.54 MiB/s 202.97 MiB/s]
change:
time: [+1.1073% +2.9754% +5.3818%] (p = 0.00 < 0.05)
thrpt: [-5.1069% -2.8894% -1.0951%]
Performance has regressed.
Found 13 outliers among 100 measurements (13.00%)
5 (5.00%) high mild
8 (8.00%) high severe
Benchmarking point_to_offset/65536: Warming up for 3.0000 s
Warning: Unable to complete 100 samples in 5.0s. You may wish to increase target time to 6.6s, enable flat sampling, or reduce sample count to 60.
point_to_offset/65536 time: [741.87 µs 743.28 µs 744.74 µs]
thrpt: [83.922 MiB/s 84.086 MiB/s 84.247 MiB/s]
change:
time: [+5.0577% +5.6751% +6.3133%] (p = 0.00 < 0.05)
thrpt: [-5.9384% -5.3703% -4.8142%]
Performance has regressed.
Found 7 outliers among 100 measurements (7.00%)
4 (4.00%) high mild
3 (3.00%) high severe
cursor/4096 time: [27.407 µs 27.483 µs 27.600 µs]
thrpt: [141.53 MiB/s 142.13 MiB/s 142.53 MiB/s]
change:
time: [-7.1479% -6.2928% -5.6378%] (p = 0.00 < 0.05)
thrpt: [+5.9747% +6.7154% +7.6981%]
Performance has improved.
Found 9 outliers among 100 measurements (9.00%)
1 (1.00%) high mild
8 (8.00%) high severe
cursor/65536 time: [848.91 µs 849.70 µs 850.59 µs]
thrpt: [73.478 MiB/s 73.555 MiB/s 73.624 MiB/s]
change:
time: [+0.0281% +0.3487% +0.6686%] (p = 0.04 < 0.05)
thrpt: [-0.6642% -0.3475% -0.0281%]
Change within noise threshold.
Found 9 outliers among 100 measurements (9.00%)
5 (5.00%) high mild
4 (4.00%) high severe
```
</details>
Release Notes:
- N/A
Follow up to https://github.com/zed-industries/zed/pull/39979. The
previous PR made it the title would change even if you were on a
non-root tree view item. This PR fixes that by fixating the title to
show only the root tree view item.
Release Notes:
- N/A
Closes #ISSUE
Annotated our `default.json` with `$schema` to get diagnostics, then
fixed the non-language not installed warnings.
Release Notes:
- N/A *or* Added/Fixed/Improved ...
Closes #ISSUE
Release Notes:
- settings: Deprecated `code_actions_on_format` in favor of specifying
code actions to run on format inline in the `formatter` array.
Previously, you would configure code actions to run on format like this:
```json
{
"code_actions_on_format": {
"source.organizeImports": true,
"source.fixAll.eslint": true
}
}
```
This has been migrated to the new format:
```json
{
"formatter": [
{
"code_action": "source.organizeImports"
},
{
"code_action": "source.fixAll.eslint"
}
]
}
```
This change will be automatically migrated for you. If you had an
existing `formatter` setting, the code actions are prepended to your
formatter array (matching the existing behavior). This migration applies
to both global settings and language-specific settings
Rendering breaks when both an element and its parent have opacity set.
The following code reproduces the issue:
```rust
struct Repro;
impl Render for Repro {
fn render(&mut self, _window: &mut Window, _cx: &mut Context<Self>) -> impl IntoElement {
fn make_box(bg: impl Into<Fill>) -> impl IntoElement {
div().size_8().bg(bg).hover(|style| style.opacity(0.5))
}
div()
.flex()
.items_center()
.justify_center()
.size(px(500.0))
.hover(|style| style.opacity(0.5))
.child(make_box(gpui::red()))
.child(make_box(gpui::green()))
.child(make_box(gpui::blue()))
}
}
```
Before (broken behavior):
https://github.com/user-attachments/assets/2c5c1e31-88b2-4f39-81f8-40060e3fe958
The child element resets its parent and siblings' opacity, which is an
unexpected behavior.
After (fixed behavior):
https://github.com/user-attachments/assets/48527033-b06f-4737-b6c3-0ee3d133f138
Release Notes:
- Fixed an issue where nested opacity is rendered incorrectly.
This PR renames the following actions to make it easier and prioritize
the UI version of interacting with them:
| Before | After |
|--------|--------|
| `OpenSettingsEditor` | `OpenSettings` |
| `OpenSettings` | `OpenSettingsFile` |
| `OpenKeymapEditor` | `OpenKeymap` |
| `OpenKeymap` | `OpenKeymapFile` |
Release Notes:
- Rename actions to open settings (UI/window and JSON file) as well as
to open the keymap (editor tab and JSON file).
Previously we were always adding a `Navigable` entry for the "new WSL
connection" option in this modal, even though we don't have the
corresponding button on non-Windows. This was causing `menu::SelectNext`
to behave incorrectly (focusing the center pane instead) when `Connect
New Server` was selected on macOS and Linux.
Release Notes:
- Fixed a bug with keyboard navigation in the remote project modal.
Closes#39263
Release Notes:
- N/A
from
https://github.com/zed-industries/zed/issues/39263#issuecomment-3358220988
>
> > If you replace that code with
> >
> > let adapter: IDXGIAdapter1 = unsafe {
> > dxgi_factory.EnumAdapters(adapter_index)
> > }?.cast()?;
> >
> > does it not select the right GPU?
>
> @reflectronic That does seem to select the active gpu for me, meaning
whichever GPU is currently connected. This is a much simpler solution
than the one I have here
(https://github.com/zed-industries/zed/pull/39264 - updated) and while
I'm sure I could imagine someone wanting to choose their GPU to render
Zed on, that may not be something that the application really needs to
support.
>
> I have a branch with just this as the only change that I can push to
that PR if the simpler solution is preferred.
>
> ```rust
> let adapter: IDXGIAdapter1 = unsafe {
> dxgi_factory.EnumAdapters(adapter_index)?.cast()?
> };
> ```
Gathering LSP declarations in zeta_cli can take a really long time for
big repos and has to be started from scratch if interrupted.
Instead of writing the cache file once we have walked the whole
worktree, we'll now do so incrementally as we complete each file. On
subsequent runs, we'll load as many valid declarations as has been
previously written to the cache, and then continue to request the rest
from the LSP which will append to the existing file as it makes
progress. If the last cache entry is incomplete, we'll truncate the
cache file to the end of the last valid line and continue from there, so
we can just `ctrl-c` without breaking resumability.
Release Notes:
- N/A
- Update `AcpThreadView.insert_selections` to take into account whether
the user is currently editing an existing message and, if it is, insert
the selection into that message instead of the thread's message editor
- Update Window's default keymap to use the `agent::QuoteSelection`
action instead of the deprecated `assistant::QuoteSelection` action
- Introduce `AcpThreadView.active_editor` to allow callers to retrieve
either the thread view's message editor or the editor for the message
being edited, in case `AcpThreadView.editing_message` is not `None`
- Improve `AcpThreadView.focus_handle` to focus on the message being
currently edited in case the user navigates back to the editor and then
to the thread view again, all while editing a message
- Add tests for `AcpThreadView.insert_selections`, ensuring that the
selection is inserted in the message being currently edited, if a
message is being edited, or the thread view's message editor if no
message is being edited
Closes#39693
Release Notes:
- Improved `agent: quote selection` to also work for a message that was
already sent but is being edited
---------
Co-authored-by: Ben Brandt <benjamin.j.brandt@gmail.com>
The feedback modal did not match our keyboard-driven design. We can
revisit this later if we want, but for now, removing it makes sense. All
actions have been inlined in the `Help` menu to maintain
discoverability.
Additionally, not all feedback-based actions in the command palette were
namespaced under `feedback:`, and now they are, so they can all be found
there easily.
Release Notes:
- Notice: The `Give Feedback` modal has been removed. The options to
file bug reports, feature requests, email us, and open the Zed
repository can now be found within the `Help` menu directly. The command
palette actions have undergone the following changes:
- `feedback: give feedback` (removed)
- `feedback: file bug report` (no change)
- `zed: request feature` → `feedback: request feature`
- `zed: email zed` → `feedback: email zed`
- `zed: open zed repo` → `contribute: open zed repo`
Previously we were guessing the context window size here:
8c3f09e31e/crates/ollama/src/ollama.rs (L22)
This is inaccurate and must be updated manually. This PR ensures that we
extract the context window size from the request in the same way that
the Ollama CLI does when running `ollama show <model-name>` (Relevant
code is
[here](3d32249c74/cmd/cmd.go (L860)))
The format looks like this:
```json
{
"model_info": {
"general.architecture": "llama",
"llama.context_length": 132000
}
}
```
Once this PR is merged we could technically remove the old code
8c3f09e31e/crates/ollama/src/ollama.rs (L22)
I decided to keep it for now, as it is unclear if the necessary fields
are available via the API on older Ollama versions.
Release Notes:
- Fixed an issue where Ollama models would use the wrong context window
size
The issue was caused by the scroll handle taking a couple of frames to
update its offset correctly after calling
`ScrollHandle::scroll_to_top_of_item`. The fast fix is forcing 3 frames
to render back-to-back.
In the future, we should look into `ScrollHandle` and see if there's any
way to update its state outside of paint.
Release Notes:
- N/A
Co-authored-by: Danilo Leal <daniloleal09@gmail.com>
Co-authored-by: Mikayla Maki <mikayla.c.maki@gmail.com>
Co-authored-by: Katie Geer <katie@zed.dev>
Co-authored-by: Ben Kunkle <ben@zed.dev>
Re-adds: https://github.com/zed-industries/zed/pull/37264
This PR re-adds basic support for showing HTML images, without touching
the display mode for images.
The initial PR changed the `div().flex().flex_col()` to
`h_flex().flex_wrap()` but this broke the text wrapping in almost all
cases.
**Note**: This does not add support for showing the images inline,
because we haven't figured out how they correctly do this.
I'm working on adding the CSS `inline` display feature support to taffy
that hopefully allows us to correctly show images/other elements inline
without breaking the text wrapping.
**Before (nightly) and after (dev) for the README file inside Zed.
(nothing has changed, which is good)**
<img width="3440" height="1380" alt="Screenshot 2025-09-13 at 12 49 08"
src="https://github.com/user-attachments/assets/9cbdcb07-dbe9-4236-9d20-e59acc0e955e"
/>
**Result**
<img width="1717" height="1314" alt="Screenshot 2025-09-13 at 12 51 54"
src="https://github.com/user-attachments/assets/1c0f8507-c63d-472e-8e82-a654a63f7153"
/>
cc @SomeoneToIgnore
Release Notes:
- markdown preview: Added support for HTML `img` tags inside paragraphs
As you can see in the image, we were previously returning different
`ascent`s/`descent`s when a line would/would not contain an Emoji.
<img width="104" height="36" alt="image"
src="https://github.com/user-attachments/assets/436aeda0-87c0-4dee-943b-6da83681d466"
/>
---
CoreTexts `CTLineGetTypographicBounds` seems to return a different
ascent/descent depending on if an Emoji is there or not AFAIK it is not
documented if this is intended behaviour or not. For us it is
undesirable, as typing an Emoji causes the line to be shifted to the
bottom, see here:
https://github.com/user-attachments/assets/2ad1c82e-6297-48ac-a522-fb382ea56eea
---
Instead of using `CTLineGetTypographicBounds` to resolve the
ascent/descent, we look at every run and choose the maximum
ascent/descent. This matches how it [works on
Linux](f1d17fcfbe/crates/gpui/src/platform/linux/text_system.rs (L452))
Release Notes:
- Fixed an issue on macOS where typing an emoji on a line would cause
the line to shift downwards by a few pixels
Fixes the `Open Diff` action for untracked files when the `sort_by_path`
setting is enabled. The `ProjectDiff` wasn't correctly moving the
multibuffer's cursor to the untracked file because, when that setting is
enabled, it's sort prefix is changed to the tracked files sort prefix, and that
wasn't accounted for in `move_to_entry`.
Before these changes, the `sort_prefix` field for `PathKey` was called `namespace`, it was renamed to be clearer what its purpose is.
Closes#39529
Release Notes:
- Fixed 'Open Diff' action for untracked files when `sort_by_path` is
enabled
---------
Co-authored-by: David Kleingeld <davidsk@zed.dev>
- Prefer agent-specific logout handling to allow state reset
- Treat any auth method as supported; remove provider-specific filter
- Avoid prompting auth when issuing /logout and agent supports it
Release Notes:
- N/A
These changes refactor the whitespace handling logic for Vim's change
surrounds command (`cs`), making its behavior closely match
[tpope/vim-surround](https://github.com/tpope/vim-surround), following
[this
discussion](https://github.com/zed-industries/zed/issues/38169#issuecomment-3304129461).
Zed's current implementation has two main differences when compared to
[tpope/vim-surround](https://github.com/tpope/vim-surround):
- It only considers whether a single space should be added or removed,
instead of all the space that is between the surrounding character and
the content
- It only takes into consideration the new surrounding characters in
order to determine whether to add or remove that space
A review of
[tpope/vim-surround](https://github.com/tpope/vim-surround)'s behavior
reveals these rules for whitespace:
* Quote to Quote
* Whitespace is never changed
* Quote to Bracket
* If opening bracket, add one space
* If closing bracket, do not add space
* Bracket to Bracket
* If opening to opening, keep only one space
* If opening to closing, remove all space
* If closing to opening, add one space
* If closing to closing, do not change space
* Bracket to Quote
* If opening, remove all space
* If closing, preserve all space
Below is a table with examples for each scenario. A new test has also
been added to specifically check the scenarios outlined above,
`vim::surrounds::test::test_change_surrounds_vim`.
| Type | Before | Command | After |
|-------------------|-------------|---------|---------------|
| Quote → Quote | `' a '` | `cs'"` | `" a "` |
| Quote → Quote | `" a "` | `cs"'` | `' a '` |
| Quote → Bracket | `' a '` | `cs'{` | `{ a }` |
| Quote → Bracket | `' a '` | `cs'}` | `{ a }` |
| Bracket → Bracket | `[ a ]` | `cs[{` | `{ a }` |
| Bracket → Bracket | `[ a ]` | `cs[}` | `{a}` |
| Bracket → Bracket | `[ a ]` | `cs]{` | `{ a }` |
| Bracket → Bracket | `[ a ]` | `cs]}` | `{ a }` |
| Bracket → Quote | `[ a ]` | `cs['` | `'a'` |
| Bracket → Quote | `[ a ]` | `cs]'` | `' a '` |
These changes diverge from
[tpope/vim-surround](https://github.com/tpope/vim-surround) when
handling newlines. For example, with the following snippet:
```rust
fn test_surround() {
if 2 > 1 {
println!("place cursor here");
}
};
```
Placing the cursor inside the string and running any combination of
`cs{[`, `cs{]`, `cs}[`, or `cs}]` would previously remove newline
characters. With these changes, using commands like `cs}]` will now
preserve newlines.
Related to #38169Closes#39334
Release Notes:
- Improved Vim’s change surround command to closely match
[tpope/vim-surround](https://github.com/tpope/vim-surround) behavior.
---------
Co-authored-by: Conrad Irwin <conrad.irwin@gmail.com>
This takes the idea that @RemcoSmitsDev started on in
https://github.com/zed-industries/zed/pull/39354. We did away with
grabbing a snapshot of the display map when buffer coordinates were
sufficient.
Closes#37267
Release Notes:
- Reduced micro-stutters in project search with large multi-buffer
contents.
---------
Co-authored-by: Smit Barmase <heysmitbarmase@gmail.com>
Closes #ISSUE
From notes:
```markdown
- [x] Clicking on the disclsoure icon button in the root-level tree view item should steal focus and move it to the root item (not the icon button)
- [x] [@ben] Allow left/right arrow keys to expand/collapse root tree view items in the nav
- [x] With this, make enter/space work the same as clicking (activate page, don't expand root items, focus moves to the content and leaves nav — becomes consistent with mouse interaction)
- [x] Smart cmd-shift-e: toggling focus should take you to the selected item
- [x] [@ben] pageup + pagedown in nav -> jump between root items
- [x] [@ben] home + end buttons should work
- in nav:
- home always goes to first section header
- end always goes to last _visible_ item (does not expand)
```
Release Notes:
- N/A *or* Added/Fixed/Improved ...
Closes https://github.com/zed-industries/zed/issues/39259
- Fixes import of `editor.fontFamily` (we were looking for the wrong
key)
- Adds basic support for the CSS font-family syntax used by VS Code,
including font fallback
Release Notes:
- N/A
This PR adds support for browser debugging in SSH and WSL projects. We
use the vscode-js-debug-companion extension, repackaged as a standalone
CLI (https://github.com/zed-industries/js-debug-companion-cli).
Closes#38878
Release Notes:
- debugger: Browser debugging is now supported in SSH and WSL projects.
---------
Co-authored-by: Nia <nia@zed.dev>
Two tweaks were required to ensure we correctly clear the shell after
running an activate script(s):
1. PowerShell upon receiving `\r\n` input, will enter the continuation
mode (>>). To avoid this, we send an "enter" key press instead `\x0d`.
2. In order to clear the terminal _after_ issuing all activation
commands, we need to take into account the asynchronous nature of the
activation process:
- We write the command to run the script to PTY
- We send "enter" (It is now being processed by the shell) At this point
we need to wait for the shell to finish executing before we clear the
terminal. Otherwise we will create a race where we might clear the
terminal _before_ the shell finished executing the activation script(s).
- Write `clear`/`cls` command to PTY
- Send "enter" This way we guarantee that we clear the terminal _after_
all scripts were executed.
Closes#38474
Release Notes:
- N/A
Plans and displays the prompt locally before the response arrives.
Helpful while debugging prompt planning.
Release Notes:
- N/A
---------
Co-authored-by: Michael Sloan <mgsloan@gmail.com>
I didn't find a commit, but it's now required for all platforms, I got
this compile error with 0.207.3 tag
```
error: cannot find macro `info` in this scope
--> crates\audio\src\audio.rs:121:13
|
121 | info!("Output stream: {:?}", output_handle);
| ^^^^
|
help: consider importing this macro
|
1 + use log::info;
|
error: could not compile `audio` (lib) due to 1 previous error
```
Closes #ISSUE
Release Notes:
- N/A
Closes #ISSUE
This allows new windows like the Rules library or the Settings UI window
to appear floating on window managers like hyprland:
https://github.com/user-attachments/assets/628db7f9-4459-4601-85f1-789923831182
Left is with `WindowKind::Floating` and right is with
`WindowKind::Normal`
Release Notes:
- Added support for floating windows on x11 and wayland
Release Notes:
- Added Codestral edit predictions provider which can be enabled by adding an API key in the Mistral section of agent settings.

## Config
Get API key from https://console.mistral.ai/codestral and add it in the Mistral section of the agent settings.
```
"features": {
"edit_prediction_provider": "codestral"
},
"edit_predictions": {
"codestral": {
"model": "codestral-latest",
"max_tokens": 150
}
},
```
---------
Co-authored-by: Michael Sloan <michael@zed.dev>
## Description
Fixes#39376
Add individual FoldAtLevel1-9 actions so users can find fold commands in
the command palette while keeping existing keybindings.
Migrating user keymaps is necessary to have the keybinds show in the command palette.
Closes#39376
### Changes
- `crates/editor/src/actions.rs` - Added FoldAtLevel1-9 action structs
- `crates/editor/src/editor.rs` - Implemented fold_at_level_1-9 handler
methods
- `crates/editor/src/element.rs` - Registered new actions
- `assets/keymaps/*.json` - Updated keybindings to use new individual
actions
### Other Approaches considered
- Adding #[serde(default)] to existing FoldAtLevel(u32) - wouldn't make
it discoverable
- Creating a single action with enumerated variants - idk about this
that well.
### Release Notes
Release Notes:
- Added Fold At Level 1-9 actions to the command palette
---------
Co-authored-by: HactarCE <6060305+HactarCE@users.noreply.github.com>
# How
Tweak the way in which inspected element bounds and size are printed to
improved readability of GPUI Inspector data.
> [!note]
> It looks like the only place in the workspace where bounds are used
within formatted print is GPUI Inspector panel, but I decided to do not
alter [GPUI `geometry.rs` default
format](a7e7f46020/crates/gpui/src/geometry.rs (L1579-L1587)),
since adding multiline output and additional labels in there does not
feel like the beast approach, but maybe I'm wrong?
Release Notes:
- N/A
# Preview
<img width="1168" height="224" alt="Screenshot 2025-10-07 at 20 08 35"
src="https://github.com/user-attachments/assets/97753fc1-68d7-4cf8-ad92-afe85319f3d8"
/>
<img width="1168" height="228" alt="Screenshot 2025-10-07 at 20 09 24"
src="https://github.com/user-attachments/assets/beed2a92-0817-4ed2-bb62-4d7b931e8709"
/>
I mistakenly broke this when refactoring settings
Closes#39479
Release Notes:
- Fixed a bug where you could no longer configure `terminal.shell` in
project settings
A couple of caveats:
- We should not auto-escape arguments with Alacritty's `escape_args`
option if using CMD otherwise, the generated command will have way too
many escaped characters for CMD to parse correctly.
- When composing a full command for CMD, we need to put it in double
quotes manually: `cmd /C "activate.bat& pwsh.exe -C do_something"` so
that CMD executes the entire string as a sequence of commands.
- CMD requires `&` as a chaining operator for commands (`;` for other
shells).
Release Notes:
- N/A
This PR expands our automatic retry behavior for certain classes of
completion errors (e.g., rate limit errors).
Previously this was only available when using burn mode.
We now auto-retry when:
- Using the Zed provider while on a token-based plan
- Using the Zed provider while on a legacy plan with burn mode enabled
- Using a non-Zed provider
Release Notes:
- Expanded automatic retry behavior for errors in the Agent. Errors
classified as "retryable" (such as rate limit errors) will now
automatically be retried when:
- Using the Zed provider while on a token-based plan
- Using the Zed provider while on a legacy plan with burn mode enabled
- Using a non-Zed provider
---------
Co-authored-by: David Kleingeld <davidsk@zed.dev>
These changes update the way the file finder decides wether to only look
for an absolute path or for a relative path too.
When the provided query started with a slash (`/`) the file finder would
assume this to be an absolute path so would always try to find an
absolute path and return no matches if none was found. This is meant to
support situtations where, for example, a CLI tool might output the
absolute path of a file and the user can copy and paste that in the file
finder.
However, it's should be possible to use slash (`/`) at the start of the
query to specify that only relative files inside a folder should be
matched, which would not work in this scenario.
With these changes, the file finder will first check if the path is
absolute and, if it is and no absolute matches were found, it'll still
try to find relative matches, otherwise it'll simply look for relative
matches.
Closes#39350
Release Notes:
- Fixed project files matches when using slash (`/`) at the start in
order to consider relative paths
---------
Co-authored-by: Piotr Osiewicz <piotr@zed.dev>
Co-authored-by: Piotr Osiewicz <24362066+osiewicz@users.noreply.github.com>
We don't get an ExitStatus from a remote terminal, so this check was
failing.
Ideally we move all of this to just needing an exit code, but we will
have to revisit that later.
Release Notes:
- N/A
Update Vim's `%` motion to first attempt finding the exact matching
bracket/tag under the cursor, then fall back to the previous
nearest-enclosing logic if none is found. This prevents accidentally
jumping to nested pairs in languages like TSX and Svelte where `<>`,
`</>`, and `/>` are also treated as brackets.
Closes#39368
Release Notes:
- Fixed an edge case with the `%` motion in vim, where the cursor could
end up in a closing HTML tag instead of the matching bracket
This commit fixes an issue where opening zed using `--user-data-dir`
with an empty directory would cause the first run to display a "Failed
to migrate settings" error.
This was caused by the migrator attempting to migrate an empty string,
so if that's the case, we'll simply return `Ok(None)` and avoid
attempting to migrate anything at all.
Relates to #39400
Release Notes:
- N/A
Co-authored-by: Smit Barmase <heysmitbarmase@gmail.com>
Use path! macro for platform-specific path formatting in test
assertions, fixing hardcoded Unix-style paths that failed on Windows.
Release Notes:
- N/A
Signed-off-by: Xiaobo Liu <cppcoffee@gmail.com>
This PR adds support for HTML block quotes, that also allows you to have
nested variant of it.
<img width="1441" height="804" alt="Screenshot 2025-10-08 at 10 25 57"
src="https://github.com/user-attachments/assets/4e1da766-fb54-4e87-8654-1ea14330bc97"
/>
Code example used in screenshot:
```html
<blockquote>
<p>
Words can be like X-rays, if you use them properly—they’ll go through
anything. You read and you’re pierced.
</p>
<blockquote>
<p>
lorem ipsum dolor sit amet, consectetur adipiscing elit. Sed non risus. Suspendisse lectus tortor, dignissim sit amet, adipiscing nec, ultricies sed, dolor.
</p>
</blockquote>
</blockquote>
```
Release Notes:
- Markdown: Added support for `HTML` block quotes
Follow up to https://github.com/zed-industries/zed/pull/39468.
Unlike `agent_ui_font_size`, the `agent_buffer_font_size` setting does
have a default value, which means it does not fall back to the regular
UI font size, but rather to its default value.
Release Notes:
- N/A
Closes#38538
Release Notes:
- Fixed an issue where opening a remote terminal failed on systems like
BusyBox, Alpine, Amazon Linux 2, some CentOS images, etc., due to an
invalid option 'C'.
This PR makes selecting a sub-entry in the settings UI nav bar scroll to
that section in the settings page. It also updates the selected
sub-entry when scrolling through a settings page to match what a user is
viewing on the page.
I also added a new helper method to `ScrollHandle` type called
`scroll_to_top_of_item` that scrolls until an item is the top element
visible.
Release Notes:
- N/A
Closes#38919
Now, when unfocusing the filename editor while creating a file or
directory in the project panel, it will create it by default unless the
name is empty or already exists.
Release Notes:
- Improved behavior where unfocusing while creating a new file or
directory in the project panel now creates it instead of discarding it.
The previous modifier detection treated `AltGr` presses as `Ctrl+Alt`,
which broke entering characters produced by AltGr. For example, on a
Hungarian layout `{` is typed with `AltGr+B`; our code saw that as
`Ctrl+Alt+B` and the keybind took precedence, so the character couldn’t
be entered.
On Windows, AltGr isn’t a first-class modifier. It’s emulated as a
combination of `Right Alt (VK_RMENU)` plus a synthetic `Left Ctrl
(VK_LCONTROL)` press. When users press AltGr, `GetKeyState` reports both
Ctrl and Alt as down, which makes AltGr indistinguishable from a real
`Ctrl+Alt` chord if we only look at aggregate modifier state.
Fix: detect the AltGr pattern by checking `VK_RMENU && VK_LCONTROL`.
When that pattern is present, treat it as text-entry intent and suppress
`control` and `alt` in `current_modifiers()`. This prevents
AltGr-produced characters from colliding with `Ctrl+Alt` keybinds while
keeping other modifiers intact.
Limitation: there is no Windows API to tell whether the active layout
actually has AltGr. As a result, on non-AltGr layouts (e.g. US),
pressing `Right Alt + Left Ctrl` will be interpreted as AltGr and will
not trigger `Ctrl+Alt` keybinds. This is an acceptable trade-off to
ensure AltGr layouts can reliably enter characters; users can still
invoke `Ctrl+Alt` keybinds using `Left Alt` or by choosing bindings that
avoid common AltGr pairs.
I based this on https://github.com/zed-industries/zed/pull/36115 after
trying other different approaches, but this one is a bit more specific.
Does this approach make sense, or is slightly breaking US input in favor
of fixing international input a no-go? I think the benefit - being able
to type certain characters _at all_ - outweighs the shortcomings.
Otherwise, there's a way to detect if the keyboard layout uses AltGr or
not, but it's quite hacky, and involves reading the registry to find the
current layout dll's name, opening that dll, manually declaring struct
layouts that it uses, then parsing out the AltGr flag from a function
call result. I don't think that's worth it, but if needed, I can give
that a shot, let me know.
Release Notes:
- windows: Fixed handling of AltGr to avoid keybinds preventing
character input
Reverts zed-industries/zed#39581
This has done its job uncovering incorrect constructions of the
highlight ranges pretty fast. Reverting this to prevent this from
spilling into preview until I can fix the call sites next week
Closes#39007
Strings should be escaped with backticks in PowerShell, so the following
```
\"pwsh.exe -C pytest -m \\\"some_test\\\"\"
```
becomes
```
\"pwsh.exe -C pytest -m `\"some_test`\"\"
```
Otherwise PowerShell will misinterpret the invocation resulting in
weirdness all-around such as the issue linked above.
Release Notes:
- N/A
Follow-up to #39649, possible fix for #39669
This implements an alternate strategy for showing/hiding the agent panel
in response to `disable_ai`. We don't load the panel at all if AI is
disabled at startup, and when the value of `disable_ai` changes, we load
the panel or destroy it as needed.
Release Notes:
- N/A
Closes#39028
Fixed empty lines appearing when collapsing files with diagnostic
messages in the diagnostics panel.
Added a flag to track when processing a `FoldedBuffer` and skip
`Near/Below` blocks (diagnostic messages) that immediately follow it.
This prevents diagnostics from rendering as empty lines when their file
is collapsed.
Before:
<img width="1489" height="429" alt="before"
src="https://github.com/user-attachments/assets/5e233290-1f6e-403c-a6b3-a65107586d01"
/>
After:
<img width="981" height="270" alt="after"
src="https://github.com/user-attachments/assets/a877b651-6b7f-4441-805c-38ea41e73a18"
/>
Release Notes:
- Fixed empty lines when collapsing files with diagnostics in the
diagnostics panel
This PR fixes an issue where scrollbars would overagressively capture
some events, which could lead to clicks being lost in the process. Also
improves how hovering of the parent is detected to lead to less false
positives.
Release Notes:
- Fixed a rare issue where scrollbars would react to and capture events
they should not react to.
Fixes ZED-1NX
This panic could occur when an `bulk_staging` was set to `Some(...)` and
`sort_by_path` was set to `true`.
When setting `sort_by_path: true`, we call `update_visible_entries(...)`
which then checks if `bulk_staging ` is `Some(...)` and calls
`entry_by_path`. That function accesses `entries`, which still consists
of both headers and entries. But the code
(`entry.status_entry().unwrap()`) assumes that there are no headers in
the entry list if `sort_by_path: true`.
```rust
if GitPanelSettings::get_global(cx).sort_by_path {
return self
.entries
.binary_search_by(|entry| entry.status_entry().unwrap().repo_path.cmp(path)) //This unwrap() would panic
.ok();
}
```
This has now been fixed by clearing all the entries when `sort_by_path`
changes, as this is the only case where our assumptions are invalid. I
also added a test which 1) actually tests the sort_by_path logic 2)
ensures that we do not re-introduce this panic in the future.
Release Notes:
- Fixed a panic that could occur when using `sort_by_path: true` in the
git panel
- **paths: Cache away results of static construction of RelPath**
- **agent: Cache away results of converting rules file names into
relpaths**
This PR fixed a regression from relpath PR where we've started doing
more work when working with static (Rel-)Paths.
Release Notes:
- N/A
Prior we only logged the crate in `log_err`, which is not too helpful.
We now assemble the module path from the file system path.
Release Notes:
- N/A *or* Added/Fixed/Improved ...
Before this change the active theme and icon theme were retrofitted onto
the ThemeSettings.
Now they're in their own new global (GlobalTheme::theme(cx) and
GlobalTheme::icon_theme(cx))
This lets us remove cx from the settings traits, and tidy up a few other
things along the way.
Release Notes:
- N/A
Closes#39469Closes#39438Closes#39458
I'm not able to test it, i would appreciate if somebody could do it. I
think this bug was present also for SSH remote projects
Release Notes:
- Fixed an issue where zed bin was not found in remote servers for
askpass
---------
Signed-off-by: Marco Mihai Condrache <52580954+marcocondrache@users.noreply.github.com>
This fixes a regression in #39557--for the project diff, we rely on
getting an event when a path inside a git repository changes, even if
the git state of the repository didn't change as a result (e.g. a new
modification to a file that already had the "modified" status).
I've also changed this code to send the `UpdateRepository` proto message
even when the git state didn't change, since otherwise we have the same
problem in SSH and collab projects.
Release Notes:
- N/A
The panic happened when a user had a settings file with a buffer line
height custom variant, because the drop-down renderer only took into
account the two named variants.
The fix for this will be creating a custom element that allows a user to
manually input a line height greater than one or select either
Comfortable or Standard.
Release Notes:
- N/A
The font picker from onboarding is a lot friendlier to interact with and
makes it impossible for a user to select an invalid font from the
settings ui.
I also moved the font picker from the onboarding crate to the ui_input
crate
## New Look
<img width="1136" height="812" alt="image"
src="https://github.com/user-attachments/assets/7436682c-6a41-4860-a18b-13e15b8f3f31"
/>
Release Notes:
- N/A
mac_watcher already does this so it would make more sense to also do
this on Windows and it saves ~500-600mb of ram on the chromium project.
This does not improve memory usage on linux because inotify cannot do
recursive directory monitoring
Release Notes:
- N/A
## Summary
Fixes an issue where font features (like ligatures) were not applied to
text under the vim block cursor. The cursor would inherit the font
family from the character at the cursor
position, but would use default font features instead of the editor's
configured font features.
## Changes
- Make the font mutable when rendering the vim block cursor
- Apply the editor's text style font features to the cursor font
This ensures that text under the block cursor renders with the same
visual appearance as the rest of the editor content.
Closes#39471
Release Notes:
- Fixed vim block cursor not respecting font features (like ligatures)
Should close#39428
The working directory of the `wsl.exe` program is set to a Linux path,
which is invalid on the Windows side, causing the terminal to crash. The
first spawn works because there is no active terminal view, allowing a
new shell (which checks for the remote) to be created. I cannot explain
why it works on SSH remote clients, but I may be missing something in
the remote connection implementation.
I don't have a Windows machine to test this, so I would appreciate
someone testing it. 🙏🏼
Release Notes:
- Fixed an issue where WSL terminals could not be splitted
---------
Signed-off-by: Marco Mihai Condrache <52580954+marcocondrache@users.noreply.github.com>
This PR adds the numeric stepper component to the settings ui and
implements some settings that rely on this component as well.
I also switched {buffer/ui}_font_weight to the `gpui::FontWeight` type
and added a manual implementation of the Schemars trait. This allows Zed
to send min, max, and default information to the JSON LSP when a user is
manually editing the settings file.
The numeric stepper elements added to the settings ui are below:
- ui font size
- ui font weight
- Buffer font size
- Buffer font weight
- Scroll sensitivity
- Fast scroll sensitivity
- Vertical scroll margin
- Horizontal scroll margin
- Inline blame padding
- Inline blame delay
- Inline blame min column
- Unnecessary code fade
- Tab Size
- Hover popover delay
Release Notes:
- N/A
# Why
I have find out that this tool exists by browsing Keymap Editor. I think
it would be nice for its discoverability to show it in the app menus in
Dev builds.
# How
Add "GPUI Inspector" app menu item conditionally for Dev builds only.
Release Notes:
- N/A
# Preview
<img width="1014" height="948" alt="Screenshot 2025-10-01 at 14 36 48"
src="https://github.com/user-attachments/assets/c0409e67-1f4d-44f3-90b3-293ad4fe5c73"
/>
We have unnecessary clones for the fields here as most of the snapshots
contain the others hierarchically.
Release Notes:
- N/A *or* Added/Fixed/Improved ...
Add support for rendering Unicode combining characters (diacritics) in
the terminal's batched text runs.
- Add append_zero_width_chars() to handle combining marks
- Integrate zero-width chars into all batching code paths
- Update cell extras tracking logic
- Add test for combining character rendering
Fixes display of é, ñ, ô and other diacritics.
Closes#39525
Release Notes:
- Fixed: NFD/NFKD normalized text (e.g., é as e + ◌́) not rendering in
integrated terminal
Before:
<img width="874" height="688" alt="SCR-20251004-udnj"
src="https://github.com/user-attachments/assets/8d9f9c9f-dac4-4382-92c2-8b6c1d817abd"
/>
After:
<img width="873" height="686" alt="SCR-20251004-ulsw"
src="https://github.com/user-attachments/assets/fbd5cdc7-fdd6-44dc-8b05-cc425644f1a0"
/>
The editor settings control module was the first prototype of what a
settings UI could look like in Zed, but the code is outdated now and is
no longer used. So this PR removes it for cleanup.
Release Notes:
- N/A
I was looking at the rope implementation and some of the existing bugs
that crash in there, and I ran cargo-mutants to inspect test coverage. I
was motivated by bugs like
https://github.com/zed-industries/zed/issues/38556 but this doesn't fix
it and the bug may well be at a higher layer.
This PR adds coverage for a few functions that aren't tested today. I
didn't find any actual bugs yet.
I can see this tree is pretty sparse on docstrings so if you think these
are too verbose I can take them out or drop the whole PR.
Release Notes:
- N/A
When running flycheck, I've noticed that scrolling starts to lag:
https://github.com/user-attachments/assets/b0bef0a3-ccbd-479d-a385-273398086d38
When checking the trace, it is notable that project panel updates its
entire tree multiple times during flycheck:
<img width="2032" height="1136" alt="image"
src="https://github.com/user-attachments/assets/d1935e77-3b00-4be5-a12a-8a17a9d64202"
/>
[scrolling.trace.zip](https://github.com/user-attachments/files/22710852/scrolling.trace.zip)
Turns out, `target/debug` directory is loaded by Zed (presumably,
reported by langserver as there are sources generated by bindgen and
proto that need to be loaded), and `target/debug/build` directory
received multiple events of a `None` kind for Zed, which trigger the
rescans.
Rework the logic to omit the `None`-kind events in Zed, and to avoid
excessive repo updates if not needed.
Release Notes:
- Improved worktree FS event emits in gitignored directories
---------
Co-authored-by: Cole Miller <cole@zed.dev>
Follow-up: https://github.com/zed-industries/zed/pull/38590
**Note**: this PR contains changes from the [previous
PR](https://github.com/zed-industries/zed/pull/38590), when that PR gets
merged we should see the real changes.
This PR fixes 4 things in order to make:
1. Add html/markdown minifier to remove all the **\t** and **\n**
characters. This is needed as you cannot create new lines with markdown
by just adding an enter to the source file.
2. The event Event::HTML only contained a chunk of the real html for
multiline HTML code. I fixed this by storing the currently watched HTML
inside a buffer and at the end we parse it into the right elements.
Instead of trying to parse a chunck into multiple elements which would
always fail before.
3. Add support for html tables.
4. Fixed panic that occured when table does not have an header.
I also decided to keep the html minifier inside Zed, because making it a
dependency for just a few 100 lines seems to be an overkill. The
original crate had a few cve in their dependencies, so figured this
would be the best.
**Html table support**
<img width="1439" height="801" alt="Screenshot 2025-09-27 at 12 19 07"
src="https://github.com/user-attachments/assets/a884cc6f-cf47-45a2-81fa-91300c7bbf3f"
/>
**Before & after Zed's README (no changes)**
<img width="3440" height="1378" alt="Screenshot 2025-09-27 at 12 34 47"
src="https://github.com/user-attachments/assets/1273b094-fb24-4abd-bffa-56ef3b44670c"
/>
Release Notes:
- Markdown: Added support for html tables
## Problem
When splitting a terminal pane, the new pane opens in the root directory
(`/`) instead of preserving the current working directory of the
original terminal.
For example, when working in `/Users/modestnerd/Developer/Projects/zed`
(my pc) and splitting the terminal pane, the new pane would open in `/`
instead of staying in the current directory.
## Solution
Restructured the fallback logic in
`new_pane_with_cloned_active_terminal` (terminal_panel.rs:452-456) to
ensure `default_working_directory(workspace, cx)` is called as a
fallback even when a terminal view exists but its `working_directory()`
returns `None`.
The fix changes the nested `and_then` to use `or_else` for the fallback,
ensuring the working directory is always properly resolved before
entering the async block.
Release Notes:
- Fixed terminal split pane opening in wrong directory instead of
preserving the current working directory
Fixes a `--release`-only bug in feature-flagged agents where the feature
flag isn't picked up in some situations (unless there was a settings
change to go with it - due to an early return when settings didn't
change).
Release Notes:
- N/A
If we get a `cwd` from ACP (because e.g. `codex-acp` is driving the
terminal rather than our own PTY) then use that to display the `cwd` of
the terminal process.
Release Notes:
- N/A
This only affects `codex-acp` for now.
Not using the PTY in display-only terminals means they don't display the
login prompt (or spurious `%`s) at the end of terminal output
renderings.
Release Notes:
- N/A
The ordering of path-based excerpts in multibuffers regressed with
#38744, because we changed the `path` field of `PathKey` to be a string
(from `std::path::Path`) and used the derived `Ord` implementation,
which doesn't agree with the path-based order of worktree traversals.
This PR fixes that by using `RelPath` for `PathKey`. Instead of using
`File::full_path`, which can be absolute, we always use `File::path` and
distinguish different worktrees using their ID.
Release Notes:
- N/A
---------
Co-authored-by: Lukas Wirth <me@lukaswirth.dev>
This fixes an issue where the outline modal would not work in editors
that had no explicit workspace attached to them.
Release Notes:
- Enabled the outline modal to work in channel notes.
This is the first step to allowing users to type into a numeric stepper
to set its value. This PR makes the numeric stepper take in a generic
type `T` where T: `NumericStepperType`
```rust
pub trait NumericStepperType:
Display
+ Add<Output = Self>
+ Sub<Output = Self>
+ Copy
+ Clone
+ Sized
+ PartialOrd
+ FromStr
+ 'static
{
fn default_format(value: &Self) -> String {
format!("{}", value)
}
fn default_step() -> Self;
fn large_step() -> Self;
fn small_step() -> Self;
fn min_value() -> Self;
fn max_value() -> Self;
}
```
This allows setting of step sizes and min/max values as well as making
the component easier to use.
cc @danilo-leal
Release Notes:
- N/A
---------
Co-authored-by: Mikayla Maki <mikayla.c.maki@gmail.com>
Co-authored-by: Gaauwe Rombouts <mail@grombouts.nl>
Closes https://github.com/zed-industries/zed/issues/39406
Follow up to https://github.com/zed-industries/zed/pull/38726
This PR introduces the `agent_buffer_font_size` setting and renames
`agent_font_size` to `agent_ui_font_size`. This allows whoever wants
`buffer_font_size` and `agent_buffer_font_size` to match, as well as
folks who want a slightly smaller size only in the agent panel (which...
also looks just better by default!).
Release Notes:
- agent: Introduced the `agent_buffer_font_size` setting and renamed
`agent_font_size` to `agent_ui_font_size`, allowing for granular buffer
font size control in the agent panel vs. regular editors.
This PR fixes the JSON schema for the `ExtensionCapabilityContent`.
Having the nested structs in the variants caused the `kind` property to
not be generated properly. Inlining the fields into the variants fixes
this.
Release Notes:
- N/A
This PR adds the ability to control the capabilities granted to
extensions by the extension host via the new
`granted_extension_capabilities` setting.
This setting is a list of the capabilities granted to any extension
running in Zed.
The currently available capabilities are:
- `process:exec` - Grants extensions the ability to invoke commands
using
[`zed_extension_api::process::Command`](https://docs.rs/zed_extension_api/latest/zed_extension_api/process/struct.Command.html)
- `download_file` - Grants extensions the ability to download files
using
[`zed_extension_api::download_file`](https://docs.rs/zed_extension_api/latest/zed_extension_api/fn.download_file.html)
- `npm:install` - Grants extensions the ability to install npm packages
using
[`zed_extension_api::npm_install_package`](https://docs.rs/zed_extension_api/latest/zed_extension_api/fn.npm_install_package.html)
Each of these capabilities has parameters that can be used to customize
the permissions.
For instance, to only allow downloads from GitHub, the `download_file`
capability can specify an allowed `host`:
```json
[
{ "kind": "download_file", "host": "github.com", "path": ["**"] }
]
```
The same capability can also be granted multiple times with different
parameters to build up an allowlist:
```json
[
{ "kind": "download_file", "host": "github.com", "path": ["**"] },
{ "kind": "download_file", "host": "gitlab.com", "path": ["**"] }
]
```
When an extension is not granted a capability, the associated extension
APIs protected by that capability will fail.
For instance, trying to use `zed_extension_api::download_file` when the
`download_file` capability is not granted will result in an error that
will be surfaced by the extension:
```
Language server phpactor:
from extension "PHP" version 0.4.3: failed to download file: capability for download_file https://github.com/phpactor/phpactor/releases/download/2025.07.25.0/phpactor.phar is not granted by the extension host
```
Release Notes:
- Added a `granted_extension_capabilities` setting to control the
capabilities granted to extensions.
Closes#39308
Also fixes a possible bug in `apply_selected_diff_hunks()` caused by
reversed selections.
Release Notes:
- Fixed "editor: fold at level" closing regions containing selections
Co-authored-by: Conrad Irwin <conrad.irwin@gmail.com>
These changes fix an issue with vim's visual block mode when soft
wrapping is enabled. In this situation, if one was to move the cursor
either up or down, the selection would be updated to include visual
(wrapped) rows, instead of only the buffer rows. For example, take the
following contents:
```
1 | And here's a very long line that is wrapping
at this exact point.
2 | And another very long line that is will also
wrap at this exact point.
```
If one was to place the cursor at the start of the first line, character
`A`, trigger visual block mode with `ctrl-v` and then move down one line
with `j`, the selection would end up as (with [X] representing the
selected characters):
```
1 | [A]nd here's a very long line that is wrapping
[a]t this exact point.
2 | [A]nd another very long line that is will also
wrap at this exact point.
```
Instead of the expected:
```
1 | [A]nd here's a very long line that is wrapping
at this exact point.
2 | [A]nd another very long line that is will also
wrap at this exact point.
```
With the changes in this commit, `Vim.visual_block_motion` will now
leverage buffer rows in order to navigate to the next or previous row.
Release Notes:
- Fixed handling of soft wrapped lines in vim's visual block mode
This improves the design of the profile picker a bit by making every
item on it have the same height; it also makes it more consistent with
the model selector.
Release Notes:
- N/A
I'm not sure about the exact conditions for reproducing this issue, but
whenever I build Zed locally and have it open a single-file worktree on
launch, the rust-analyzer language server fails to start up because Zed
attempts to run `rust-analyzer --help` on a path that is not a
directory. This fixes that by running the command on the parent path in
the case of a single-file worktree.
Release Notes:
- Fixed rust-analyzer startup issue in single-file worktrees
Now we use GitHub Releases to detect when there's a new version of
codex-acp out, and we notify the user in the same way we do for the
other external agents.
This also moves `github_download.rs` out of the `languages` crate and
into `http_client`, because now we're not just using it for language
servers anymore, we're also using it for external agents.
Release Notes:
- N/A
---------
Co-authored-by: Lukas Wirth <me@lukaswirth.dev>
Currently most icon theme extensions already support file types like
stories.tsx and stories.svelte. However within Zed itself these file
type overrides are not supported yet. This change adds support for those
Release Notes:
- Added support for icons on file extensions such as stories.tsx and
stories.svelte
This removes a long-standing thing we've done, which is send a `DidSave`
notification to the language server for the clean parts of a
multi-buffer. However, it seems like the intent of that notification is
to tell the language server to reload the file from disk.
As we didn't actually write those files to disk, it seems clearer to not
send this notification; and just remove this whole code-path.
Release Notes:
- Fixed a race where autosave in a multibuffer could cause unsaved
buffers to appear saved
Codex needs (and future projects are anticipated to need as well) a
concept of display-only terminals. This refactors terminals to decouple
the PTY part from the display part, so that we can render terminal
changes based on a series of events - regardless of whether they're
being driven from a PTY inside Zed or from an outside source (e.g.
`codex-acp`).
Release Notes:
- N/A
This was added for Codex, but had undesirable consequences for Claude
Code (on Nightly, never made it to Preview). We're going to address this
in `codex-acp` instead.
Release Notes:
- N/A
This PR adds a `token_spend_in_cents` and associated
`token_spend_in_cents_updated_at` column to the `billing_subscriptions`
table.
Release Notes:
- N/A
Closes#5355
Release Notes:
- Fixed rendering glitches with files with more than 16 million lines
(that occured due to floating number rounding errors).
---------
Co-authored-by: Smit Barmase <heysmitbarmase@gmail.com>
Closes #ISSUE
Release Notes:
- settings: Removed support for having format steps in both the
`format_on_save` and `formatter` settings for languages.
`format_on_save` is now restricted to the values of `"on"` and `"off"`,
and all format steps should be set under the `formatter` key. If you
were using `format_on_save` but not `formatter` this will be migrated
for you, otherwise it will require a manual migration.
---------
Co-authored-by: Smit <smit@zed.dev>
When sourcing the project environment for the terminal tool, we will now
do so by spawning the shell specified by the users `terminal.shell`
setting (or as usual fall back to the login shell).
Closes#37687
Release Notes:
- N/A
Closes #ISSUE
Adds the ability to create settings and keymap migrations by mutating
`serde_json::Value`s instead of using tree-sitter queries. This
(hopefully) will make complicated migrations far simpler to implement.
Release Notes:
- N/A *or* Added/Fixed/Improved ...
---------
Co-authored-by: Smit <heysmitbarmase@gmail.com>
Co-authored-by: Smit <smit@zed.dev>
Closes#38571
Release Notes:
- git: Fixed git features not working when git was installed in an
unusual location.
---------
Co-authored-by: Lukas Wirth <me@lukaswirth.dev>
How it looks:
https://github.com/user-attachments/assets/9a355807-5461-4e8d-b7a8-9efb98cea67a
Idea behind this is to reduce flickering in areas where nothing is
happening - whenever these hide, the user is specifically not
interacting with them, hence it can be distracting to have something
flicker in the side of your eye. This PR tackles this.
Release Notes:
- Added graceful autohiding to scrollbars outside of the editor
---------
Co-authored-by: Danilo Leal <67129314+danilo-leal@users.noreply.github.com>
Closes#39283
Release Notes:
- Fixed: In multi-repo workspaces, files with the same name are no
longer hidden in the file picker after one is opened
---------
Signed-off-by: Marco Mihai Condrache <52580954+marcocondrache@users.noreply.github.com>
Closes #ISSUE
Release Notes:
- settings: Changed code action format in `formatter` and
`format_on_save` settings.
**Previous format:**
```
{
"code_actions": {
"source.organizeImports": true,
"source.fixAll": true
}
}
```
**New format:**
```
[
{"code_action": "source.organizeImports"},
{"code_action": "source.fixAll"}
]
```
After #39246, code actions run sequentially in order. The structure now
reflects this and aligns with other formatter options (e.g., language
servers).
Both the `formatter` and `format_on_save` settings will be
auto-migrated.
### Summary
* Auto-activates the active repository when opening a buffer.
* Prepares branching for future support of a user choice (e.g.,
`auto_activate_repo_on_open` flag).
### Release Notes
* **Improved**: Opening a buffer now automatically updates the active
repository.
This pull request adds the missing **`GEMINI.md`** file, which will
serve as the rule/configuration file for **`gemini-cli`**.
Currently, the repository includes several rule files such as
**`.clinerules`**, **`.cursorrules`**, **`.rules`**, and
**`.windsurfrules`**. Adding **`GEMINI.md`** standardizes the
configuration structure and ensures that the specific rules for the
`gemini-cli` are properly documented alongside the others.
Release Notes:
- N/A
Remove the ad-hoc quoting we were doing before, which only works for
POSIX shells, in favor of using `Shell::WithArguments`.
Release Notes:
- N/A
---------
Co-authored-by: Lukas Wirth <me@lukaswirth.dev>
This PR starts the process of adding each setting field manually to
their respective page in the UI and organizes user/project fields as
well. The next major step is implementing a numeric stepper component,
and handling discriminate union enums as well.
I also did some minor polish in this PR as well
- Switches now use accent color
- Fixed text input rendering with zero width
- Made setting pages scrollable
- Set drop down context menu style to outline
Release Notes:
- N/A
---------
Co-authored-by: dino <dinojoaocosta@gmail.com>
In the ACP changes, we changed how terminals are created for the agent,
and so the system prompt was putting in the system shell instead of the
default one, potentially causing confusion for the model.
These are now in sync, so this will hopefully alleviate issues people
were seeing, as well as use a more standard shell to increase the
likelihood of successful model tool calls.
Release Notes:
- agent: Align default shell path in system prompt with the actual path
it is given
Fixes titlebar double-click behavior to properly handle the macOS system
setting when "Do Nothing" is selected in System Settings > Desktop &
Dock > "Double-click a window's title bar to".
Closes https://github.com/zed-industries/zed/issues/39102
Release Notes:
- Fixed macOS Do Nothing window double click setting not being
respected.
Closes #ISSUE
Release Notes:
- project panel: Revamped how project panel entries are refreshed, which
should lead to a significantly smoother experience when working in large
projects.
---------
Co-authored-by: Smit Barmase <heysmitbarmase@gmail.com>
Thanks to @Zertsov for #37932 which caused me to consider this
implementation approach.
One known issue with this is that it will not wait for actions that do
async work to complete. Supporting this would require quite a lot of
code change. It also doesn't affect the main usecase of sequencing
editor actions, since few are async.
Another caveat is that this is implemented as an action handler on
workspace and so won't work in other types of windows. This seems fine
for now, since action sequences don't seem useful in other window types.
The command palette isn't accessible in non-workspace windows.
Alternatives considered:
* Add `cx: &App` to `Action::build`. This would allow removal of the
special case in keymap parsing. Decided not to do this, since ideally
`build` is a pure function of the input json.
* Build it more directly into GPUI. The main advantage of this would be
the potential to handle non-workspace windows. Since it's possible to do
outside of GPUI, seems better to do so. While some aspects of the GPUI
action system are pretty directly informed by the specifics of Zed's
keymap files, it seems to avoid this as much as possible.
* Bake it more directly into keymap syntax like in #37932. While I think
it would be good for this to be a primitive in the JSON syntax, it seems
like it would better fit in a more comprehensive change to provide
better JSON structure. So in the meantime it seems better to keep the
structure the same and just add a new action.
- Another reason to not bake it in yet is that this provides a place to
document the caveat about async actions.
Closes#17710
Release Notes:
- Added support for action sequences in keymaps. Example:
`["action::Sequence", [ ["editor::SelectLargerSyntaxNode",
"editor::Copy", "editor::UndoSelection"]`
---------
Co-authored-by: Mitchel Vostrez <mitch@voz.dev>
Closes#39318
The rules panel on the rules library window was rendering a black
background when the `panel.background` property on the active theme had
some level of transparency (for example `1917264D` on `nightfox` theme).
<img width="1650" height="889" alt="image"
src="https://github.com/user-attachments/assets/6a8d124a-38da-4d01-817a-c289926bd39c"
/>
Left is before, right is after. The bug can be replicated by using
`theme_overrides` on settings:
```json
"experimental.theme_overrides": {
"panel.background": "#00000000",
"background": "#ffffff"
},
```
Release Notes:
- Fix "secondary" background on rules panel
These are now being crafted by hand, using the social media content we
do each Wednesday. I'm keeping the action around because we may want to
use this to automate publishing the hand-crafted emails in the future.
Release Notes:
- N/A
Removes the preview note of the `buffer_font_size` used for agent panel
buffers, now that's available in stable as of 206.6. Also ended up
removing the "available in agent settings UI" thing because... that will
very soon not be needed to be called out.
Release Notes:
- N/A
Closes#24412 and #19471
I tested both insertion and replacing with o3-mini and it failed with
the current prompt. With the updated prompt it does no longer return
`<document><rewrite_this>` or `{{REWRITTEN_CODE}}`
I have ensured the LLM Worker works with these prompt changes.
Release Notes:
- Improved prompting for the inline assistant
This removes a hack from `MultiBuffer::anchor_at` that works around
missing logic for handling `ExcerptId::max()` by implementing that said
missing logic.
Generally, `ExcerptId::min()` is already being handled correctly due to
how `Cursor` seeking works, we tend to seek to or beyond a seek target,
meaning `min` will always match the first excerpt as expected. `max` on
the other hand will always seek beyond the last excerpt resulting in no
excerpt being found, so any code path dealing with the excerpt sumtree
will have to specially check for this special excerpt ID to work
correctly.
Release Notes:
- N/A *or* Added/Fixed/Improved ...
Fixes titlebar double-click behavior to properly handle the macOS system
setting when "Do Nothing" is selected in System Settings > Desktop &
Dock > "Double-click a window's title bar to".
Closes#39102
Release Notes:
- Fixed macOS `Do Nothing` window double click setting not be respected
Before this change, it would save every buffer and wait for diagnostics.
For rust analyzer this would cause a lot of rechecking and greatly slow
down the analysis
Release Notes:
- N/A
Co-authored-by: Agus <agus@zed.dev>
Closes#39112
Release Notes:
- Fixed an issue when using code actions on format where specifying
multiple code actions in the same code actions block that resolved to
code actions from different language servers could result in conflicting
edits being applied and mangled buffer text.
@ConradIrwin No longer needed the issue appears to be fully resolved
after moving to MacOS Tahoe as the latest instead of only in dev beta
Release Notes:
- N/A
This happened when search results completely filtered out a page above
the selected page index.
The old index was calculated based on the nav bar entry's position and
the count of root entries above it, this was wrong because root entries
could be filtered out with a search. Now the page index is saved when
building the navbar
Release Notes:
- N/A
Get a basic search implementation working in the settings ui and fix nav
bar toggling bugs.
Search functionality works by passing in each page and its items into
our fuzzy search crate and filtering out any non-matches. A page is a
match if any of its items are a match and an item is a match if its
title or description has a fuzzy score greater than zero.
In the future, a page section header will be filtered out if none of its
children has a match or it will show all its children on a match. The
team still has to decide what to do in that edge case, but that's the
last step until search is fully implemented for our initial launch.
Finally, I found some bugs in our nav bar toggling that occurred because
we weren't taking into account the index change that occurred when
toggling an element with children that is above the selected nav bar
entry. I added tests to cover those edge cases as well.
Release Notes:
- N/A
---------
Co-authored-by: Ben Kunkle <ben@zed.dev>
We've seen this panic come up in the last two weeks, which might be
caused by #33592. However, we are not sure what paths can cause this
`unwrap()` to fail. Therefore adding some logging around this, so that
the next time someone opens a bug report we can further diagnose the
issue.
Fixes ZED-1F6
Release Notes:
- Fixed an issue where Zed could crash when including specific paths in
a global `.gitignore` files
The bug happened because the Python locator was checking for a quote
before the ZED task variable. Removing that part of the check fixed the
issue.
Closes#39179
Release Notes:
- Fix Python debug tasks not showing up in code actions or debug picker
Closes #ISSUE
Adds a couple functions to the `SettingsStore`:
- `get_value_from_file`: Gets a value from a given settings file
(`Local`, `User`, etc) and if the value isn't found in the requested
file, walks the known settings files in the order in which they are
merged to find the settings value in lower precedence settings files
(i.e. if value not set anywhere will always return default value)
- `get_overrides_for_field`: Returns a list of settings files where a
given setting is set that have higher precedence than the passed in
file. e.g. passing in user will result in project settings files where
the value is set being returned.
Additionally changes the default for the `project_name` setting to
uphold the rules we are attempting to enforce on the settings, namely:
- All settings fields should be of the form `Option<T>`
- `None` (or `null` in JSON) should never be a meaningful value
Follow up PRs will handle implementing a function to write to an
arbitrary settings file, and passing through metadata to the above
functions to control how overrides are determined for more complicated
cases like `SaturatingBool` (`disable_ai`) and `ExtendingVec`
Release Notes:
- N/A *or* Added/Fixed/Improved ...
---------
Co-authored-by: Ben Kunkle <ben@zed.dev>
Co-authored-by: Anthony Eid <hello@anthonyeid.me>
Co-authored-by: Danilo Leal <daniloleal09@gmail.com>
Co-authored-by: Anthony <anthony@zed.dev>
There was an issue with login after the migration to the new anthropic
package. This makes sure folks are migrated to a known working version
(though the latest version also now works on old versions)
Release Notes:
- N/A
Co-authored-by: Richard Feldman <oss@rtfeldman.com>
I don't totally follow how the `cmd_click_reveal_task` function works,
but it branches on whether `self.hovered_link_state` exists and contains
any links, and in case it doesn't, it doesn't use `modifiers.alt` for
deciding where to navigate. This PR addresses that.
The problem I've been having is that cmd-alt-click sometimes behaves as
cmd-click, i.e. it navigates to the definition in the current pane. This
appears to happen whenever I cmd-alt-click while the symbol I'm hovering
over isn't underlined, possibly when I click too quickly?
An alternative way to reliably reproduce this is to cmd-alt-click on a
symbol without letting go of cmd and alt and without moving the cursor.
Now the symbol is no longer underlined (and the hover preview has
disappeared as well), so clicking again (while still holding cmd and
alt) goes to the definition in the current pane:
https://github.com/user-attachments/assets/34003e01-fd95-4741-8a7d-6240d1c5a495
Release notes:
- Fixed a bug that caused cmd-alt-click to sometimes go to the
definition in the current pane
Co-authored-by: Joseph T. Lyons <JosephTLyons@gmail.com>
Closes https://github.com/zed-industries/zed/issues/39183
This PR adds UI improvements to clarify the concept of "default rules"
and how they separate from regular rules. This is mostly motivated by
the issue linked above, where it clarified that the star icon was
communicating a "favoriting" affordance, which is not correct with how
rules work in Zed. When you tag/attach a rule as default, it will always
be included in every prompt, together with the agent's system prompt and
project rules (if they exist).
Hopefully, this will make understanding better. Here's how it looks like
now?
https://github.com/user-attachments/assets/435d3af7-e8a6-4646-8f00-94a409bd5f42
Release Notes:
- Improve rules library UI to better communicate the concept of default
rules vs. regular rules.
Despite how great `cmd-d` as a keybinding is, that was not working as it
was conflicting with an editor keybinding:
https://github.com/user-attachments/assets/2ea8665b-7008-4f0a-9426-8d31d379ee1c
This PR changes it to `cmd-alt-z`, which is the best "remove/fix"-type
of keybinding I could find that doesn't conflict with anything else.
Ideally, we'd use either the D, N, or R letters for "deny", "no", and
"reject", but unfortunately, none of them are nicely available in this
context...
Release Notes:
- agent: Fix keybinding to deny running a command
Before we would notify the user even if the download failed. We also
we're overwriting the directory, which means a user could be stuck in a
loop if a previous download failed
Release Notes:
- acp: Fix user seeing update prompt in a loop because of a previous
failed download
Closes#34393
Currently, we’re using `zed.exe --askpass` kind of like an `nc`
substitute, it prints out the SSH password to stdout with something like
`println!("user-pwd")`. `ssh.exe` then reads the password from stdout so
it can establish the connection.
The problem is that in release builds we set `subsystem=windows` to
avoid Windows spawning a black console window by default. The side
effect is that `zed.exe` no longer has a stdout, so `ssh.exe` can’t read
the password.
Through testing, I confirmed that neither allocating a new console for
`zed.exe` nor attaching it to the parent process’s stdout resolves the
issue. As a result, this PR updates the implementation to use `cli.exe
--askpass` instead.
TODO:
- [ ] Check that the `cli` path is correct on macOS
- [ ] Check that the `cli` path is correct on Linux
Release Notes:
- N/A
---------
Co-authored-by: Piotr Osiewicz <24362066+osiewicz@users.noreply.github.com>
This PR is a follow-up to #39090 and addresses two issues:
* Moves `conpty.dll` and `OpenConsole.exe` out of the `bin` folder to
prevent other programs from using them.
* Updates these files only after Zed exits, avoiding update failures due
to file locks.
Release Notes:
- N/A
---------
Co-authored-by: Jakub Konka <kubkon@jakubkonka.com>
The state of the child bounds is not up-to-date when `scroll_to_item`
gets triggered, causing the new tab to not scroll completely into view.
Closes#36317
Release Notes:
- Fix an issue where a new tab is only partially visible on creation.
Update the list of supported options in vim mode so that the following
are now available:
- `:set ignorecase`
- `:set noignorecase`
- `:set ic`
- `:set noic`
This controls whether the case-sensitive search option is disabled or
enabled when using the buffer and project searches, with `ignorecase`
disabling the search option and `noignorecase` enabling it.
Release Notes:
- Added support for `:set ignorecase` and `:set noignorecase` in vim
mode
---------
Co-authored-by: Conrad Irwin <conrad.irwin@gmail.com>
Also skips indexing files that don't have a suffix that indicates a
known language, and skips when the language doesn't have an outline
grammar.
Release Notes:
- N/A
---------
Co-authored-by: Agus <agus@zed.dev>
Closes#10930Closes#11353
Release Notes:
- Adds commands to project_panel
- `ctrl-u` scrolls the project_panel up half of the visible entries
- `ctrl-d` scrolls the project_panel down half of the visible entries
- `z z` scrolls current selection to center of window
- `z t` scrolls current selection to top of window
- `z b` scrolls current selection to bottom of window
- `{num} j` and `{num} k` now move up and down with a count
Add the single word "Locally" to clarify where the info is coming from,
(and that you don't need to be online.)
Closes #ISSUE
Release Notes:
- N/A *or* Added/Fixed/Improved ...
Since 2021 Neovim remaps Y to $y (1). DO the same in zed through a new action `YankToEndOfLine`.
1: https://github.com/neovim/neovim/pull/13268
Release Notes:
- Added vim::YankToEndOfLine action which copies from the cursor to the end of the line excluding the newline. We bind it to Y by default in the vim keymap.
Closes#22657Closes#37863
# Background
Several users have noted that the terminal shipped with Zed on Windows
is either misbehaving or missing several features including lack of
consistent clearing behaviour. After some investigation which included
digging into the Microsoft Terminal project and VSCode editor, it turns
out that the pseudoconsole provided by Windows OS is severely outdated
which manifests itself in problems such as lack of clearing behaviour,
etc. Interestingly however, neither MS Terminal nor VSCode exhibit this
limitation so the question was why. Enter custom `conpty.dll` and
`OpenConsole.exe` runtime. These are updated, developed in MS Terminal
tree subprojects that aim to replace native Windows API as well as
augment the `conhost.exe` process that runs by default in Windows. They
also fix all the woes we had with the terminal on Windows (there is a
chance that ctrl-c behaviour is also fixed with these, but still need to
double check that this is indeed the case). This PR ensures that Zed
also benefits from the update pseudoconsole API.
# Proposed approach
It is possible to fork MS Terminal and instrument the necessary
subprojects for Rust-awareness (using `cc-rs` or otherwise to compile
the C++ code and then embed it in Rust-produced binaries for easier
inclusion in projects) but it comes at a cost of added complexity,
maintenance burden, etc. An alternative approach was proposed by
@reflectronic to download the binary from the official Nuget repo and
bundle it for release/local use. This PR aims to do just that.
There are two bits to this PR:
1. ~~when building Zed locally, and more specifically, when the `zed`
crate is being built, we will strive to download and unpack the binaries
into `OUT_DIR` provided by `cargo`. We will then set
`ZED_CONPTY_INSTALL_PATH=${OUT_DIR}/conpty` and use it at runtime in Zed
binary to tweak the loader's search path with that additional path. This
effectively ensures that Zed built from source on Windows has full
terminal support.~~ EDIT: after several discussions offline, we've
decided that keeping it minimal will serve us best, meaning: when
developing locally it is up to the developer of Zed to install
`conpty.dll` and put it in the loader's search path.
2. when bundling Windows release, we will download and unpack the nuget
package into Zed's bundle which will ensure it is installed in the same
directory as Zed by the installer.
**Note** I realise that 1. may actually not be needed - instead we could
leave that bit for the user who wants to run Zed from source to ensure
that they have `conpty.dll` in the loader's search path. I'd love to
hear opinions on this!
Release Notes:
- N/A
---------
Co-authored-by: Cole Miller <cole@zed.dev>
Fixes two inconsistencies around the behavior of cmd-alt-click that mess
with my VSCode muscle memory:
- The definition is opened in a pane to the right of the current pane,
unless there exists an adjacent pane to the left and not to the right,
in which case it's opened in the pane on the left
- In case Go to Definition needs to open a multibuffer, cmd-alt-click
does not open it in an existing pane to the right of the current pane,
it always creates a new pane directly to the right of the current pane
This PR irons out this behavior by always going to the definition in the
pane directly to the right of the current one, creating one only if one
doesn't yet exist.
If changing `Workspace::adjacent_pane` to not consider an existing pane
to the left is undesirable then that logic could be moved somewhere
else, or we can make it user configurable if necessary. Also happy to
split this PR up if either of these changes is controversial 🙂
Before:
https://github.com/user-attachments/assets/395754cd-6ecb-40bf-ae61-ee8903eed4ae
After:
https://github.com/user-attachments/assets/002797b1-51a7-48e5-a8d0-100d3a5049eb
Release Notes:
- Made the behavior of cmd-alt-click more consistent
---------
Co-authored-by: Joseph T. Lyons <JosephTLyons@gmail.com>
This is a follow up to #37510 and is also related to #38910.
Release Notes:
- Improved ordering of virtual environments, sort by distance to
worktree root.
I was trying to use the new user toolchains but every time I clicked on
one I had added, it would delete it from the picker. Ironically, it
wouldn't delete it permanently when I tried to by clicking on the trash
can icon. Every time I reopened the workspace all user toolchains were
there.
Release Notes:
- Fixed selecting and deleting user toolchains.
This allows to filter by main zed binary or remote server crashes, as
well as easily tell whether a crash happened in a remote-server binary
or not.
Release Notes:
- N/A
Previously, search results were sorted solely by candidate_id
(preserving original order from the database), which could result in
less relevant matches appearing before better ones.
This change sorts results primarily by fuzzy match score (descending),
with candidate_id as a tiebreaker for equal scores. This ensures that
better matches appear first while preserving recency order among items
with identical scores.
Example improvement:
- Searching for 'pica' will now rank 'picabo' higher than scattered
matches like 'project-api, project-chat'
- Consecutive character matches are prioritized over scattered matches
across multiple path segments
Release Notes:
- Improved project search relevance by ranking results using match score
instead of insertion order.
Replaces the use of Rodio's basic linear resampler with an fft based
resampler from the rubato crate. As we are down-sampling to the minimal
(transparent) sample rate for human speech (16kHz) any down-sampling
artifact will be noticeable.
This also refactors the rodio_ext module into sub-models as it was
getting quite long.
Release Notes:
- N/A
Closes https://github.com/zed-industries/zed/issues/38643
This PR adds some UI improvements to the Zed replacement of the system
dialog/prompt, including better visibility of which button is currently
focused.
One little design note, though: because of a current (and somewhat
annoying) constraint of button component, where we're only drawing a
border when its style is outlined, if I kept them horizontally stacked,
there'd be a little layout shift now that I'm toggling styles for better
focus visibility. So, for this reason, I changed them to be vertically
stacked, which matches the macOS design and avoids this problem. Maybe
in the future, we'll revert it back to being `flex_row` because that
ultimately consumes less space.
https://github.com/user-attachments/assets/500c840b-6b56-4c0c-b56a-535939398a7b
Release Notes:
- Improve focus visibility of the actions within Zed's UI system prompt.
Since https://github.com/zed-industries/zed/pull/36219 we now render
inlay hints as bold due to this.
Release Notes:
- N/A *or* Added/Fixed/Improved ...
- The fork with the patch is now included in 0.25.0
(7ff26dacd7).
- We no longer need `except*` as a keyword, which was added in
https://github.com/zed-industries/zed/pull/21389. It now highlights
correctly without explicitly mentioning it after
1b1ca93298.
Release Notes:
- N/A
After the change, we can add "supports_images", "supports_tools" and
"parallel_tool_calls" properties to set up new models. Our
`settings.json` will be as follows:
```json
"language_models": {
"x_ai": {
"api_url": "https://api.x.ai/v1",
"available_models": [
{
"name": "grok-4-fast-reasoning",
"display_name": "Grok 4 Fast Reasoning",
"max_tokens": 2000000,
"max_output_tokens": 64000,
"supports_tools": true,
"parallel_tool_calls": true,
},
{
"name": "grok-4-fast-non-reasoning",
"display_name": "Grok 4 Fast Non-Reasoning",
"max_tokens": 2000000,
"max_output_tokens": 64000,
"supports_images": true,
}
]
}
}
```
Closes https://github.com/zed-industries/zed/issues/38752
Release Notes:
- xAI: Added support for for configuring tool and image support for
custom model configurations
Since we might run MCP servers locally for an agent, we don't want to
use the proxy for those.
We set this if the user has set a proxy, but not a custom NO_PROXY env
var.
Closes#38839
Release Notes:
- acp: Don't run local mcp servers through proxy, if set
Using `crate::command::new_smol_command` on the Windows platform will
not display the PowerShell window.
Closes#39052
Release Notes:
- N/A
Signed-off-by: Xiaobo Liu <cppcoffee@gmail.com>
Fixes the "failed to get working directory environment for repository"
error on Windows by implementing proper shell environment variable
capture.
Release Notes:
- Fixed failed to get working directory environment for repository
---------
Signed-off-by: Xiaobo Liu <cppcoffee@gmail.com>
Release Notes:
- collab: A distinct sound effect is now used for when a guest joins a
call.
- collab: Fixed the "joined" sound being excessively loud when joining a
call that already has many participants.
---------
Co-authored-by: David Kleingeld <davidsk@zed.dev>
⚠️ Don't merge until Zed 0.205.x is on stable ⚠️
See https://github.com/zed-industries/zed/pull/37811
This PR updates the HTML extension, bumping the zed extension API to the
latest version, which removes the need to work around a bug where
`current_dir()` returned an invalid path on windows.
Release Notes:
- N/A
The edit prediction button menu was displaying stale authentication
status due to capturing the Copilot status in a closure. After signing
out, the menu would still show "Sign Out" instead of "Sign In to
Copilot".
This change fixes the issue by reading the current Copilot status each
time the menu is displayed, ensuring the menu options are always
accurate.
Release Notes:
- Fixed Copilot AI menu not updating after sign out
Signed-off-by: Xiaobo Liu <cppcoffee@gmail.com>
i'm testing out zed, coming from emacs, and so i'm trying out the base
keymap for it. i noticed though that zed's default git keybindings don't
work when the gitpanel is open though, because of the top-level binding
of `ctrl-g` to cancel. my expectation is that the emacs-like keybindings
would work insofar as they don't clobber zed's defaults (which would
take precedence), but obviously i'll defer to others on this!
another option could be to use the `C-x v` keymap prefix that the emacs
built-in `vc` package uses, but it doesn't contain the same set of
bindings for git commands that zed has.
This reverts commit 1bbf98aea6.
We found that #38411 caused problems where anonymous functions are
included too many times in the outline. We'd like to figure out a better
fix before shipping this to stable.
Fixes#38956
Release Notes:
- (preview only) revert changes to outline view
Follows on from
https://github.com/zed-industries/zed/pull/37717#discussion_r2376739687
@dvdsk suggested this but I didn't get to it in the previous PR.
# Tested
```
; sudo rm /usr/local/bin/wild
; ./script/install-wild
Downloading from https://github.com/davidlattimore/wild/releases/download/0.6.0/wild-linker-0.6.0-x86_64-unknown-linux-gnu.tar.gz
Wild is installed to /usr/local/bin/wild
To make it your default, add or merge these lines into your ~/.cargo/config.toml:
[target.x86_64-unknown-linux-gnu]
linker = "clang"
rustflags = ["-C", "link-arg=--ld-path=wild"]
[target.aarch64-unknown-linux-gnu]
linker = "clang"
rustflags = ["-C", "link-arg=--ld-path=wild"]
```
```
; sudo rm /usr/local/bin/mold
; ./script/install-mold 2.34.0
Downloading from https://github.com/rui314/mold/releases/download/v2.34.0/mold-2.34.0-x86_64-linux.tar.gz
Mold is installed to /usr/local/bin/mold
To make it your default, add or merge these lines into your ~/.cargo/config.toml:
[target.'cfg(target_os = "linux")']
linker = "clang"
rustflags = ["-C", "link-arg=-fuse-ld=mold"]
```
Release Notes:
- N/A
# Why
I have recently corrected this tooltip content for macOS, but recently
have learnt that keystroke to text helpers already exist in the
codebase.
# How
Replace hardcoded keystroke for Excerpt Fold Toggle in Uncommitted
Changes tab.
> [!important]
> Should be merged after #38969 and #38971, otherwise it would be a
regression on macOS.
Release Notes:
- N/A
# Preview (stacked on mentioned above PRs)
<img width="618" height="248" alt="Screenshot 2025-09-26 at 17 43 53"
src="https://github.com/user-attachments/assets/cdc7fb74-e1d8-4a59-b847-8a8d2edd4641"
/>
# Why
Refs:
* #38969
When working on the PR above I have spotted that keybinding to text
helpers incorrectly detects if Vim mode is enabled.
# How
Replace inline check with an existing `KeyBinding::is_vim_mode` method
in keybinding text helpers.
Release Notes:
- Fixed incorrect Vim mode detection in UI keybinding to text helpers.
# Test plan
Made sure that when Vim mode is not specified in settings file it
resolves to `false`, and correct keybindings are displayed, than I have
added the `"vim_mode": true,` line to my settings file and made sure
that keybindings text have changed accordingly.
### Before
<img width="712" height="264" alt="Screenshot 2025-09-26 at 16 57 08"
src="https://github.com/user-attachments/assets/62bc24bd-c335-420f-9c2e-3690031518c1"
/>
### After
<img width="712" height="264" alt="Screenshot 2025-09-26 at 17 13 50"
src="https://github.com/user-attachments/assets/e0088897-eb6b-4d7b-855a-931adcc15fe8"
/>
Closes #ISSUE
Improves the efficiency of our interactions with the Zed language
server. Previously, on startup and after every workspace configuration
changed notification, we would send >1MB of JSON Schemas to the JSON
LSP. The only reason this had to happen was due to the case where an
extension was installed that would result in a change to the JSON schema
for settings (i.e. added language, theme, etc).
This PR changes the behavior to use the URI LSP extensions of
`vscode-json-language-server` in order to send the server URI's that it
can then use to fetch the schemas as needed (i.e. the settings schema is
only generated and sent when `settings.json` is opened. This brings the
JSON we send to on startup and after every workspace configuration
changed notification down to a couple of KB.
Additionally, using another LSP extension request we can notify the
server when a schema has changed using the URI as a key, so we no longer
have to send a workspace configuration changed notification, and the
schema contents will only be re-requested and regenerated if the schema
is in use.
Release Notes:
- Improved the efficiency of communication with the builtin JSON LSP.
JSON Schemas are no longer sent to the JSON language server in their
full form. If you wish to view a builtin JSON schema in the language
server info tab of the language server logs (`dev: open language server
logs`), you must now use the `editor: open url` action with your cursor
over the URL that is sent to the server.
- Made it so that Zed urls (`zed://...`) are resolved locally when
opened within the editor instead of being resolved through the OS. Users
who could not previously open `zed://*` URLs in the editor can now do so
by pasting the link into a buffer and using the `editor: open url`
action (please open an issue if this is the case for you!).
---------
Co-authored-by: Michael <michael@zed.dev>
std commands can block for an arbitrary duration and so runs risk of
blocking tasks for too long. This replaces all such uses where sensible
with async processes.
Release Notes:
- N/A *or* Added/Fixed/Improved ...
Wild changed in 0.6.0 to using gzip rather than xz, and changed the
format of the package name.
Follows on from and fixes
https://github.com/zed-industries/zed/pull/37717
cc @dvdsk @mati865
Release Notes:
- N/A
This PR adds an `x-zed-client-supports-x-ai` header to the `GET /models`
request sent to Cloud to indicate that the client supports xAI models.
Release Notes:
- N/A
Make `resolve_full_path` use the appropriate separators, and return a
`String`.
As part of fixing the fallout from that type change, this also fixes a
bunch of places in the agent code that were using `std::path::Path`
operations on paths that could be non-local, by changing them to operate
instead on strings and use the project's `PathStyle`.
This clears the way a bit for making `full_path` also return a string
instead of a `PathBuf`, but I've left that for a follow-up.
Release Notes:
- N/A
Closes#38553
Release Notes:
- Fixed wrong AssetKind specified on linux for ty
As discussed in the linked issue. All of the non windows assets for ty
are `tar.gz` files. This change applies that fix.
Release Notes:
- When `helix_mode = true`, modes are called without the `HELIX_` prefix
in the UI:
`HELIX_NORMAL` becomes `NORMAL`
`HELIX_SELECT` becomes `SELECT`
- (breaking change) Helix users should remove `"default_mode":
"helix_normal"` from their settings. This is now the default when
`"helix_mode": true`.
Release Notes:
- Fixed editor inlay hints incorrectly using status theming when syntax
theming is available
Previously, a theme's `style.syntax.hint` object is completely ignored,
and `style.hint` `style.hint.background` are used instead. However,
these seem to be related to status hints, such as the inline git blame
integration.
For syntax hints (as given by an LSP), the reasonable assumption would
be that the `style.syntax.hint` object is used instead, but it isn't.
This means that defining other style characteristics (`font_style`, for
example) does nothing.
I've fixed the issue in a backward-compatible way, by using the theme
`syntax` `HighlightStyle` as the base for inlay hint styling, and
falling back to the original `status` colors should the syntax object
not contain the color definitions.
With the following theme settings:
```jsonc
{
"hint": "#ff00ff", // Status hints (git blame, etc.)
"hint.background": "#ff00ff10",
"syntax": {
"hint": {
"color": "#ffffff", // LSP inlay hints
"background_color": "#ffffff10",
"font_style": "italic", // Now properly applied
"font_weight": 700
}
}
}
```
Current behavior:
<img width="896" height="201" alt="image"
src="https://github.com/user-attachments/assets/e89d212f-ed7e-4d27-94e4-96d716e229d2"
/>
Italics and font weight are ignored. Uses status colors instead.
Fixed behavior:
<img width="896" height="202" alt="image"
src="https://github.com/user-attachments/assets/f14ed2c3-bb60-4b74-886d-6b409d338714"
/>
Italics and font weight are used properly. Status color is preserved for
the git blame status, but correct syntax colors are used for the inlay
hints.
Closes#38620
`Url::from_file_path` and `Url::from_directory_path` assume the path
style of the target they were compiled for, so we can't use them in
general. So, switch from `file://` to encoding the absolute path (for
mentions that have one) as a query parameter, which works no matter the
platforms. We'll still parse the old `file://` mention URIs for
compatibility with thread history.
Release Notes:
- windows: Fixed a crash when using `@mentions` in agent threads when
remoting from Windows to Linux or WSL.
Tracing terminal events can now be enabled using typical `RUST_LOG`
invocation:
```
RUST_LOG=info,terminal=trace,alacritty_terminal=trace cargo run
```
Release Notes:
- N/A
This allows ITERATIONS and SEED environment variables to override the
hard coded values during testing.
cc @ConradIrwin @as-cii
Release Notes:
- N/A
---------
Co-authored-by: Conrad Irwin <conrad.irwin@gmail.com>
# Why
I have spotted that Keymap Editor filter input (editor) is misaligned
vertically.
# How
Switch the input wrapper to flex layout, use `items_center` to align
editor vertically in center of the wrapper.
Release Notes:
- Fixed Keymap Editor filter input alignment
# Test plan
I have tested the change locally and compared the UI before and after,
to make sure that change does not affect the size of the wrapper
element.
### Before
<img width="1622" height="428" alt="Screenshot 2025-09-25 at 18 18 59"
src="https://github.com/user-attachments/assets/7d09be5c-6caf-4873-8ecf-2542851cb40a"
/>
### After
<img width="1622" height="428" alt="Screenshot 2025-09-25 at 18 07 18"
src="https://github.com/user-attachments/assets/540fcb3e-691d-4fb7-8130-2ed45ddc0adc"
/>
This is how `ctrl-n` works on macOS. Right now `ctrl-n` on Windows with
the default keymap usually causes a new buffer to open, which is
inconvenient.
Release Notes:
- N/A
BusyBox's off brand `wget` does not have support for the `--method`
argument, which makes `zed` incapable of downloading the remote server
unless the _☙authentic❧_ one is installed. Removing this should fix the
issue. Couldn't find much about guidelines on how the code is supposed
to be formatted, so I opted for commenting the line out with an
explanation.
Closes#38712
Release Notes:
- Fixed remote development on BusyBox
This reverts commit ed7bd5a8ed.
We noticed this PR causes the editor to hang if you hold down any of the
menu item actions like ctrl+z, ctrl+x, etc
Release Notes:
- Fixed macOS menu item actions hanging the editor when their key
combination is held down
Uses the previously merged denoising crate (and fixes a bug in it that
snug in during refactoring) to add denoising to the microphone input.
Adds automatic volume control for microphone and output.
Prepares for migrating to 16kHz SR mono:
The experimental audio path now picks the samplerate and channel count depending on a setting. It can handle incoming streams with both the current (future legacy) and new samplerate & channel count. These are url-encoded into the livekit track name
Release Notes:
- N/A
There's a mismatch between the URL used here and the one that's referred
to in `build_zed_cloud_url`, which prevents using the script on Windows.
A previous PR changed the script to use `127.0.0.1` instead of
`localhost` because of supposed URL parsing issues, but we were unable
to reproduce those.
Release Notes:
- N/A
- Map path lookup and internal failures to acp::Error
- Return INVALID_PARAMS for reads beyond EOF
Release Notes:
- acp: Return more informative error types from `read_text_file` to
agents
This now uses the default zed icon for file associations as our own icon
svgs are black/white shapes which are not suitable to set as an icon in
a file explorer.
Closes#36286
Release Notes:
- N/A
Inspired by the recent anchor assertions, this asserts that the produced
selections are always ordered at various resolutions stages, this is an
invariant within `SelectionsCollection` but something breaks it
somewhere causing us to seek cursors backwards which panics.
Related to ZED-13X
Release Notes:
- N/A
The previous validation was too strict and didn't permit reading empty
files.
Addresses: https://github.com/google-gemini/gemini-cli/issues/9280
Release Notes:
- acp: Fix `read_text_file` returning errors for empty files
# Summary
Today, Zed uses Mold on Linux, but Wild can be significantly faster.
On my machine, Wild is 14% faster at a whole-tree clean build, 20%
faster on an incremental build with a minimal change, and makes no
measurable effect on runtime performance of tests.
However, Wild's page says it's not yet ready for production, so it seems
to early to switch for production and CI builds.
This PR keeps using Mold in CI and lets developers choose in their own
config what linker to use. (The downside of this is that after landing
this change, developers will have to do some local config or it will
fall back to the default linker which may be slower.)
[Wild 0.6 is out, and their announcement has some
benchmarks](https://davidlattimore.github.io/posts/2025/09/23/wild-update-0.6.0.html).
cc @davidlattimore from Wild, just fyi
# Tasks
- [x] Measure Wild build, incremental build, and runtime performance in
different scenarios
- [x] Remove the Linux linker config from `.cargo/config.toml` in the
tree
- [x] Test rope benchmarks etc
- [x] Set the linker to Mold in CI
- [x] Add instructions to use Wild or Mold into `linux.md`
- [x] Add a script to download Wild
- [x] Measure binary size
- [x] Recommend Wild from `scripts/linux`
# Benchmarks
| | wild 0.6 (rust 1.89) | mold 2.37.1 (1.89) | lld (rust 1.90) | wild
advantage |
| -- | -- | -- | -- | -- |
| clean workspace build | 176s | 184s | 182s | 5% faster than mold |
| nextest run workspace after build | 137s | 142s | 137s | in the noise?
|
| incremental rebuild | 3.9s | 5.0s | 6.6s | 22% faster than mold |
I didn't observe any apparent significant change in runtime performance
or binary size, or in the in-tree microbenchmarks.
Release Notes:
- N/A
---------
Co-authored-by: Mateusz Mikuła <oss@mateuszmikula.dev>
# Why
In Git Panel, it felt to me that repo and branch separator can be
slightly demphasized (since it is not-interactable) and separated a bit
more from the repo and branch popover triggers.
# How
Use `icon_muted` color for the separator (happy to know if this is an
abuse of the UI styleguide 😄), add one pixel horizontal spacing around
the `/` character.
Release Notes:
- Improved appearance of repo and branch separator in Git Commit Panel
# Test plan
I have tested the change locally and compared the UI before and after to
make sure it feels right.
### Before
<img width="466" height="196" alt="Screenshot 2025-09-18 at 20 25 46"
src="https://github.com/user-attachments/assets/7bfcd1a4-8d16-4e75-8660-9cbfa3952848"
/>
### After
<img width="466" height="196" alt="Screenshot 2025-09-18 at 20 25 12"
src="https://github.com/user-attachments/assets/100d3599-ecc6-473f-b270-a71005b41494"
/>
---------
Co-authored-by: Danilo Leal <daniloleal09@gmail.com>
Added blank line in front of 2 image tags so markdown renders correctly
in zed. (Previously, images were skipped. They are also skipped in zed
if there are leading spaces in front of img tag.)
Updated text in 3 alt tags.
Fixed 1 typo.
Release Notes:
- N/A
Closes#37601
Regressed in https://github.com/zed-industries/zed/pull/36469.
Edit: Original issue https://github.com/zed-industries/zed/issues/25744
is fixed for Zeta in this PR. For Copilot, it will be covered in a
follow-up. In the case of Copilot, even after discarding, we still get a
prediction on suggest, which is a bug.
Release Notes:
- Fixed issue where predict edit at cursor didn't work when
`show_edit_predictions` is `false`.
Closes https://github.com/zed-industries/zed/issues/38690Closes#37353
### Background
On Windows, paths are normally separated by `\`, unlike mac and linux
where they are separated by `/`. When editing code in a project that
uses a different path style than your local system (e.g. remoting from
Windows to Linux, using WSL, and collaboration between windows and unix
users), the correct separator for a path may differ from the "native"
separator.
Previously, to work around this, Zed converted paths' separators in
numerous places. This was applied to both absolute and relative paths,
leading to incorrect conversions in some cases.
### Solution
Many code paths in Zed use paths that are *relative* to either a
worktree root or a git repository. This PR introduces a dedicated type
for these paths called `RelPath`, which stores the path in the same way
regardless of host platform, and offers `Path`-like manipulation APIs.
RelPath supports *displaying* the path using either separator, so that
we can display paths in a style that is determined at runtime based on
the current project.
The representation of absolute paths is left untouched, for now.
Absolute paths are different from relative paths because (except in
contexts where we know that the path refers to the local filesystem)
they should generally be treated as opaque strings. Currently we use a
mix of types for these paths (std::path::Path, String, SanitizedPath).
Release Notes:
- N/A
---------
Co-authored-by: Cole Miller <cole@zed.dev>
Co-authored-by: Piotr Osiewicz <24362066+osiewicz@users.noreply.github.com>
Co-authored-by: Peter Tripp <petertripp@gmail.com>
Co-authored-by: Smit Barmase <heysmitbarmase@gmail.com>
Co-authored-by: Lukas Wirth <me@lukaswirth.dev>
Closes #ISSUE
Updates the settings editor to collect all known settings files from the
settings store, in order to show them in the UI. Additionally adds a
fake worktree instantiation in the settings UI example binary in order
to have more than one file available when testing.
Release Notes:
- N/A *or* Added/Fixed/Improved ...
On macOS, traditionally when a keyboard shortcut is activated, the menu
in the menu bar flashes to indicate that the action was recognised.
<img width="289" height="172" alt="image"
src="https://github.com/user-attachments/assets/a03ecd2f-f159-4f82-b4fd-227f34393703"
/>
This PR adds this functionality to GPUI, where when a keybind is pressed
that triggers an action in the menu, the menu flashes.
Release Notes:
- N/A
This makes rust-analyzer not consider the function for project symbols,
meaning searching for tests wont show two entries.
Release Notes:
- N/A *or* Added/Fixed/Improved ...
As of stable 206.0, the `agent.message_editor_min_lines` setting is
fully available, so removing the docs note that said it was only for
Preview.
Release Notes:
- N/A
This reverts commit 9e7302520e.
I run into an infinite hang in Zed nightly and used instruments and
activity monitor to sample what was going on. The root cause seemed to
be the unwrap_unchecked introduced in reverted PR.
Release Notes:
- N/A
Just making it more consistent with other pickers—button actions
justified to the right and timestamp directly in the list item to avoid
as much as possible relevant information tucked away in a tooltip where
using the keyboard will mostly be the main mean of interaction.
<img width="500" height="310" alt="Screenshot 2025-09-24 at 10 41@2x"
src="https://github.com/user-attachments/assets/0bd478da-d1a6-48fe-ade7-a4759d175c60"
/>
Release Notes:
- N/A
The new cloud endpoint returns structured edits, but they may include
more of the input excerpt than what we want to display in the preview,
so we compute a smaller diff on the client side against the snapshot.
Release Notes:
- N/A
In some rare cases, the auto-generated block gets stuck in
`.git/info/exclude`. We now auto-clean it.
Closes#38374
Release Notes:
- Remove auto-generated block from git excludes if it gets stuck there.
The `Duration` argument in `get_models` has been unused for over a year.
The `complete` function is also unused and it has fallen behind in new
feature additions such as Authorization support. This used to exist
because ollama didn't support tools in streaming mode, `with_tools` also
existed because of that. Now however there is no reason to keep this
around.
`ChatResponseDelta ` had unnecessary `#[allow(unused)]` macros since the
fields are marked `pub`. Using `#[expect(unused)]` would've caught this.
Release Notes:
- N/A
Not an ideal fix, but a proper one will require restructuring the
iterator state (which would be easier if Rust had first class
generators)
Fixes ZED-1MB
Release Notes:
- N/A *or* Added/Fixed/Improved ...
Closes https://github.com/zed-industries/zed/issues/38547
Release Notes:
- Reverted the ability to show/hide the titlebar. This caused rendering
bugs on
macOS, and we're preparing for the redesign which requires the toolbar
being present.
---------
Co-authored-by: Kirill Bulatov <kirill@zed.dev>
Closes https://github.com/zed-industries/zed/issues/38528
In the agent panel's `thread_view.rs` file, we have a `render_tool_call`
function that controls what we show in the UI for most types of tools.
However, for some of them—for example, terminal/execute and edit
tools—we have a special rendering so we can tailor the UI for their
specific needs. But... before the specific rendering function is called,
all tools still go through the `render_tool_call`.
Problem is that, in the case of the terminal tool, you couldn't see the
full command the agent wants to run when the tool is still in its
`render_tool_call` state. That's mostly because of the treatment we give
to labels while in that state. A particularly bad scenario because
well... seeing the _full_ command _before_ you choose to accept or
reject is rather important.
This PR fixes that by essentially special-casing the terminal tool
display when in the `render_tool_call` rendering state, so to speak.
There's still a slight UI misalignment I want to fix but it shouldn't
block this fix to go out.
Here's our final result:
<img width="400" height="1172" alt="Screenshot 2025-09-23 at 6 19@2x"
src="https://github.com/user-attachments/assets/71c79e45-ab66-4102-b046-950f137fa3ea"
/>
Release Notes:
- agent: Fixed terminal command not being fully displayed while in the
"waiting for confirmation" state.
This PR removes the experimental jj bookmark picker that was added in
#30883.
This was just an exploratory prototype and while I would like to have
native jj UI at some point, I don't know when we'll get back to it.
Release Notes:
- N/A
Closes#30678
This is caused by `TerminalOutput::full_text` triming trailing newline
when creating the "REPL Output" buffer.
Release Notes:
- fix: Preserve trailing newline in `TerminalOutput::full_text`
The current problem is that if I specify model parameters, like
`max_tokens`, in `settings.json` for an Ollama model, they do not
override the values coming from the Ollama API. Instead, the parameters
from the API are used. For example, in the settings below, even though I
have overridden `max_tokens`, Zed will still use the API's default
`context_length` of 4k.
```
"language_models": {
"ollama": {
"available_models": [
{
"name": "qwen3-coder:latest",
"display_name": "Qwen 3 Coder",
"max_tokens": 64000,
"supports_tools": true,
"keep_alive": "15m",
"supports_thinking": false,
"supports_images": false
}
]
}
},
```
Release Notes:
- Fixed an issue where Ollama model parameters were not being correctly
overridden by user settings.
Closes https://github.com/zed-industries/zed/issues/37882
Previously, every piece of text in the agent panel was controlled by
`agent_font_size`. Although it is nice to only have one setting to tweak
that, it could be a bit misleading particularly because we use
monospaced and sans-serif fonts for different elements in the panel. Any
editor/textarea in the panel, whehter it is the main message editor or
the previous message editor, uses the buffer font. Therefore, I think it
is reasonable to expect that tweaking `buffer_font_size` would also
change the agent panel's usage of buffer fonts.
With this change, regular buffers and the agent panel's message editor
will always have the same size.
Release Notes:
- agent: Made the agent panel's textarea font size follow the font size
of regular buffers. They're now both controlled by the
`buffer_font_size` setting.
Address an issue where, in Vim mode, clicking past the end of a line
after selecting the entire line would place the cursor on the newline
character instead of the last character of the line, which is
inconsistent with Vim's normal mode expectations.
I believe the root cause was that the cursor’s position was updated to
the end of the line before the mode switch from Visual to Normal, at
which point `DisplayMap.clip_at_line_ends` was still set to `false`. As
a result, the cursor could end up in an invalid position for Normal
mode. The fix ensures that when switching between these two modes, and
if the selection is empty, the selection point is properly clipped,
preventing the cursor from being placed past the end of the line.
Related #38049
Release Notes:
- Fixed issue in Vim mode where switching from any mode to normal mode
could end up with the cursor in the newline character
---------
Co-authored-by: Conrad Irwin <conrad.irwin@gmail.com>
Nowadays, people don't expect @-mentioning a directory to include the
contents of all files within it. Doing so makes it very likely to
consume an undesirable amount of tokens.
By default, we'll now only include the path of the directory and let the
model decide how much to read via tools. We'll still include the
contents if no tools are available (e.g. "Minimal" profile is selected).
Release Notes:
- Agent Panel: Do not include the content of @-mentioned directories
when tools are available
The edit prediction debug tools has been renamed to zeta2 inspector
because it's now zeta specific. It will now always display the last
prediction request context, prompt, and model response.
Release Notes:
- N/A
---------
Co-authored-by: Bennet <bennet@zed.dev>
Co-authored-by: Bennet Bo Fenner <bennetbo@gmx.de>
Closes#38651
`git_panel.set_amend_pending(false, cx);` was being called before
`git_panel.commit_changes(...)` which was causing the commit buffer to
be cleared/reset before actually sending the commit request to git.
Introduced by #35268 which added clear buffer functionality to the
`set_amend_pending` function.
Release Notes:
- Fix git amend on panel sending "Update ..." instead of the original
commit message
- FIx git amend button not working
Release Notes:
- Added "show_summary" & "show_command" settings to the initial
tasks.json file.
This makes the initial task template match the docs here:
https://zed.dev/docs/tasks
Solves an issue where Google APIs refuse all requests with file-based
tool calls attached.
This seems to get triggered in the case where:
- copy_path + another file-based tool call is enabled
- default terminal is `/bin/bash` or something similar
It is unclear why this is happening, but removing the terminal commands
in those tool calls seems to have solved the issue.
Closes#37180 and #37414
Release Notes:
- agent: Fix Gemini refusing requests with certain profiles/systems.
## Problem
Zed was crashing with a UTF-8 character boundary error when rendering
text containing multi-byte characters (like emojis or CJK characters):
```
Thread "main" panicked with "byte index 49 is not a char boundary; it is inside '…' (bytes 48..51)"
```
## Root Cause Analysis
The PR reviewer correctly identified that the issue was not in the
DirectWrite boundary handling, but rather in the text run length
calculation in the text system. When text runs are split across lines in
`text_system.rs:426`, the calculation:
```rust
let run_len_within_line = cmp::min(line_end, run_start + run.len) - run_start;
```
This could result in `run_len_within_line` values that don't respect
UTF-8 character boundaries, especially when multi-byte characters (like
'…' which is 3 bytes) get split across lines. The resulting `FontRun`
objects would have lengths that don't align with character boundaries,
causing the panic when DirectWrite tries to slice the string.
## Solution
Fixed the issue by adding UTF-8 character boundary validation in the
text system where run lengths are calculated. The fix ensures that when
text runs are split across lines, the split always occurs at valid UTF-8
character boundaries:
```rust
// Ensure the run length respects UTF-8 character boundaries
if run_len_within_line > 0 {
let text_slice = &line_text[run_start - line_start..];
if run_len_within_line < text_slice.len() && !text_slice.is_char_boundary(run_len_within_line) {
// Find the previous character boundary using efficient bit-level checking
// UTF-8 characters are at most 4 bytes, so we only need to check up to 3 bytes back
let lower_bound = run_len_within_line.saturating_sub(3);
let search_range = &text_slice.as_bytes()[lower_bound..=run_len_within_line];
// SAFETY: A valid character boundary must exist in this range because:
// 1. run_len_within_line is a valid position in the string slice
// 2. UTF-8 characters are at most 4 bytes, so some boundary exists in [run_len_within_line-3..=run_len_within_line]
let pos_from_lower = unsafe {
search_range
.iter()
.rposition(|&b| (b as i8) >= -0x40)
.unwrap_unchecked()
};
run_len_within_line = lower_bound + pos_from_lower;
}
}
```
## Testing
- ✅ Builds successfully on all platforms
- ✅ Eliminates UTF-8 character boundary panics
- ✅ Maintains existing functionality for all text types
- ✅ Handles edge cases like very long multi-byte characters
## Benefits
1. **Root cause fix**: Addresses the issue at the source rather than
treating symptoms
2. **Performance optimal**: Uses the same efficient algorithm as the
standard library
3. **Minimal changes**: Only modifies the specific problematic code path
4. **Future compatible**: Can be easily replaced with
`str::floor_char_boundary()` when stabilized
## Alternative Approaches Considered
1. **DirectWrite boundary fixing**: Initially tried to fix in
DirectWrite, but this was treating symptoms rather than the root cause
2. **Helper function approach**: Considered extracting to a helper
function, but inlined implementation is more appropriate for this
specific use case
3. **Standard library methods**: `floor_char_boundary()` is not yet
stable, so implemented equivalent logic
The chosen approach provides the best balance of performance, safety,
and code maintainability.
---
Release Notes:
- N/A
Closes
https://github.com/zed-industries/zed/issues/6730#issuecomment-3320933701
That way if multiple servers are running while reporting the same
results we prevent opening multi buffers for single entries.
Release Notes:
- N/A *or* Added/Fixed/Improved ...
Add tests on task commands, to ensure things like
https://github.com/zed-industries/zed/issues/38343 do not come so easily
unnoticed and to provide a base to create more tests in the future, if
needed.
Release Notes:
- N/A
---------
Co-authored-by: Lukas Wirth <lukas@zed.dev>
Closed#33759Closed#38166
### Summary
This PR fixes the way `go test` commands are generated for **testify
suite test methods**.
Previously, only the method name was included in the `-run` flag, which
caused Go’s test runner to fail to find suite test cases.
---
### Problem
https://github.com/user-attachments/assets/e6f80a77-bcf3-457c-8bfb-a7286d44ff71
1. **Incorrect command** was generated for suite tests:
```bash
go test -run TestSomething_Success
```
This results in:
```
testing: warning: no tests to run
```
2. The correct format requires the **suite name + method name**:
```bash
go test -run ^TestFooSuite$/TestSomething_Success$
```
Without the suite prefix (`TestFooSuite`), Go cannot locate test methods
defined on a suite struct.
---
### Changes Made
* **Updated `runnables.scm`**:
* Added a new query rule for suite methods (`.*Suite` receiver types).
* Ensures only methods on suite structs (e.g., `FooSuite`) are matched.
* Tagged these with `go-testify-suite` in addition to `go-test`.
* **Extended task template generation**:
* Introduced `GO_SUITE_NAME_TASK_VARIABLE` to capture the suite name.
* Create a `TaskTemplate` for the testify suite.
* **Improved labeling**:
* Labels now show the full path (`go test ./pkg -v -run
TestFooSuite/TestSomething_Success`) for clarity.
* **Added a test** `test_testify_suite_detection`:
* Covered testify suite cases to ensure correct detection and command
generation.
---
### Impact
https://github.com/user-attachments/assets/ef509183-534a-4aa4-9dc7-01402ac32260
* **Before**: Running a suite test method produced “no tests to run.”
* **After**: Suite test methods are runnable individually with the
correct `-run` command, and full suites can still be executed as before.
### Release Notes
* Fixed generation of `go test` commands for **testify suite test
methods**.
Suite methods now include both the suite name and the method name in the
`-run` flag (e.g., `^TestFooSuite$/TestSomething_Success$`), ensuring
they are properly detected and runnable individually.
Buffer search initiates a new search every time a key is pressed in the
buffer search bar. This would cancel the task associated with any
pending searches. Whenever one of these searches was canceled Zed would
log `[search]: oneshot canceled`. This log would trigger almost on every
keypress when typing moderately fast. This PR silences these logs by not
treating canceled searches as errors.
Release Notes:
- N/A
I noticed that after we paste in line mode, the cursor position is
positioned at the beginning of the next logical line which is somewhat
undesirable since then inserting/appending will position the cursor
after the selection. This does not match helix behaviour which we should
further investigate.
Follow-up to https://github.com/zed-industries/zed/pull/38663
Release Notes:
- N/A
iTerm's editor configuration dialog allows you to set your editor to
`zed \1:\2`, but not (as far as I know) to leave off the : when there's
no line number
This fixes clicking on bare filenames in iTerm for me.
Release Notes:
- Fixed line number parsing so that `zed filename.rs:` will now act as
though you did `zed filename.rs`
Creates a new `EditPredictionProvider` for zeta2, that requests
completions from a new cloud endpoint including context from the new
`edit_prediction_context` crate. This is not ready for use, but it
allows us to iterate.
Release Notes:
- N/A
---------
Co-authored-by: Michael Sloan <michael@zed.dev>
Co-authored-by: Bennet <bennet@zed.dev>
Co-authored-by: Bennet Bo Fenner <bennetbo@gmx.de>
This took me quite a while to find out when I developed my first
language extension. I had non-matching entries in the `languages` array
and in the name field of `config.toml`, and it was especially tricky
because the zed extension would start up, but not the language server. I
sure which this had been in the docs, so I am contributing it now!
In particular,
* if the selection ends at the beginning of the next line, and the
current line under the cursor is empty, we paste at the selection's end.
* if however the current line under the cursor is empty, we need to move
to the beginning of the next line to avoid pasting above the end of
current selection
In addition, in line mode, we always move the cursor to the end of the
inserted text. Otherwise, while it looks fine visually,
inserting/appending ends up in the next logical line which is not
desirable.
Release Notes:
- N/A
This PR updates the Gemini provider to treat a
`prompt_feedback.block_reason` as a refusal, as Gemini does not seem to
return a `stop_reason` to use in this case.
<img width="639" height="162" alt="Screenshot 2025-09-22 at 4 23 15 PM"
src="https://github.com/user-attachments/assets/7a86d67e-06c1-49ea-b58f-fa80666f0f8c"
/>
Previously this would just result in no feedback to the user.
Release Notes:
- Added an error message when a Gemini response contains a
`block_reason`.
This PR fixes a regression where settings profiles were no longer
ordered in the same order that the user defined in their settings.
Release Notes:
- N/A
Closes#38495
Cause:
- When the Find input is focused, CopyPath/CopyRelativePath were handled
by the editor and stopped during the bubble phase, preventing
BufferSearchBar from relaying to the file-backed editor.
Release Notes:
- Fixes “Workspace: Copy Relative Path” not copying while the Find bar
is focused.
This PR adds automatic markdown URL embedding on paste when you are in
text associated with the Markdown language and you have a valid URL in
your clipboard. This the default behavior in VS Code and GitHub, when
pasting a URL in Markdown. It works in both singleton buffers and multi
buffers.
One thing that is a bit unfortunate is that, previously, `do_paste` use
to simply call `Editor::insert()`, in the case of pasting content that
was copied from an external application, and now, we are duplicating
some of `insert()`'s logic in place, in order to have control over
transforming the edits before they are inserted.
Release Notes:
- Added automatic Markdown URL embedding on paste.
---------
Co-authored-by: Cole Miller <53574922+cole-miller@users.noreply.github.com>
Vim mode currently supports `gt` (go to next tab) and `gT` (go to
previous tab) but not with count. Implement the expected behavior as
defined by vim:
- `<count>gt` moves to tab `<count>`
- `<count>gT` moves to previous tab `<count>` times (with wraparound)
Release Notes:
- Improved vim `gt` and `gT` to support count, e.g. `5gt` - go to tab 5,
`8gT` - go to 8th previous tab with wraparound.
This button already exists in the main menu, as well as the "New
Session" view in the debugger panel. However, this view disappears after
starting the debugging session. This PR adds the same button to the
debugger control strip that remains accessible. This is convenient for
people editing their debug.json frequently.
Site-node: I feel like the `Cog` icon would be more appropriate, but I
picked `Code` to stay consistent with the "New Session" view.
Before:
<img width="194" height="118" alt="image"
src="https://github.com/user-attachments/assets/5b42a8a4-f48f-4145-a425-53365dd785ca"
/>
After:
<img width="194" height="118" alt="image"
src="https://github.com/user-attachments/assets/12f56ea1-150b-4564-8e6a-da4671f52079"
/>
Release Notes:
- Added "Edit debug.json" button to debugger control strip
Found this outdated piece of information in the docs while trying to
disable it myself, this PR simply changes `false` to `"off"`.
Release Notes:
- N/A
> Your extension can define it's own debug locators
> Your extension can define it is own debug locators
The sentence above does not make sense after expanding "it's". We should
instead be using the possessive "its" in this scenario.
Release Notes:
- N/A
Signed-off-by: Remy Suen <remy.suen@docker.com>
Expands on #38543 (notably allows setting importance categories and
weights on tests, and a lot of internal refactoring) because I couldn't
help myself. Also allows exporting runs to json and comparing across them. See code for docs.
Release Notes:
- N/A
Reverts #38175, which is not correct, since in fact we do need to
pre-quote the command and arguments for the shell when using
`SpawnInTerminal` (although we should probably change the API so that
this isn't necessary). Then, applies the same fix as #38565 to fix the
root cause of being unable to spawn the login task on macOS, or in any
case where the command/args contain spaces.
Release Notes:
- Fixed being unable to login with Claude Code or Gemini using the
terminal.
Hi! This pull request mentions [the `herb` LSP](https://herb-tools.dev)
for `HTML/ERB` language that the Ruby extension supports. Thanks!
Release Notes:
- N/A
---------
Co-authored-by: Finn Evers <finn.evers@outlook.de>
Add an auto-profiler for our tests, to hopefully allow better triage of
performance impacts resulting from code changes. Comprehensive usage
docs are in the code.
Currently, it uses hyperfine under the hood and prints markdown to the
command line for all crates with relevant tests enabled. We may want to
expand this to allow outputting json in the future to allow e.g.
automatically comparing the difference between two runs on different
commits, and in general a lot of functionality could be added (maybe
measuring memory usage?).
It's enabled (mostly as an example) on two tests inside `gpui` and a
bunch of those inside `vim`. I'd have happily used `cargo bench`, but that's nightly-only.
Release Notes:
- N/A
This PR updates the version range for v0.6.0 of the extension API to
include v0.7.0.
Since we bumped the `zed_extension_api` crate's version to v0.7.0, we
need to expand this range in order for Zed clients to be able to install
extensions built against v0.7.0 of `zed_extension_api`.
Currently no extensions that target `zed_extension_api@0.7.0` can be
installed.
Release Notes:
- N/A
In the settings refactor I'd assumed server settings were like project
settings. This is not the case, they are in fact the normal user
settings;
but just read from the server.
Release Notes:
- N/A
It was just a bunch of finnickery around UI layout. It affected Linux
too.
Release Notes:
* Fixed aspect ratio of peer screen share when using Linux/Windows
builds.
Fix an issue introduced in
https://github.com/zed-industries/zed/pull/37321 where vim's surround
wouldn't work as expected when replacing quotes with non-quotes, with
whitespace always being added, regardless of whether the opening or
closing bracket was used. This is not the intended, or previous,
behavior, where only the opening bracket would trigger whitespace to be
added.
Closes#38169
Release Notes:
- Fixed regression in vim's surround plugin that ignored whether the
opening or closing bracket was being used when replacing quotes, so
space would always be added
https://github.com/zed-industries/zed/pull/38367 introduced panic:
```
thread 'main' panicked at crates/theme/src/settings.rs:812:18:
called `Option::unwrap()` on a `None` value
```
In this PR I restored fallback logic from the original code - before
settings refactor.
Release Notes:
- N/A
Closes https://github.com/zed-industries/zed/issues/38331
This fixes an issue where we would not dismiss the panel once the user
toggled the setting, leaving them in an awkward state where closing the
panel would become hard.
Also takes care of one more check for the `Fix with assistant` action
and consolidates some of the `AgentSettings` and `DisableAiSetting`
checks into one method to make the code more readable.
Release Notes:
- N/A
Found duplicate `postgresql` package in installation command. Uncertain
whether it should be `postgresql-contrib` or `postgresql-client`, but
neither appears necessary.
Release Notes:
- N/A
Just install Zed for the first time and got a warning from the first
config example i copied from docs.
Great design btw, immediately able to see that this is a well thought
out app. seems like i'll stick with zed and make it my new dev
'sanctuary'.
Release Notes:
- N/A
Closes#38347
Release Notes:
- Fixed path and args to ty lsp binary
When attempting to use the new ty lsp integration in the preview, I
noticed issues related to accessing the binary. After deleting the
downloaded archive and adding the following changes that:
- downloads the archive with the correct `AssetKind::TarGz`
- uses the correct path to the extracted binary
- adds the `server` argument to initialize the lsp (like ruff)
After the above changes the LSP starts correctly
```bash
2025-09-18T16:17:03-05:00 INFO [lsp] starting language server process. binary path: "/Users/dereknguyen/Library/Application Support/Zed/languages/ty/ty-0.0.1-alpha.20/ty-aarch64-apple-darwin/ty", working directory: "/Users/dereknguyen/projects/test-project", args: ["server"]
```
<img width="206" height="98" alt="image"
src="https://github.com/user-attachments/assets/8fcf423f-40a0-4cd9-a79e-e09666323fe2"
/>
---------
Co-authored-by: Cole Miller <cole@zed.dev>
Uses the previously merged denoising crate (and fixes a bug in it that snug in during refactoring) in the microphone input. The experimental audio path now picks the samplerate and channel count depending on a setting. It can handle incoming streams with both the current (future legacy) and new samplerate & channel count. These are url-encoded into the livekit track name.
This is a redo of #29776. I went for a separate function -- instead of
adding a bunch of conditions to `vim::Paste` -- because there were quite
a few differences.
Release Notes:
- Added a `vim::HelixPaste` command that imitates Helix's paste behavior
---------
Co-authored-by: Jakub Konka <kubkon@jakubkonka.com>
`HttpClient`: Relaxes the lifetime bound to `&self` in `get`/`post`
by returning the `self.send` future directly. This makes both
methods return `'static` futures without extra boxing.
`HttpRequestExt`: Added fluent builder methods to `HttpRequestExt`
inspired by the `gpui::FluentBuilder` trait.
Release Notes:
- N/A
When we refactored settings to not pass JSON blobs around, we ended up
needing
to write *a lot* of code that just merged things (like json merge used
to do).
Use a derive macro to prevent typos in this logic.
Release Notes:
- N/A
Closes#36280
Release Notes:
- Added additional context to debug task selection
Adding additional context when selecting a debug task to help with
projects that have multiple config files with similar names for tasks.
I think there is room for improvement, especially adding context for a
LanguageTask type. I started but it looked like it would need to add a
path value to that and wanted to make sure this was a good idea before
working on that.
Also any thoughts on the wording if you do like this format?
---
<img width="1246" height="696" alt="image"
src="https://github.com/user-attachments/assets/b42e3f45-cfdb-4cb1-8a7a-3c37f33f5ee2"
/>
---------
Co-authored-by: Anthony <anthony@zed.dev>
Co-authored-by: Anthony <hello@anthonyeid.me>
Adds a `dev: open edit prediction context` action that opens a new
workspace pane that displays the excerpts and snippets that would be
included in the edit prediction request.
Release Notes:
- N/A
---------
Co-authored-by: Bennet <bennet@zed.dev>
This panic only happened in debug builds because of a left shift
overflow. The slice range has bounds between 0 and 128. The 128 case
caused the overflow.
We now do an unbounded shift and a wrapped sub to get the correct
bitmask. If the slice range is 128 left, it should make 1 zero. Then the
wrapped sub would flip all bits, which is expected behavior.
Release Notes:
- N/A
Co-authored-by: Nia <nia@zed.dev>
Co-Authored-By: Ben K <ben@zed.dev>
Co-Authored-By: Anthony <anthony@zed.dev>
Co-Authored-By: Mikayla <mikayla@zed.dev>
Release Notes:
- settings: Major internal changes to settings. The primary user-facing
effect is that some settings which did not make sense in project
settings files are no-longer read from there. (For example the inline
blame settings)
---------
Co-authored-by: Ben Kunkle <ben@zed.dev>
Co-authored-by: Mikayla Maki <mikayla.c.maki@gmail.com>
Co-authored-by: Anthony <anthony@zed.dev>
## Summary
Fixes#38362 - Privacy tooltip behavior issues in AI Setup onboarding
## Problem
The Privacy tooltip in AI Setup onboarding had incorrect behavior:
1. Tooltip remained visible after mouse left the Privacy button
2. Clicking the button didn't toggle tooltip properly
3. Clicking in intersection area between tooltip and button didn't work
## Root Cause
Badge component used `tooltip()` instead of `hoverable_tooltip()`,
causing:
- Immediate tooltip hiding when mouse left triggering element
- No support for tooltip content interaction
- Poor intersection area click handling
## Solution
**Single line change** in `crates/ui/src/components/badge.rs:61`:
```rust
// Before:
this.tooltip(move |window, cx| tooltip(window, cx))
// After:
this.hoverable_tooltip(move |window, cx| tooltip(window, cx))
```
## Technical Details
- Leverages existing GPUI `hoverable_tooltip()` infrastructure
- Enables 500ms grace period before tooltip hiding
- Allows hovering over tooltip content without disappearing
- Uses proper tooltip bounds detection for click handling
- Affects all Badge tooltips system-wide (positive improvement)
- Full backward compatibility - no API changes
## Test Plan
- [x] Hover over Privacy badge → tooltip appears
- [x] Move mouse away → tooltip stays visible for 500ms
- [x] Move mouse to tooltip content → tooltip remains visible
- [x] Click on tooltip content → properly handled
- [x] Move mouse completely away → tooltip hides after delay
- [x] Verify no regression in other Badge tooltip usage
Release Notes:
- N/A
With this, scrollbars across the app will now auto-hide unless it is
specified that they should follow a specific setting.
Optimally, we would just track the user preference by default. However,
this is currently not possible. because the setting we would need to
read lives in `editor` and we cannot read that from within the `ui`
crate.
Release Notes:
- N/A
Closes https://github.com/zed-industries/zed/issues/37660
This PR makes sections in the AI settings UI more consistent with each
other and also just overall simpler. One of the main changes here is
adding the tools from a given MCP server in a modal (as opposed to in a
disclosure within the settings view). That's mostly an artifact of
wanting to make all of the items within sections look more of the same.
Then, in the process of doing so, also changed the logic that we were
using to display MCP servers; previously, in the case of extension-based
servers, we were only showing those that were _configured_, which felt
wrong because you should be able to see everything you have _installed_,
despite of its status (configured or not).
However, there's still a bit of a bug (to be solved in a follow-up PR),
which already existed but it was just not visible given we'd only
display configured servers: an MCP server installed through an extension
stays as a "custom server" until it is configured. If you don't
configure it, you can't also uninstall it from the settings view (though
it is possible to do so via the extensions UI).
Release Notes:
- agent: Improve settings view UI and solve issue where MCP servers
would get unsorted upon turning them on and off (they're all
alphabetically sorted now).
- Reflect that basedpyright is the new primary language server
- Discuss Ruff
- Deemphasize manual venv configuration for language servers
Release Notes:
- N/A
---------
Co-authored-by: Katie Geer <katie@zed.dev>
Co-authored-by: Piotr <piotr@zed.dev>
The built-up command for the WSL remote connection looks like
```
wsl.exe --distribution Ubuntu --user cole --cd /home/cole -- bash -c SCRIPT
```
Where `SCRIPT` is a command itself. We don't need extra quotes around
`SCRIPT` because we already pass it whole as a separate argument to
`wsl.exe`.
This isn't yet enough to get ACP servers working in WSL projects
(#38332), but it removes one roadblock.
Release Notes:
- windows: Fixed an issue that could prevent running binaries in WSL
remote projects.
This partially reverts commit 4002602a89.
Specifically the parts that closes
https://github.com/zed-industries/zed/issues/38343
Release Notes:
- N/A *or* Added/Fixed/Improved ...
We were incorrectly handling the line number as well as stripping out
line breaks when returning portions of files.
It also makes sure following is updated even when we load a snapshot
from cache, which wasn't the case before.
We also are able to load the text via a range in the snapshot, rather
than allocating a string for the entire file and then another after
iterating over lines in the file.
Release Notes:
- acp: Fix incorrect behavior when ACP agents requested to read portions
of files.
Closes#34192
Without selection, only current character would be affected.
Also if #38117 is merged too, then transformations in SelectMode behave
correctly too and selection is not collapsed.
Release Notes:
- helix: Implemented `~`, `` ` ``, `` Alt-` `` correctly in normal and
select modes
---------
Co-authored-by: Jakub Konka <kubkon@jakubkonka.com>
This makes the hover background change keep a visible border element
between the gutter and blame entries
Release Notes:
- N/A *or* Added/Fixed/Improved ...
Closes#38304
Release Notes:
- Fixed true color detection regression by setting `COLORTERM=truecolor`
---
Reason:
The regression is possibly introduced in [pr#36576: Inject venv
environment via the
toolchain](https://github.com/zed-industries/zed/pull/36576/files#diff-6f30387876b79f1de44f8193401d6c8fb49a2156479c4f2e32bc922ec5d54d76),
where `alacritty_terminal::tty::setup_env();` is removed.
The `alacritty_terminal::tty::setup_env();` does 2 things, which sets
`TERM` & `COLORTERM` envvar.
```rs
/// Setup environment variables.
pub fn setup_env() {
// Default to 'alacritty' terminfo if it is available, otherwise
// default to 'xterm-256color'. May be overridden by user's config
// below.
let terminfo = if terminfo_exists("alacritty") { "alacritty" } else { "xterm-256color" };
unsafe { env::set_var("TERM", terminfo) };
// Advertise 24-bit color support.
unsafe { env::set_var("COLORTERM", "truecolor") };
}
```
Tests that the downstream project can see custom agents configured in
the remote server's settings, and that it constructs an appropriate
`AgentServerCommand`.
Release Notes:
- N/A
In local projects, initialize the list of agents in the agent server
store immediately. Previously we were initializing the list only after a
delay, in an attempt to avoid sending the `ExternalAgentsUpdated`
message to the downstream client (if any) before its handlers were
initialized. But we already have a separate codepath for that situation,
in the `AgentServerStore::shared`, and we can insert the delay in that
place instead.
Release Notes:
- acp: Fixed a bug where starting an external agent thread soon after
Zed starts up would show a "not registered" error.
---------
Co-authored-by: Michael <michael@zed.dev>
Co-authored-by: Agus <agus@zed.dev>
Ensures build task's CWD paths use POSIX-friendly path separator on
Windows host so that `std::path::Path` ops work as expected within the
Wasm guest.
Release Notes:
- N/A
This PR removes the `/cargo-workspace` slash command.
We never fully shipped this—with it requiring explicit opt-in via a
setting—and it doesn't seem like the feature is needed in an agentic
world.
Release Notes:
- Removed the `/cargo-workspace` slash command.
Adds a shortcut to add a WSL distro for better wsl feature
discoverability.
- [x] Open wsl from open remote
- [x] Open local folder in wsl action
- [x] Open wsl shortcut (shortcuts to open remote)
Release Notes:
- N/A
Closes#11760
The command `project panel: collapse all entries` currently does not
collapse top-level entries (the workspaces themselves). I think this
should be expected behaviour if you only have a single workspace in your
project. However, if you have multiple workspaces, we should collapse
their top-level folders as well. This is the expected behaviour in the
screenshots in #11760.
For more context: Atm the `.retain` function empties the
`self.expanded_dir_ids` Hash Map, because the `expanded_entries` Vec is
(almost) never empty - it contains the id of the `root_entry` of the
workspace.
d48d6a7454/crates/project_panel/src/project_panel.rs (L1148-L1152)
We then update the `self.expanded_dir_ids` in the
`update_visible_entries` function, and since the Hash Map is empty, we
execute the `hash_map::Entry::Vacant` arm of the following match
statement.
d48d6a7454/crates/project_panel/src/project_panel.rs (L3062-L3073)
This change makes sure that we do not clear the `expanded_dir_ids`
HashMap and always keep the keys for all visible workspaces and
therefore we run the `hash_map::Entry::Occupied` arm, which does not
override the `expanded_dir_ids` anymore.
https://github.com/user-attachments/assets/b607523b-2ea2-4159-8edf-aed7bca05e3a
cc @MrSubidubi
Release Notes:
- N/A *or* Added/Fixed/Improved ...
---------
Co-authored-by: Finn Evers <finn.evers@outlook.de>
This PR adds an option to allow opening local folders inside WSL
containers. (wsl_actions::OpenFolderInWsl). It is accessible via the
command palette and should be available to keybind.
- [x] Open wsl from open remote
- [x] Open local folder in wsl action
- [ ] Open wsl shortcut (shortcuts to open remote)
Release Notes:
- N/A
Closes https://github.com/zed-industries/zed/issues/37774
Bug in https://github.com/zed-industries/zed/pull/32927
Instead of using trigger characters to clear cached completions items,
now we check if the query is empty to clear it. Turns out Emmet defines
whole [alphanumeric as trigger
characters](279be10872/index.ts (L116))
which causes flickering.
Clear on trigger characters was introduced to get rid of cached
completions like in the case of "Parent.Foo.Bar", where "." is one of
the trigger characters. This works still since "." is not part of
`completion_query_characters` and hence we use it as a boundary while
building the current query. i.e in this case, the query would be empty
after typing ".", clearing cached completions.
Release Notes:
- Fixed issue where completions menu flashed on every keystroke in TSX
files with emmet extension installed.
This PR adds an option to open WSL machines from the UI.
- [x] Open wsl from open remote
- [ ] Open local folder in wsl action
- [ ] Open wsl shortcut (shortcuts to open remote)
Release Notes:
- N/A
The crash occured because we raced against the platform windowing
backend to render a frame, and if we lost the race there would be no
frame on a window that we return, which breaks most of gpui
Release Notes:
- N/A
This can lead to an infinite regress when using a language server that
supports pull diagnostics, since the excerpts for the diagnostics editor
are set based on the project's diagnostics.
Closes#36772
Release Notes:
- Fixed a bug that could cause duplicated diagnostics with some language
servers.
Closes#36287
Release Notes:
- Windows: Fixed an issue where a Zed window would stay minimized when
opening an existing file in that window via the Zed CLI.
The audio crate will use the denoise crate to remove background noises
from microphone input.
We intent to contribute this to rodio. Before that can happen a PR needs
to land in candle. Until then this lives here.
Uses a candle fork which removes the dependency on `protoc` and has the PR's mentioned above already applied.
Release Notes:
- N/A
---------
Co-authored-by: Mikayla <mikayla@zed.dev>
This PR updates the Cloud language model provider to use the `message`
field from the Cloud error response, if it is present.
Previously we would always show the entire JSON payload in the error
message, but with this change we can show just the user-facing `message`
the error response is in a shape that we recognize.
Release Notes:
- N/A
The problem from issue #37509 comes from local virtual environments
created with certain approaches (including the 'simple' way of `python
-m venv`) not having a `.project` file with the path to the project's
root directory. When the toolchains are sorted, a virtual environment in
the project is not treated as being for that project and therefore is
not prioritized.
With this change, if a toolchain does not have a `project` associated
with it, we check to see if it is a virtual environment, and if it is we
use its parent directory as the `project`. This will make it the top
priority (i.e. the default) if there are no other virtual environments
for a project, which is what should be expected.
Closes#37509
Release Notes:
- Improved python toolchain prioritization of local virtual
environments.
Move keyboard shortcut for `pane:GoForward` so it's going to be
displayed as a shortcut hint in UI. Currently `Forward` is shown as a
hint, which isn't consistent with `GoBack` action and can be confusing.
Release Notes:
- Improved the displayed keybinding for the `pane::GoForward` action on
Linux.
Closes#37028
I noticed many projects use Tailwind in plain TypeScript (.ts) files, so
it makes sense to support them out of the box, alongside .js and .tsx
files we already handle. For example, see
[supabase](https://github.com/supabase/supabase/blob/master/packages/ui/src/lib/theme/defaultTheme.ts).
Note: You’ll still need to add `"classFunctions": ["cva", "cx"],`
manually for Tailwind completions to work in `cva` type methods. This is
because you don’t want completions on every string, only in specific
methods or regex matches. This is documented.
Release Notes:
- Added out-of-the-box support for Tailwind completions in `.ts` files.
- Use ProxySettings::proxy_url to read from settings or env
- Export HTTP(S)_PROXY and NO_PROXY for agent CLIs
- Add read_no_proxy_from_env and move parsing from main
Closes https://github.com/zed-industries/claude-code-acp/issues/46
Release Notes:
- acp: Pass proxy settings through to all ACP agents
Release Notes:
- Added the `agent. message_editor_min_lines `setting to allow users to
customize the agent panel message editor default size by using a
different minimum number of lines.
<img width="800" height="1316" alt="Screenshot 2025-09-11 at 5 47 18 pm"
src="https://github.com/user-attachments/assets/20990b90-c4f9-4f5c-af59-76358642a273"
/>
---------
Co-authored-by: Danilo Leal <daniloleal09@gmail.com>
Closes#37214
This PR adds a scrollbar to the onboarding view and additionally ensures
the scroll state is properly reset when switching between the different
pages each time.
Release Notes:
- N/A
## Summary
Adds a "Copy as Markdown" button to the documentation toolbar that
allows users to easily copy the raw markdown content of any
documentation page.
This feature is inspired by similar implementations on sites like
[Better Auth docs](https://www.better-auth.com/docs/installation) and
[Cloudflare Workers docs](https://developers.cloudflare.com/workers/)
which provide easy ways for users to copy documentation content.
## Features
- **Button placement**: Positioned between theme toggle and search icon
for optimal UX
- **Content fetching**: Retrieves raw markdown from GitHub's API for the
current page
- **Consistent styling**: Matches existing toolbar button patterns
## Test plan
- [x] Copy functionality works on all documentation pages
- [x] Toast notifications appear and disappear correctly
- [x] Button icon animations work properly (spinner → checkmark → copy)
- [x] Styling matches other toolbar buttons
- [x] Works in both light and dark themes
## Screenshots
The button appears as a copy icon between the theme and search buttons
in the left toolbar.
<img width="798" height="295" alt="image"
src="https://github.com/user-attachments/assets/37d41258-d71b-40f8-b8fe-16eaa46b8d7f"
/>
<img width="1628" height="358" alt="image"
src="https://github.com/user-attachments/assets/fc45bc04-a290-4a07-8d1a-a010a92be033"
/>
---------
Co-authored-by: Danilo Leal <daniloleal09@gmail.com>
This adds a test to make sure that the default value of the auto update
setting is always true. We manually re-applied the broken code from last
week, and confirmed that this test fails with that code.
Release Notes:
- N/A
---------
Co-authored-by: Ben Kunkle <ben@zed.dev>
Co-authored-by: Conrad Irwin <conrad.irwin@gmail.com>
support for injecting sql, json, yaml, xml, html, css, js, lua and csv
value
if you use `/* lang */` before string literals, highlights them
**Example:**
```go
const sqlQuery = /* sql */ "SELECT * FROM users;" // highlights as SQL code
```
<img width="629" height="46" alt="Screenshot 2025-09-05 at 06 17 49"
src="https://github.com/user-attachments/assets/80f404d8-0a47-428d-bdb5-09fbee502cfe"
/>
Closes #ISSUE
Release Notes:
- Go: Added support for injecting sql, json, yaml, xml, html, css, js, lua and csv language highlights into string literals, when they are prefixed with `/* lang */`
**Example:**
```go
const sqlQuery = /* sql */ "SELECT * FROM users;" // Will be highlighted as SQL code
```
Closes #ISSUE
Release Notes:
- (preview only) restored ctrl-shift-{left,right} for Larger/Smaller
syntax node. This is VSCode's default and avoids the breaking change
from #37874
Do not report all open buffers to new instances of the same language
server, as they can respond with ~spurious errors.
This regressed in https://github.com/zed-industries/zed/pull/34142
Closes https://github.com/zed-industries/zed/issues/35017
Release Notes:
- Fixed Zed overly notifying language servers about open buffers, which
could've resulted in confusing errors in multi-language projects (in
e.g. Go).
This fixes terminal-based authentication for external ACP agents (Claude
Code, Gemini CLI) when file paths contain spaces, like "Application
Support" on macOS and "Program Files" on Windows.
When users click authentication buttons or type `/login`, they get
errors like `Cannot find module '/Users/username/Library/Application'`
because the path gets split at the space.
The fix removes redundant `shlex::try_quote` calls from
`spawn_external_agent_login`. These were causing double-quoting since
the terminal spawning code already handles proper shell escaping.
Added a test to verify paths with spaces aren't pre-quoted.
Release Notes:
- Fixed external agent authentication failures when file paths contain
spaces
---------
Co-authored-by: Hakan Ensari <hakanensari@users.noreply.github.com>
Co-authored-by: Claude <claude@anthropic.com>
Closes https://github.com/zed-industries/zed/issues/38141
This PR adds default scrollbars to the markdown preview and syntax tree
view.
Release Notes:
- Added scrollbars to the markdown preview and syntax tree view.
This PR lands some more improvements to the reworked scrollbars.
Namely, we will now explicitly paint a background in cases where a track
is requested for the specific scrollbar, which prevents a flicker, and
also reserve space only if space actually needs to be reserved. The
latter was a regression introduced by the recent changes.
Release Notes:
- N/A
The `Hsla` -> `Rgba` conversion sometimes results in negative (but very
close to 0) color components due to floating point imprecision, causing
the `.powf(constants.main_trc)` computations in the `srgb_to_y` function
to evaluate to `NaN`. This propagates to `apca_contrast` which then
makes `ensure_minimum_contrast` unconditionally return `black` for
certain background colors. This PR addresses this by clamping the rgba
components in `impl From<Hsla> for Rgba` to 0-1.
Before/after:
<img width="1044" height="48" alt="before"
src="https://github.com/user-attachments/assets/771f809f-3959-43e9-8ed0-152ff284cef8"
/>
<img width="1044" height="49" alt="after"
src="https://github.com/user-attachments/assets/5fd6ae25-1ef0-4334-90d1-7fc5acf48958"
/>
Release Notes:
- Fixed an issue where ANSI colors were incorrectly adjusted to improve
contrast on some background colors
This PR fixes the `BasedPyrightBanner`, making sure the banner is
completely hidden in the toolbar, when it was dismissed, or it's not
installed.
Without the fix, the banner still occupies some space in the toolbar,
making the UI looks inconsistent when editing a Python file. The bug is
**especially prominent** when the toolbar is hidden in the user's
settings (see below).
_Banner is shown_
<img width="1470" height="254" alt="Screenshot 2025-09-14 at 11 36 37"
src="https://github.com/user-attachments/assets/1415b075-0660-41ed-8069-c2318ac3a7cf"
/>
_Banner dismissed_
<img width="1470" height="207" alt="Screenshot 2025-09-14 at 11 36 44"
src="https://github.com/user-attachments/assets/828a3fba-5c50-4aba-832c-3e0cc6ed464b"
/>
_Banner dismissed (and the toolbar is hidden)_
<img width="1470" height="177" alt="Screenshot 2025-09-14 at 12 07 25"
src="https://github.com/user-attachments/assets/41aa5861-87df-491f-ac7e-09fc1558dd84"
/>
Closes n/a
Release Notes:
- Fixed the basedpyright onboarding banner
Three motivations for this:
* Changing provider URL could cause credentials for the prior URL to be
sent to the new URL.
* The UI is in a misleading state after URL change - it shows a
configured API key, but on restart it will show no API key.
* #34110 will add support for both URL and key configuration for Ollama.
This is the first provider to have UI for setting the URL, and this
makes these issues show up more directly as odd UI interactions.
#37610 implemented something similar for the OpenAI and OpenAI
compatible providers. This extracts out some shared code, uses it in all
relevant providers, and adds more safety around key use.
I haven't tested all providers, but the per-provider changes were pretty
mechanical, so hopefully work properly.
Release Notes:
- Fixed handling of changes to LLM provider URL in settings to also load
the associated API key.
Closes #ISSUE
Move the data table component created for the Keymap Editor to the UI
crate. Additionally includes simplifications to the scrollbar component
in UI necessary for the table component to support scrollbar
configurations, and a fix for an issue with the table component where
when used with the `.row` API instead of `uniform_list` the rows would
render on top of each other.
Release Notes:
- N/A *or* Added/Fixed/Improved ...
This has noticeable misbehavior when framerates are low (in my case this
sometimes happens when CPUs are throttled and compilation is happening),
as now a batch of x11 events can contain events over the span of 100s of
millis. So in that case, key press repetitions with quite normal typing
are skipped.
Under normal operating conditions it can be reproduced by running this
and quickly switching to Zed:
> sleep 1; for i in {1..5}; do xdotool type --delay 5 "aaaaaa "; xdotool
key Return; done
Output before looks like:
```
aaa
aaaaa
aaa
aaa
aaaa
```
Output after looks like:
```
aaaaaa
aaaaaa
aaaaaa
aaaaaa
aaaaaa
```
This behavior was added in #13955.
Release Notes:
- N/A
Closes#38147
The scrollbar's `show_state` field was always being initialized to
`VisibilityState::Visible`, ignoring the `show_setting` value.
Release Notes:
- N/A
Closes #ISSUE
Adds the ability to our JSON updating code to update arrays within other
objects. Previously updating of arrays was limited to just top level
arrays (i.e. `keymap.json`) however this PR makes it so nested arrays
are supported as well using `#{index}` syntax as a key.
This PR also fixes an issue with the array updating code that meant that
updating empty json values `""` or an empty `keymap.json` file in the
case of the Keymap Editor would fail instead of creating a new array.
Release Notes:
- Fixed an issue where keybindings would fail to save in the Keymap
Editor if the `keymap.json` file was completely empty
serde 1.0.221 introduced serde_core into the build graph, which should
render explicitly depending on serde_derive for faster build times an
obsolote method.
Besides, I'm not even sure if that worked for us. My hunch is that at
least one of our deps would have `serde` with derive feature enabled..
and then, most of the crates using `serde_derive` explicitly were also
depending on gpui, which depended on `serde`.. thus, we wouldn't have
gained anything from explicit dep on `serde_derive`
Release Notes:
- N/A
Closes#37829
This PR introduces and exposes `REPLSettings` to control the number of
lines and columns in the REPL. These settings are integrated into the
existing configuration system, allowing for customization and management
through the standard settings interface.
#### Changes
- Added `REPLSettings` struct with `max_number_of_lines` and
`max_number_of_columns` fields.
- Integrated `REPLSettings` with the settings system by implementing the
`Settings` trait.
- Ensured compatibility with the workspace and existing settings
infrastructure.
Release Notes:
- Add configuration "repl" to settings to configure max lines and
columns for repl.
---------
Co-authored-by: Marshall Bowers <git@maxdeviant.com>
Co-authored-by: Kirill Bulatov <kirill@zed.dev>
In zed logs you can see these logs of lmstudio connection refused.
Currently zed connects to lmstudio by default as there is no credential
mechanism to check if the user has enabled lmstudio previously or not
like we do with other providers using api keys.
This pr removes the below annoying log and makes the zed logs less
polluted.
```
2025-09-01T02:11:33+05:30 ERROR [language_models] Other(error sending request for url (http://localhost:1234/api/v0/models)
Caused by:
0: client error (Connect)
1: tcp connect error: Connection refused (os error 61)
2: Connection refused (os error 61))
```
Release Notes:
- N/A
---------
Signed-off-by: Umesh Yadav <git@umesh.dev>
This allows you to write `buffer_snapshot.debug(ranges, value)` and it
will be displayed in the buffer (or multibuffer!) until that callsite
runs again. `ranges` can be any position (`usize`, `Anchor`, etc), any
range, or a slice or vec of those. `value` just needs a `Debug` impl.
These are stored in a mutable global for convenience, and this is only
available in debug builds.
For example, using this to visualize the captures of the brackets
Tree-sitter query:
<img width="1215" height="480" alt="image"
src="https://github.com/user-attachments/assets/c1878fc7-f6b3-4e27-949e-ecf67a7906b9"
/>
Release Notes:
- N/A
Closes https://github.com/zed-industries/zed/issues/37621
Improves https://github.com/zed-industries/zed/issues/24623
Adding scrollbars withing Zed's UI currently is rather cumbersome, as it
requires the copying of a lot of code in order for these to work. Wiring
up settings for scrollbar visibilty always has to be done at the call
site and the state has to be saved and maintained by the caller as well.
Similarly, reserving space has to also be handled by the caller.
This PR changes the way scrollbars work in Zed fundamentally by making
use of the new `use_keyed_state` APIs: Instead of saving the state at
the call site, the window now keeps track of the state corresponding to
scrollbars. This enables us to add scrollbars with e.g. one simple call
on divs:
```rust
div()
.vertical_scrollbar(window, cx)
```
will add a scrollbar to the corresponding container. There are some more
improvements regarding tracking of scrollbar visibility settings (which
is now handled by a trait for each setting that supports this) as well
as reserving space.
Additionally, all needed stuff for layouting, catching events and
reserving space is also now managed by the scrollbar component instead.
This drastically reduces the amount of event listeners and makes
layouting of two scrollbars easier.
Furthermore, this paves the way for more improvements to scrollbars,
such as graceful auto-hide. Only downsight here is that we lose some
customizability in a few areas. However, once this lands, we gain the
ability to quickly follow these up without breaking stuff elsewhere.
This also already fixes a few bugs:
- Scrollbars no longer flicker on first render.
- Auto-hide now properly works for all scrollbars.
- If the content size changes, the scrollbar is updated on the same
frame. Both of these happened because we were computing the scrollbar
sizes too early, causing us to use the sizes from the previous frame or
unitialized sizes.
- The project panel no longer jumps if scrolled all the way to the
bottom and the scrollbar actually auto-hides.
Still TODO:
- [x] Fix scrolling in the debugger memory view
- [x] Clean up some more in the scrollbar component and reduce clones
there
- [x] Ensure we don't over-notify the entity the scrollbar is rendered
within
- [x] Make sure auto-hide properly works for all cases
- [x] Check whether we want to implement the scrollbar trait for
`UniformList`s as well
- ~~ [ ] Use for uniformlist where possible~~ Postponed
- [x] Improve layout for cases where we render both scrollbars.
Release Notes:
- N/A
This ensures that we highlight the log file with the log extension
should the extension be installed.
If it is not installed, we just fallback to the default of no
highlighting, but also log no errors.
Release Notes:
- N/A
Now logs warnings for unrecognized capture names and logs errors for
missing required captures.
Release Notes:
- N/A
---------
Co-authored-by: Max <max@zed.dev>
Closes https://github.com/zed-industries/zed/issues/31106
This fixes an issue where you would have to manually uninstall the
release extension before installing the dev extension in case that is
locally installed.
Release Notes:
- Installing a dev extension will now automatically remove the release
extension should it be installed.
Follows on from
https://github.com/zed-industries/zed/pull/37716#pullrequestreview-3195695110
by @SomeoneToIgnore
After this the doctests will be run in CI to check that the examples are
still accurate.
Note that doctests aren't run by Nextest: you can run them locally with
`cargo test --doc`.
Summary:
* Run tests from CI
* Loosen an exact float comparison to match approximately (otherwise it
fails)
* Fixed one actual bug in the tests for `dilate` where the test code
assumed that `dilate` mutates `self` rather than returning a new object
* Add some `must_use` on some functions that seemed at risk of similar
bugs, following the Rust stdlib style to add it where ignoring the
result is almost certainly a bug.
* Fix some cases where the doc examples seem to have gone out of date
with the code
* Add imports to doctests that need them
* Add some dev-dependencies to make the tests build
* Fix the `key_dispatch` module docstring, which was accidentally
attached to objects within that module
* Skip some doctest examples that seem like they need an async
environment or that just looked hard to get running
AI usage: I asked Claude to do some of the repetitive tests. I checked
the output and fixed up some things that seemed to not be in the right
spirit of the test, or too longwinded.
I think we could reasonably run the tests on only Linux to save CI
CPU-seconds and latency, but I haven't done that yet, partly because of
how it's implemented in the action.
Release Notes:
- N/A
Using `window.use_state` made the element IDs match between elements,
thus causing the same menu to be shared for drop down menus. I switched
to `window.use_keyed_state` and used a value's path as it's element id
Release Notes:
- N/A
Adds a `named_directory_icons` field to the icon theme that can be used
to specify a collection of icons for collapsed and expanded folders
based on the folder name.
The `named_directory_icons` is a map from the folder name to a
`DirectoryIcons` object containing the paths to the expanded and
collapsed icons for that folder:
```json
{
"named_directory_icons": {
".angular": {
"collapsed": "./icons/folder_angular.svg",
"expanded": "./icons/folder_angular_open.svg"
}
}
}
```
Closes#20295
Also referenced
https://github.com/zed-industries/zed/pull/23987#issuecomment-2638869213
Example using https://github.com/jacobtread/zed-vscode-icons/ which I've
ported over from a VSCode theme,
<img width="609" height="1307" alt="image"
src="https://github.com/user-attachments/assets/2d3c120a-b2f0-43fd-889d-641ad4bb9cee"
/>
Release Notes:
- Added support for icon themes to change the folder icon based on the
directory name.
---------
Co-authored-by: Marshall Bowers <git@maxdeviant.com>
Closes #ISSUE
This PR continues work from #32821 by adding a stash entry picker for
pop/drop operations. Additionally, the stash pop action in the git panel
is now disabled when no stash entries exist, preventing error logs from
attempted pops on empty stashes.
Preview:
<img width="1920" height="1256" alt="Screenshot From 2025-09-11
14-08-31"
src="https://github.com/user-attachments/assets/b2f32974-8c69-4e50-8951-24ab2cf93c12"
/>
<img width="1920" height="1256" alt="Screenshot From 2025-09-11
14-08-12"
src="https://github.com/user-attachments/assets/992ce237-43c9-456e-979c-c2e2149d633e"
/>
Release Notes:
- Added a stash picker to pop and drop a specific stash entry
- Disabled the stash pop action on the git panel when no stash entries
exist
- Added git stash apply command
- Added git stash drop command
This fixes an issue where we would not update neither the path nor the
editor that was listened to during follow mode, which in turn would
cause the preview to become stale.
Fix here is to update the subscription whenever the active item changes
and also update the associated path accordingly.
Release Notes:
- Fixed an issue where the SVG preview would not update when following
the active editor.
Menu items in the context menu component have the ability to display a
documentation aside popover. However, because this docs aside popover
was setup as a sibling flex container to the actual menu popover, if the
menu had a short amount of items and the docs popover is bigger than the
menu, this flickering would happen, making it essentially unusable:
https://github.com/user-attachments/assets/74956254-fff6-4c5c-9f79-02998c64a105
So, this PR makes the docs aside popover in wide window sizes
absolutely-positioned relative to the menu container, which removes all
flickering. On top of that, I'm adding a `DocumentationEdge` enum that
allows to control the edge anchor of the docs aside, which is useful in
this particular mode selector example to make the layout work well.
https://github.com/user-attachments/assets/a3e811e1-86b4-4839-a219-c3b0734532b3
When the window is small, the docs aside continue to be a sibling flex
container, which causes a super subtle shift in the items within the
menu popover. This is something I want to pursue fixing, but didn't want
to delay this PR too much.
Release Notes:
- N/A
Instead of passing CWD verbatim from the Windows host with backslashes
and all, we now rewrite it into a more POSIX-happy format featuring
forward slashes which means `std::path::Path` operations now work within
WASI with Windows-style paths.
Release Notes:
- N/A
In https://github.com/zed-industries/zed/pull/22983 we made it possible
to drag items onto folded directories.
This PR handles the reverse: dragging folded directories onto other
items.
Release Notes:
- Improved drag-and-drop support by allowing folded directories to be
dragged onto other items in Project Panel.
This removes the `gemini-and-native` and `claude-code` feature flags.
Also, I removed a bunch of unused agent1 code that we do not need
anymore.
Initially I wanted to remove much more of the `agent` code, but noticed
some things that we need to figure out first:
- The inline assistant + context strip use `Thread`/`ContextStore`
directly
- We need some replacement for `ToolWorkingSet`, so we can access
available tools (as well as context server tools) in other places, e.g.
the agent configuration and the configure profile modal
Release Notes:
- N/A
Please credit @eliaperantoni, for the original PR (#34136).
Merge after (#34060) to avoid conflicts.
Closes https://github.com/zed-industries/zed/issues/33838
Closes https://github.com/zed-industries/zed/issues/33906
Release Notes:
- Helix will no longer sometimes fall out into "normal" mode, will
remain in "helix normal" (example: vv)
- Added dedicated "helix select" mode that can be targeted by
keybindings
Known issues:
- [ ] Helix motion, especially surround-add will not properly work in
visual mode, as it won't call `helix_move_cursor`. It is possible
however to respect self.mode in change_selection now.
- [ ] Some operations, such as `Ctrl+A` (increment) or `>` (indent) will
collapse selection also. I haven't found a way to avoid it.
---------
Co-authored-by: fantacell <ghub@giggo.de>
Co-authored-by: Conrad Irwin <conrad.irwin@gmail.com>
The rodio channelcount convertor halves the volume. This addresses that
in most cases by using the default channelcount for the system
microphone which is usually 2.
A proper fix will follow later as part of the de-noising PR
Release Notes:
- N/A
Part of reworking our installation handling to allow for multiple
different versions to be handled
Release Notes:
- Fixed pre-release lsp fetching setting not having an affect until
restarting Zed
Supersedes: #34500
Also this will allow to fix this: #35386 without the UX changes but
providers can now be control through settings as well within zed.
Just rebased the latest main and docs added. Added @AurelienTollard as
co-author as it was started by him everything else remains the same from
original PR.
Release Notes:
- Added ability to control Provider Routing for OpenRouter models from
settings.
Co-authored-by: Aurelien Tollard <tollard.aurelien1999@gmail.com>
When working on the git stash picker PR (#35927) I notice that my test
was detected as a binary file on the git diff view and on GitHub. This
was due to the fact that I was using the literal char \0 (instead of a
proper representation like `\x00` or `\u{0000}`) character in my test
strings. This causes problems with git diff and GitHub's diff viewer,
and a reviewer might even assume that the file is corrupted, not
viewable or even malicious.
Looking at the rest of the codebase, only at `crates/git/src/commit.rs`
this character was used, so I replaced it with `\x00` which is a more
common representation of the null character in Rust strings.
It can also be seen that the PR that introduced this code, can't be
viewed properly on Github:
https://github.com/zed-industries/zed/pull/27636/files#diff-31114f0b22306b467482573446f71c638277510b442a10e60dd9a8667ccd93c3
Closes #ISSUE
Release Notes:
- Use `\x00` representation instead of literal null character in strings
to improve compatibility with git diff and GitHub's diff viewer.
Since the file is not viewable from the "Files changed" tab on Github,
this is the changed code:
dcd743aca4/crates/git/src/commit.rs (L66-L74)
Also removed the symbolicate script, which we could replace with a
`minidump-stackwalk` wrapper that downloaded sources/unstripped binaries
from github releases if that's helpful for folks.
Release Notes:
- N/A
<img width="598" height="311" alt="Screenshot 2025-09-11 at 9 39 12 PM"
src="https://github.com/user-attachments/assets/b526e648-37cf-4412-83a0-42037b9fc94d"
/>
This is for both ACP and the regular agent. Previously we would always
include the whole file, which can easily blow the context window on huge
files.
Release Notes:
- When `@mention`ing large files, the Agent Panel now send an outline of
the file instead of the whole thing.
#37337 Made `AutoUpdateSetting` `FileContent =
AutoUpdateSettingsContent` which caused a deserialization bug to occur
because the field it was wrapping wasn't optional. Thus serde would
deserialize the wrapped type `bool` to its default value `false`
stopping the settings load function from reading the correct default
value from `default.json`
I also added a log message that states when the auto updater struct is
checking for updates to make this easier to test.
Release Notes:
- fix auto update defaulting to false
#35053 split out these utility functions. I found the names / doc
comments a bit confusing so this improves that. Before that PR there was
also a mild inefficiency - it would walk the cursor all the way down to
a leaf and then back up to an ancestor.
Release Notes:
- N/A
Enums with six or less fields can still use toggle groups by adding a
definition.
I also renamed the `OpenSettingsEditor` action to `OpenSettingsUi`
Release Notes:
- N/A
### Background
Zed extensions use WASI to access the file-system. They only have
read-write access to one specific folder called their work dir. But
extensions do need to be able to *refer* to other arbitrary files on the
user's machine. For instance, extensions need to be able to look up
existing binaries on the user's `PATH`, and request that Zed invoke them
as language servers. Similarly, extensions can create paths to files in
the user's project, and use them as arguments in commands that Zed
should run. For these reasons, we pass *real* paths back and forth
between the host and extensions; we don't try to abstract over the
file-system with some virtualization scheme.
On Windows, this results in a bit of mismatch, because `wasi-libc` uses
*unix-like* path conventions (and thus, so does the Rust standard
library when compiling to WASI).
### Change 1 - Fixing `current_dir`
In order to keep the extension API minimal, extensions use the standard
library function`env::current_dir()` to query the location of their
"work" directory. Previously, when initializing extensions, we used the
`env::set_current_dir` function to set their work directory, but on
Windows, where absolute paths typically begin with a drive letter, like
`C:`, the [`wasi-libc` implementation of
`chdir`](d1793637d8/libc-bottom-half/sources/chdir.c (L21))
was prepending an extra forward slash to the path, which caused
`current_dir()` to return an invalid path.
See https://github.com/bytecodealliance/wasmtime/issues/10415
In this PR, I've switched our extension initialization function to
*bypass* wasi-libc's `chdir` function, and instead write directly to
wasi-libc's private, internal state. This is a bit of a hack, but it
causes the `current_dir()` function to do what we want on Windows
without any changes to extensions' source code.
### Change 2 - Working around WASI's relative path handling
Once `current_dir` was fixed (giving us correct absolute paths on
Windows), @kubkon and I discovered that without the spurious leading `/`
character, windows absolute paths were no longer accepted by Rust's
`std::fs` APIs, because they were now recognized as relative paths, and
were being appended to the working directory.
We first tried to override the `__wasilibc_find_abspath` function in
`wasi-libc` to make it recognize windows absolute paths as being
absolute, but that functionality is difficult to override. Eventually
@kubkon realized that we could prevent WASI-libc's CWD handling from
being linked into the WASM file by overriding the `chdir` function.
wasi-libc is designed so that if you don't use their `chdir` function,
then all paths will be interpreted as relative to `/`. This makes
absolute paths behave correctly. Then, in order to make *relative* paths
work again, we simply add a preopen for `.`. Relative paths will match
that.
### Next Steps
This is a change to `zed-extension-api`, so we do need to update every
Zed extension to use the new version, in order for them to work on
windows.
Release Notes:
- N/A
---------
Co-authored-by: Jakub Konka <kubkon@jakubkonka.com>
Release Notes:
- python: The Ruff native language server is now available without
installing an extension.
---------
Co-authored-by: Piotr Osiewicz <24362066+osiewicz@users.noreply.github.com>
We need a PAT to have permission to check team information. Also, the
COAUTHOR_TEMPLATES didn't feel quite right. Skipping this for now.
Release Notes:
- N/A
@maxdeviant We can eventually turn down the panic telemetry endpoint,
but should probably leave it up while there's still a bunch of stable
users hitting it.
@maxbrunsfeld We're optimistic that this change also fixed the macos
crashed-thread misreporting. We think it was because the
`CrashContext::exception` was getting set to `None` only on macos, while
on linux it was getting a real exception value from the sigtrap. Now
we've unified and it uses `SIGABRT` on both platforms (I need to double
check that this works as expected for windows).
We unconditionally set `RUST_BACKTRACE=1` for the current process so
that we see backtraces when running in a terminal by default. This
should be fine but I just wanted to note it since it's a bit abnormal.
Release Notes:
- N/A
---------
Co-authored-by: Conrad Irwin <conrad.irwin@gmail.com>
Closes#25854
You can now drag-and-drop on the remaining space in the project panel to
drop entries/external paths in the last worktree.
https://github.com/user-attachments/assets/a7e14518-6065-4b0f-ba2c-823c70f154f4
Release Notes:
- Added support for drag-and-drop files and external paths into the
empty space of the project panel, placing them in the last folder you
have added to the project.
A very primitive attempt, we just key the editor with the locations and
re-use the editor if we open a new buffer with the same initial
locations and title.
Release Notes:
- Added reusing of reference search buffers when applicable
Follow up on https://github.com/zed-industries/zed/pull/37786
adds conditional cmp removing use of libwebrtc on windows/freebsd
They cant compile livekit yet. This removes microphone and echo
cancellation on those platforms however they can not join calls due to
the same cause so it does not matter.
Documentation and error handing improvements
Release Notes:
- N/A
---------
Co-authored-by: Richard <richard@zed.dev>
Closes#36109
Adds an additional option to `search` and `update_matches` to specify
whether the update should affect the search history.
Release Notes:
- Fix navigating buffer search history
Closes#36491
This issue is caused by the Python language configuration treating
compound statements (such as for loops and if statements) that end with
an inline comment as not requiring an increased indent.
Release Notes:
- python: Correctly indent lines starting the blocks (for, finally, if,
else, try) that have trailing comments.
This fixes a minor issue where we would show "Removing extension ..." in
the status bar when we would actually be installing it.
Release Notes:
- Fixed an issue where installing a dev extension would show the
installation status as "removing" in the activity indicator.
Closes#37980
There seems to be no reason to hard limit this to 1, and we even have
existing UX for this case already:
<img width="1530" height="748" alt="Bildschirmfoto 2025-09-11 um 11 22
57"
src="https://github.com/user-attachments/assets/d6498318-c905-4d3c-90ab-60e4f2bb6c48"
/>
(Notice the different arrows in the gutter area for single lines)
Hence, allowing the value to honor the request from the issue
Release Notes:
- Allowed `0` as a value for the `excerpt_context_lines` setting
Closes#35623
Previously if a base keymap had a `null` set to an action, leading to a
`NoAction` being assigned to the keymap, if a user wanted to take
advantage of that keymap (in this particular case, `cmd-2`), the keymap
binding check would favor the `NoAction` over the user, since
technically the context depth matched better. Instead, we should always
prefer the user's settings over whatever base or default.
Release Notes:
- Fixed keymap precedence by favoring user settings over base keymap /
configs.
This PR moves the feature flag definitions to their own module so that
they aren't intermingled with the feature flag infrastructure itself.
Release Notes:
- N/A
This will users to change the wording of the most recent commit,
something they might want to do if they realize they made a small typo
of some kind or if the formatting of their commit message is wrong, but
don't have any other changes they need to make.
Release Notes:
- Commit messages can now be amended in the UI without any other changes
needing to be made.
---------
Co-authored-by: Cole Miller <cole@zed.dev>
Follow up to https://github.com/zed-industries/zed/pull/37824, which
made items be cut-off in the _editor_ instance of the code actions menu.
This PR applies the default UI font size for the code action menu items
only when the origin is the quick actions bar.
Release Notes:
- Fix code actions menu items being cut-off in the editor.
It was previously copied incorrectly from `Terminal: Copy On Select`.
Release Notes:
- Fixed wrong description in `Terminal: Cursor Shape` in `Configuring
Zed` document
Closes #ISSUE
Adds handling for Enums with fields (i.e. not `enum Foo { Yes, No }`) in
Settings UI. Accomplished by creating default values for each element
with fields (in the derive macro), and rendering a toggle button group
with a button for each variant where switching the active variant sets
the value in the settings JSON to the default for the new active
variant.
Release Notes:
- N/A *or* Added/Fixed/Improved ...
---------
Co-authored-by: Conrad <conrad@zed.dev>
## Context
While looking into: #32051 and #16120 with instruments, I noticed that
`TabSnapshot::to_tab_point` and `TabSnapshot::to_fold_point` are a
common bottleneck between the two issues. This PR takes the first steps
into closing the stated issues by improving the performance of both
those functions.
### Method
`to_tab_point` and `to_fold_point` iterate through each character in
their rows to find tab characters and translate those characters into
their respective transformations. This PR changes this iteration to take
advantage of the tab character bitmap in the `Rope` data structure and
goes directly to each tab character when iterating.
The tab bitmap is now passed from each layer in-between the `Rope` to
the `TabMap`.
### Testing
I added several randomized tests to ensure that the new `to_tab_point`
and `to_fold_point` functions have the same behavior as the old methods
they're replacing. I also added `test_random_chunk_bitmap` on each layer
the tab bitmap is passed up to the `TabMap` to make sure that the bitmap
being passed is transformed correctly between the layers of
`DisplayMap`.
`test_random_chunk_bitmap` was added to these layers:
- buffer
- multi buffer
- custom_highlights
- inlay_map
- fold_map
## Benchmarking
I setup benchmarks with criterion that is runnable via `cargo bench -p
editor --profile=release-fast`. When benchmarking I had my laptop
plugged in and did so from the terminal with a minimal amount of
processes running. I'm also on a m4 max
### Results
#### To Tab Point
Went from completing 6.8M iterations in 5s with an average time of
`736.13 ns` to `683.38 ns` which is a `-7.1875%` improvement
#### To Fold Point
Went from completing 6.8M iterations in 5s with an average time of
`736.55 ns` to `682.40 ns` which is a `-7.1659%` improvement
#### Editor render
Went from having an average render time of `62.561 µs` to `57.216 µs`
which is a `-8.8248%` improvement
#### Build Buffer with one long line
Went from having an average buffer build time of `3.2549 ms` to `3.2635
ms` which is a `+0.2151%` regression within the margin of error
#### Editor with 1000 multi cursor input
Went from having an average edit time of `133.05 ms` to `122.96 ms`
which is a `-7.5776%` improvement
Release Notes:
- N/A
---------
Co-authored-by: Remco Smits <djsmits12@gmail.com>
Co-authored-by: Cole Miller <cole@zed.dev>
Co-authored-by: Piotr Osiewicz <24362066+osiewicz@users.noreply.github.com>
This PR fixes the backwards compatibility of the new `Plan` variants.
We can't add new variants to the wire representation, as old clients
won't be able to understand them.
Release Notes:
- N/A
Closes#19816
Release Notes:
- Improved `ctrl-k` (`editor::CutToEndOfLine`) behavior when used at the
end of lines
- Add option to make `editor::CutToEndOfLine` not gobble newlines.
```json
{
"context": "Editor",
"bindings": { "ctrl-k": ["editor::CutToEndOfLine", { "stop_at_newlines":
true }] }
},
```
---------
Co-authored-by: Peter Tripp <peter@zed.dev>
This setting controls which visible characters are used to render
whitespace when the show_whitespace setting is enabled.
Release Notes:
- Added `whitespace_map` setting to control which visible characters are
used to render whitespace when the `show_whitespace` setting is enabled.
---------
Co-authored-by: Nia Espera <nia@zed.dev>
Closes#37617
We're already using `get` in a bunch of places, this PR updates the
remaining spots to follow the same pattern. Note that the `ix` we read
in `render_match` can sometimes be stale.
The likely reason is that we run the match-update logic asynchronously
(see
[here](138117e0b1/crates/picker/src/picker.rs (L643))).
That means it's possible to render items after the list's [data
update](138117e0b1/crates/picker/src/picker.rs (L652))
but before the [list
reset](138117e0b1/crates/picker/src/picker.rs (L662)),
in which case the `ix` can be greater than that of our updated data.
Release Notes:
- Fixed crash when filtering MCP tools.
Whilst looking into adding support for RainbowBrackes, we stumbled upon
this: Whereas for all properties during this blending, we take the value
of `other` if it is set, for the color we actually take `self.color`
instead of `other.color` if `self.color` is at full opacity.
`Hsla::blend` returns the latter color if it is at full opacity, which
seems wrong for this case. Hence, this PR swaps these.
Will not merge before the next release, to ensure that we don't break
something somewhere unexpected.
Release Notes:
- N/A
Previously we would still show a completion menu even when the user
typed an unrecognised mode with an argument,
e.g. `@something word`.
This PR ensures that we only show the completion menu, when the part
after the `@` is a known mode (e.g. `file`/`symbol`/`rule`/...)
Release Notes:
- Fix an issue where completions for `@mentions` in the agent panel
would sometimes not be dismissed when typing a space
TODO:
- [x] Double-check if we like the naming of the new actions
- [x] Only show keybinding hint once per option (e.g. if there are two
`allow_once` buttons only show it on the first one)
- [x] If there are multiple tool calls that need authorisation, only
show keybindings on the first tool call
- [x] Figure out which keybindings to use
- [x] Add linux keybindings
- [x] Add windows keybindings
- [x] Bug: long keybindings can make the buttons overflow
Release Notes:
- Add keybindings for authorizing tool calls (`agent: Allow once`,
`agent: Allow always`, `agent: Reject once`) in the agent panel
---------
Co-authored-by: Agus Zubiaga <agus@zed.dev>
Release Notes:
- Fixed matching bracket highlighting not highlighting closing brackets
when adjacent to each other
Co-authored-by: Finn Evers <finn@zed.dev>
Potentially fixes#37367. Just going ahead with the change even though
it's unclear whether this is the fix, since it is quite low risk.
Release Notes:
- N/A
Adding mistral nemo, sorting by name and adding comment about clamp
sizing
Release Notes:
- Added support for mistral-nemo
---------
Co-authored-by: Conrad Irwin <conrad.irwin@gmail.com>
Skipping Linux and Windows keymaps here, as it's hard to find a
consistent base-binding for all 4 actions across all platforms that
don't break important actions for each keymap. Someone else can think on
that and make a proposal.
Release Notes:
- Added bindings for navigating between sibling nodes in the syntax tree
on macOS (`cmd-ctrl-{up/down}` for `SelectPreviousSyntaxNode` and
`SelectNextSyntaxNode`). Breaking change: the existing syntax tree
parent/child navigation bindings have moved from
`ctrl-shift-{left/right}` to `cmd-ctrl-{left/right}` to create a unified
four-directional navigation pattern where all syntax tree operations use
the same modifier combination. We could not use the previous base
modifiers without breaking more bindings.
Closes#37208
## Release Notes:
- Fixed: SVG preview now refreshes automatically when files are modified
by external programs
## Summary
Previously, SVG preview would only refresh when files were saved within
the Zed editor, but not when modified by external programs (like
scripts, other editors, etc.)
## What Changed
The SVG preview now subscribes to file system events through the
worktree system. When an external program modifies an SVG file, the
worktree detects the change and notifies the preview. The preview then
clears its cache and refreshes to show the updated content.
## Before the fix
https://github.com/user-attachments/assets/e7f9a2b2-50f9-4b43-95e9-93a0720749f5
## After the fix
https://github.com/user-attachments/assets/b23511e3-8e59-45a1-b29b-d5105d32bd2c
AI Usage:
Used Cursor for code generation
While working on fixing this: #37116. I reliased the current
implementation of github copilot is not truly resilient to upstream
changes.
This PR enhances GitHub Copilot Chat to be forward-compatible with new
AI model vendors and improves token counting accuracy by using
vendor-specific tokenizers from the GitHub Copilot API. The system
previously failed when GitHub added new model vendors like xAI with
deserialization errors, and token counting wasn't utilizing the
vendor-specific tokenizer information provided by the API. The solution
adds an Unknown variant to the ModelVendor enum with serde other
attribute to gracefully handle any new vendors GitHub introduces,
implements tokenizer-aware token counting that uses the model's
specified tokenizer mapping o200k_base to gpt-4o with fallback, adds
explicit support for xAI models with proper tool input format handling,
and includes comprehensive test coverage for unknown vendor scenarios.
Key changes include adding the tokenizer field to model capabilities,
implementing the tokenizer method on models, updating tool input format
logic to handle unknown vendors, and simplifying token counting to use
the vendor's specified tokenizer or fall back to gpt-4o. This ensures
Zed's Copilot Chat integration remains robust and accurate as GitHub
continues expanding their AI model provider ecosystem.
Release Notes:
- Enhanced model vendor compatibility to automatically support future AI
providers and improved token counting accuracy using vendor-specific
tokenizers from the GitHub Copilot
---------
Signed-off-by: Umesh Yadav <git@umesh.dev>
Closes#37511
The outline modal seems to have a bug where if it's open and the
`outline::Toggle` is triggered, it would not close if there was another
command with the same keybind. So instead, if the outline modal is open
and an `outline::Toggle` is triggered, we dismiss the modal.
Release Notes:
- Fixed a bug where `outline::Toggle` would sometimes not close outline
modal
Somehow we have a regression where the auth wasn't being called, so the
model didn't exist.
Looking at the code, it is likely this was relying on some other part of
the code doing the auth, since the order wouldn't have worked before
without that happening. This new order of doing auth before checking for
available models should fix it going forward.
Release Notes:
- N/A
The "Install CLI" menu button and `install_cli::Install` action are
effectively no-op on Windows since the CLI is directly available in
Windows Terminal (CMD prompt, PowerShell, etc.) after the user runs Zed
installer package.
Release Notes:
- N/A
Co-authored-by: Peter Tripp <peter@zed.dev>
This is an initial implementation that isn't used for any settings yet,
but will be used once `Vec<String>` is implemented.
I also updated the window.with_state api to grant access to a
`Context<S>` app reference instead of just an App.
## Example
<img width="603" height="83" alt="Screenshot 2025-09-09 at 2 15 56 PM"
src="https://github.com/user-attachments/assets/7b3fc350-a157-431f-a4bc-80a1806a3147"
/>
Release Notes:
- N/A
Closes#21193Closes#14703
Having the ability to navigate directly to the next
symbolHighlight/reference lets you follow the data flow of a variable.
If you highlight the function itself (depending on the LSP), you can
also navigate to all returns.
Note that this is a different feature from navigating to the next match,
as that is not language-context aware. For example, if you have a var
named foo it would also navigate to an unrelated variable fooBar.
Here's how this patch works:
- The editor struct has a background_highlights.
- Collect all highlights with the keys [DocumentHighlightRead,
DocumentHighlightWrite]
- Depending on the direction, move the cursor to the next or previous
highlight relative to the current position.
Release Notes:
- Added `editor::GoToNextDocumentHighlight` and
`editor::GoToPreviousDocumentHighlight` to navigate to the next LSP
document highlight. Useful for navigating to the next usage of a certain
symbol.
When the cursor was sitting on a syntactically insignificant character,
like a `{` or `,`, this function was selecting only that character, when
what the user likely wanted was to select the next larger syntax node.
Those punctuation characters all seemed to be not "named", in
tree-sitter terminology, so I updated the function to walk up the node
tree until it found a node where `is_named()` is true.
Closes#4555
Also, while writing the tests, the output of a failing test with the
wrong thing selected was harder to read than it needed to be.
It used to output a diff of ranges, like this:
<img width="217" height="111" alt="image"
src="https://github.com/user-attachments/assets/00de53a8-8776-47aa-8101-5a5b5bc3fa5e"
/>
I leveraged the existing `generate_marked_text` helper function and
updated the assertion to output a diff of the text with the selection
markers:
<img width="211" height="116" alt="image"
src="https://github.com/user-attachments/assets/53b2b882-2676-4c70-8718-e2e2ba6f254e"
/>
Happy to make that a separate PR, if needed.
Release Notes:
- Fixed Editor select_larger_syntax_node to be smart about punctuation.
Adds a new menu option to toggle between sorting git entries by path or
status, with settings integration
Release Notes:
- Git Panel: Added toggle to switch between sorting git panel entries by
path or by status (available in git panel ellipsis menu)
---------
Co-authored-by: Conrad Irwin <conrad.irwin@gmail.com>
It appears that in macOS, the `AcpConnection._wait_task` doesn't always
get dropped when quitting the app. In these cases, the subprocess would
be kept alive because we move the `child` into it.
Instead, we will now explicitly kill it when `AcpConnection` is dropped.
It's ok to do this because when the connection is dropped, the thread is
also dropped, so there's no need to report the exit status to it.
Closes#37741
Release Notes:
- Claude Code: Fix subprocess leak on app quit
Follow up to this: #35114
* Previously we were still showing the commit message even after
cancelling amend which was the old commit message.
* This PR fixes that by restoring the commit message to the old state
before the amend begin so that in case user typed a commit message it's
shown if not then it's not.
Before:
https://github.com/user-attachments/assets/e0edcfff-863d-4367-a7c4-8a2998e702ca
After:
https://github.com/user-attachments/assets/9daf9be0-8a3d-4914-91a4-567693711b6b
Release Notes:
- Resolved an issue where cancelling an amend commit would incorrectly
leave the old commit message in the input field. The commit message box
now properly reverts to its pre-amend state.
Pyright sets different `sortText` based on whether a given completion
item was recently resolved. This probably lines up with VSCode's way of
resolving items, but it's a no-no for us, as it makes completions
unstable.
Closes#9983
Release Notes:
- python: Fixed code completions having arbitrary order when using
Pyright/basedpyright
Fixes#12338, related to #37616
This change improves URL detection in the terminal by removing trailing
periods that appear to be sentence punctuation rather than part of the
URL structure. It builds upon the parentheses sanitization work from
#37076 by consolidating both approaches into a unified
`sanitize_url_punctuation` function.
## Changes
- Combines parentheses and period sanitization into a single
`sanitize_url_punctuation` function
- Uses optimized single traversal with `fold()` for parentheses counting
(addressing code review feedback)
- Removes trailing periods using heuristics to distinguish sentence
punctuation from legitimate URL components
- Removes multiple trailing periods (always considered punctuation)
- Removes single trailing periods when they appear after alphanumeric
characters or slashes
- Preserves periods that are part of legitimate URL structure (e.g.,
version numbers, IP addresses, subdomains)
- Maintains existing parentheses balancing logic from #37076
## Implementation Details
- **Parentheses handling**: Counts opening and closing parentheses,
removes trailing `)` when unbalanced
- **Period handling**: Uses `take_while()` iterator for efficient period
counting
- **Performance**: Single pass counting with optimized loop to avoid
redundant work
- **Code clarity**: Uses let-else pattern for readable conditional logic
## Testing
- Added comprehensive test coverage for both parentheses and period
sanitization
- Tests cover balanced vs unbalanced parentheses cases
- Tests cover various period scenarios including legitimate URL periods
vs sentence punctuation
- All existing tests continue to pass
## Release Notes
- Improved terminal URL detection by further trimming trailing
punctuation. URLs ending with periods (like
`https://example.com.`) and unbalanced parentheses (like
`https://example.com/path)`) are now properly detected without including
the trailing punctuation.
- Makes the keymap editor search container more consistent with the
project & file search corresponding elements
- Changes the keymap editor menu item in the user menu be called "Keymap
Editor", as opposed to "Key Binding", to match with the tab and action
name
Design note: Still a bit unsure about the extra space on the right for
the keymap editor. This makes it way more consistent with the other
search views, but it also just feels like space that could be used. On
the other hand, though, it's very unlikely anyone will ever use more
than 30% of the search bar width as search queries here are likely
pretty short; definitely much shorter than project search queries.
<img width="600" height="552" alt="Screenshot 2025-09-09 at 1 02@2x"
src="https://github.com/user-attachments/assets/9825a129-2c5a-4852-9837-c586b88e9332"
/>
Release Notes:
- N/A
At RustConf we were demo'ing zed, and it continually popped open the
chat panel.
We're usually inured to this because the Chat panel doesn't open unless
a Guest
is in the channel, but it made me sad that we were showing a long stream
of
vacuous comments and unresponded to questions on every demo screen.
We may bring chat back in the future, but we need more thought on the
UX, and
we need to rebuild the backend to not use the existing collab server
that we're
trying to move off of.
Release Notes:
- Removed the chat feature from Zed (Sorry to the 5 of you who use this
on the regular!)
Updates #37623
Release Notes:
- Changed the behaviour when editing an old message in a native agent
thread.
Prior to this, it would automatically restore the checkpoint (which
could
lead to a surprising amount of work being discarded). Now it will just
reject
any unaccepted agent edits, and you can use the "restore checkpoint"
button
for the original behavior.
This PR mostly adds some style treatment to popover button triggers in
the agent panel, either making them better aligned with their trigger or
adjusting the color to better clarify which button is triggering the
currently opened menu.
Moving forward, I think the selected styles at least should probably be
tackled at the component level, whether that's a context menu or a
popover, so we don't have to ever do this manually (and running the risk
of forgetting to do it).
Release Notes:
- N/A
Closes#37487
Proxy settings are now taken from the Zed configuration and passed to
Gemini via the "--proxy" flag.
Release Notes:
- acp: Gemini ACP server now uses proxy settings from Zed configuration.
Follow-up to #35250. Let's experiment with having this by default on
nightly.
Release Notes:
- Added built-in support for the basedpyright language server for Python
code. basedpyright is now enabled by default, and pyright (previously
the primary Python language server) remains available but is disabled by
default. This supersedes the basedpyright extension, which can be
uninstalled. Advantages of basedpyright over pyright include support for
inlay hints, semantic highlighting, auto-import code actions, and
stricter type checking. To switch back to pyright, add the following
configuration to settings.json:
```json
{
"languages": {
"Python": {
"language_servers": ["pyright", "pylsp", "!basedpyright"]
}
}
}
```
---------
Co-authored-by: Piotr Osiewicz <24362066+osiewicz@users.noreply.github.com>
Co-authored-by: Lukas Wirth <lukas@zed.dev>
This PR adds support for using external agents in SSH projects via ACP,
including automatic installation of Gemini CLI and Claude Code,
authentication with API keys (for Gemini) and CLI login, and custom
agents from user configuration.
Co-authored-by: maan2003 <manmeetmann2003@gmail.com>
Release Notes:
- agent: Gemini CLI, Claude Code, and custom external agents can now be
used in SSH projects.
---------
Co-authored-by: maan2003 <manmeetmann2003@gmail.com>
For read_file and edit_file, show the worktree-relative path if there's
only one visible worktree, and the "full path" otherwise. Also restores
the display of line numbers for read_file calls.
Release Notes:
- N/A
When a keybind contains a backslash character (\\), it is parsed
incorrectly, which results in an invalid keybind configuration.
This patch fixes the issue by ensuring that backslashes are properly
escaped during the parsing process. This allows them to be used as
intended in keybind definitions.
Release Notes:
- Fixed an issue where keybinds containing a backslash character (\\)
failed to be replaced correctly
## Screenshots
<img width="912" height="530" alt="SCR-20250828-borp"
src="https://github.com/user-attachments/assets/561a040f-575b-4222-ac75-17ab4fa71d07"
/>
<img width="912" height="530" alt="SCR-20250828-bosx"
src="https://github.com/user-attachments/assets/b8e0fb99-549e-4fc9-8609-9b9aa2004656"
/>
Required for https://github.com/isographlabs/isograph/pull/568 to work
properly. Tested with a local build and made sure everything's working
great!
Release Notes:
- JavaScript/TypeScript/JSX: Added support for injecting Isograph language support into `iso`
function calls
These changes introduce a new command to the Diagnostics panel,
`diagnostics: deploy current file`, which allows the user to view the
diagnostics only for the currently opened file.
Here's a screen recording showing these changes in action 🔽
[diagnostics: deploy current
file](https://github.com/user-attachments/assets/b0e87eea-3b3a-4888-95f8-9e21aff8ea97)
Closes#4739
Release Notes:
- Added new `diagnostics: deploy current file` command to view
diagnostics for the currently open file
---------
Co-authored-by: Conrad Irwin <conrad.irwin@gmail.com>
Closes #ISSUE
Fixed an issue where the first frame of the `Editing` page in onboarding
would have a slight delay before rendering the first time it was
navigated to. This was caused by listing the OS fonts on the main
thread, blocking rendering. This PR fixes the issue by adding a new
method to the font family cache to prefill the cache on a background
thread.
Release Notes:
- N/A *or* Added/Fixed/Improved ...
---------
Co-authored-by: Mikayla Maki <mikayla.c.maki@gmail.com>
Co-authored-by: Anthony Eid <hello@anthonyeid.me>
Co-authored-by: Anthony <anthony@zed.dev>
This is an implementation of matching like "m i (", as well as "] (" and
"[ (" in `helix_mode` with a few supported objects and a basis for more.
Release Notes:
- Added helix operators for selecting text objects
---------
Co-authored-by: Conrad Irwin <conrad.irwin@gmail.com>
Closes#35712
Release Notes:
- Fixed white-space trimming leading to disconnect between list items
and content in markdown previews.
---------
Co-authored-by: Bennet Bo Fenner <bennetbo@gmx.de>
Check whether the GPU/driver supports the StructuredBuffer feature
required by our shaders. If it doesn’t, log an error and skip that
GPU/driver, so Windows can fall back to the software renderer.
Release Notes:
- N/A
It is unused and generates a warning
```
LINK : warning LNK4044: unrecognized option '/fuse-ld=lld'; ignored
```
If in the future we want to give `lld-link.exe` a try, we can set
```toml
linker = "lld-link.exe"
```
instead. At the time of writing, my tests have shown that there is no
real difference between `lld-link` and `link` in terms of linking speed.
Release Notes:
- N/A
I ran `scripts/linux` on Debian Trixie 13. It suggested manually
installing Mold, but [mold](http://packages.debian.org/mold) is packaged
on Debian and so we could install it automatically.
The version packaged there seems to work well enough for `cargo t` to
pass, at least.
## Tested
```
; sudo apt remove mold libstdc++-14-dev
... uninstalls them
; ./script/linux
The following NEW packages will be installed:
build-essential clang clang-19 clang-tools-19 g++ g++-14 g++-14-x86-64-linux-gnu g++-x86-64-linux-gnu libstdc++-14-dev mold
; cargo t
(passes)
```
Release Notes:
- N/A
Previously, `cargo test --package component` failed due to missing
imports for a doctest:
```
Doc-tests component
running 1 test
test crates/component/src/component.rs - Component::description (line 229) ... FAILED
failures:
---- crates/component/src/component.rs - Component::description (line 229) stdout ----
error: cannot find derive macro `Documented` in this scope
--> crates/component/src/component.rs:231:10
|
4 | #[derive(Documented)]
| ^^^^^^^^^^
error[E0599]: no associated item named `DOCS` found for struct `MyComponent` in the current scope
--> crates/component/src/component.rs:236:20
|
5 | struct MyComponent;
| ------------------ associated item `DOCS` not found for this struct
...
9 | Some(Self::DOCS)
| ^^^^ associated item not found in `MyComponent`
error: aborting due to 2 previous errors
For more information about this error, try `rustc --explain E0599`.
Couldn't compile the test.
failures:
crates/component/src/component.rs - Component::description (line 229)
test result: FAILED. 0 passed; 1 failed; 0 ignored; 0 measured; 0 filtered out; finished in 0.29s
error: doctest failed, to rerun pass `-p component --doc`
bobcat ~/src/zed (doctests) 18:33
```
This might be unnoticed if you mostly run nextest, as it does not run
doctests.
Release Notes:
- N/A
Follow-up: #36700
This PR adds basic support for showing images inline inside a text.
As you can see inside the before screenshot, the image was displayed
right below the `Some inline text` text. This was because we didn't
consider the image to be inline with the text (paragraph). Now we do :)
All the test changes are making sure it is not more than 1 element
parsed, instead of only checking for the first parsed element. This
could work out bad when we return more than 1 result.
**Before**
<img width="1717" height="1344" alt="Screenshot 2025-08-31 at 13 49 45"
src="https://github.com/user-attachments/assets/13c5f9dd-0e0a-4e08-b2a6-28e9a4e0cab8"
/>
**After**
<img width="1719" height="1343" alt="Screenshot 2025-08-31 at 13 42 14"
src="https://github.com/user-attachments/assets/bf7aa82f-3743-4fb3-87aa-4a97a550c4d1"
/>
**Code example**:
```markdown
<p>some inline text <img src="https://picsum.photos/200/300" alt="Description of image" style="height: 100px" /> asdjkflsadjfl</p>
# Html Tag
<img src="https://picsum.photos/200/300" alt="Description of image" />
# Html Tag with width and height
<img src="https://picsum.photos/200/300" alt="Description of image" width="100" height="200" />
# Html Tag with style attribute with width and height
<img src="https://picsum.photos/200/300" alt="Description of image" style="width: 100px; height: 200px" />
# Normal Tag

```
Release Notes:
- Markdown: Added support for inline HTML `img` tags inside paragraphs
Closes#37093
Also check this: #37099.
So currently in zed for both OpenAI and OpenAI Compatible provider when
the url is changed from settings the api_key stored in the provider
state is not cleared and it is still used. But if you restart zed the
api_key is cleared. Currently zed uses the api_url to store and fetch
the api key from credential provider. The behaviour is not changed
overall, it's just that we have made it consistent it with the zed
restart logic where it re-authenticates and fetches the api_key again. I
have attached the video below to show case before and after of this.
So all in all the problem was we were not re-authenticating the in case
api_url change while zed is still running. Now we trigger a
re-authentication and clear the state in case authentication fails.
OpenAI Compatible Provider:
| Before | After |
|--------|--------|
| <video
src="https://github.com/user-attachments/assets/324d2707-ea72-4119-8981-6b596a9f40a3"
/> | <video
src="https://github.com/user-attachments/assets/cc7fdb73-8975-4aaf-a642-809bb03ce319"
/> |
OpenAI Provider:
| Before | After |
|--------|--------|
| <video
src="https://github.com/user-attachments/assets/a1c07d1b-1909-4b49-b33c-fc05123e92e7"
/> | <video
src="https://github.com/user-attachments/assets/d78aeccd-5cd3-4d0c-8b9f-6f98e499d7c8"
/> |
Release Notes:
- Fixed OpenAI and OpenAI Compatible provide API keys being persisted
when changing the API URL setting. Authentication is now properly
revalidated when settings change.
---------
Signed-off-by: Umesh Yadav <git@umesh.dev>
Fix an issue that resulted in Ollama models not being able to not being
able to access the input of the commands they executed (only being able
to access the result).
This properly return the function history as shown in
https://github.com/ollama/ollama/blob/main/docs/api.md#chat-request-with-history-with-tools
Previously, function input where not returned and result where returned
as a "user" role.
Release Notes:
- ollama: Improved format when returning tool results to the models
Closes#37597
Release Notes:
- N/A
---
## Problem
When using "Tab Switcher: Toggle All", temporary files (untitled buffers
without associated file paths) cannot be searched by their displayed
content. This creates an inconsistent user experience where:
- **UI Display**: Shows dynamic titles based on the first line of
content (up to 40 characters)
- **Search Text**: Only searches for the static text "untitled"
### Example
- A temporary file containing `Hello World` is displayed as "Hello
World" in the tab
- However, searching for "Hello" in Tab Switcher returns no results
- Only searching for "untitled" will find this temporary file
## Root Cause
The issue stems from inconsistent title generation logic between display
and search:
1. **Display Title** (`items.rs:724`): Uses `self.title(cx)` →
`MultiBuffer::title()` → `buffer_content_title()`
- Returns the first line of content (max 40 chars) for temporary files
2. **Search Text** (`items.rs:650-656`): Uses `tab_content_text()`
method
- Returns hardcoded "untitled" for files without paths
## Solution
Modified the `tab_content_text()` method in `crates/editor/src/items.rs`
to use the same logic as the displayed title for consistency:
```rust
fn tab_content_text(&self, detail: usize, cx: &App) -> SharedString {
if let Some(path) = path_for_buffer(&self.buffer, detail, true, cx) {
path.to_string_lossy().to_string().into()
} else {
// Use the same logic as the displayed title for consistency
self.buffer.read(cx).title(cx).to_string().into()
}
}
```
Also:
* Adds tests for can_collect_data.
* Temporarily removes collection of diagnostics.
Release Notes:
- Edit Prediction: Fixed a bug where requests were marked eligible for
data collection despite the recent edit history in the request involving
files that may not be open source. The requests affected by this bug
will not be used in training data.
Minor docs fix.
Seems like 0a4ff2f475 accidentally added
"hidden" to the docs of both – `close_position` and `show_close_button`.
Release Notes:
- N/A
Co-authored-by: tastenbier <>
Follow-up of https://github.com/zed-industries/zed/pull/37352
Closes https://github.com/zed-industries/zed/issues/37132
* disabled word completions in the agent panel's editor
* if not disabled, allow to trigger word completions with an action even
if the completions threshold is not reached
Release Notes:
- Fixed word completions appearing in the agent panel's editor and not
appearing when triggered with the action before the completion threshold
is reached
This PR switches the OpenRouter integration from fetching all models to
fetching only the models specified in the user's account preferences.
This will help improve the experience
**The Problem**
The previous implementation used the `/models` endpoint, which returned
an exhaustive list of all models supported by OpenRouter. This resulted
in a long and cluttered model selection dropdown in Zed, making it
difficult for users to find the models they actually use.
**The Solution**
We now use the `/models/user` endpoint. This API call returns a curated
list based on the models and providers the user has selected in their
[OpenRouter dashboard](https://openrouter.ai/models).
Ref: [OpenRouter API Docs for User-Filtered
Models](https://openrouter.ai/docs/api-reference/list-models-filtered-by-user-provider-preferences)
Release Notes:
- language_models: Support OpenRouter user preferences for available
models
Closes#37302
Related: #37614
In case of open_ai_compatible providers like Zhipu AI and z.ai they
return empty content along with usage data. below is the example json
captured from z.ai. We now ignore empty content returned by providers
now to avoid this issue where we would return the same empty content
back to provider which would error out.
```
OpenAI Stream Response JSON:
{
"id": "2025090518465610d80dc21e66426d",
"created": 1757069216,
"model": "glm-4.5",
"choices": [
{
"index": 0,
"finish_reason": "tool_calls",
"delta": {
"role": "assistant",
"content": ""
}
}
],
"usage": {
"prompt_tokens": 7882,
"completion_tokens": 150,
"total_tokens": 8032,
"prompt_tokens_details": {
"cached_tokens": 7881
}
}
}
```
Release Notes:
- Skip empty delta text content in OpenAI and OpenAI compatible provider
Signed-off-by: Umesh Yadav <git@umesh.dev>
Closes#37473
### Background
Previously, we enabled foreign keys at all times for our sqlite database
that we use for client-side state.
The problem with this is that In sqlite, `alter table` is somewhat
limited, so for many migrations, you must *recreate* the table: create a
new table called e.g. `workspace__2`, then copy all of the data from
`workspaces` into `workspace__2`, then delete the old `workspaces` table
and rename `workspaces__2` to `workspaces`. The way foreign keys work in
sqlite, when we delete the old table, all of its associated records in
other tables will be deleted due to `on delete cascade` clauses.
Unfortunately, one of the types of associated records that can be
deleted are `editors`, which sometimes store unsaved text. It is very
bad to delete these records, as they are the *only* place that this
unsaved text is stored.
This has already happened multiple times as we have migrated tables as
we develop Zed, but I caused it to happened again in
https://github.com/zed-industries/zed/pull/36714.
### The Fix
The Sqlite docs recommend a multi-step approach to migrations where you:
* disable foreign keys
* start a transaction
* create a new table
* populate the new table with data from the old table
* delete the old table
* rename the new table to the old name
* run a foreign key check
* if it passes, commit the transaction
* enable foreign keys
In this PR, I've adjusted our sqlite migration code path to follow this
pattern more closely. Specifically, we disable foreign key checks before
running migrations, run a foreign key check before committing, and then
enable foreign key checks after the migrations are done.
In addition, I've added a generic query that we run *before* running the
foreign key check that explicitly deletes any rows that have dangling
foreign keys. This way, we avoid failing the migration (and breaking the
app) if a migration deletes data that *does* cause associated records to
need to be deleted.
But now, in the common case where we migrate old data in the new table
and keep the ids, all of the associated data will be preserved.
Release Notes:
- Fixed a bug where workspace state would be lost when upgrading from
Zed 0.201.x. or below.
- **toolchains: Add new state to toolchain selector**
- **Use toolchain term for Add Toolchain button**
- **Hoist out a meta function for toolchain listers**
Closes#27332
Release Notes:
- python: Users can now specify a custom path to their virtual
environment from within the picker.
---------
Co-authored-by: Danilo Leal <daniloleal09@gmail.com>
Closes#36978
This PR fixes an issue that we would only show the first `root -> child`
session in compact mode, but the session that came after it, we would
only show the child session label instead of also adding the parent
label due to compact mode.
## Before
<img width="348" height="173" alt="Screenshot 2025-08-27 at 22 18 39"
src="https://github.com/user-attachments/assets/ad6afd3a-196d-497f-812a-00698676ee90"
/>
## After
<img width="563" height="211" alt="Screenshot 2025-08-27 at 21 57 16"
src="https://github.com/user-attachments/assets/a953ef2a-a796-4160-b868-96e96f81c858"
/>
With 3 parent + child sessions and one parent session only.
<img width="484" height="223" alt="Screenshot 2025-08-27 at 22 22 13"
src="https://github.com/user-attachments/assets/a26f79a4-63a5-43d0-a714-d62cb1995e6e"
/>
cc @cole-miller I know we hacked on this some while ago, so figured you
might be the best guy to ask for a review.
Release Notes:
- Debugger: Fix to allow showing more than 1 compact session item
---------
Co-authored-by: Anthony <anthony@zed.dev>
Closes#37520
This change makes the attach modal load processes from the remote server
when connecting via SSH, rather than showing local processes from the
client machine.
This works by using the new GetProcessesRequest RPC message to allow
downstream clients to get the correct processes to display. It also only
works with downstream ssh clients because the message handler is only
registered on headless projects.
Release Notes:
- debugger: Fix bug where SSH attach modal showed local processes
instead of processes from the server
Bug:
<img width="196" height="95" alt="Screenshot 2025-09-06 at 1 21 39 AM"
src="https://github.com/user-attachments/assets/66ec0fc9-961e-4289-bd75-68b24dad485e"
/>
The fold marker we use, `⋯`, isn’t rendered at the same size as the
editor’s font. Notice how the fold marker appears larger than the same
character typed directly in the editor buffer.
<img width="146" height="82" alt="image"
src="https://github.com/user-attachments/assets/a059d221-6b55-4cf9-bc1e-898ff5444006"
/>
When we shape the line, we use the editor’s font size, and it ends up
determining the element’s width. To fix this, we should treat the
ellipsis as a UI element rather than a buffer character, since current
visual size looks good to me.
<img width="196" height="95" alt="Screenshot 2025-09-06 at 1 29 28 AM"
src="https://github.com/user-attachments/assets/1b766d46-00ab-40c7-b98a-95ea2d4b29bf"
/>
Release Notes:
- Fixed an issue where the fold placeholder’s hover area was smaller
than the marker.
Follow-up to https://github.com/zed-industries/zed/pull/37489
Notification panel settings were always missing the content, hence this
PR adds it. After #37489, the use of the same content twice broke
things, which currently makes the notification panel non-configurable on
Nightly. This PR fixes this.
There once was an issue about the documentation for the panel being
wrong as well. However, I was just unable to find that sadly.
Release Notes:
- N/A
Co-Authored-By: Brandan <b5@n0.computer>
Release Notes:
- Added a new action `terminal::Toggle` that is by default bound to
'ctrl-\`'. This copies the default behaviour from VSCode and Jetbrains
where the terminal opens and closes correctly. If you'd like the old
behaviour you can rebind 'ctrl-\`' to `terminal::ToggleFocus`
Co-authored-by: Brandan <b5@n0.computer>
This commit updates the implementation for
`editor::Editor.manipulate_text` to use
`editor::selections_collection::SelectionsCollection.all_adjusted`
instead of `editor::selections_collection::SelectionsCollection.all`, as
the former takes into account the selection's `line_mode`, fixing the
issue where, if an user was in vim's visual line mode, running the
`editor: convert to upper case` command would not work as expected.
Closes#36953
Release Notes:
- Fixed bug where using the editor's convert case commands while in
vim's Visual Line mode would not work as expected
macOS versions are currently reported as `macOS 26.0.0`.
But this makes it impossible to differentiate amongst macOS Beta
releases which have the same version number (`X.0.0`) but are different
builds.
This PR adds build number info to `os_version` for macOS Betas and
[Rapid Security Response](https://support.apple.com/en-us/102657)
release that have identical version numbers to stable release, but have
different builds numbers. We can differentiate them because the build
numbers end with a letter.
| Version | Before | After |
| - | - | - |
| macOS Sonoma 14.7.8 | 14.7.8 | 14.7.8 |
| macOS Sequoia 15.6.1 | 15.6.1 | 15.6.1 |
| mcOS Ventura 13.3.1 | 13.3.1 | 13.3.1 |
| macOS Ventura 13.3.1 (a) | 13.3.1 | 13.3.1 (Build 22E772610a) |
| macOS Tahoe 26.0.0 (Beta1) | 26.0.0 | 26.0.0 (Build 25A5316a) |
| macOS Tahoe 26.0.0 (Beta5) | 26.0.0 | 26.0.0 (Build 25A5349a) |
This should cause minimal telemetry changes and only impacting a macOS
betas and a couple specific older macOS versions, but will allow
differentiation between macOS beta releases in GitHub issues.
Alternatives:
1. Leave as-is (can't differentiate between macOS beta builds)
2. Always include build number info (impacts telemetry; more consistent
going forward; differentiates non-final Release Candidates which don't
include a trailing letter)
I couldn't find a cocoa method to retrieve macOS build number, so I
switched dependencies from `cocoa` to `objc2-foundation` in the client
crate. We already depend upon this crate as a dependency of
`blade-graphics` so I matched the features of that and so workspace-hack
doesn't change.
1ebc69a447/tooling/workspace-hack/Cargo.toml (L355)
Release Notes:
- N/A
This is a small fix for default values in task variables. The
[documentation](https://zed.dev/docs/tasks) states
> You can also use verbose syntax that allows specifying a default if a
given variable is not available: ${ZED_FILE:default_value}
I found, however, that this doesn't actually work. Instead, the Zed
variable and the default value are just appended in the output. For
example, if I run a task `echo ${ZED_ROW:100}` the result I get is
`447:100` (in this case it should just be `447`).
This PR fixes that. I also added a new test case for handling default
values.
I also tested the fix in a dev build and it seems to work.
There are no UI adjustments.
AI disclosure: I used Claude Code to write the code, including the fix
and the tests.
This is actually my first open-source PR ever, so if I did something
wrong, I'd appreciate any tips and I'll make it right!
Release Notes:
- Fixed task variable substitution always appending the default
In an effort to improve the experience while developing extensions and
improving themes, this PR updates the syntax tree views behavior
slightly.
Before, the view would always update to the current active editor whilst
being used. This was quite painful for improving extension scheme files,
as you would always have to change back and forth between editors to
have a view at the relevant syntax tree.
With this PR, the syntax tree view will now stay attached to the editor
it was opened in, similar to preview views. Once the view is shown, the
`UseActiveEditor` will become available in the command palette and
enable the user to update the view to the last focused editor. On file
close, the view will also be updated accordingly.
https://github.com/user-attachments/assets/922075e5-9da0-4c1d-9e1a-51e024bf41ea
A button is also shown whenever switching is possible.
Futhermore, improved the empty state of the view.
Lastly, a drive-by cleanup of the `show_action_types` method so there is
no need to call `iter()` when calling the method.
Release Notes:
- The syntax tree view will now stay attached to the buffer it was
opened in, similar to the Markdown preview. Use the `UseActiveEditor`
action when the view is shown to change it to the last focused editor.
Doesn't fix anything, but it seems that we do not need to assert and
convert into an error until after the closure run to completion,
especially since this is the only error we throw.
Release Notes:
- N/A
This isn't quite right, but using the env manager path causes conda to
scream and I am not yet sure why, either way this is an improvement over
the status quo
Release Notes:
- N/A\
The `test` attribute doesn't really matter to rust-analyzer, so we can
make use of its cfg to have it think its just the standard test
attribute which should make rust-analyzer slightly less resource
intensive in zed. It also should prevent some IDE features from possibly
failing within tests.
Notably this has no effect outside of this repo, as the `rust-analyzer`
cfg only takes effect on workspace member crates.
Ideally we'd use the ignored proc macro config here but rust-analyzer
still doesn't have toml configs working unfortunately.
Release Notes:
- N/A
Removes IME bounds scaling on Wayland since it uses logical pixels,
unlike X11. We now scale only on X11. Windows and macOS don’t use these
bounds for IME anyway.
Release Notes:
- Fixed an issue where the IME popover could appear outside the window
or fail to show on Wayland.
This change also causes Zeta to not do anything for editors that are not
associated with a project. In practice, this shouldn't affect any
behavior - those editors shouldn't have edit predictions anyway.
Release Notes:
- Edit Prediction: Requests no longer include recent edits from other
projects (other Zed windows).
This PR improves the settings_ui proc macro by taking into account more
serde attributes
1. rename_all
2. rename
3. flatten
We also pass field documentation to the UI layer now too. This allows ui
elements to have more information like the switch field description.
We got the scrollbar working and started getting language settings to
show up.
Release Notes:
- N/A
---------
Co-authored-by: Ben Kunkle <ben@zed.dev>
Closes#37469
Release Notes:
- agent: The project shell environment is now passed to external agent
processes.
Co-authored-by: Richard Feldman <oss@rtfeldman.com>
Co-authored-by: Nia Espera <nia-e@haecceity.cc>
This PR updates the default configuration of the `snippets` extension to
disable suggesting paths (`feature_paths`).
If users want to enable it, it can be done via the settings:
```json
{
"lsp": {
"snippet-completion-server": {
"settings": {
"feature_paths": true
}
}
}
}
```
Release Notes:
- N/A
This PR adds a configuration example for the
`simple-completion-language-server`.
We show the user how to re-enable the `feature_paths` option, as we're
now disabling it by default
(https://github.com/zed-industries/zed/pull/37565).
Release Notes:
- N/A
This PR separates out the associated constant `KEY` from the `Settings`
trait into a new trait `SettingsKey`. This allows for the key trait to
be derived using attributes to specify the path so that the new
`SettingsUi` derive macro can use the same attributes to determine top
level settings paths thereby removing the need to duplicate the path in
both `Settings::KEY` and `#[settings_ui(path = "...")]`
Co-authored-by: Ben Kunkle <ben@zed.dev>
Release Notes:
- N/A
---------
Co-authored-by: Ben Kunkle <ben@zed.dev>
This PR updates the TOML docs to remove references to Taplo and suggest
the Tombi extension for users wanting language server support.
Relates to https://github.com/zed-industries/zed/issues/36766.
Release Notes:
- N/A
The crash was caused by not accounting for the fact that a range of
collapse frames only counts as one entry. Causing the filter indices to
overshoot for indices after collapse frames (it was counting all
collapse frames instead of just one).
The test missed this because it all happened in one `cx.update` closure
and didn't render the stack frame list when the filter was applied. The
test has been updated to account for this.
Release Notes:
- N/A
Co-authored-by: Cole Miller <cole@zed.dev>
Updates blade-graphics from e0ec4e7 to bfa594e to fix GPU crashes on
Wayland with AMD graphics cards.
The crash was caused by incorrect BLAS scratch buffer alignment - the
old version hardcoded 256-byte alignment, but AMD GPUs require different
alignment values. The newer Blade version uses the GPU's actual
alignment requirements instead of hardcoding.
Closes#37448
Release Notes:
- Migrate to newer version of Blade upstream
Since Claude Code has it's own preferred method of grabbing API keys, we
don't want to reuse this one.
Release Notes:
- acp: Don't share Anthropic API key from the Anthropic provider to
allow default Claude Code login options
---------
Co-authored-by: Agus Zubiaga <agus@zed.dev>
Extracts and cleans up GPUI's scheduler code into a new `scheduler`
crate, making it pluggable by external runtimes. This will enable
deterministic integration testing with cloud components by providing a
unified test scheduler across Zed and backend code. In Zed, it will
replace the existing GPUI scheduler for consistent async task management
across platforms.
## Changes
- **Core Implementation**: `TestScheduler` with seed-based
randomization, session tracking (`SessionId`), and foreground/background
task separation for reproducible testing.
- **Executors**: `ForegroundExecutor` (!Send, thread-local) and
`BackgroundExecutor` (Send, with blocking/timeout support) as
GPUI-compatible wrappers.
- **Clock and Timer**: Controllable `TestClock` and future-based `Timer`
for time-sensitive tests.
- **Testing APIs**: `once()`, `with_seed()`, and `many()` methods for
configurable test runs.
- **Dependencies**: Added `async-task`, `chrono`, `futures`, etc., with
updates to `Cargo.toml` and lock file.
## Benefits
- **Integration Testing**: Facilitates reliable async tests involving
cloud sessions, reducing flakiness via deterministic execution.
- **Pluggability**: Trait-based design (`Scheduler`) allows easy
integration into non-GPUI runtimes while maintaining GPUI compatibility.
- **Cleanup**: Refactors GPUI scheduler logic for clarity, correctness
(no `unwrap()`, proper error handling), and extensibility.
Follows Rust guidelines; run `./script/clippy` for verification.
- [x] Define and test a core scheduler that we think can power our cloud
code and GPUI
- [ ] Replace GPUI's scheduler
Release Notes:
- N/A
---------
Co-authored-by: Antonio Scandurra <me@as-cii.com>
Now we only keep a single copy of the GPU device. The GPU lost handling
got broken after #35376, but it’s properly handled again now.
Release Notes:
- N/A
This PR cleans up some emitted events around the codebase. These events
are either never emitted or never listened for.
It seems better to re-implement these at some point should they again be
needed - this ensures that they will actually be fired in the cases
where they are needed as opposed to being there and getting unreliable
and stale (which is already the case for the majority of the events
removed here).
Lastly, this ensures the `CapabilitiesChanged` event is not fired too
often.
Release Notes:
- N/A
Added schemars annotations to generate inline enums instead of
references ($ref) in the JSON schema passed to LLMs.
Concerns :
- "timezeone" parameter for "now" tool function
- "mode" parameter for "edit_file" tool function
Should be the same for futures tools/functions enums. This is easier for
LLMs to understand the schema since many of them don't use JSON
references correctly.
Tested with :
- local GPT-OSS-120b with llama.cpp server (openai compatible)
- remote Claude Sonnet 4.0 with Zed pro subscription
Thanks in advance for the merge.
(notice this is my first PR ever on Github, I hope I'm doing things
well, please let me know if you have any comment - edit: just noticed my
username/email were not correctly setup on my local git, sorry, it's
been 5 years I've not used git)
Closes#37389
Release Notes:
- agent: Improve "now" and "edit_file" tool schemas to work with more
models.
The example was still showing how we used to setup openai compatible
providers, but that format should only be used for changing the url for
your actual OpenAI provider.
If you are doing a compatible provider, it should be using the new
format.
Closes#37093
Release Notes:
- N/A
Closes#37289
The current implementation has a problem. The **`from_id` method** in
the Anthropic crate works well for predefined models, but not for custom
models that are defined in the settings. This is because it fallbacks to
using default beta headers, which are incorrect for custom models.
The issue is that the model instance for custom models lives within the
`language_models` provider, so I've updated the **`stream_completion`**
method to explicitly accept beta headers from its caller. Now, the beta
headers are passed from the `language_models` provider all the way to
`anthropic.stream_completion`, which resolves the issue.
Release Notes:
- Fixed a bug where extra_beta_headers defined in settings for Anthropic
custom models were being ignored.
---------
Signed-off-by: Umesh Yadav <git@umesh.dev>
Closes #ISSUE
Centralizes the references to the `ZED_STATELESS` env var into a single
location in a new crate named `zed_env_vars`
Release Notes:
- N/A *or* Added/Fixed/Improved ...
Some users asked whether Claude Code in Zed can also observe/consume
`CLAUDE.md` guidelines, regardless of whether they're at the root
`.claude` directory or within the project. Answer is yes and the
documentation will mention it now!
Release Notes:
- N/A
This reverts commit bf5ed6d1c9.
We believe this may be breaking some users whose shell initialization
scripts change the working directory.
Release Notes:
- N/A
Rendering the disclosure button last (on the far right of the header
container) to avoid awkward layouts when there's truncation and elapsed
time information being displayed.
Release Notes:
- N/A
This reverts commit 40199266b6.
The issue with the commit is: ContentMask<Pixels>::intersect is doing
intersection of corner radii which makes inner containers use the max
corner radius out of all the parents when it should be more complex to
correctly clip children (clip sorting..?)
Release Notes:
- N/A
Related to #37213, #37150
When listing previously-downloaded versions of an external agent, don't
try to use any downloads that are missing the agent entrypoint
(indicating that they're corrupt/unusable), and delete those versions,
so that we can attempt to download the latest version again.
Also report clearer errors when failing to start a session due to an
agent server entrypoint or root directory not existing.
Release Notes:
- N/A
Closes #ISSUE
Adds a test that checks that all settings have default values in
`default.json`. Currently only tests that settings supported by
SettingsUi have defaults, as more settings are added to the settings
editor they will be added to the test as well.
Release Notes:
- N/A *or* Added/Fixed/Improved ...
We don’t know the background color behind a non-opaque editor, so we
should skip contrast correction in that case. This prevents
single-editor mode (which is always transparent) from showing weird text
colors when text is selected.
We can’t account for the actual background during contrast correction
because we compute contrast outside gpui, while the actual color
blending happens inside gpui during drawing.
<img width="522" height="145" alt="image"
src="https://github.com/user-attachments/assets/6ee71475-f666-482d-87e6-15cf4c4fceef"
/>
Release Notes:
- Fixed an issue where Command Palette text looked faded when selected.
Closes https://github.com/zed-industries/zed/issues/37144
Adjusts `editor::DeleteToPreviousWordStart`,
`editor::DeleteToNextWordEnd`, `editor::DeleteToNextSubwordEnd` and
`editor::DeleteToPreviousSubwordStart` actions to
* take whitespace sequences with length >= 2 into account and stop after
removing them (whilst movement would also include the word after such
sequences)
* take current language's brackets into account and stop after removing
the text before them
The latter is configurable and can be disabled with `"ignore_brackets":
true` parameter in the action.
Release Notes:
- Improved word deletions to consider whitespace sequences and brackets
by default
With `reveal_stragegy=always` + `reveal_target=center`,
`TerminalPanel::spawn_task` activates & focuses the pane of the task.
This works fine in the terminal pane but doesn't for
`reveal_target=center`.
Please note: I'm not verified familiar with the architecture and
internal APIs of zed. If there's a better way or if this fix is a bad
idea, I'm fine with adapting this 😃Closes#35908
Release Notes:
- Fixed task focus when re-spawning a task with `reveal_target=center`
---------
Co-authored-by: Marshall Bowers <git@maxdeviant.com>
### First issue
In the scenario where you have an API key configured in Zed and you run
`/logout`, clicking on `Use Anthropic API Key` would show `Method not
implemented`.
This happened because we were only intercepting the `Use Anthropic API
Key` click if the provider was NOT authenticated, which would not be the
case when the user has an API key set.
### Second issue
When clicking on `Reset API Key` the modal would be dismissed even
though you picked no Authentication Method (which means you still would
be unauthenticated)
---
This PR fixes both of these issues
Release Notes:
- N/A
When the first visible worktree is a single-file worktree, we would
previously try to use the absolute path of that file as the root
directory for external agents, causing an error. This PR changes how we
handle this situation: we'll use the root of the first non-single-file
visible worktree if there are any, and if there are none, the parent
directory of the first single-file visible worktree.
Related to #37213
Release Notes:
- acp: Fixed being unable to run external agents when a single file (not
part of a project) was opened in Zed.
The only warnings remaining are links to private modules/items, but I
lack knowledge to work out if the referenced modules/items should be
made public, or if the links should be rewritten into exposed
traits/items.
Links to associated items such as trait implementations have to be
written using full markdown format such as:
... [[ `App::update_global` ]](( BorrowAppContext::update_global ))
This is due to https://github.com/rust-lang/rust/issues/74563 which
sadly prohibits fully-qualified syntax:
... [[ `<App as BorrowAppContext>::update_global` ]]
Release Notes:
- N/A
Probably related to https://github.com/zed-industries/zed/pull/37072
When doing stable/preview releases simultaneously there are two tags and
two branches pushed. Previously nix was attempting 1 job for each. Our
current mac parallelism is 4.
Can't easily test this. 🤷
Release Notes:
- N/A
We'll just SSH into the Windows runners and look for crashes there.
Reverts #35926
Release Notes:
- N/A
---------
Co-authored-by: Peter Tripp <petertripp@gmail.com>
Closes: #32668
- Add
[tool_call_timeout_millis](https://github.com/cline/cline/pull/1904)
field to ContextServerCommand, like in Cline
- Update ModelContextServerBinary to include timeout configuration
- Modify Client to store and use configurable request timeout
- Replace hardcoded REQUEST_TIMEOUT with self.request_timeout
- Rename REQUEST_TIMEOUT to DEFAULT_REQUEST_TIMEOUT for clarity
- Maintain backward compatibility with 60-second default
Release Notes:
- context_server: Add support for configurable timeout for MCP tool
calls
---------
Co-authored-by: Ben Brandt <benjamin.j.brandt@gmail.com>
- I believe this is caused by metal not being found due to it being on
the XcodeBeta path, not sure if there's a better fix for this but it'll
work until 26 is the latest release
Release Notes:
- N/A
Hi! As part of https://github.com/zed-extensions/ruby/issues/162 we
would like to rename HTML/ERB to HTML+ERB since it is more syntactically
correct to treat such language as ERB on top of HTML rather than HTML or
ERB.
To keep the user experience intact, we outlined the prerequisites in the
linked issue. This is the first PR that adds the HTML+ERB language name
to the list of enabled languages for the Emmet extension. We will do the
same for the Tailwind configuration in the Zed codebase. Once the new
versions of Emmet and Zed are released, we will merge the pull request
in the Ruby extension repository and release the updated version. After
that, we will remove the old HTML/ERB and YAML/ERB languages. Let me
know if that sounds good. Thanks!
Release Notes:
- N/A
Co-authored-by: Marshall Bowers <git@maxdeviant.com>
Closes#32758
Release Notes:
- Resolved an issue with the Ollama provider that caused requests to
fail with a 400 error for models that don't support tools. The tools
object is now only sent to compatible models to ensure successful
requests.
Follow up: #34532Closes#35434
Mostly fixes a issue were when the tool_choice is none it was getting
serialised as null. This was fixed for openrouter just wanted to follow
up and cleanup for other providers which might have this issue as this
is against the spec.
Release Notes:
- N/A
Follow up to https://github.com/zed-industries/zed/pull/30598
This PR introduces the `display_options` field in the
`CompletionResponse`, allowing a code context menu width to be
dynamically dictated based on its larger item. This will allow us to
have the @-mentions and slash commands completion menus in the agent
panel not be bigger than it needs to be. It may also be relevant/useful
in the future for other use cases.
For now, we set all instances of code context menus to use a fixed
width, as defined in the PR linked above, which means this PR shouldn't
cause any visual change.
Release Notes:
- N/A
Co-authored-by: Michael Sloan <mgsloan+github@gmail.com>
This PR removes the `http_client` feature from the `gpui` crate, as it
wasn't really doing anything.
It only controlled whether we depend on the `http_client` crate, but
from what I can tell we always depended on it anyways.
Obviates https://github.com/zed-industries/zed/pull/36615.
Release Notes:
- N/A
Improves the error handling for openrouter and adds automatic retry like
anthropic for few of the status codes.
Release Notes:
- Improves error messages for Openrouter provider
- Automatic retry when rate limited or Server error from Openrouter
This commit fixes an issue with how the `AnyBrackets` object was handled
with change surrounds (`cs`). With the keymap below, if one was to use
`csb{` with the text `(bracketed)` and the cursor inside the
parentheses, the text would not change.
```json
{
"context": "vim_operator == a || vim_operator == i || vim_operator == cs",
"bindings": {
"b": "vim::AnyBrackets"
}
}
```
Unfortunately there was no implementation for finding a corresponding
`BracketPair` for the `AnyBrackets` object, meaning that, when using
`cs` (change surrounds) the code would simply do nothing.
This commit updates this logic so as to try and find the nearest
surrounding bracket (parentheses, curly brackets, square brackets or
angle brackets), ensuring that `cs` also works with `AnyBrackets`.
Closes#24439
Release Notes:
- Fixed handling of `AnyBrackets` in vim's change surrounds (`cs`)
Before we were setting up lots of test setup regardless of if we were
actually going to be making real requests or not.
This will hopefully help with intermittent test errors we're seeing on
Windows in CI.
Release Notes:
- N/A
Closes#37249
We no longer show edit prediction when composing IME since it isn't
useful for unfinished alphabet.
Release Notes:
- Fixed edit predictions showing up during partial IME composition.
Closes#37211
Regressed in https://github.com/zed-industries/zed/pull/33305
Every time the terminal updates, we emit
`SearchEvent::MatchesInvalidated` to trigger a re-run of the buffer
search, which calls `clear_matches` to drop stale results.
https://github.com/zed-industries/zed/pull/33305 PR also cleared the
selection when clearing matches, which caused this issue. We could fix
it by only clearing matches and selection when they’re non-empty, but
it’s better to not clear the selection at all. This matches how the
editor behaves and keeps it consistent. This PR reverts that part of
code.
Release Notes:
- Fixed an issue where text selection was lost during continuous
terminal output.
If we get back slash-commands that aren't supported, tell the user that
this is the problem.
Release Notes:
- Improve error messages for unsupported ACP slash-commands
---------
Co-authored-by: Conrad Irwin <conrad.irwin@gmail.com>
Closes#30188Closes#34911Closes#34906
Many OpenAI-compatible providers do not automatically filter the tool
schema to comply with the underlying model's requirements; they simply
proxy the request. This creates issues, as models like **Gemini**,
**Grok**, and **Claude** (when accessed via LiteLLM on Bedrock) are
incompatible with Zed's default tool schema.
This PR addresses this by defaulting to a more compatible schema subset
instead of the full schema.
### Why this approach?
* **Avoids Poor User Experience:** One alternative was to add an option
for users to manually set the JSON schema for models that return a `400
Bad Request` due to an invalid tool schema. This was discarded as it
provides a poor user experience.
* **Simplifies Complex Logic:** Another option was to filter the schema
based on the model ID. However, as demonstrated in the attached issues,
this is unreliable. For instance, `claude-4-sonnet` fails when proxied
through LiteLLM on Bedrock. Reliably determining behavior would require
a non-trivial implementation to manage provider-and-model combinations.
* **Better Default Behavior:** The current approach ensures that tool
usage works out-of-the-box for the majority of cases by default,
providing the most robust and user-friendly solution.
Release Notes:
- Improved tool compatibility with OpenAI API-compatible providers
Signed-off-by: Umesh Yadav <git@umesh.dev>
Co-authored-by: Peter Tripp <peter@zed.dev>
Right now if you open Zed, and we deserialize an agent that's behind a
feature flag (e.g. CC), we don't restore it because the feature flag
check hasn't happened yet at the time we're deserializing (due to auth
not having finished yet).
This is a simple fix: assume that if you had serialized it in the first
place, you must have had the feature flag enabled, so go ahead and
reopen it for you.
Release Notes:
- N/A
This commit fixes a bug with Zed's vim mode surrounds plugin when
dealing with replacing pairs with quote and the contents between the
pairs had some whitespace within them.
For example, with the following string:
```
' str '
```
If one was to use the `cs'"` command, to replace single quotes with
double quotes, the result would actually be:
```
"str"
```
As the whitespace before and after the closing character was removed.
This happens because of the way the plugin decides whether to add or
remove whitespace after and before the opening and closing characters,
repsectively. For example, using `cs{[` yields a different result from
using `cs{]`, the former adds a space while the latter does not.
However, since for quotes the opening and closing character is exactly
the same, this behavior is not possible, so this commit updates the code
in `vim::surrounds::Vim.change_surrounds` so that it never adds or
removes whitespace when dealing with any type of quotes.
Closes#12247
Release Notes:
- Fixed whitespace handling when changing surrounding pairs to quotes in
vim mode
This PR fixes an issue where extension operations would never show in
the activity indicator despite this being implemented for ages. This
happened because we were always returning `None` whenever the app has a
global auto updater, which is always the case, so the code path for
showing extension updates in the indicator could never be hit despite
existing prior. Also slightly improves the messages shown for ongoing
extension operations, as these were previously context unaware.
While I was at this, I also quickly took a stab at cleaning up some
remotely related stuff, namely:
- The `AnimationExt` trait is now by default only implemented for
anything that also implements `IntoElement`. This prevents
`with_animation` from showing up for e.g. `u32` within the suggestions
(finally).
- Commonly used animations are now implemented in the
`CommonAnimationExt` trait within the `ui` crate so the needed code does
not always need to be copied and element IDs for the animations are
truly unique.
Relevant change here regarding the original issue is the change from the
`return match` to just a `match` within the activitiy indicator, which
solved the issue at hand.
If we find this to be too noisy at some point, we can easily revisit,
but I think this holds important enough information to be shown in the
activity indicator, especially whilst developing extensions.
Release Notes:
- Extension installation and updates will now be shown in the activity
indicator.
Previously, we were using `PostThreadMessage` to pass messages to
`WindowsPlatform`. This PR switches to an approach similar to `winit`
which using a hidden window as the message window (I guess that’s why
winit uses a hidden window?). The difference is that this PR creates it
as a message-only window.
Thanks to @reflectronic for the original PR #37255, this implementation
just fits better with the current code style.
Release Notes:
- N/A
---------
Co-authored-by: reflectronic <john-tur@outlook.com>
On nightly, when I run `zed` under WSL, I get an error parsing the
shebang line
```
/usr/bin/env: ‘sh\r’: No such file or directory
```
I believe that this is because in CI, Git checks out the file with CRLF
line endings, and that is how it is copied into the installer.
Also, the file extension was incorrect when downloading the production
remote server (a gzipped binary), preventing extraction from working
properly.
Release Notes:
- N/A
This improves emoji rendering on windows removing artifacts at the edges
by using premultiplied alpha. A bit more context can be found in #37167
Release Notes:
- N/A
We render terminals as inline if their content is below a certain line
count, and scrollable past that point. In the scrollable case we weren't
setting a height for the terminal's container, causing it to be rendered
at height 0, which means no lines would be displayed. This PR fixes that
by setting an explicit height for the scrollable case, like we do in the
agent1 UI code.
Release Notes:
- agent: Fixed a bug that caused terminals in the panel to be empty
after their content reached a certain size.
Closes #ISSUE
Improves the derive macro for `SettingsUi` so that titles generated from
struct and field names are shown in title case, and toggle button groups
use title case for rendering, while using lower case/snake case in JSON
Release Notes:
- N/A *or* Added/Fixed/Improved ...
Closes #ISSUE
This PR includes the necessary work to get `EditorSettings` showing up
in the settings UI. Including making the `path` field on
`SettingsUiItem`'s optional so that top level items such as
`EditorSettings` which have `Settings::KEY = None` (i.e. are treated
like `serde(flatten)`) have their paths computed correctly for JSON
reading/updating.
It includes the first examples of a pattern I expect to continue with
the `SettingsUi` work with respect to settings reorganization, that
being adding missing defaults, and adding explicit values (or aliases)
to settings which previously relied on `null` being a value for optional
fields.
Release Notes:
- N/A *or* Added/Fixed/Improved ...
Closes #ISSUE
Initially, the `SettingsUi` trait was tied to `Settings`, however, given
that the `Settings::FileContent` type (which may be the same as the type
that implements `Settings`) will be the type that more directly maps to
the JSON structure (and therefore have the documentation, correct field
names (or `serde` rename attributes), etc) it makes more sense to have
the deriving of `SettingsUi` occur on the `FileContent` type rather than
the `Settings` type.
In order for this to work a relatively important change had to be made
to the derive macro, that being that it now "unwraps" options into their
inner type, so a field with type `Option<Foo>` where `Foo: SettingsUi`
will treat the field as if it were just `Foo`, expecting there to be a
default set in `default.json`. This imposes some restrictions on what
`Settings::FileContent` can be as seen in 1e19398 where `FileContent`
itself can't be optional without manually implementing `SettingsUi`, as
well as introducing some risk that if the `FileContent` type has
`serde(default)`, the default value will override the default value from
`default.json` in the UI even though it may differ (but it should!).
A future PR should probably replace the other settings with `FileContent
= Option<T>` (all of which currently have `T == bool`) with wrapper
structs and have `KEY = None` so the further niceties
`derive(SettingsUi)` will provide such as path renaming, custom UI, auto
naming and doc comment extraction can be used.
Release Notes:
- N/A *or* Added/Fixed/Improved ...
Closes #ISSUE
Adds a first draft of a way for "Dynamic" settings items to be added,
where Dynamic means settings where multiple sets of options are possible
(i.e. discriminated union, rust enum, etc). The implementation is very
similar to that of `Group`, except that instead of rendering all of it's
descendants, it contains a function to determine _which_ descendant to
render, whether that be a single item or a nested group of items.
Currently this is done in a type-unsafe way with indices, a future
improvement could be to make the API more type safe, and easier to
manually implement correctly.
An example of a "Dynamic" setting is `theme`, where it can either be a
string of the desired theme name, or an object with `mode: "light" |
"dark" | "system"` as well as theme names for `light` and `dark`. In the
system implemented by this PR, this would become a dynamic settings UI
item, where option `0` is a single item, the theme name selector, and
option `1` is a group, containing items for the `mode`, and
`light`/`dark` options.
Release Notes:
- N/A *or* Added/Fixed/Improved ...
This updates `editor: rewrap` to work within doc comments, based on the
code that extends such comments on newline. I added some tests, and I've
tested it out in JS, C and PHP. (Though PHP depends on
https://github.com/zed-extensions/php/pull/40)
Closes#19794Closes#18221
**Caveat:**
~~This will not rewrap an existing single-line block comment, such as
the one provided in #18221:~~ this will now rewrap as expected
```c
/* we can triangulate any convex polygon by picking a vertex and connecting it to the next two vertices; we first read two vertices, and then, for every subsequent vertex, we can form a triangle by connecting it to the first and previous vertex */
```
However, it will rewrap a similar comment if it is shaped like a doc
comment. In other words, this will rewrap as expected:
```c
/*
* we can triangulate any convex polygon by picking a vertex and connecting it to the next two vertices; we first read two vertices, and then, for every subsequent vertex, we can form a triangle by connecting it to the first and previous vertex
*/
```
This seems like a reasonable improvement and limitation to me,
especially as a first step.
cc @smitbarmase because I think that you've been making a lot of the
`newline` and `rewrap` changes recently. (Thank you for those, by the
way!)
Release Notes:
- Added support for rewrap in block comments.
---------
Co-authored-by: Smit Barmase <heysmitbarmase@gmail.com>
This PR fixes a typo in the Windows alpha correction shader that is now
caught by https://github.com/zed-industries/zed/pull/37314.
Another case that could be addressed by Bors.
Release Notes:
- N/A
Closes#36023
This improves font rendering quality by doing perceptual gamma+contrast
correction which makes font edges look nicer and more legible.
A comparison image: (left is old, right is new)
<img width="1638" height="854" alt="Screenshot 2025-08-29 140015"
src="https://github.com/user-attachments/assets/85ca9818-0d55-4af0-a796-19e8cf9ed36b"
/>
This is most noticeable on smaller fonts / low-dpi displays
Release Notes:
- Improved font rendering quality
Currently when we render text with differing styles adjacently we might
form a ligature between the text, causing the ligature forming
characters to take on one of the two styles. This can especially become
confusing when a ligature is formed between actual text and inlay hints.
Annoyingly, the only ways to prevent this with core text is to either
render each run separately, or to insert a zero-width non-joiner to
force core text to break the ligatures apart, as it otherwise will merge
subsequent font runs of the same fonts.
We currently do layouting on a per line basis and it is unlikely we want
to change that as it would incur a lot of complexity and annoyances to
merge things back into a line, so this goes with the other approach of
inserting ZWNJ characters instead.
Note that neither linux nor windows seem to currently render ligatures,
so this only concerns macOS rendering at the moment.
Release Notes:
- Fixed ligatures forming between real text and inlay hints on macOS
Follow up of https://github.com/zed-industries/zed/pull/33334
After chatting with @MrSubidubi we found out that he had an old defaults
setting (most likely from when he encountered a previous window tabbing
bug):
```
❯ defaults read dev.zed.Zed-Nightly
{
NSNavPanelExpandedSizeForOpenMode = "{800, 448}";
NSNavPanelExpandedSizeForSaveMode = "{800, 448}";
NSNavPanelExpandedStateForSaveMode = 1;
NSOSPLastRootDirectory = {length = 828, bytes = 0x626f6f6b 3c030000 00000410 30000000 ... dc010000 00000000 };
"NSWindow Frame NSNavPanelAutosaveName" = "557 1726 800 448 -323 982 2560 1440 ";
"NSWindowTabbingShoudShowTabBarKey-GPUIWindow-GPUIWindow-(null)-HT-FS" = 1;
}
```
> That suffix is AppKit’s fallback autosave name when no tabbing
identifier is set. It encodes the NSWindow subclass (GPUIWindow), plus
traits like HT (hidden titlebar) and FS (fullscreen).
Which explains why it only happened on the Nightly build, since each
bundle has it's own defaults. It also explains why the tabbar would
disappear when he activated the `use_system_window_tabs` setting,
because with that setting activated, the tabbing identifier becomes
"zed" (instead of the default one when omitted) for which he didn't have
the `NSWindowTabbingShoudShowTabBarKey` default.
The original implementation was perhaps a bit naive and relied fully on
macOS to determine if the tabbar should be shown. I've updated the code
to always hide the tabbar, if the setting is turned off and there is
only 1 tab entry.
While testing, I also noticed that the menu's like 'merge all windows'
wouldn't become active when the setting was turned on, only after a full
workspace reload. So I added a setting observer as well, to immediately
set the correct window properties to enable all the features without a
reload.
Release Notes:
- N/A
This PR fixes a deserialization issue in GitHub Copilot Chat that was
causing warnings when encountering xAI models from the GitHub Copilot
API and skipping the Grok model from model selector.
Release Notes:
- Fixed support for xAI models that are now available through GitHub
Copilot Chat.
Removes excess log which got through on each start of Zed
```
ERROR [agent_ui::language_model_selector] Failed to authenticate provider: Anthropic: credentials not found
```
The `AnthropicLanguageModelProvider::api_key` method returned a
`anyhow::Result` which would convert
`AuthenticateError::CredentialsNotFound` into a generic error because of
the implicit `Into` when using the `?` operator. This would then get
converted into a `AuthenticateError::Other` later.
By specifying the error type as `AuthenticateError`, we remove this
implicit conversion and the log gets removed.
Release Notes:
- N/A
`darwin.apple_sdk.frameworks` has been obsoleted and is no longer
required to be specified explicitly as per [Nixpkgs Reference
Manual](https://nixos.org/manual/nixpkgs/stable/#sec-darwin-legacy-frameworks).
@P1n3appl3 not sure what the process for updating Nix is, so lemme know
if this is desired/acceptable!
Release Notes:
- N/A
This PR contains the following updates:
| Package | Type | Update | Change |
|---|---|---|---|
| [tracing-subscriber](https://tokio.rs)
([source](https://redirect.github.com/tokio-rs/tracing)) | dependencies
| patch | `0.3.19` -> `0.3.20` |
### GitHub Vulnerability Alerts
####
[CVE-2025-58160](https://redirect.github.com/tokio-rs/tracing/security/advisories/GHSA-xwfj-jgwm-7wp5)
### Impact
Previous versions of tracing-subscriber were vulnerable to ANSI escape
sequence injection attacks. Untrusted user input containing ANSI escape
sequences could be injected into terminal output when logged,
potentially allowing attackers to:
- Manipulate terminal title bars
- Clear screens or modify terminal display
- Potentially mislead users through terminal manipulation
In isolation, impact is minimal, however security issues have been found
in terminal emulators that enabled an attacker to use ANSI escape
sequences via logs to exploit vulnerabilities in the terminal emulator.
### Patches
`tracing-subscriber` version 0.3.20 fixes this vulnerability by escaping
ANSI control characters in when writing events to destinations that may
be printed to the terminal.
### Workarounds
Avoid printing logs to terminal emulators without escaping ANSI control
sequences.
### References
https://www.packetlabs.net/posts/weaponizing-ansi-escape-sequences/
### Acknowledgments
We would like to thank [zefr0x](http://github.com/zefr0x) who
responsibly reported the issue at `security@tokio.rs`.
If you believe you have found a security vulnerability in any tokio-rs
project, please email us at `security@tokio.rs`.
---
### Release Notes
<details>
<summary>tokio-rs/tracing (tracing-subscriber)</summary>
###
[`v0.3.20`](https://redirect.github.com/tokio-rs/tracing/releases/tag/tracing-subscriber-0.3.20):
tracing-subscriber 0.3.20
[Compare
Source](https://redirect.github.com/tokio-rs/tracing/compare/tracing-subscriber-0.3.19...tracing-subscriber-0.3.20)
**Security Fix**: ANSI Escape Sequence Injection (CVE-TBD)
#### Impact
Previous versions of tracing-subscriber were vulnerable to ANSI escape
sequence injection attacks. Untrusted user input containing ANSI escape
sequences could be injected into terminal output when logged,
potentially allowing attackers to:
- Manipulate terminal title bars
- Clear screens or modify terminal display
- Potentially mislead users through terminal manipulation
In isolation, impact is minimal, however security issues have been found
in terminal emulators that enabled an attacker to use ANSI escape
sequences via logs to exploit vulnerabilities in the terminal emulator.
#### Solution
Version 0.3.20 fixes this vulnerability by escaping ANSI control
characters in when writing events to destinations that may be printed to
the terminal.
#### Affected Versions
All versions of tracing-subscriber prior to 0.3.20 are affected by this
vulnerability.
#### Recommendations
Immediate Action Required: We recommend upgrading to tracing-subscriber
0.3.20 immediately, especially if your application:
- Logs user-provided input (form data, HTTP headers, query parameters,
etc.)
- Runs in environments where terminal output is displayed to users
#### Migration
This is a patch release with no breaking API changes. Simply update your
Cargo.toml:
```toml
[dependencies]
tracing-subscriber = "0.3.20"
```
#### Acknowledgments
We would like to thank [zefr0x](http://github.com/zefr0x) who
responsibly reported the issue at `security@tokio.rs`.
If you believe you have found a security vulnerability in any tokio-rs
project, please email us at `security@tokio.rs`.
</details>
---
### Configuration
📅 **Schedule**: Branch creation - "" in timezone America/New_York,
Automerge - At any time (no schedule defined).
🚦 **Automerge**: Disabled by config. Please merge this manually once you
are satisfied.
♻ **Rebasing**: Whenever PR becomes conflicted, or you tick the
rebase/retry checkbox.
🔕 **Ignore**: Close this PR and you won't be reminded about this update
again.
---
- [ ] <!-- rebase-check -->If you want to rebase/retry this PR, check
this box
---
Release Notes:
- N/A
<!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiI0MS44Mi43IiwidXBkYXRlZEluVmVyIjoiNDEuODIuNyIsInRhcmdldEJyYW5jaCI6Im1haW4iLCJsYWJlbHMiOltdfQ==-->
---------
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Kirill Bulatov <kirill@zed.dev>
See discussion on #36564
Adds a simple ad-hoc substring matching pattern language which allows
skipping a bounded number of chars between matched substrings. Before
this change compiling the regex was taking ~120ms on a fast machine and
~8mb of memory. This new version is way faster and uses minimal memory.
Checked the behavior of this vs by running it against 10k licenses that
happened to be in my home dir. There were only 4 differences of behavior
with the regex implementation, and these were false negatives for the
regex implementation that are true positives with the new one.
Of the ~10k licenses in my home dir, ~1k do not match one of these
licenses, usually because it's GPL/MPL/etc.
Release Notes:
- N/A
See discussion on #36564. Makes the license regexes a less fragile by
not matching on symbols, while also excluding cases where a long file
ends with a valid license. Also adds Zlib license, a commented out test
to check all license-like files discovered in the homedir, and more
testcases.
Not too happy with the efficiency here, on my quite good computer it
takes ~120ms to compile the regex and allocates ~8mb for it. This is
just not a great use of regexes, I think something using eager substring
matching would be much more efficient - hoping to followup with that.
Release Notes:
- Edit Prediction: Added Zlib license to open-source licenses eligible
for data collection.
Closes#37171
Release Notes:
- agent: Fixed a bug that caused the agent information in the panel
header to be incorrect when opening a thread from history.
Closes #ISSUE
Adds a dependency on `serde_path_to_error` to the workspace allowing us
to include the path to the setting that failed to parse on settings
parse failure.
Release Notes:
- N/A *or* Added/Fixed/Improved ...
Closes#37025
This PR fixes GitHub Copilot thread summary failures by removing the
unnecessary `noop` tool insertion logic. The code was originally added
as a workaround in https://github.com/zed-industries/zed/pull/30007 for
supposed GitHub Copilot API issues when tools were used previously in a
conversation but no tools are provided in the current request. However,
testing revealed that this scenario works fine without the workaround,
and the `noop` tool insertion was actually causing "Invalid schema for
function 'noop'" errors that prevented thread summarization from
working. Removing this logic eliminates the errors and allows thread
summarization to function correctly with GitHub Copilot models.
The best way to see if removing that part of code works is just
triggering thread summarisation.
Error Log:
```
2025-08-27T13:47:50-04:00 ERROR [workspace::notifications] "Failed to connect to API: 400 Bad Request {"error":{"message":"Invalid schema for function 'noop': In context=(), object schema missing properties.","code":"invalid_function_parameters"}}\n"
```
Release Notes:
- Fixed GitHub Copilot thread summary failures by removing unnecessary
noop tool insertion logic.
Follow-up to https://github.com/zed-industries/zed/pull/37035
In the WSL PR, `ssh_connection_id` was renamed to
`remote_connection_id`. However, that was not accounted for within the
`recent_workspaces_query`. This caused a query fail:
```
2025-08-30T14:45:44+02:00 ERROR [recent_projects] Prepare call failed for query:
SELECT
workspace_id,
paths,
paths_order,
ssh_connection_id
FROM
workspaces
WHERE
paths IS NOT NULL
OR ssh_connection_id IS NOT NULL
ORDER BY
timestamp DESC
Caused by:
Sqlite call failed with code 1 and message: Some("no such column: ssh_connection_id")
```
and resulted in no recent workspaces being shown within the recent
projects picker.
This change updates the column name to the new name and thus fixes the
error.
Release Notes:
- N/A
After setting a `grok` model via the agent panel, the settings complains
that it doesn't recognize the language model provider:
<img width="1005" height="188" alt="SCR-20250829-tqqd"
src="https://github.com/user-attachments/assets/a25fc7e0-60f0-44fd-96d2-b1cb316d06b6"
/>
Also, sorted the list, in the follow-up commit.
Release Notes:
- N/A
This is just copying over the same workaround here:
a790e514af/crates/agent/src/thread.rs (L1455-L1459)
Into the agent2 code.
Release Notes:
- agent: Fixed an issue where some tool calls in the Zed agent could
return an error like "`tool_use` ids were found without `tool_result`
blocks immediately after"
Fixes#36866
- Updated internal naming for Claude 4 models to be consistent.
- Corrected max output tokens for Anthropic Bedrock models to match docs
Shoutout to @tlehn for noticing the bug, and finding the resolution.
Release Notes:
- bedrock: Fixed inference config errors causing Opus 4 Thinking and
Opus 4.1 Thinking to fail (thanks [@tlehn](https://github.com/tlehn) and
[@5herlocked](https://github.com/5herlocked])
- bedrock: Fixed an issue which prevented Rules / System prompts not
functioning with Bedrock models (thanks
[@tlehn](https://github.com/tlehn) and
[@5herlocked](https://github.com/5herlocked])
## Goal
This PR creates the initial settings ui structure with the primary goal
of making a settings UI that is
- Comprehensive: All settings are available through the UI
- Correct: Easy to understand the underlying JSON file from the UI
- Intuitive
- Easy to implement per setting so that UI is not a hindrance to future
settings changes
### Structure
The overall structure is settings layer -> data layer -> ui layer.
The settings layer is the pre-existing settings definitions, that
implement the `Settings` trait. The data layer is constructed from
settings primarily through the `SettingsUi` trait, and it's associated
derive macro. The data layer tracks the grouping of the settings, the
json path of the settings, and a data representation of how to render
the controls for the setting in the UI, that is either a marker value
for the component to use (avoiding a dependency on the `ui` crate) or a
custom render function.
Abstracting the data layer from the ui layer allows crates depending on
`settings` to implement their own UI without having to add additional UI
dependencies, thus avoiding circular dependencies. In cases where custom
UI is desired, and a creating a custom render function in the same crate
is infeasible due to circular dependencies, the current solution is to
implement a marker for the component in the `settings` crate, and then
handle the rendering of that component in `settings_ui`.
### Foundation
This PR creates a macro and a trait both called `SettingsUi`. The
`SettingsUi` trait is added as a new trait bound on the `Settings`
trait, this allows the type system to guarantee that all settings
implement UI functionality. The macro is used to derived the trait for
most types, and can be modified through attributes for unique cases as
well.
A derive-macro is used to generate the settings UI trait impl, allowing
it the UI generation to be generated from the static information in our
code base (`default.json`, Struct/Enum names, field names, `serde`
attributes, etc). This allows the UI to be auto-generated for the most
part, and ensures consistency across the UI.
#### Immediate Follow ups
- Add a new `SettingsPath` trait that will be a trait bound on
`SettingsUi` and `Settings`
- This trait will replace the `Settings::key` value to enable
`SettingsUi` to infer the json path of it's derived type
- Figure out how to render `Option<T> where T: SettingsUi` correctly
- Handle `serde` attributes in the `SettingsUi` proc macro to correctly
get json path from a type's field and identity
Release Notes:
- N/A
---------
Co-authored-by: Ben Kunkle <ben@zed.dev>
Add support for scrolling the contents rendered aside an
`editor::code_context_menus::CodeContextMenu` by introducing the
`scroll_aside` method.
For now this method is only implemented for the
`CodeContextMenu::Completions` variant, which will scroll the aside
contents for an `editor::code_context_menus::CompletionsMenu` element,
as a `ScrollHandle` is added to the aside content that is rendered.
In order to be possible to trigger this via keybindings, a new editor
action is introduced, `ContextMenuScrollAside`, which accepts a number
of lines or pages to scroll the content by.
Lastly, the default keymaps for both MacOS and Linux, as well as for
Zed's vim mode, are updated to ensure that the following keybindings are
supported when a completion menu is open and the completion item's
documentation is rendered aside:
- `ctrl-e`
- `ctrl-y`
- `ctrl-d`
- `ctrl-u`
### Recording
https://github.com/user-attachments/assets/02043763-87ea-46f5-9768-00e907127b69
---
Closes#13194
Release Notes:
- Added support for scrolling the documentation panel shown alongside
the completion menu in the editor with `cltr-d`, `ctrl-u`, `ctrl-e` and
`ctrl-y`
---------
Co-authored-by: Conrad Irwin <conrad.irwin@gmail.com>
Co-authored-by: MrSubidubi <finn@zed.dev>
Closes#36981
- Add completion text and position caching to reduce redundant API calls
- Only trigger new completion requests on text changes, not cursor
movement
- Validate cursor position to ensure completions show at correct
location
- Improve end-of-line range calculation for more accurate deletions
- Extract reset_completion_cache helper for cleaner code organization
- Update completion diff algorithm documentation for clarity
Edit: Sorry this is the 2nd PR, I forgot that the forks history was
messy; I cherrypicked and cleaned it properly with this PR
Release Notes:
- supermaven: Improved caching of predictions
- supermaven: Fixed an issue where changing cursor position would
incorrectly trigger new completions
In the case where we fail to create an ACP connection to Gemini, only
report the "unsupported version" error if the version for the found
binary is at least our minimum version. That means we'll surface the
real error in this situation.
This also fixes incorrect sorting of downloaded Gemini versions--as @kpe
pointed out we were effectively using the version string as a key. Now
we'll correctly use the parsed semver::Version instead.
Release Notes:
- N/A
Closes https://github.com/zed-industries/zed/issues/36383
The project symbols modal didn't use the buffer font and highlighted
matches through modifying the font weight, which is inconsistent with
the outline picker, which presents code in list items in a similar way,
as well as project _and_ buffer search highlighting design.
Release Notes:
- N/A
Closes#35787Closes#17890Closes#28789Closes#36495
How it works:
For highlights (and selections) within the visible rows of the editor,
we split them row by row. This is efficient since the number of visible
rows is constant. For each row, all highlights and selections, which may
overlap, are flattened using a line sweep. This produces non-overlapping
consecutive segments for each row, each with a blended background color.
Next, for each row, we split text runs into smaller runs to adjust its
color using APCA contrast. Since both text runs and segment are
non-overlapping and consecutive, we can use two-pointer on them to do
this.
For example, a text run for the variable red might be split into two
runs if a highlight partially covers it. As a result, one part may
appear as red, while the other appears as a lighter red, depending on
the background behind it.
Result:
<img width="1458" height="949" alt="image"
src="https://github.com/user-attachments/assets/4814c93d-12e7-4b4d-8542-d912acccfb8e"
/>
<img width="1459" height="952" alt="image"
src="https://github.com/user-attachments/assets/9e497b6c-3e66-43e8-8e5b-f634dd5ee8d3"
/>
<img width="1457" height="621" alt="image"
src="https://github.com/user-attachments/assets/8dfa6ce5-f46b-45b9-8008-66169d5aecd4"
/>
Release Notes:
- Improved text contrast when selected or highlighted in the editor.
Follow-up of https://github.com/zed-industries/zed/pull/36764
* Fix `anyhow!({e})` conversion lossing Collab error codes context when
opening a buffer remotely
* Use this context to only allow opening files that had not specific
Collab error code
Release Notes:
- N/A
Follow-up https://github.com/zed-industries/zed/pull/37083
Noisy RPC LSP logs were functioning this way already, but to keep Collab
loaded even less, do not send any kind of logs to the client if the
client has a corresponding log tab not opened.
This change is pretty raw and does not fully cover scenarious with
multiple clients: if one client has a log tab open and another opens tab
with another kind of log, the 2nd kind of logs will be streamed only.
Also, it should be possible to forward the host logs to the client on
enabling — that is not done to keep the change smaller.
Release Notes:
- N/A
To show these notifications, Zeta was being initialized with the initial
workspace it's used on - which may not even still exist! This removes a
confusing/misleading workspace field from Zeta.
Release Notes:
- N/A
This PR updates the language server configuration for Elixir and HEEx to
not start the [Expert](https://github.com/elixir-lang/expert) language
server by default.
While Expert is the official Elixir language server, it is still early,
so we don't want to make it the default just yet.
Release Notes:
- Updated the default Elixir and HEEx language server settings to not
start the Expert language server.
This PR adds documentation for
[Expert](https://github.com/elixir-lang/expert) to the Elixir docs.
Also updated the examples for the other language servers to be
representative of all the supported language servers.
Release Notes:
- N/A
We have a bug in our ACP implementation where sometimes the
Accept/Reject buttons are disabled (and stay disabled even after the
thread has finished). I haven't found a complete fix for this yet, so in
the meantime I'm putting out the fire by making it so those buttons are
always enabled. That way you're never blocked, and the only consequence
of the bug is that sometimes they should be disabled but are enabled
instead.
Release Notes:
- N/A
@JosephTLyons pointed out that it's a bit weird that we only show a
preview for items selected after the initial one, so this does it for
that too.
It makes tab switching feel even faster!
Release Notes:
- N/A
Co-authored-by: David Kleingeld <davidsk@zed.dev>
Closes: https://github.com/zed-industries/zed/issues/37089
Instead of looking for the gemini command on `$PATH`, by default we'll
install our own copy on demand under our data dir, as we already do for
language servers and debug adapters. This also means we can handle
keeping the binary up to date instead of prompting the user to upgrade.
Notes:
- The download is only triggered if you open a new Gemini thread
- Custom commands from `agent_servers.gemini` in settings are respected
as before
- A new `agent_servers.gemini.ignore_system_version` setting is added,
similar to the existing settings for language servers. It's `true` by
default, and setting it to `false` disables the automatic download and
makes Zed search `$PATH` as before.
- If `agent_servers.gemini.ignore_system_version` is `false` and no
binary is found on `$PATH`, we'll fall back to automatic installation.
If it's `false` and a binary is found, but the version is older than
v0.2.1, we'll show an error.
Release Notes:
- acp: By default, Zed will now download and use a private copy of the
Gemini CLI binary, instead of searching your `$PATH`. To make Zed search
your `$PATH` for Gemini CLI before attempting to download it, use the
following setting:
```
{
"agent_servers": {
"gemini": {
"ignore_system_version": false
}
}
}
```
This PR makes it so the channel list will still be shown while
reconnecting to Collab instead of showing the signed-out state.
In order to model the transitional states that occur while reconnecting,
we needed to introduce a new `Status::Reauthenticated` state that we go
through when signing in as part of a reconnect. This is because we
cannot tell from `Status::Authenticated` alone if we're authenticating
for the first time or reauthenticating.
Release Notes:
- N/A
Closes#36420
## Synopsis
The issue in #36420 is caused by #7276, which bound the appropriate
tree-sitter queries to the `@variable.member` color. However, I have
found neither this color's declaration nor its other usages in the
codebase (neither on the latest `main` nor on
79c1003b34).
Other languages use for such situations the `@property` color.
## Solution
Just change the used `@variable.member` color to the `@property` one.
Seems fully inline with the changes illustrated in #7276.
## Screenshots
<img width="856" height="465" alt="Screenshot 2025-08-28 at 13 18 38"
src="https://github.com/user-attachments/assets/9d1f3542-8749-421f-864f-959c1242cc64"
/>
<img width="837" height="462" alt="Screenshot 2025-08-28 at 13 20 08"
src="https://github.com/user-attachments/assets/36a80c22-9de9-46b1-87e3-7fdeaa62978f"
/>
## Changelog
Release Notes:
- go: Fixed highlighting of fields.
Use the latest Copilot Chat model schema, matching what is used in
VSCode, to get more data about available models than was previously
accessible. Replace hardcoded default model (gpt-4.1) with the default
model included in JSON. Other data like premium request multipliers
could be used in the future if Zed implements a way for models to
display additional details about themselves, such as with tooltips on
hover.
Release Notes:
- N/A
---------
Co-authored-by: Peter Tripp <peter@zed.dev>
Closes#37022Closes#36994
This update ensures all Grok models use the JsonSchemaSubset format for
tool schemas.
A previous fix for this issue was too specific, only targeting grok-4
models. This caused other variants, like grok-code-fast-1, to be missed.
We've now broadened the logic to correctly apply the setting to the
entire Grok model family.
Release Notes:
- Fix tool calling for `x-ai/grok-code-fast-1` model via OpenRouter.
Instead of manually constructing the venv we now ask the python
toolchain for the relevant information, unifying the approach of vent
inspection
Fixes https://github.com/zed-industries/zed/issues/27350
Release Notes:
- Improved the detection of python virtual environments for terminals
and tasks in remote projects.
Closes#37043
Previously claude sonnet 4 was missing from copilot as it was colliding
with zed's claude-sonnet-4 model id. Now we do deduplication based upon
model and provider id both.
| Before | After |
|--------|--------|
| <img width="784" height="950" alt="CleanShot 2025-08-28 at 18 31
28@2x"
src="https://github.com/user-attachments/assets/d49d5a17-7271-417d-bb5e-bc380071e810"
/> | <img width="720" height="876" alt="CleanShot 2025-08-28 at 18 31
42@2x"
src="https://github.com/user-attachments/assets/a5100c05-994e-4e19-ab20-34c0258b977c"
/> |
Release Notes:
- Fixed an issue where models with the same ID from different providers
(such as Claude Sonnet 4 from both Zed and Copilot) were incorrectly
deduplicated in the model selector—now all variants are shown.
Take 2: https://github.com/zed-industries/zed/pull/36709 but without the
very bad `cfg`-based approach for storing the RPC logs.
--------------
Enables LSP log tracing in both remote collab and remote ssh
environments.
Server logs and server RPC traces can now be viewed remotely, and the
LSP button is now shown in such projects too.
Closes https://github.com/zed-industries/zed/issues/28557
Co-Authored-By: Kirill <kirill@zed.dev>
Co-Authored-By: Lukas <lukas@zed.dev>
Release Notes:
- Enabled LSP log tracing in both remote collab and remote ssh
environments
---------
Co-authored-by: Ben Kunkle <ben@zed.dev>
Co-authored-by: Lukas Wirth <lukas@zed.dev>
This prevents the common footgun of copy/pasting an API key
starting/ending with extra newlines, which would lead to a "bad request"
error.
Closes#37038
Release Notes:
- agent: Support pasting language model API keys that contain newlines.
Release Notes:
- agent: Fixed a bug that canceled editing when scrolling the user
message out of view.
Co-authored-by: Bennet Bo Fenner <bennetbo@gmx.de>
This fixes some errors in the examples in the "Agent Settings" page at
https://zed.dev/docs/ai/agent-settings#agent-settings, where strings
"true" and "false" are used in place of the proper boolean JSON values:
strings don't work for all those settings, and are marked as errors when
editing settings.json, while booleans do work.
Release Notes:
- N/A
This pull request refactors the `KeybindingKeystroke` struct and related
code to improve platform abstraction. The changes centralize
platform-specific logic within `KeybindingKeystroke` and update its
usage throughout the codebase, making the API more consistent and less
error-prone.
Release Notes:
- N/A
This PR adds a toggleable filter to the stack frame list that filters
out entries that don't exist within a user's project (visible work
trees). This works by keeping a vector of entry indices that exist
within a user's project and updates the list state based on these
entries when filtering the list.
I went with this approach so the stack frame list wouldn't have to
rebuild itself whenever the filter is toggled and it could persist its
state across toggles (uncollapsing a collapse list). It was also easier
to keep track of selected entries on toggle using the vector as well.
### Preview
https://github.com/user-attachments/assets/d86c7485-c885-4bbb-bebb-2f6385674925
Release Notes:
- debugger: Add option to only show stack frames from user's project in
stack frame list
This PR fixes two bugs and also changes one behavior in the **Keymap
Editor**.
As shown in the video, when I press `ctrl-shift-2` in the Keymap Editor,
the first keystroke is displayed as `ctrl-shift-@`, which is incorrect.
On macOS and Linux, it should be `ctrl-@`.
https://github.com/user-attachments/assets/69cfcfa0-b422-45d6-8e69-80f8608180fd
Also, after pressing `ctrl-shift-2` and then releasing `2` and `ctrl`, a
`shift` keystroke was incorrectly added.
https://github.com/user-attachments/assets/892124fd-847d-4fde-9b20-a27ba49ac934
Now, when you enter a sequence like `+ctrl+alt-alt+f` in the Keymap
Editor, it will output `ctrl-f` instead of `ctrl-alt-f`, matching VS
Code’s behavior.
Release Notes:
- Fixed incorrect keystroke reporting in the Keymap Editor.
This Pull Request introduces support for pattern items in the buffer
search. It does so by splitting the `query` methods into two new
methods:
- `BufferSearchBar.raw_query` – returns the text from the search query
editor
- `BufferSearchBar.query` - returns the search query with pattern items
removed
Whenever the search query is updated, processing of the
`EditorEvent::Edited` event ends up calling the
`BufferSearchBar.apply_pattern_items` method, which parses the pattern
items from the raw query, and updates the buffer search bar's search
options accordingly. This `apply_pattern_items` function avoids updating
the `BufferSearchBar.default_options` field in order to be able to reset
the search options when a pattern items is removed. Lastly, new pattern
items can easily be added by updating the `PATTERN_ITEMS` array.
### Screen Capture
https://github.com/user-attachments/assets/ebd83c38-e480-4c24-9b8c-6edde69cf392
---
Closes#32390
Release Notes:
- Added support for the `\c` and `\C` query pattern items to control
case-sensitivity in buffer search
---------
Co-authored-by: Conrad Irwin <conrad.irwin@gmail.com>
Closes#32020
Release Notes:
- Helix: Improve `x` behaviour. Will respect modifiers (`5 x`). Pressing
`x` on a empty line, will select current+next line, because helix
considers current line to be already selected without the need of
pressing `x`.
The scanner is restarted after loading initial settings, and there was
an optimization to not re-discover and re-watch git repositories if they
already exist in the snapshot. #35865 added cleanup of watches that
occurred when the scanner restarts, and so in some cases repos were no
longer watched.
Release Notes:
- Linux: Fixed a case where Git repositories might not be watched for
changes, causing branch switching to not update the UI.
Co-authored-by: Julia <julia@zed.dev>
This makes sure we do not apply the highlights for snake case
identifiers as well as paths for attributes too broadly to all types of
macros, which should make macros much more readable overall whilst
keeping the highlighting for the attribute items.
| Before | After |
| --- | --- |
| <img width="1414" height="958" alt="Bildschirmfoto 2025-08-28 um 00 37
58"
src="https://github.com/user-attachments/assets/1254b9a2-d07a-4be4-9b4f-555a7c640302"
/> | <img width="1414" height="958" alt="Bildschirmfoto 2025-08-28 um 00
37 38"
src="https://github.com/user-attachments/assets/5f6dd66c-5469-4f27-9f1d-0a6e6e8d8085"
/> |
Release Notes:
- rust: Improved highlighting within macros.
Closes#36931 and #21956
Preserves `SearchOptions` across dismisses of the buffer search bar.
This behavior is consistent with VSCode, which seems reasonable. The
`configured_options` field is then no longer being used. The
configuration is still read during initialization of the
`BufferSearchBar`, but not after.
Something to consider is that there are other elements in the search bar
which are not kept across dismisses such as replace status. However
these are visually separated in the UI, leading me to believe this is a
okay change to make.
Release Notes:
- Preserve search options between buffer search dismisses
This PR adds the ability for a user to select one or more blocks of text
and wrap each selection in an HTML tag — which works by placing multiple
cursors inside the open and close tags so the appropriate element name
can be typed in to all places simultaneously.
This is similar to the emmet "Wrap with Abbreviation" functionality
discussed in #15588 but is a simpler version that does not rely on
Emmet's language server.
Here's a preview of the feature in action:
https://github.com/user-attachments/assets/1931e717-136c-4766-a585-e4ba939d9adf
Some notes and questions:
- The current implementation is a hardcoded with regards to supported
languages. I'd love some direction on how much of this information to
push into the relevant language structs.
- I can see this feature as something that languages added by an
extension would want to enable support for — is this something you'd
want?
- The syntax is hardcoded to support HTML/XML/JSX-like languages. I
don't suppose this is a problem but figured I'd point it out anyway.
- I called it "Wrap in tag" but open to whatever naming you feel is
appropriate.
- The implementation doesn't use `manipulate_lines` — I wasn't sure how
make use of that without extra overhead / bookkeeping — does this seem
fine?
- I could also investigate adding wrap in abbreviation support by
communicating with the Emmet language server but I think I'll need some
direction on how to handle Emmet's custom LSP message. I could do this
either in addition to or instead of this feature — though imo this
feature is a nice "shortcut" regardless.
Release Notes:
- Added a new "Wrap Selections in Tag" action that lets you wrap one or
more selections in tags based on language. Works in HTML, JSX, and
similar languages, and places cursors inside both opening and closing
tags so you can type the tag name once and apply it everywhere.
---------
Co-authored-by: Smit Barmase <heysmitbarmase@gmail.com>
cc @michael-ud - if you can build Zed, I'd appreciate it if you could
give this a go with your project. Otherwise I can provide a link to
download of current nightly via an e-mail for you to try out (if you
want).
This change will land in Preview (if merged) on next Wednesday and then
it'll be in Stable a week after that.
Related to: #20402
Release Notes:
- python: Zed now searches for virtual environments in intermediate
directories between a root of the worktree and the location of
pyproject.toml applicable to the currently focused file.
Enables LSP log tracing in both remote collab and remote ssh
environments.
Server logs and server RPC traces can now be viewed remotely, and the
LSP button is now shown in such projects too.
Closes https://github.com/zed-industries/zed/issues/28557
Co-Authored-By: Kirill <kirill@zed.dev>
Co-Authored-By: Lukas <lukas@zed.dev>
Release Notes:
- Enabled LSP log tracing in both remote collab and remote ssh
environments
---------
Co-authored-by: Kirill Bulatov <kirill@zed.dev>
Co-authored-by: Lukas Wirth <lukas@zed.dev>
Gemini cli - 0.2.0 is no longer in preview it's the latest version and
released as of today.
Release Notes:
- N/A
Signed-off-by: Umesh Yadav <git@umesh.dev>
Release Notes:
- acp: Fixed a bug that caused external agent server subprocesses to be
leaked.
---------
Co-authored-by: Agus Zubiaga <agus@zed.dev>
Co-authored-by: Bennet Bo Fenner <bennetbo@gmx.de>
Co-authored-by: Antonio Scandurra <me@as-cii.com>
Within our hosted docs, we are missing documentation for quite a lot of
settings - sometimes for newer settings, sometimes for settings that are
more than two years old. This leads (amongst other things) to feature
requests for features that are already supported, false issue reports
(because people couldn't find the setting for what caused the issue
within the documentation) and generally just takes time for for both
these affected by the missing documentation as well as these handling
the questions around it.
This change here takes a stab at the problem by adding more
documentation for a lot supported setting (not all of it) as well as
reorganizing some settings so that some stuff can (hopefully) be found
more easily. Eventually, we should find a better method for this, but
it's still better than informing people for the n-th time that we e.g.
have `agent_font_size` for the agent panel. Manually audited twice but
I'll take another thorough look before merging.
Release Notes:
- N/A
Closes#36938
Follow up to https://github.com/zed-industries/zed/pull/36554
When `registerOptions` is `None`, we should fall back instead of
skipping capability registration.
1. `Option<OneOf<bool, T>>`, where `T` is struct – handled in the
attached PR ✅
2. `Option<T>`, where `T` is an enum that can be `Simple(bool)` or
`Options(S)` – this PR ✅
3. `Option<T>`, where `T` is struct – we should fall back to default
values for these options ⚠️
Release Notes:
- Fixed an issue where hover popovers would not appear in language
servers like Java.
Closes https://github.com/zed-industries/zed/issues/33725
The default bindings for the `editor::NewlineAbove` and
`editor::NewlineBelow` actions in the default keymap were accidentally
swapped some time ago. This causes confusion, as normally these are the
other way around.
This PR fixes this by swapping these back, which also matches what
[VSCode does by
default](https://code.visualstudio.com/shortcuts/keyboard-shortcuts-linux.pdf).
Release Notes:
- Swapped the default bindings for `editor::NewlineBelow` and
`editor::NewlineAbove` for Linux and Windows to align more with other
editors.
- **Pass --engine-strict to gemini install command**
- **Make it clearer that if upgrading fails, you need to fix i**
Closes #ISSUE
Release Notes:
- N/A
This is a pure refactor that consolidates all SSH remoting logic such
that it should be straightforward to add another transport to the
remoting system.
Release Notes:
- N/A
---------
Co-authored-by: Mikayla Maki <mikayla.c.maki@gmail.com>
Closes#36300
This PR follows Windows conventions by introducing
`KeybindingKeystroke`, so shortcuts now show up as `ctrl-shift-4`
instead of `ctrl-$`.
It also fixes issues with keyboard layouts: when `use_key_equivalents`
is set to true, keys are remapped based on their virtual key codes. For
example, `ctrl-\` on a standard English layout will be mapped to
`ctrl-ё` on a Russian layout.
Release Notes:
- N/A
---------
Co-authored-by: Kate <kate@zed.dev>
## Fix: Preserve Helix mode when using search
### Problem
When using `buffer search: deploy` in Helix mode, pressing Enter to
dismiss the search incorrectly returned to Vim NORMAL mode instead of
Helix NORMAL mode.
### Root Cause
The `search_deploy` function was resetting the entire `SearchState` to
default values when buffer search: deploy was activated. Since the
default `Mode` is `Normal`, this caused `prior_mode` to be set to Vim's
Normal mode regardless of the actual mode before search.
### Solution
Modified `search_deploy` to preserve the current mode when resetting
search state:
- Store the current mode before resetting
- Reset search state to default
- Restore the saved mode to `prior_mode`
This ensures the editor returns to the correct mode (Helix NORMAL or Vim
NORMAL) after dismissing buffer search.
### Settings
I was able to reproduce and then test the fix was successful with the
following config and have also tested with vim: default_mode commented
out to ensure that's not influencing the mode selection flow:
```
"helix_mode": true,
"vim_mode": true,
"vim": {
"default_mode": "helix_normal"
},
```
This is on Kubuntu 24.04.
The following test combinations pass locally:
- `cargo test -p search`
- `cargo test -p vim`
- `cargo test -p editor`
- `cargo test -p workspace`
- `cargo test -p gpui -- vim`
- `cargo test -p gpui -- helix`
Release Notes:
- Fixed Helix mode switching to Vim normal mode after using `buffer
search: deploy` to search
Closes#36872
Closes https://github.com/zed-industries/zed/issues/29746
| Action | New Key | Old Key | Former Conflict |
| - | - | - | - |
| `edit_prediction::ToggleMenu` | `ctrl-alt-shift-i` | `ctrl-shift-i` |
`editor::Format` |
| `editor::ToggleEditPrediction` | `ctrl-alt-shift-e` | `ctrl-shift-e` |
`project_panel::ToggleFocus` |
These aren't great keys and I'm open to alternate suggestions, but the
will work out of the box without conflict.
Release Notes:
- N/A
Previously, we wouldn't finalize the diff if an error occurred during
editing or the tool call was canceled.
Release Notes:
- N/A
---------
Co-authored-by: Antonio Scandurra <me@as-cii.com>
Closes #ISSUE
Release Notes:
- The environment of original remote dev cannot be changed without sudo
because of the behavior of "sh -c". This PR changes "sh -c" to "sh -lc"
to let the shell source $HOME/.profile and support customized
environment like customized $PATH variable.
Related #4642
Compatible with #34136
Release Notes:
- Helix: `Shift+R` works as Paste instead of taking you to ReplaceMode
- Helix: `g .` goes to last modification place (similar to `. in vim)
Closes#33736
Use `thiserror` to implement error stack and `anyhow` to report is to
user.
Also move some code from main to remote_server to have better crate
isolation.
Release Notes:
- N/A
---------
Co-authored-by: Kirill Bulatov <kirill@zed.dev>
Support to show diagnostics on the tab switcher in the same way they are
displayed on the tab bar. This follows the setting
`tabs.show_diagnostics`.
This will improve user experience when disabling the tab bar and still
being able to see the diagnostics when switching tabs
Preview:
<img width="768" height="523" alt="Screenshot From 2025-07-16 11-02-42"
src="https://github.com/user-attachments/assets/308873ba-0458-485d-ae05-0de7c1cdfb28"
/>
Release Notes:
- Added diagnostics indicators to the tab switcher
---------
Co-authored-by: Kirill Bulatov <kirill@zed.dev>
Adds support for per-session prompt capabilities and capability changes
on the Zed side (ACP itself still only has per-connection static
capabilities for now), and uses it to reflect image support accurately
in 1PA threads based on the currently-selected model.
Release Notes:
- N/A
Reverts zed-industries/zed#36012
We thought we didn't need this UI, but it turns out it was load bearing
:)
Release Notes:
- Restored the zoomed panel padding
As of
db52fc3655,
the Kotlin extension has two language servers. However, following that
change, no default language server for Kotlin was configured within this
repo, which led to two language servers being activated for Kotlin by
default.
This PR makes `kotlin-language-server` the default language server for
the extension. This also ensures that the [documentation within the
repository](https://github.com/zed-extensions/kotlin?tab=readme-ov-file#kotlin-lsp)
matches what is actually the case.
Release Notes:
- kotlin: Made `kotlin-language-server` the default language server.
Using prompt injection, the agent may be tricked into making a fetch
request that includes unexpected data from the conversation in the URL.
As agent conversations may contain sensitive information (like private
code, or
potentially even API keys), this seems bad.
The easiest way to prevent this is to require the user to look at the
URL
before the model is allowed to fetch it.
Thanks to @ant4g0nist for bringing this to our attention.
Release Notes:
- agent panel: The fetch tool now requires confirmation.
A beta user reported that following was "lost" when asking for
confirmation, I
suspect they moved their cursor in the agent file while reviewing the
change.
Now we will resume following when the agent starts up again.
Release Notes:
- N/A
In the thread view, when focusing on the user message, we display the
editing control container absolutely-positioned in the top right.
However, if there are no rules items and no restore checkpoint button
_and_ it is the very first message, the editing controls container would
be cut-off. This PR fixes that by giving it a bit more top padding.
Release Notes:
- N/A
We were rendering a Markdown link like `[Read file x.rs (lines
Y-Z)](@selection)` while the tool ran, but then switching to just `x.rs`
as soon as we got the file location from the tool call (due to an
if/else in the UI code that applies to all tools). This caused a
flicker, which is fixed by having `initial_title` return just the
filename from the input as it arrives instead of a link that we're going
to stop rendering almost immediately anyway.
Release Notes:
- N/A
<img width="1988" height="1420" alt="multi-buffer-icons-git-diff"
src="https://github.com/user-attachments/assets/48f9722f-ca09-4aa7-ad7a-0b7e85f440d9"
/>
Unfortunately, `cargo format` decided to reformat everything. Probably,
because of hitting the right margin, no idea. The essence of this change
is the following:
```rust
.map(|path_header| {
let filename = filename
.map(SharedString::from)
.unwrap_or_else(|| "untitled".into());
let path = path::Path::new(filename.as_str());
let icon =
FileIcons::get_icon(path, cx).unwrap_or_default();
let icon = Icon::from_path(icon).color(Color::Muted);
let label = Label::new(filename).single_line().when_some(
file_status,
|el, status| {
el.color(if status.is_conflicted() {
Color::Conflict
} else if status.is_modified() {
Color::Modified
} else if status.is_deleted() {
Color::Disabled
} else {
Color::Created
})
.when(status.is_deleted(), |el| el.strikethrough())
},
);
path_header.child(icon).child(label)
})
```
Release Notes:
- Added file icons to multi buffer view
Merge conflict resolution for #36741 accidentally reverted the changes
in #36670 to allow expanding terminals individually and in #36675 to
allow collapsing edit cards. This PR re-applies those changes, fixing
the regression.
Release Notes:
- N/A
- Add pulsating animation for context creases while they're loading
- Add spinner in message editors (replacing send button) during the
window where sending has been requested, but we haven't finished loading
the message contents to send to the model
- During the same window, ignore further send requests, so we don't end
up sending the same message twice if you mash enter while loading is in
progress
- Wait for context to load before rewinding the thread when sending an
edited past message, avoiding an empty-looking state during the same
window
Release Notes:
- N/A
Removes `diagnostics.cargo.fetch_cargo_diagnostics` settings as those
are not needed for the flycheck diagnostics to run.
This setting disabled `checkOnSave` in rust-analyzer and allowed to
update diagnostics via flycheck in the project diagnostics editor with
the "refresh" button.
Instead, `"checkOnSave": false,` can be set manually as
https://zed.dev/docs/languages/rust#more-server-configuration example
shows and flycheck commands can be called manually from anywhere,
including the diagnostics panel, to refresh the diagnostics.
Release Notes:
- Removed redundant `diagnostics.cargo.fetch_cargo_diagnostics` settings
This PR makes it so that all kinds of @-mentions start loading their
context as soon as they are confirmed. Previously, we were waiting to
load the context for file, symbol, selection, and rule mentions until
the user's message was sent. By kicking off loading immediately for
these kinds of context, we can support adding selections from unsaved
buffers, and we make the semantics of @-mentions more consistent.
Loading all kinds of context eagerly also makes it possible to simplify
the structure of the MentionSet and the code around it. Now MentionSet
is just a single hash map, all the management of creases happens in a
uniform way in `MessageEditor::confirm_completion`, and the helper
methods for loading different kinds of context are much more focused and
orthogonal.
Release Notes:
- N/A
---------
Co-authored-by: Conrad <conrad@zed.dev>
Flycheck commands are global and makes sense to fall back to looking up
project's rust-analyzer even if the commands are run on a non-rust
buffer. If multiple rust-analyzers are found in the project, avoid
ambiguous commands and bail (as before).
Closes #ISSUE
Release Notes:
- Made it possible to run rust-analyzer's flycheck actions from anywhere
in the project
This fixes a panic I randomly ran into whilst mistyping in the command
palette: I accidentally ran `pane: swap item right`in a state where no
items were opened in my active pane. We were checking for `index + 1 ==
self.items.len()` there when it really should be `>=`, as otherwise in
the case of no items this panics.
This PR fixes the bug, adds a test for both the panic as well as the
actions themselves (they were untested previously). Lastly (and mostly),
this also cleans up a bit around existing actions to update them with
how we generally handle actions now.
Release Notes:
- Fixed a panic that could occur with the `pane: swap item right`
action.
This is another pure refactor, to prepare for adding direct WSL support.
### Todo
* [x] Represent `paths` in the same way for all workspaces, instead of
having a completely separate SSH representation
* [x] Adjust sqlite tables
* [x] `ssh_projects` -> `ssh_connections` (drop paths)
* [x] `workspaces.local_paths` -> `paths`
* [x] remove duplicate path columns on `workspaces`
* [x] Add migrations for backward-compatibility
Release Notes:
- N/A
---------
Co-authored-by: Mikayla Maki <mikayla.c.maki@gmail.com>
Also changes the message editor placeholder depending on the agent.
Release Notes:
- N/A
---------
Co-authored-by: Conrad Irwin <conrad.irwin@gmail.com>
Currently shorthand field initializers are not captured the same way as
the full initializers, leading to awkward and mismatching highlighting.
This PR addresses this fact, in addition to capturing new highlights:
- Tags the `!` as part of a macro invocation.
- Tags the identifier part of a lifetime as `@lifetime`.
- Tag module definitions as a new capture group, `@module`.
- Shorthand initializers are now properly tagged as `@property`.
Here's what the current version of Zed looks like:
<img width="596" height="683" alt="image"
src="https://github.com/user-attachments/assets/c9e52d8e-03dc-426b-8545-4fe872b803e0"
/>
With the new highlighting applied:
<img width="596" height="683" alt="image"
src="https://github.com/user-attachments/assets/b7bd9391-9910-456b-8198-6871174d0f4f"
/>
Release Notes:
- Improved highlighting of Rust files, including new highlight groups
for modules and shorthand initializers.
Small fixes to onboarding.
Correct ligature example.
Replace`ctrl-escape` and `alt-tab` since they are reserved on windows
(and often on linux) and so are caught by the OS.
Release Notes:
- N/A
Users now accept ToS from Zed's website when they sign in to Zed the
first time. So it's no longer possible that a signed in account could
not have accepted the ToS.
Release Notes:
- N/A
---------
Co-authored-by: Mikayla Maki <mikayla.c.maki@gmail.com>
Introduce `min_words_query_len` threshold for automatic word completion
display, and set it to 3 by default.
Re-enable word completions in Markdown and Plaintext.
Release Notes:
- Introduced `min_words_query_len` threshold for automatic word
completion display, and set it to 3 by default to make them less
intrusive
## Summary
Fixes cursor movement behavior in protected files (like Default
Settings) when pressing backspace or delete keys.
Previously, these keys would cause unwanted cursor movement instead of
being ignored as expected in read-only files.
## Changes
- Added read-only checks to `backspace()` and `delete()` methods in the
editor
- Consistent with existing pattern used by other editing methods
(`indent()`, `outdent()`, `undo()`, etc.)
## Test Plan
1. Open Default Settings in Zed
2. Place cursor at arbitrary position (not at start/end of file)
3. Press backspace - cursor should remain in place (no movement)
4. Press delete - cursor should remain in place (no movement)
Fixes#36302
Release Notes:
- Fixed backspace and delete keys moving caret in protected files
Co-authored-by: Claude <noreply@anthropic.com>
We had a frequent panic when the agent was using our edit file tool. The
root cause was that we were constructing a `BufferDiff` with
`BufferDiff::new`, then calling `set_base_text`, but not waiting for
that asynchronous operation to finish. This means there was a window of
time where the diff's base text was set to the initial value of
`""`--that's not a problem in itself, but it was possible for us to call
`PendingDiff::update` during that window, which calls
`BufferDiff::update_diff`, which calls
`BufferDiffSnapshot::new_with_base_buffer`, which takes two arguments
`base_text` and `base_text_snapshot` that are supposed to represent the
same text. We were getting the first of those arguments from the
`base_text` field of `PendingDiff`, which is set immediately to the
target base text without waiting for `BufferDiff::set_base_text` to run
to completion; and the second from the `BufferDiff` itself, which still
has the empty base text during that window.
As a result of that mismatch, we could end up adding `DeletedHunk` diff
transforms to the multibuffer for the diff card even though the
multibuffer's base text was empty, ultimately leading to a panic very
far away in rendering code.
I've fixed this by adding a new `BufferDiff` constructor for the case
where the buffer contents and the base text are (initially) the same,
like for the diff cards, and so we don't need an async diff calculation.
I also added a debug assertion to catch the basic issue here earlier,
when `BufferDiffSnapshot::new_with_base_buffer` is called with two base
texts that don't match.
Release Notes:
- N/A
---------
Co-authored-by: Conrad <conrad@zed.dev>
The event has two fields
1. name: The name of the panel being clicked
2. toggle_state: true if clicking to open, otherwise false
cc @katie-z-geer
Release Notes:
- N/A
This PR identifies automatic configuration options that users can select
from the agent panel. If no default provider is set in their settings,
the PR defaults to the first recommended option. Additionally, it
updates the selected provider for a thread when a user changes the
default provider through the settings file, if the thread hasn't had any
queries yet.
Release Notes:
- agent: automatically select a language model provider if there's no
user set provider.
---------
Co-authored-by: Michael Sloan <michael@zed.dev>
**Summary**
Fixes#29134 - Visual mode cursor incorrectly jumps past empty lines
that contain inlay hints (type hints).
**Problem**
When in VIM visual mode, pressing j to move down from a longer line to
an empty line that contains an inlay hint would cause the cursor to skip
the empty line entirely and jump to the next line. This only occurred
when moving down (not up) and only in visual mode.
**Root Cause**
The issue was introduced by commit f9ee28db5e which added bias-based
navigation for handling multi-line inlay hints. When using Bias::Right
while moving down, the clipping logic would place the cursor past the
inlay hint, causing it to jump to the next line.
**Solution**
Added logic in up_down_buffer_rows to detect when clipping would place
the cursor within an inlay hint position. When detected, it uses the
buffer column position instead of the display column to avoid jumping
past the hint.
**Testing**
- Added comprehensive test case
test_visual_mode_with_inlay_hints_on_empty_line that reproduces the
exact scenario
- Manually verified the fix with the reproduction case from the issue
- All 356 tests pass with `cargo test -p vim`
**Release Notes:**
- Fixed VIM visual mode cursor jumping past empty lines with type hints
when navigating down
This change adds the ability to increment / decrement numbers that are
part of a visual selection. Previously Zed would resolve to the entire
number under visual selection for increment as oppposed to only
incrementing the part of the number that is selected
Release Notes:
- vim: Fixed increment/decrement in visual mode
Closes #ISSUE
Creates a function named `normalized_ctx_eq` that compares
`gpui::KeybindContextPredicate`'s while taking into account the
associativity of the binary operators. This function is now used to
compare context predicates in the keymap editor, greatly improving the
number of cases caught by our overloading and conflict detection
Release Notes:
- N/A *or* Added/Fixed/Improved ...
Closes #ISSUE
Adds system GPU collection to crash reporting. Currently this is Linux
only.
The system GPUs are determined by reading the `/sys/class/drm` directory
structure, rather than using the exisiting `gpui::Window::gpu_specs()`
method in order to gather more information, and so that the GPU context
is not dependent on Vulkan context initialization (i.e. we still get GPU
info when Zed fails to start because Vulkan failed to initialize).
Unfortunately, the `blade` APIs do not support querying which GPU _will_
be used, so we do not know which GPU was attempted to be used when
Vulkan context initialization fails, however, when Vulkan initialization
succeeds, we send a message to the crash handler containing the result
of `gpui::Window::gpu_specs()` to include the "Active" gpu in any crash
report that may occur
Release Notes:
- N/A *or* Added/Fixed/Improved ...
Similar to nvim's telescope this makes it easier to find the right tab
in the list.
The preview takes place in the pane where the tab resides.
- on dismiss: We restore all panes.
- on confirm: We restore all panes except the one where the selected tab
resides. For this reason we collect the active item for each pane before
the tabswither starts.
Release Notes:
- Improved tab switcher, it now shows a preview of the selected tab
Co-authored-by: Julia Ryan <juliaryan3.14@gmail.com>
The `PromptCapabilities` introduced in previous PRs were only getting
set on the main message editor and not for the editors in user messages.
This caused a bug where mentions would disappear after resending the
message, and for the completion provider to be limited to files.
Release Notes:
- N/A
The loading diff animation can be jarring for external agents because
they stream the diff at the same time the tool call is pushed, so it's
only displayed while we're asynchronously calculating the diff. We'll
now only show it for the native agent.
Also, we'll now only update the diff when it changes, which avoids
unnecessarily hiding it for a few frames.
Release Notes:
- N/A
Co-authored-by: Bennet Bo Fenner <bennetbo@gmx.de>
Part of
- #28238
This PR refactors `Event::NewNavigationTarget` and `Event::Open`
handling of `PathLikeTarget` and associated code in `terminal_view.rs`
into its own file, `terminal_path_like_target.rs` for improved
testability, and adds tests which cover cases from:
- #28339
- #28407
- #33498
- #34027
- #34078
Release Notes:
- N/A
Hi! This pull request adds missing `cwd` field to all Ruby test tasks
otherwise `rdbg` will be broken when the user tries to debug a test.
Thanks!
Release Notes:
- N/A
This was causing panics due to the handles being dropped out of order.
It doesn't seem possible to guarantee the correct drop ordering given
that we're holding them over await points, so lets just spawn on the
tokio executor itself which gives us access to the state we needed those
handles for in the first place.
Fixes: ZED-1R
Release Notes:
- N/A
Co-authored-by: Conrad Irwin <conrad.irwin@gmail.com>
Co-authored-by: Marshall Bowers <git@maxdeviant.com>
The previous tags are non-customizable (added by default).
This will enable us to pull specific runs out of the pool for
maintenance.
Also disable actionlint invoking shellcheck because it chokes on
PowerShell.
Release Notes:
- N/A
---------
Co-authored-by: Cole Miller <cole@zed.dev>
This will let us track crashes-per-launch using the new minidump-based
crash reporting.
Release Notes:
- N/A
Co-authored-by: Conrad Irwin <conrad.irwin@gmail.com>
Co-authored-by: Marshall Bowers <git@maxdeviant.com>
The completion provider was already limiting the mention kinds according
to `acp::PromptCapabilities`. However, it was still using
`ContentBlock::EmbeddedResource` when
`acp::PromptCapabilities::embedded_context` was `false`. We will now use
`ResourceLink` in that case making it more complaint with the
specification.
Release Notes:
- N/A
PR #20198, "Do not alter soft wrap based on .editorconfig contents"
removed support for setting line lengths for both soft and hard wrap,
not just soft wrap. This causes the `max_line_length` property within a
`.editorconfig` file to be ignored by Zed. This commit restores allowing
for hard wrap limits to be set using `max_line_length` without impacting
soft wrap limits. This is done by merging the `max_line_length` property
from an editorconfig file into Zed's `preferred_line_length` property.
Release Notes:
- Added support for .editorconfig's `max_line_length` property
Signed-off-by: Ryan Drew <git@ry4n.me>
Closes#34445
Now we open a multi-buffer consisting of buffers that have updated,
renamed file imports.
Only local is handled, for now.
Release Notes:
- Fixed an issue where renaming a file would not update imports in
related files if they are not already open.
This PR adds the following new columns to the `billing_subscriptions`
table:
- `orb_subscription_status`
- `orb_current_billing_period_start_date`
- `orb_current_billing_period_end_date`
Release Notes:
- N/A
Rodio parts are well tested and need less configuration then the livekit
parts. I suspect there is a bug in the livekit configuration regarding
resampling. Rather then investigate that it seemed faster & easier to
swap in Rodio.
This opens the door to using other Rodio parts like:
- Decibel based volume control
- Limiter (prevents sound from becoming too loud)
- Automatic gain control
To use this add to settings:
```
"audio": {
"experimental.rodio_audio": true
}
```
Release Notes:
- N/A
Co-authored-by: Mikayla <mikayla@zed.dev>
Co-authored-by: Antonio Scandurra <me@as-cii.com>
On the latest build @maxbrunsfeld got a panic that hung zed. It appeared
that the hang occured after the minidump had been successfully written,
so our theory on what happened is that the `suspend_all_other_threads`
call in the crash handler suspended the panicking thread (due to the
signal from simulate_exception being received on a different thread),
and then when the crash handler returned everything was suspended so the
panic hook never made it to the `process::abort`.
This change makes the crash handler avoid _both_ the current and the
panicking thread which should avoid that scenario.
Release Notes:
- N/A
Instead of holding a connection for potentially long LSP queries (e.g.
rust-analyzer might take minutes to look up a definition), disconnect
right after sending the initial request and handle the follow-up
responses later.
As a bonus, this allows to cancel previously sent request on the local
Collab clients' side due to this, as instead of holding and serving the
old connection, local clients now can stop previous requests, if needed.
Current PR does not convert all LSP requests to the new paradigm, but
the problematic ones, deprecating `MultiLspQuery` and moving all its
requests to the new paradigm.
Release Notes:
- Improved resource usage when querying LSP over Collab
---------
Co-authored-by: David Kleingeld <git@davidsk.dev>
Co-authored-by: Mikayla Maki <mikayla@zed.dev>
Co-authored-by: David Kleingeld <davidsk@zed.dev>
This PR fixes the check for if the user is signed in in the Agent panel
configuration.
Supersedes https://github.com/zed-industries/zed/pull/36634.
Release Notes:
- Fixed the user's plan badge near the Zed provider in the Agent panel
not showing despite being signed in.
This PR adds a temporary workaround to supress "Aborted" errors from
Gemini when cancelling generation. This won't be needed once
https://github.com/google-gemini/gemini-cli/pull/6656 is generally
available.
Release Notes:
- N/A
schemars was passing along the newlines from the doc comments. This
should make these closer to the markdown file versions we had in the old
agent.
Release Notes:
- N/A
Uses the new
[`acp::PromptCapabilities`](a39b7f635d/rust/agent.rs (L194-L215))
to disable non-file mentions and images for agents that don't support
them.
Release Notes:
- N/A
This may be responsible for a panic that we've been seeing with
increased frequency in agent2 threads.
Release Notes:
- N/A
Co-authored-by: Conrad Irwin <conrad.irwin@gmail.com>
This was caused by calling `list_state.splice` on updated entries. We
don't need to splice the entry, as we'll recompute its measurements
automatically when we render it.
Release Notes:
- N/A
Move lints which aren't apart of the style category.
Motivation: They might get accidentally get reverted when we turn the
style category on again and remove the manual lint enforcements.
Release Notes:
- N/A
This removes around 900 unnecessary clones, ranging from cloning a few
ints all the way to large data structures and images.
A lot of these were fixed using `cargo clippy --fix --workspace
--all-targets`, however it often breaks other lints and needs to be run
again. This was then followed up with some manual fixing.
I understand this is a large diff, but all the changes are pretty
trivial. Rust is doing some heavy lifting here for us. Once I get it up
to speed with main, I'd appreciate this getting merged rather sooner
than later.
Release Notes:
- N/A
Follow-up to #36469
Part of the issue was that we hadn't defined comment and string
overrides for some languages. Hence, even after the fix edit predictions
would show up in comments for me in e.g. JSONC files.
This PR adds some more overrides where possible for this repo to ensure
this happens less frequently.
Release Notes:
- N/A
- Render a helpful message when the installed CC version is too old
- Show the full path for agent binaries when the version is not recent
enough (helps in cases where multiple binaries are installed in
different places)
- Add UI for the case where a server binary is not installed at all
- Refresh thread view after installing/updating server binary
Release Notes:
- N/A
- Return unified diff from `Edit` tool so model can see the final state
- Format on save if enabled
- Provide `Write` tool
- Disable `MultiEdit` tool
- Better prompting
Release Notes:
- N/A
This PR is one step in a series of refactors to prepare for having
"remote" projects that do not use SSH. The main use cases for this are
WSL and dev containers.
Release Notes:
- N/A
This PR makes the `stripe_subscription_id` and
`stripe_subscription_status` columns nullable on the
`billing_subscriptions` table.
Release Notes:
- N/A
- **Use key value store instead of JSON**
- **Default NewThread to the native agent when flagged**
Closes #ISSUE
Release Notes:
- N/A *or* Added/Fixed/Improved ...
We see a bunch of crash events with truncated minidumps where they have
a valid header but no events. We think this is due to an issue
generating them, so we're attaching the relevant result to the uploaded
tags.
Release Notes:
- N/A
Co-authored-by: Max Brunsfeld <maxbrunsfeld@gmail.com>
This should improve our detection of which thread crashed since they
wont be able to resume while the minidump is being generated.
Release Notes:
- N/A
- Clean up failed load tasks for mentions that require async processing
- When dragging and dropping files, hold onto added worktrees until any
async processing has completed; this fixes a bug when dragging items
from outside the project
Release Notes:
- N/A
Previously, selecting the "System" theme during onboarding would
hardcode the theme based on the device's current mode (e.g., Light or
Dark). This change ensures the "System" setting is saved correctly,
allowing the app to dynamically follow the OS theme by inserting the
correct theme in the config for both light and dark mode.
Release Notes:
- N/A
Signed-off-by: Umesh Yadav <git@umesh.dev>
There are two tests commented out in the helix file, but one of them
works again. I don't know if this is too little a change to be merged,
but I wanted to suggest it.
The other test might be more complicated though, so I didn't touch it.
Release Notes:
- N/A
This pull request introduces title generation and history replaying. We
still need to wire up the rest of the history but this gets us very
close. I extracted a lot of this code from `agent2-history` because that
branch was starting to get long-lived and there were lots of changes
since we started.
Release Notes:
- N/A
Minor tweak in the wording of the comments for the default settings
regarding the `dock` option of the panels, in order to make them
congruent across all panels.
Release Notes:
- N/A
Closes#25744
Only setting changes and editor init determined whether to show
predictions, so glob patterns and toggles correctly disabled them. On
cursor changes we call `update_visible_edit_prediction`, but we weren’t
discarding predictions when the scope changed. This PR fixes that.
Release Notes:
- Fixed an issue where the `edit_predictions_disabled_in` setting was
ignored in some cases.
Closes#34325
**Background**
When upgrading/reinstalling the ESLint language server, extracting the
archive over an existing version directory that contains symlinks can
fail and interrupt the installation.
```
failed to unpack .../vscode-eslint-2.4.4/.../client/src/shared
File exists (os error 17) when symlinking ../../$shared/ to .../client/src/shared
```
**Root cause**
Extracting into a non-empty directory conflicts with leftover
files/symlinks (e.g., `client/src/shared -> ../../$shared`), causing
“File exists (os error 17)”.
When `fs::metadata(&server_path).await.is_err()` is true, the code falls
back to cached_server_binary, but that still targets the same
(potentially corrupted/half-installed) directory and does not run `npm
install` or `npm run compile`, so the system cannot recover and remains
broken.
**Change**
Before downloading and extracting, delete the target version directory
(vscode-eslint-<version>) to ensure an empty extraction destination and
avoid conflicts.
**Alternative approaches**
temp directory + rename: extract into a clean temp directory and rename
into place to avoid half-installed states
[async-tar](https://github.com/dignifiedquire/async-tar) enhancement:
tolerate already-existing symlinks (or add a “replace-existing” option).
Release Notes:
- Fixed eslint installation not clearing files after previous attempts'
Highlight them as errors in the editor, and add a leading space when
sending them so users don't hit the odd behavior when sending these
commands to the SDK.
Release Notes:
- N/A
Note that (at least for now) this only works for creases in the "new
message" editor, not when editing past messages. That's because we don't
have the original image available when putting together the creases for
past messages, only the base64-encoded language model content.
Release Notes:
- N/A
Accidentally regressed this in #35512, causing this migration to not
work and an error log to appear when one of these actions is in the user
keymap
Release Notes:
- N/A
Closes #ISSUE
Adds `merge_message` field to the `UpdateRepository` proto message so
that suggested merge messages are displayed in remote projects.
Release Notes:
- git: Fixed an issue where suggested merge commit messages would not
appear for remote projects
This PR refactors the callout component and improves how we display
errors and warnings in the agent panel, along with improvements for
specific cases (e.g., you have `zed.dev` as your LLM provider and is
signed out).
Still a work in progress, though, wrapping up some details.
Release Notes:
- N/A
This PR makes it so `Client::sign_in_with_optional_connect` does nothing
when the user is already connected to Collab.
This fixes the issue where clicking on a channel link would temporarily
disconnect you from Collab.
Release Notes:
- N/A
I haven't found any issues related to this, but it seems like currently
the wrong directory is added to the path when spawning tasks on windows
with a python virtual environment. I also deduplicated the logic at a
few places. The same constant exists in the languages crate, but we
don't want to pull an additional dependency just for this.
-1 papercut
Release Notes:
- Fix python venv path when spawning tasks on windows
Closes#35932Closes#35933
I only intended to fix multi select in this, I accidentally drive-by
fixed the VIM issue as well. `replace_text_in_range` which I was using
before has two, to me unexpected, side-effects:
- it no-ops when input is disabled, which is the case in VIM's
Insert/Visual modes
- it takes the current selection into account, and does not just operate
on the given range (which I erroneously assumed before)
Now the code is using `buffer.edit` instead, which seems more lower
level, and does not have those side-effects. I was enthused to see that
it accepts a vec of edits, so I didn't have to calculate offsets for
following edits... until I also wanted to set selections, where I do
need to do it by hand. I'm still wondering if there is a simpler way to
do it, but for now it at least passes my muster
Release Notes:
- Added multiple selection support to UnwrapSyntaxNode action
- Fixed UnwrapSyntaxNode not working in VIM Insert/Visual modes
Follow-up of https://github.com/zed-industries/zed/pull/35306
This PR contains two changes:
Both changes are inspired from:
d90a87f955/client/src/common/textSynchronization.ts
1. Handling `textDocument/didSave` and `textDocument/didChange`
registration and unregistration correctly:
```rs
#[derive(Debug, Eq, PartialEq, Clone, Deserialize, Serialize)]
#[serde(untagged)]
pub enum TextDocumentSyncCapability {
Kind(TextDocumentSyncKind),
Options(TextDocumentSyncOptions),
}
```
- `textDocument/didSave` dynamic registration contains "includeText"
- `textDocument/didChange` dynamic registration contains "syncKind"
While storing this to Language Server, we use
`TextDocumentSyncCapability::Options` instead of
`TextDocumentSyncCapability::Kind` since it also include
[change](be7336e92a/src/lib.rs (L1714-L1717))
field as `TextDocumentSyncCapability::Kind` as well as
[save](be7336e92a/src/lib.rs (L1727-L1729))
field as `TextDocumentSyncSaveOptions`. This way while registering or
unregistering both of them, we don't accidentaly mess with other data.
So, if at intialization we end up getting
`TextDocumentSyncCapability::Kind` and we receive any above kind of
dynamic registration, we change `TextDocumentSyncCapability::Kind` to
`TextDocumentSyncCapability::Options` so we can store more data anyway.
2. Modify `include_text` method to only depend on
`TextDocumentSyncSaveOptions`, instead of depending on
`TextDocumentSyncKind`. Idea behind this is,
`TextDocumentSyncSaveOptions` should be responsible for
"textDocument/didSave" notification, and `TextDocumentSyncKind` should
be responsible for "textDocument/didChange", which it already is:
4b79eade1d/crates/project/src/lsp_store.rs (L7324-L7331)
Release Notes:
- N/A
We'll now use the anthropic provider to get credentials for `claude` and
embed its configuration view in the panel when they are not present.
Release Notes:
- N/A
This PR fixes an issue where we would redirect the user's browser to the
sign-in success page even if the OAuth callback was malformed.
We now parse the OAuth callback parameters from the query string and
only redirect to the sign-in success page when they are valid.
Release Notes:
- Updated the sign-in flow to not show the sign-in success page
prematurely.
- Correctly pre-allocate `Vec` when deserializing regexes
- Simplify manual `Vec::with_capacity` calls by using `Iterator::unzip`
- Collect directly into `Arc<[T]>` (uses `Vec` internally anyway, but
simplifies code)
- Remove unnecessary `LazyLock` around Atomics by not using const
incompatible `Default` for initialization.
Release Notes:
- N/A
In Vim mode, `ap` text object (used in `vap`, `dap`, `cap`) was
selecting multiple paragraphs when soft wrap was enabled. The bug was
caused by using DisplayRow coordinates for arithmetic instead of buffer
row coordinates in the paragraph boundary calculation.
Fix by converting to buffer coordinates before arithmetic, then back to
display coordinates for the final result.
Closes#35085
---------
Co-authored-by: Conrad Irwin <conrad.irwin@gmail.com>
The view was cancelling the generation, but `AcpThread` already handles
that, so we removed that extra code and fixed a bug where an update from
the first user message would appear after the second one.
Release Notes:
- N/A
Co-authored-by: Danilo <danilo@zed.dev>
When a turn ends and the checkpoint is updated, `AcpThread` emits
`EntryUpdated` with the index of the user message. This was causing the
message editor to be recreated and, therefore, lose focus.
Release Notes:
- N/A
Prior to https://github.com/zed-industries/zed/pull/34564 as well as
https://github.com/zed-industries/zed/pull/26893, we would have cases
where editors would be scrollable even if `soft_wrap` was set to
`editor_width`. This has regressed and improved quite a few times back
and forth. The issue was only within the editor code, the code for the
wrap map was functioning and tested properly.
Hence, this PR adds two tests to the editor rendering code in an effort
to ensure that we maintain the current correct behavior.
Release Notes:
- N/A
Closes https://github.com/zed-industries/zed/issues/11780
While auto indentation is generally nice to have, there are cases where
it is currently just not good enough for some languages (e.g. Haskell)
or users just straight up do not want their editor to auto indent for
them. Hence, this PR adds the possibilty to disable auto indentation for
either all language or on a per-language basis. Manual invocation via
the `editor: auto indent` action will continue to work.
Also takes a similar approach as
https://github.com/zed-industries/zed/pull/31569 to ensure performance
is fine for larger multicursor edits.
Release Notes:
- Added the possibility to configure auto indentation for all languages
and per language. Add `"auto_indent": false"` to your settings or
desired language to disable the feature.
Closes#36247
Fix a panic when padding inlay hints if the last character is a
multi-byte character. Regressed in
https://github.com/zed-industries/zed/pull/35786.
Release Notes:
- Fixed a crash that could occur when an inlay hint ended with `...`.
Follow up to #36278 to ensure this bug is actually fixed. Also fixes
this on two layers and adds a test for the lower layer, as we cannot
properly test it in the UI.
Furthermore, this improves the error message to show some more context
and ensures the status toast is actually only shown when the keybind was
successfully updated: Before, we would show the success toast whilst
also showing an error in the editor.
Lastly, this also fixes some issues with the status toast (and
animations) where no status toast or no animation would show in certain
scenarios.
Release Notes:
- N/A
This adds a context menu to buffer headers mimicking that of pane tabs,
notably being able to copy the relative and absolute paths of the buffer
as well as opening a terminal in the parent.
Confusingly prior to this right clicking a buffer header used to open
the context menu of the underlying editor.
Release Notes:
- Added context menu for buffer titles
Closes#36341
<img width="543" height="548" alt="image"
src="https://github.com/user-attachments/assets/ab76a32c-c622-4025-9b28-5accc8d3f04c"
/>
In the case where commit message was suggested based on single tracked
entry, this PR adds a clause to the condition to ensure there are no
staged entries.
Release Notes:
- Fixed commit message suggestion when there is one unstaged tracked
file, but multiple untracked files are staged.
- **WIP: reorganize dispositions**
- **Introduce a LocalToolchainStore trait and use it for LspAdapter
methods**
Closes#35782Closes#27331
Release Notes:
- Python: Improved propagation of a selected virtual environment into
the LSP configuration. This should the make all language-related
features such as Go to definition or Find all references more reliable.
---------
Co-authored-by: Cole Miller <cole@zed.dev>
Co-authored-by: Lukas Wirth <lukas@zed.dev>
### TL;DR
* Adds `capabilities` configuration for OpenAI-compatible models
* Relates to
https://github.com/zed-industries/zed/issues/36215#issuecomment-3193920491
### Summary
This PR introduces support for configuring model capabilities for
OpenAI-compatible language models. The implementation addresses the
issue that not all OpenAI-compatible APIs support the same features -
for example, Cerebras' API explicitly does not support
`parallel_tool_calls` as documented in their [OpenAI compatibility
guide](https://inference-docs.cerebras.ai/resources/openai#currently-unsupported-openai-features).
### Changes
1. **Model Capabilities Structure**:
- Added `ModelCapabilityToggles` struct for UI representation with
boolean toggle states
- Implemented proper parsing of capability toggles into
`ModelCapabilities`
2. **UI Updates**:
- Modified the "Add LLM Provider" modal to include checkboxes for each
capability
- Each OpenAI-compatible model can now be configured with its specific
capabilities through the UI
3. **Configuration File Structure**:
- Updated the settings schema to support a `capabilities` object for
each `openai_compatible` model
- Each capability (`tools`, `images`, `parallel_tool_calls`,
`prompt_cache_key`) can be individually specified per model
### Example Configuration
```json
{
"openai_compatible": {
"Cerebras": {
"api_url": "https://api.cerebras.ai/v1",
"available_models": [
{
"name": "gpt-oss-120b",
"max_tokens": 131000,
"capabilities": {
"tools": true,
"images": false,
"parallel_tool_calls": false,
"prompt_cache_key": false
}
}
]
}
}
}
```
### Tests Added
- Added tests to verify default capability values are correctly applied
- Added tests to verify that deselected toggles are properly parsed as
`false`
- Added tests to verify that mixed capability selections work correctly
Thanks to @osyvokon for the desired `capabilities` configuration
structure!
Release Notes:
- OpenAI-compatible models now have configurable capabilities (#36370;
thanks @calesennett)
---------
Co-authored-by: Oleksiy Syvokon <oleksiy@zed.dev>
Closes#36229
Fix zero-sized texture creation that triggers a SIGABRT in the Metal
renderer. Not sure why this happens yet, but it likely occurs when
`native_window.contentView()` returns a zero `NSSize` during initial
window creation, before the view size is computed.
Release Notes:
- Fixed a rare startup crash on macOS.
This PR adds the git clone action to the project panel. It also changes
the "open" button to open a folder instead of the recent projects modal,
which feels faster to start with, more intuitive, and also consistent
with VS Code (which I think is good in this specific case).
<img width="500" height="1334" alt="CleanShot 2025-08-17 at 2 10 01@2x"
src="https://github.com/user-attachments/assets/ff953228-9e8e-413b-89ba-fa0870a0df17"
/>
Release Notes:
- Improved the project panel empty state by including the git clone
action and allowing users to quickly open a local folder.
After redesigning all Zed icons
(https://github.com/zed-industries/zed/pull/35856), it felt like using
1.5 for stroke width didn't really flow well with the default typeface
default font weight. Reducing it to 1.2 makes the UI much sharper, less
burry, and more cohesive overall.
Release Notes:
- N/A
Closes#36097
Release Notes:
- Fixed API key input fields getting shrunk in Agent Panel settings view
on low panel widths paired with high UI font sizes.
This PR removes the `/docs` slash command.
We never fully shipped this—with it requiring explicit opt-in via a
setting—and it doesn't seem like the feature is needed in an agentic
world.
Release Notes:
- Removed the `/docs` slash command.
Ensures issues like #36242 and #36295 do not arise where users are
confused that the agent panel does not follow the default UI font size
whilst also keeping the possibility of customization. The agent font
size was matching the UI font size previously alredy, which makes it
easier to change it for most scenarios.
Also cleans up some related logic around modifying the font sizes.
Release Notes:
- The agent panel font size will now inherit the UI font size by default
if not set in your settings.
This PR removes the billing-related tables from the SQLite schema, as we
don't actually reference these tables anywhere in the Collab codebase
anymore.
Release Notes:
- N/A
This PR updates the `admin` column on the `users` table to be
non-nullable.
We were already treating it like this in practice.
All rows in the production database already have a value for the `admin`
column.
Release Notes:
- N/A
Closes#36297
While we set the editor as read-only for bundled files, we didn't do
this for the underlying buffer. This PR fixes this and adds a test for
the corresponding case.
Release Notes:
- Fixed an issue where bundled files (e.g. the default settings) could
be edited in some circumstances
The minidump-based crash reporting is now entirely separate from our
legacy panic_hook-based reporting. This should improve the association
of minidumps with their metadata and give us more consistent crash
reports.
Release Notes:
- N/A
---------
Co-authored-by: Max Brunsfeld <maxbrunsfeld@gmail.com>
Release Notes:
- Added an option for the status_bar.cursor_position_button. Setting to
`false` will hide the button. It defaults to `true`.
This builds off the recent work to hide the language selection button
(https://github.com/zed-industries/zed/pull/33977). I tried to follow
that pattern, and to pick a clear name for the option, but any
feedback/change is welcome.
---------
Co-authored-by: zumbalogy <3770982+zumbalogy@users.noreply.github.com>
Closes #ISSUE
Release Notes:
- Keymap Editor: Fixed an issue where leaving the arguments field empty
would result in an error even if arguments were optional
Follow-up to https://github.com/zed-industries/zed/pull/36233
The above PR simplified the handling but introduced some bugs: The
replace buttons were no longer clickable, some buttons also lost their
toggle states, some buttons shared their element id and, lastly, some
buttons were clickable but would not trigger the right action. This PR
fixes all that.
Release Notes:
- N/A
This PR increases the minimum required version to connect to Collab.
Previously this was set at v0.157.0.
The new minimum required version is v0.198.4, which is the first version
where we no longer connect to Collab automatically.
Clients on the v0.199.x minor version will also need to be v0.199.2 or
greater in order to connect, due to us hotfixing the connection changes
to the Preview branch.
We're doing this to force clients to upgrade in order to connect to
Collab, as we're going to be removing some of the old RPC usages related
to authentication that are no longer used. Therefore, we want users to
be on a version of Zed that does not rely on those messages.
Users will see a message similar to this one, prompting them to upgrade:
<img width="1209" height="875" alt="Screenshot 2025-08-15 at 11 37
55 AM"
src="https://github.com/user-attachments/assets/59ffff3e-8f82-4152-84a8-776c691eaaee"
/>
> Note: In this case I'm simulating the error state, which is why I'm
signed in via Cloud while still not being able to connect to Collab.
Users on older versions will see the "Please update Zed to Collaborate"
message without being signed in.
Release Notes:
- N/A
1. Previously, checkpoints only appeared when an agent's edit happened
immediately after a user message. This is rare (agent usually collects
some context first), so they were almost never shown. This is now fixed.
2. After this change, a checkpoint is created after every edit
operation. So when the agent edits files five times in a single dialog
turn, we will now display five checkpoints.
As a bonus, it's now possible to undo only a part of a long agent
response.
Closes#36092, #32917
Release Notes:
- Create agent checkpoints more frequently (before every edit)
Closes#24672
This PR complements a feature added earlier by @JosephTLyons (in
https://github.com/zed-industries/zed/pull/32353) where the text is
considered as the tab title in a new buffer. It piggybacks off that
change and sets the title as the suggested filename in the save dialog
(completely mirroring the same functionality in VSCode):

Release Notes:
- Text entered in a new untitled buffer is considered as the default
filename when saving
This PR removes the `POST /users/:id/refresh_llm_tokens` and `POST
/users/:id/update_plan` endpoints from Collab.
These endpoints were added to be called by Cloud in order to push down
notifications over the Collab RPC connection.
Cloud now sends down notifications to clients directly, so we no longer
need these endpoints.
All calls to these endpoints have already been removed in production.
Release Notes:
- N/A
Closes#18565
I could use some advice on the color palette / theming. A couple
options:
1. The `drop_target_background` color could be used for the border if we
didn't use it for the background of the tab. In VSCode, the background
color of tabs doesn't change as you're dragging, there's just a border
between tabs. My only concern with this option is that the current
`drop_target_background` color is a bit subtle when used for a small
area like a border.
2. Another option could be to add a `drop_target_border` theme color,
but I don't know how much complexity this adds to implementation
(presumably all existing themes would need to be updated?).
Demo:
https://github.com/user-attachments/assets/0b7c04ea-5ec5-4b45-adad-156dfbf552db
Release Notes:
- Highlight where a dragged tab will be dropped between two other tabs
---------
Co-authored-by: Smit Barmase <heysmitbarmase@gmail.com>
Some APIs fail when they get this parameter
Closes#36215
Release Notes:
- Fixed OpenAI-compatible providers that don't support prompt caching
and/or reasoning
Adds component NotificationFrame. It implements a subset of MessageNotification as a Component and refactors MessageNotification to use NotificationFrame. Having some notification UI Component is nice as it allows us to easily build new types of notifications.
Uses the new NotificationFrame component for CaptureAudioNotification.
Adds a CaptureAudio action in the dev namespace (not meant for
end-users). It records 10 seconds of audio and saves that to a wav file.
Release Notes:
- N/A
---------
Co-authored-by: Mikayla <mikayla@zed.dev>
- project search query string now turns red when no results are found
matching buffer search behavior
- General code deduplication as well as more consistent layout between
the two bars, as some minor details have drifted apart
- Tab cycling in buffer search now ends up in editor focus when cycling
backwards, matching forward cycling
- Report parse errors in filter include and exclude editors
Release Notes:
- N/A
Closes#29083
On X11, `ibus-x11` crashes on some distros after Zed interacts with it.
This is not unique to Zed, `xim-rs` shows the same behavior, and there
are similar upstream `ibus` reports with apps like Blender:
- https://github.com/ibus/ibus/issues/2697
I opened an upstream issue to track this:
- https://github.com/ibus/ibus/issues/2789
When this crash happens, we don’t get a disconnect event, so Zed keeps
sending events to the IM server and waits for a response. It works on
subsequent starts because IM server doesn't exist now and we default to
non-XIM path.
This PR detects the crash via X11 events and falls back to the non-XIM
path so typing keeps working. We still need to investigate whether the
root cause is in `xim-rs` or `ibus-x11`.
Release Notes:
- Fixed an issue on X11 where keyboard input sometimes didn’t work on
first start.
Closes #ISSUE
This will allow devs to opt out of the musl build when developing zed by
running `ZED_BUILD_REMOTE_SERVER=nomusl cargo r` which also fixes remote
builds on NixOS.
Release Notes:
- Add a env flag (`ZED_BUILD_REMOTE_SERVER=nomusl`) to opt out of musl
builds when building the remote server
- Support adding ImageContent to messages through copy/paste and through
path completions
- Ensure images are fully converted to LanguageModelImageContent before
sending them to the model
- Update ACP crate to v0.0.24 to enable passing image paths through the
protocol
Release Notes:
- N/A
---------
Co-authored-by: Conrad Irwin <conrad.irwin@gmail.com>
The latest release has span changes in it which prevents rust-analyzer
from constantly showing `Box` and `Box::pin` on hover as well as those
items polluting the go to definition feature on every identifier.
See https://github.com/dtolnay/async-trait/pull/293
Release Notes:
- N/A
We were leaking diffs and terminals on rewind, we'll now clean them up.
This PR also introduces a refactor of how we mantain the entry view
state to use a `Vec` that's kept in sync with the thread entries.
Release Notes:
- N/A
Follow-up for #36093 and
https://github.com/zed-industries/zed/pull/36138
Since v1.355.0, `@github/copilot-language-server` has stopped responding
to `CheckStatus` requests if a `DidChangeConfiguration` notification
hasn’t been sent beforehand. This causes `CheckStatus` to remain in an
await state until it times out, leaving the connection stuck for a long
period before finally throwing a timeout error.
```rs
let status = server
.request::<request::CheckStatus>(request::CheckStatusParams {
local_checks_only: false,
})
.await
.into_response() // bails here with ConnectionResult::Timeout
.context("copilot: check status")?;
````
This PR fixes the issue by sending the `DidChangeConfiguration`
notification before making the `CheckStatus` request. It’s just an
ordering change i.e. no other LSP actions occur between these two calls.
Previously, we only updated our internal connection status and UI in
between.
Release Notes:
- Fixed an issue where GitHub Copilot could get stuck and fail to sign
in.
In vim and zed (vim and helix modes) typing "tx" will jump before the
next `x`, but typing it again won't do anything. But in helix the cursor
just jumps before the `x` after that. I added that in helix mode.
This also solves another small issue where the selection doesn't include
the first `x` after typing "fx" twice. And similarly after typing "Fx"
or "Tx" the selection should include the character that the motion
startet on.
Release Notes:
- helix: Fixed inconsistencies in the "f" and "t" motions
Closes #ISSUE
Release Notes:
- Keymap Editor: Added a button in the top left to allow opening the
keymap JSON file. Right clicking the button provides shortcuts to
opening the default Zed and Vim keymaps as well.
Closes https://github.com/zed-industries/zed/issues/36149
Release Notes:
- Fixed a bug where changing the `toolbar.breadcrumbs` setting didn't
immediately update the UI when saving the `settings.json` file.
cc https://github.com/zed-industries/zed/issues/34666
Display printing anyhow errors only renders the error itself, but not
any of its causes so we've been dropping the important context when
showing the issue to the users.
Release Notes:
- N/A
- we are about to drop Zed for MINGW64 because `crash-handler` uses a
symbol which is not presented in `msvcrt.dll`
- mention MSYS2 docs page and CLANGARM64 environment
Release Notes:
- N/A
Follow up of this pr: #25148
Release Notes:
- Improved file sorting.
As described in #20126, I was fed up with lexicographical file sorting
in the project panel. The current sorting behavior doesn't handle
numeric segments properly, leading to unintuitive ordering like
`file_1.rs`, `file_10.rs`, `file_2.rs`.
## Example Sorting Results
Using `lexicographical` (default):
```
.
├── file_01.rs
├── file_1.rs
├── file_10.rs
├── file_1025.rs
├── file_2.rs
```
Using alphabetical (natural) sorting:
```
.
├── file_1.rs
├── file_01.rs
├── file_2.rs
├── file_10.rs
├── file_1025.rs
```
Currently, the terminal search function doesn't work well with ViMode.
It matches the search terms, scrolls the active match in the view, but
it doesn't move the cursor to the match, which makes it useless for
navigating the scrollback in vimode.
With this improvement, if a user activates ViMode before the search Zed
moves the cursor to the active search terms. So, when the search dialog
is dismissed the cursor is places on the latest active search term and
it's possible to navigate the scrollback via ViMode using this place as
the starting point.
https://github.com/user-attachments/assets/63325405-ed93-4bf8-a00f-28ded5511f31
Release Notes:
- Improved the search function in the terminal when ViMode is activated
Closes#35805
If the cursor is between column 0 and the indent size, pressing
`cmd-left` jumps to the indent. Pressing it again moves to the true
column 0. Further presses toggle between indent and column 0.
This PR changes the first `cmd-left` to go to column 0 instead of
indent. Toggling between is unaffected.
Release Notes:
- Fixed issue where pressing `cmd-left` with the cursor in the leading
spaces moved to the start of the text first. It now goes to the
beginning of the line first, then the start of the text.
The Zed Plex fonts were found to violate the OFL by using the word Plex
in the name.
Lilex has better ligatures and box-drawing characters than Zed Plex
Mono, but Zed Plex Sans should be identical
to IBM Plex Sans.
Closes#15542Closeszed-industries/zed-fonts#31
Release Notes:
- The "Zed Plex Sans" and "Zed Plex Mono" fonts have been replaced with
"IBM Plex Sans" and "Lilex". The old names still work for backward
compatibility. Other than fixing line-drawing characters, and improving
the ligatures, there should be little visual change as the fonts are all
of the same family.
- Introduced ".ZedSans" and ".ZedMono" as aliases to allow us to easily
change the default fonts in the future. These currently default to "IBM
Plex Sans" and "Lilex" respectively.
2025-08-13 13:25:52 -06:00
2509 changed files with 382855 additions and 181109 deletions
# Arrays are merged together though. See: https://doc.rust-lang.org/cargo/reference/config.html#hierarchical-structure
# The intent for this file is to configure CI build process with a divergance from Zed developers experience; for example, in this config file
# we use `-D warnings` for rustflags (which makes compilation fail in presence of warnings during build process). Placing that in developers `config.toml`
# would be incovenient.
# would be inconvenient.
# The reason for not using the RUSTFLAGS environment variable is that doing so would override all the settings in the config.toml file, even if the contents of the latter are completely nonsensical. See: https://github.com/rust-lang/cargo/issues/5376
# Here, we opted to use `[target.'cfg(all())']` instead of `[build]` because `[target.'**']` is guaranteed to be cumulative.
[target.'cfg(all())']
rustflags=["-D","warnings"]
# We don't need fullest debug information for dev stuff (tests etc.) in CI.
[profile.dev]
debug="limited"
# Use Mold on Linux, because it's faster than GNU ld and LLD.
#
# We no longer set this in the default `config.toml` so that developers can opt in to Wild, which
# is faster than Mold, in their own ~/.cargo/config.toml.
filter='package(worktree) and test(test_random_worktree_changes)'
priority=100
[[profile.default.overrides]]
filter='package(collab) and (test(random_project_collaboration_tests) or test(random_channel_buffer_tests) or test(test_contact_requests) or test(test_basic_following))'
priority=99
[[profile.default.overrides]]
filter='package(extension_host) and test(test_extension_store_with_test_extension)'
Something else is broken in Zed (exclude crashing).
type:"Bug"
name:Report a bug
description:Report a problem with Zed.
type:Bug
labels:"state:needs triage"
body:
- type:markdown
attributes:
value:|
Is this bug already reported? Upvote to get it noticed faster. [Here's the search](https://github.com/zed-industries/zed/issues). Upvote means giving it a :+1: reaction.
Feature request? Please open in [discussions](https://github.com/zed-industries/zed/discussions/new/choose) instead.
Just have a question or need support? Welcome to [Discord Support Forums](https://discord.com/invite/zedindustries).
- type:textarea
attributes:
label:Summary
description:Provide a one sentence summary and detailed reproduction steps
value:|
<!-- Begin your issue with a one sentence summary -->
SUMMARY_SENTENCE_HERE
### Description
<!-- Describe with sufficient detail to reproduce from a clean Zed install.
- Any code must be sufficient to reproduce (include context!)
- Code must as text, not just as a screenshot.
- Issues with insufficient detail may be summarily closed.
-->
DESCRIPTION_HERE
Steps to reproduce:
1.
2.
3.
4.
**Expected Behavior**:
**Actual Behavior**:
<!-- Before Submitting, did you:
1. Include settings.json, keymap.json, .editorconfig if relevant?
2. Check your Zed.log for relevant errors? (please include!)
3. Click Preview to ensure everything looks right?
4. Hide videos, large images and logs in ``` inside collapsible blocks:
<details><summary>click to expand</summary>
```json
```
</details>
-->
label:Reproduction steps
description:A step-by-step description of how to reproduce the bug from a **clean Zed install**. The more context you provide, the easier it is to find and fix the problem fast.
placeholder:|
1. Start Zed
2. Click X
validations:
required:true
- type:textarea
attributes:
label:Current vs. Expected behavior
description:|
Current behavior (screenshots, videos, etc. are appreciated), vs. what you expected the behavior to be.
placeholder:|
Current behavior: <screenshot with an arrow> The icon is blue. Expected behavior: The icon should be red because this is what the setting is documented to do.
validations:
required:true
- type:textarea
id:environment
attributes:
label:Zed Version and System Specs
label:Zed version and system specs
description:|
Open Zed, from the command palette select "zed: copy system specs into clipboard"
Open the command palette in Zed, then type “zed: copy system specs into clipboard”.
Open the command palette in Zed, then type `zed: open log` to see the last 1000 lines. Or type `zed: reveal log in file manager` in the command palette to reveal the log file itself.
value:|
<details><summary>Zed.log</summary>
<!-- Paste your log inside the code block. -->
```log
```
</details>
validations:
required:false
- type:textarea
attributes:
label:Relevant Zed settings
description:|
Open the command palette in Zed, then type “zed: open settings file” and copy/paste any relevant (e.g., LSP-specific) settings.
value:|
<details><summary>settings.json</summary>
<!-- Paste your settings inside the code block. -->
```json
```
</details>
validations:
required:false
- type:textarea
attributes:
label:(for AI issues) Model provider details
placeholder:|
- Provider: (Anthropic via ZedPro, Anthropic via API key, Copilot Chat, Mistral, OpenAI, etc.)
- Model Name: (Claude Sonnet 4.5, Gemini 3 Pro, GPT-5)
- Mode: (Agent Panel, Inline Assistant, Terminal Assistant or Text Threads)
- Other details (ACPs, MCPs, other settings, etc.):
validations:
required:false
- type:dropdown
attributes:
label:If you are using WSL on Windows, what flavor of Linux are you using?
description:Zed is crashing or freezing or hanging.
type:Crash
labels:"state:needs triage"
body:
- type:textarea
attributes:
label:Summary
description:Summarize the issue with detailed reproduction steps
value:|
<!-- Begin your issue with a one sentence summary -->
SUMMARY_SENTENCE_HERE
### Description
<!-- Include all steps necessary to reproduce from a clean Zed installation. Be verbose -->
Steps to trigger the problem:
1.
2.
3.
Actual Behavior:
Expected Behavior:
validations:
required:true
- type:textarea
id:environment
attributes:
label:Zed Version and System Specs
description:'Open Zed, and in the command palette select "zed: copy system specs into clipboard"'
label:Reproduction steps
description:A step-by-step description of how to reproduce the crash from a **clean Zed install**. The more context you provide, the easier it is to find and fix the problem fast.
placeholder:|
Output of "zed: copy system specs into clipboard"
1. Start Zed
2. Perform an action
3. Zed crashes
validations:
required:true
- type:textarea
attributes:
label:If applicable, attach your `~/Library/Logs/Zed/Zed.log` file to this issue.
label:Zed version and system specs
description:|
macOS: `~/Library/Logs/Zed/Zed.log`
Linux: `~/.local/share/zed/logs/Zed.log` or $XDG_DATA_HOME
If you only need the most recent lines, you can run the `zed: open log` command palette action to see the last 1000.
Open the command palette in Zed, then type “zed: copy system specs into clipboard”.
Open the command palette in Zed, then type `zed: open log` to see the last 1000 lines. Or type `zed: reveal log in file manager` in the command palette to reveal the log file itself.
We're working to clean up our issue tracker by closing older issues that might not be relevant anymore. If you are able to reproduce this issue in the latest version of Zed, please let us know by commenting on this issue, and we will keep it open. If you can't reproduce it, feel free to close the issue yourself. Otherwise, we'll close it in 7 days.
We're working to clean up our issue tracker by closing older bugs that might not be relevant anymore. If you are able to reproduce this issue in the latest version of Zed, please let us know by commenting on this issue, and it will be kept open. If you can't reproduce it, feel free to close the issue yourself. Otherwise, it will close automatically in 14 days.
Thanks for your help!
close-issue-message:"This issue was closed due to inactivity. If you're still experiencing this problem, please open a new issue with a link to this issue."
* When implementing async operations that may fail, ensure errors propagate to the UI layer so users get meaningful feedback.
* Never create files with `mod.rs` paths - prefer `src/some_module.rs` instead of `src/some_module/mod.rs`.
* When creating new crates, prefer specifying the library root path in `Cargo.toml` using `[lib] path = "...rs"` instead of the default `lib.rs`, to maintain consistent and descriptive naming (e.g., `gpui.rs` or `main.rs`).
* Use full words for variable names (no abbreviations like "q" for "queue")
* Use variable shadowing to scope clones in async contexts for clarity, minimizing the lifetime of borrowed references.
Example:
```rust
executor.spawn({
let task_ran = task_ran.clone();
async move {
*task_ran.borrow_mut() = true;
}
});
```
# GPUI
@@ -46,7 +59,7 @@ Trying to update an entity while it's already being updated must be avoided as t
When `read_with`, `update`, or `update_in` are used with an async context, the closure's return value is wrapped in an `anyhow::Result`.
`WeakEntity<T>` is a weak handle. It has `read_with`, `update`, and `update_in` methods that work the same, but always return an `anyhow::Result` so that they can fail if the entity no longer exists. This can be useful to avoid memory leaks - if entities have mutually recursive handles to eachother they will never be dropped.
`WeakEntity<T>` is a weak handle. It has `read_with`, `update`, and `update_in` methods that work the same, but always return an `anyhow::Result` so that they can fail if the entity no longer exists. This can be useful to avoid memory leaks - if entities have mutually recursive handles to eachother they will never be dropped.
Thanks for your interest in contributing to Zed, the collaborative platform that is also a code editor!
Thank you for helping us make Zed better!
All activity in Zed forums is subject to our [Code of Conduct](https://zed.dev/code-of-conduct). Additionally, contributors must sign our [Contributor License Agreement](https://zed.dev/cla) before their contributions can be merged.
All activity in Zed forums is subject to our [Code of
Conduct](https://zed.dev/code-of-conduct). Additionally, contributors must sign
our [Contributor License Agreement](https://zed.dev/cla) before their
contributions can be merged.
## Contribution ideas
If you're looking for ideas about what to work on, check out:
Zed is a large project with a number of priorities. We spend most of
our time working on what we believe the product needs, but we also love working
with the community to improve the product in ways we haven't thought of (or had time to get to yet!)
In particular we love PRs that are:
- Fixes to existing bugs and issues.
- Small enhancements to existing features, particularly to make them work for more people.
- Small extra features, like keybindings or actions you miss from other editors or extensions.
- Work towards shipping larger features on our roadmap.
If you're looking for concrete ideas:
- Our [public roadmap](https://zed.dev/roadmap) contains a rough outline of our near-term priorities for Zed.
- Our [top-ranking issues](https://github.com/zed-industries/zed/issues/5393) based on votes by the community.
- Our [public roadmap](https://zed.dev/roadmap) contains a rough outline of our near-term priorities for Zed.
For adding themes or support for a new language to Zed, check out our [docs on developing extensions](https://zed.dev/docs/extensions/developing-extensions).
## Sending changes
## Proposing changes
The Zed culture values working code and synchronous conversations over long
discussion threads.
The best way to propose a change is to [start a discussion on our GitHub repository](https://github.com/zed-industries/zed/discussions).
The best way to get us to take a look at a proposed change is to send a pull
request. We will get back to you (though this sometimes takes longer than we'd
like, sorry).
First, write a short **problem statement**, which _clearly_ and _briefly_ describes the problem you want to solve independently from any specific solution. It doesn't need to be long or formal, but it's difficult to consider a solution in absence of a clear understanding of the problem.
Although we will take a look, we tend to only merge about half the PRs that are
submitted. If you'd like your PR to have the best chance of being merged:
Next, write a short **solution proposal**. How can the problem (or set of problems) you have stated above be addressed? What are the pros and cons of your approach? Again, keep it brief and informal. This isn't a specification, but rather a starting point for a conversation.
- Include a clear description of what you're solving, and why it's important to you.
- Include tests.
- If it changes the UI, attach screenshots or screen recordings.
By effectively engaging with the Zed team and community early in your process, we're better positioned to give you feedback and understand your pull request once you open it. If the first thing we see from you is a big changeset, we're much less likely to respond to it in a timely manner.
The internal advice for reviewers is as follows:
## Pair programming
- If the fix/feature is obviously great, and the code is great. Hit merge.
- If the fix/feature is obviously great, and the code is nearly great. Send PR comments, or offer to pair to get things perfect.
- If the fix/feature is not obviously great, or the code needs rewriting from scratch. Close the PR with a thank you and some explanation.
We plan to set aside time each week to pair program with contributors on promising pull requests in Zed. This will be an experiment. We tend to prefer pairing over async code review on our team, and we'd like to see how well it works in an open source setting. If we're finding it difficult to get on the same page with async review, we may ask you to pair with us if you're open to it. The closer a contribution is to the goals outlined in our roadmap, the more likely we'll be to spend time pairing on it.
If you need morefeedback from us: the best way is to be responsive to
Github comments, or to offer up time to pair with us.
## Tips to improve the chances of your PR getting reviewed and merged
If you are making a larger change, or need advice on how to finish the change
you're making, please open the PR early. We would love to help you get
things right, and it's often easier to see how to solve a problem before the
diff gets too big.
- Discuss your plans ahead of time with the team
- Small, focused, incremental pull requests are much easier to review
- Spend time explaining your changes in the pull request body
- Add test coverage and documentation
- Choose tasks that align with our roadmap
- Pair with us and watch us code to learn the codebase
- Low effort PRs, such as those that just re-arrange syntax, won't be merged without a compelling justification
## Things we will (probably) not merge
## File icons
Although there are few hard and fast rules, typically we don't merge:
Zed's default icon theme consists of icons that are hand-designed to fit together in a cohesive manner.
We do not accept PRs for file icons that are just an off-the-shelf SVG taken from somewhere else.
### Adding new icons to the Zed icon theme
If you would like to add a new icon to the Zed icon theme, [open a Discussion](https://github.com/zed-industries/zed/discussions/new?category=ux-and-design) and we can work with you on getting an icon designed and added to Zed.
- Anything that can be provided by an extension. For example a new language, or theme. For adding themes or support for a new language to Zed, check out our [docs on developing extensions](https://zed.dev/docs/extensions/developing-extensions).
- New file icons. Zed's default icon theme consists of icons that are hand-designed to fit together in a cohesive manner, please don't submit PRs with off-the-shelf SVGs.
- Giant refactorings.
- Non-trivial changes with no tests.
- Stylistic code changes that do not alter any app logic. Reducing allocations, removing `.unwrap()`s, fixing typos is great; making code "more readable" — maybe not so much.
- Features where (in our subjective opinion) the extra complexity isn't worth it for the number of people who will benefit.
- Anything that seems completely AI generated.
## Bird's-eye view of Zed
We suggest you keep the [Zed glossary](docs/src/development/glossary.md) at your side when starting out. It lists and explains some of the structures and terms you will see throughout the codebase.
Zed is made up of several smaller crates - let's go over those you're most likely to interact with:
- [`gpui`](/crates/gpui) is a GPU-accelerated UI framework which provides all of the building blocks for Zed. **We recommend familiarizing yourself with the root level GPUI documentation.**
Welcome to Zed, a high-performance, multiplayer code editor from the creators of [Atom](https://github.com/atom/atom) and [Tree-sitter](https://github.com/tree-sitter/tree-sitter).
@@ -9,11 +9,10 @@ Welcome to Zed, a high-performance, multiplayer code editor from the creators of
### Installation
On macOS and Linux you can [download Zed directly](https://zed.dev/download) or [install Zed via your local package manager](https://zed.dev/docs/linux#installing-via-a-package-manager).
On macOS, Linux, and Windows you can [download Zed directly](https://zed.dev/download) or [install Zed via your local package manager](https://zed.dev/docs/linux#installing-via-a-package-manager).
Other platforms are not yet available:
- Windows ([tracking issue](https://github.com/zed-industries/zed/issues/5394))
- Web ([tracking issue](https://github.com/zed-industries/zed/issues/5396))
Some files were not shown because too many files have changed in this diff
Show More
Reference in New Issue
Block a user
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.