8b5ef25
docs: Add documentation for Seed search query from cursor (#25875)
Click to expand commit body
Missing documentation added for `seed_search_query_from_cursor`.
Release Notes:
- N/A
Devzeth
created
fec228b
Fix issue with `cmd-w` closing window in preview tabs on MacOS (#25878)
Click to expand commit body
Closes #25810
Reorders default macOS keymap so that `cmd-w` in `"context":
"PromptLibrary"` bindings is not the last binding for
`workspace::CloseWindow` and therefore does not get rendered in the app
menu or intercepted by MacOS
Release Notes:
- N/A
Ben Kunkle
created
e00d737
Add `constructor` highlighting for JS/TS/TSX (#25207)
Click to expand commit body
Closes #19267
Adds highlight field specifically for `constructor` in JS/TS/TSX so that
it can be highlighted as a different color than regular methods
Release Notes:
- N/A
---------
Co-authored-by: Ben Kunkle <ben@zed.dev>
Devzeth
and
Ben Kunkle
created
b0dee94
pane: Hide "Copy Relative Path" and "Reveal In Project Panel" actions for files outside of the projects (#25386)
Click to expand commit body
"Copy Relative Path" action had a check for existence of relative path
but it always passed because
[`WorktreeStore::find_worktree()`](https://github.com/zed-industries/zed/blob/1d5499bee72f1ea57ed883b942f05d5c1e7cec89/crates/project/src/worktree_store.rs#L148)
function returned empty path for these kinds of files. It feels correct
to make changes there, but I don't know what else could be impacted.
"Reveal In Project Panel" had no check whatsoever and so I made one.
Release Notes:
- N/A
Egor Krugletsov
created
e65471c
Optimize JSON merging by removing redundant key clones in serde_json operations (#25866)
Click to expand commit body
Hi Zed team! 👋
As a fan of Zed Editor who's excited to contribute, I noticed a small
optimization opportunity in the JSON merging utilities.
<b>Changes:</b>
Removed redundant key.clone() calls in insert() operations within 2
functions:
1. merge_json_value_into
2. merge_non_null_json_value_into
<b>Why:</b>
Since we're already moving ownership of `source_object` 's contents and
key is no longer used further, we could directly pass `key` to `insert`
without cloning.
Eliminates redundant allocations, improving performance slightly for
JSON-heavy operations.
<b>Testing:</b>
I have tested this locally and all existing tests passed. The change
preserves behavior while removing redundancy.
Love using Zed and happy to contribute! Let me know if any adjustments
are needed!
Release Notes:
- N/A
greathongtu
created
6713ec8
windows: Bring back restoration of tabs (#25870)
Click to expand commit body
Closes #25022
Release Notes:
- N/A
张小白
created
48e09c0
Tweak the Git beta issue template (#25869)
Click to expand commit body
Release Notes:
- N/A
Joseph T. Lyons
created
3f03d7b
Add a temporary issue template for Git beta bugs (#25867)
Click to expand commit body
Release Notes:
- N/A
Joseph T. Lyons
created
fa96e22
paths: Add support for clickable file paths in the Odin language format (#25842)
Click to expand commit body
This PR adds support for clickable file paths in the Odin language format.
The odin compiler errors use the format `/path/to/file.odin(1:1)`. We
didn't recognize this format, making these paths non-clickable in the
terminal.
Also added tests for this.
Release Notes:
- Added support for clickable file paths in the Odin language format.
---------
Co-authored-by: Peter Tripp <peter@zed.dev>
Devzeth
and
Peter Tripp
created
a8a05f2
cli: Add extra paths in `detect()` on Windows (#25765)
Click to expand commit body
I'm already integrating CLI into MSYS2 package, and this patche helped
me to make it work like in Arch:
https://github.com/msys2/MINGW-packages/pull/23537. used the same way as
in [Linux
implementation](https://github.com/zed-industries/zed/blob/6856e869fcb8fd2e164a2c43b42ac5046f1d7ea8/crates/cli/src/main.rs#L314)
Closes #ISSUE
Release Notes:
- N/A
Maksim Bondarenkov
created
aa1ab50
Add stop_at_indent for Editor::DeleteToBeginningOfLine (#25688)
Click to expand commit body
Added test_beginning_of_line_stop_at_indent editor test
- Follow-up to: https://github.com/zed-industries/zed/pull/25428
- Replaces: https://github.com/zed-industries/zed/pull/25346
This is all authored by @felixpackard in #25346
I just updated it to use `stop_at_indent` instead of
`stop_at_first_char`.
Release Notes:
- Added support for `stop_at_indent` to
`Editor::DeleteToBeginningOfLine` (thanks
[@felixpackard](https://github.com/felixpackard))
Co-authored-by: Felix Packard <felix@rigr.gg>
Peter Tripp
and
Felix Packard
created
d115cb1
windows: Use dev drive instead of `ReFS` (#25858)
42571e4
Ensure inlay hint toggling with modifiers happens fast (#25852)
Click to expand commit body
Follow-up of https://github.com/zed-industries/zed/pull/25766
Fixes the bugs found:
* modifier toggle not happening instantly due to `edit_debounce_ms`
considered
* hint update race that ignored the cache clear
Release Notes:
- N/A
Kirill Bulatov
created
2d61a51
Diff View: Scroll to center of hunks when reviewing (#25846)
Click to expand commit body
When reviewing hunks, scroll to put them at the center of the screen
so you can better see the context around that hunk.
The field `center_cursor` was added to the actions `editor::GoToHunk`
and `editor::GoToPrevHunk`, this was set to `false` by default in
keymaps, as it wouldn't help with in-editor navigation.
The field is set to `true` for when you trigger `git::StageAndNext`
and `git::UnstageAndNext`, this is also `true` for the buttons in the
Diff View toolbar.
Release Notes:
- N/A
João Marcos
created
a2876f5
Support hunk-wise `StageAndNext` and `UnstageAndNext` (#25845)
Click to expand commit body
This PR adds the `whole_excerpt` field to the actions:
- `git::StageAndNext`
- `git::UnstageAndNext`
Which is set by false by default, effectively, now staging and unstaging
with these actions is done hunk-by-hunk, this also affects the `Stage`
and
`Unstage` buttons in the Diff View toolbar.
A caveat: with this PR, there is no way to configure the buttons in the
Diff
View toolbar to restore the previous behavior, if we want, I think we
can make
it a setting, but let's see if anyone really wants that.
Release Notes:
- N/A
694afd1
Fix buffer search options not resetting when dismissed after Vim mode search then reopened with `buffer: deploy search` (#25838)
Click to expand commit body
Closes #25315
Release Notes:
- Fixes an issue where the buffer search options would not be reset when
using `buffer: deploy search` after using Vim search (`*` & `#`) which
enable all search options
Ben Kunkle
created
eb648dd
Follow-up tweaks to new git panel footer (#25832)
Click to expand commit body
- Use a popover for the branch picker
- Don't deploy a repository selector if there's only one repo
Release Notes:
- N/A
ec88a68
Fix active pane modifiers applying to parent pane axis if child pane is active (#25836)
Click to expand commit body
Closes #25304
Release Notes:
- Fixed an issue where `active_pane_modifiers` settings would be applied
to a parent pane if one of it's child panes was active
Ben Kunkle
created
7fb1697
chore: Extract PromptStore out of prompt_library (#25837)
Click to expand commit body
One step closer to removing long pole with assistant/assistant2 builds
Release Notes:
- N/A
Piotr Osiewicz
created
53b2792
Improve script/mitm-proxy.sh to support podman (#25834)
Updated JSON schemas to
[SchemaStore/schemastore@b107b83](https://github.com/SchemaStore/schemastore/tree/b107b83a50bad9ac06dd171201dc870901f92ca8)
(2025-02-28)
-
[tsconfig.json](https://github.com/SchemaStore/schemastore/commits/master/src/schemas/json/tsconfig.json)
@
[b107b83](https://raw.githubusercontent.com/SchemaStore/schemastore/b107b83a50bad9ac06dd171201dc870901f92ca8/src/schemas/json/tsconfig.json)
-
[package.json](https://github.com/SchemaStore/schemastore/commits/master/src/schemas/json/package.json)
@
[b107b83](https://raw.githubusercontent.com/SchemaStore/schemastore/b107b83a50bad9ac06dd171201dc870901f92ca8/src/schemas/json/package.json)
Previously:
- https://github.com/zed-industries/zed/pull/20910
Release Notes:
- Updated bundled JSON schemas for package.json and tsconfig.json
Peter Tripp
created
71866d6
assistant2: Include some text in the tool result messages (#25825)
Click to expand commit body
This PR makes it so we include some textual content in the user messages
that as used to send up tool results.
I observed that when sending up the tool results with no text, it would
lead the model to start replying with no text, which would then result
in an error when attaching later tool results.
I think there's a deeper issue at play here, but for now we just include
some text to keep the model on track.
Release Notes:
- N/A
Marshall Bowers
created
0c2bbb3
Optimistically update hunk states when staging and unstaging hunks (#25687)
Click to expand commit body
This PR adds an optimistic update when staging or unstaging diff hunks.
In the process, I've also refactored the logic for staging and unstaging
hunks, to consolidate more of it in the `buffer_diff` crate.
I've also changed the way that we treat untracked files. Previously, we
maintained an empty diff for them, so as not to show unwanted
entire-file diff hunks in a regular editor. But then in the project diff
view, we had to account for this, and replace these empty diffs with
entire-file diffs. This form of state management made it more difficult
to store the pending hunks, so now we always use the same
`BufferDiff`/`BufferDiffSnapshot` for untracked files (with a single
hunk spanning the entire buffer), but we just have a special case in
regular buffers, that avoids showing that entire-file hunk.
* [x] Avoid creating a long queue of `set_index` operations when
staging/unstaging rapidly
* [x] Keep pending hunks when diff is recalculated without base text
changes
* [x] Be optimistic even when staging the single hunk in added/deleted
files
* Testing
Release Notes:
- N/A
---------
Co-authored-by: Cole Miller <m@cole-miller.net>
This PR updates the ui of the git panel. It removes the header from the
panel and unifies the repository, branch and commit controls in the
bottom section.
It also adds a secondary menu to the primary button giving access to a
variety of actions for managing local and remote changes:

Known issues (will be fixed in a later pr)
- Spinner showing git operation progress was removed, will be re-added
- Clicking expand with the panel editor focused will commit (due to
shared action name. Already tracked)
Before | After

(Also adds `component`, `linkme` to cargo-machete ignore as they are
used in the `IntoComponent` proc-macro and will always be incorrectly
flagged as unused)
Release Notes:
- N/A
---------
Co-authored-by: Cole Miller <m@cole-miller.net>
Co-authored-by: Cole Miller <53574922+cole-miller@users.noreply.github.com>
Co-authored-by: Cole Miller <cole@zed.dev>
Nate Butler
,
Cole Miller
,
Cole Miller
, and
Cole Miller
created
8a22a07
git: Adjust rendering of git hunks (#25824)
Click to expand commit body
- Light themes get their own values (creating better contrast and a
better distinction between staged and unstaged hunks in light themes.)
- Scrollbar git hunks indicators now use the correct colors
Before:

After:

Release Notes:
- Fixed an issue where git hunk indicators in editor scrollbars used the
incorrect colors.
Nate Butler
created
fad4df5
editor: Add Organize Imports Action (#25793)
Click to expand commit body
Closes #10004
This PR adds support for the organize imports action. Previously, you
had to manually configure it in the settings and then use format to run
it.
Note: Default key binding will be `alt-shift-o` which is similar to
VSCode's organize import. Also, because `cmd-shift-o` is taken by
outline picker.
Todo:
- [x] Initial working
- [x] Handle remote
- [x] Handle multi buffer
- [x] Can we make it generic for executing any code action?
Release Notes:
- Added `editor:OrganizeImports` action to organize imports (sort,
remove unused, etc) for supported LSPs. You can trigger it by using the
`alt-shift-o` key binding.
fc52b43
assistant2: Factor out tool use into its own module (#25819)
Click to expand commit body
This PR factors out the concerns related to tool use out of `Thread` and
into their own module.
Release Notes:
- N/A
Marshall Bowers
created
b445e4c
assistant2: Rework how tool results are stored and referred to (#25817)
Click to expand commit body
This PR reworks how we store tool results and refer to them later.
We now maintain a mapping of the tool uses to their corresponding
results, with separate mappings for the messages and the tool uses they
correspond to.
Release Notes:
- N/A
I've been bothered by using simple hyphens for bullet lists here for a
while; it kinda looked cheap and not well-formatted. So, in this PR, I'm
adding a new, custom UI component in the `language_models` crate, called
`InstructionListItem`, based off the `ListItem` that's somewhat
mimic'ing what a `<li>` would be on the web.
It does have a "rigid" structure as in it's always a label followed by a
button (which is optional), but that seems okay given it has been the
overall shape of the copy we've been using here. Also, never really
loved that we were pasting URLs directly, that kinda felt cheap, too. I
could see an argument where it's just clearer, but it looks too
cluttered, as URLs aren't super pretty, necessarily.
| Before | After |
|--------|--------|
| <img
src="https://github.com/user-attachments/assets/ffd1ac27-b1f4-450d-abf5-079285fc9877"
width="700px" /> | <img
src="https://github.com/user-attachments/assets/28fb9d0d-205d-45d8-9e43-1aaa947adc96"
width="700px" /> |
Release Notes:
- N/A
Danilo Leal
created
c9aba6c
windows: Use a clippy script instead of `xtask` (#25807)
Click to expand commit body
Closes #ISSUE
Match the behaviour of our macOS and Linux tests
Release Notes:
- N/A *or* Added/Fixed/Improved ...
张小白
created
5740fec
Ensure search input always has regex language synced with search_options state (#25811)
Click to expand commit body
Follow-up to https://github.com/zed-industries/zed/pull/25797
Release Notes:
- N/A
Kirill Bulatov
created
22220ed
windows: Remove unnecessary code in #25412 (#25805)
7440833
Add a way to toggle inlay hints with modifiers #2 (#25766)
Click to expand commit body
https://github.com/zed-industries/zed/pull/25752 with fixes on top
* Ensures no flickering happens for all modifiers `: false` case
* Dismisses the toggled state on focus out
* Reworks cache state so that "enabled" and "toggled by modifiers" are
different states with their own lifecycle
Release Notes:
- N/A
Kirill Bulatov
created
bb3aef1
Reset buffer language on buffer search redeploy (#25797)
Click to expand commit body
Closes https://github.com/zed-industries/zed/issues/25792
Release Notes:
- Fixed search input regex highlight not going away after redeploy
Kirill Bulatov
created
ece1818
docs: Add documentation for use_smartcase_search (#25786)
604eb91
logging: Add runtime log replace upon max size limit (#25768)
Click to expand commit body
Closes #25638
We currently only check the log size limit at startup and move `Zed.log`
to `Zed.log.old`. If a user runs Zed for an extended period, there's no
runtime restriction on the log file size, which can cause it to grow to
several gigabytes.
This PR fixes that by tracking the log file size while writing. If it
exceeds a certain threshold, we perform the same log replace and
continue logging.
Release Notes:
- Fixed an issue where `Zed.log` could grow excessively large during
long sessions of Zed.
Update default slash command to use description constant format from
https://github.com/zed-industries/zed/pull/18595.
|Before|After|
|---|---|
|||
^ This is when you type slash in the assistant panel.
Release Notes:
- N/A
a5f9690
Update to suggest commit message based on file staging (#25790)
Click to expand commit body
Currently, you only get a suggested commit message if you have a single
changed file in the repository. After the PR, the suggest happens per
single-staged file.
https://github.com/user-attachments/assets/4cc19fe6-099c-4690-967d-898b8ca7540b
Release Notes:
- N/A
Joseph T. Lyons
created
b15aa5e
rust: Fix test/doctest tasks showing up outside of tests (#25787)
Click to expand commit body
Closes #ISSUE
Release Notes:
- Fixes Rust test tasks showing up outside of tests
Piotr Osiewicz
created
62fb555
Use "restore" more consistently in the git panel (#25780)
Click to expand commit body
This PR replaces almost all uses of "discard" in the git panel UI with
"restore", since that's the verb we settled on for the project diff.
The only exception is in the confirmation prompt for restoring files,
where I've kept the "discard changes" language. I think consistency is
less important here and it's helpful to rephrase the action that's being
taken to emphasize that it's destructive.
Release Notes:
- N/A
df7beb4
Use active worktree's task sources (#25784)
Click to expand commit body
Follow-up of https://github.com/zed-industries/zed/pull/25605
Previous PR made global tasks with `ZED_WORKTREE_ROOT` available for
"nothing open" scenario, this PR also gets all related worktree task
templates, using the centralized `TextContexts`' active worktree
detection.
Release Notes:
- N/A
Kirill Bulatov
created
6f30d5d
Use consistent comment style in `default.json` (#25783)
Click to expand commit body
This PR updates the comments in the `default.json` file consistently use
`//`.
Some comments were using `///`, which doesn't make sense in JSONC.
Release Notes:
- N/A
Marshall Bowers
created
b8387c6
docs: Clarify wording around `...` in `language_servers` setting (#25782)
Click to expand commit body
This PR clarifies the wording around how `...` is used in the
`language_servers` setting.
Closes https://github.com/zed-industries/zed/issues/25779.
Release Notes:
- N/A
Marshall Bowers
created
c05ce88
docs: Add note about `path` in `extensions.toml` (#25778)
Click to expand commit body
This PR adds a note about the `path` field in `extensions.toml` and how
to use it.
Suggested in https://github.com/zed-industries/extensions/pull/2128.
Release Notes:
- N/A