Commit log

9f6c5e2 Reapply "Use Project instead of Workspace in ContextStore (#28402)" (#28441)

Click to expand commit body
Motivation for this change is to use `ContextStore` in headless
assistant, which requires it to not depend on UI entities like
`Workspace`.

This reapplies a change that was revert was in #28428, and fixes the panic.

Release Notes:

- N/A

Michael Sloan created

7bf6cd4 Fix ancestor git repositories going missing (#28436)

Click to expand commit body
Closes #ISSUE

Release Notes:

- Fixed a bug that caused Zed to sometimes not discover git repositories
above a worktree root.

Cole Miller created

c7963c8 ci: Require workspace_hack for PR merge (#28431)

Click to expand commit body
Release Notes:

- N/A

Peter Tripp created

dd46294 Update cachix/install-nix-action digest to d1ca217 (#27951)

Click to expand commit body
This PR contains the following updates:

| Package | Type | Update | Change |
|---|---|---|---|
|
[cachix/install-nix-action](https://redirect.github.com/cachix/install-nix-action)
| action | digest | `02a151a` -> `d1ca217` |

---

Release Notes:

- N/A

<!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiIzOS4yMjcuMyIsInVwZGF0ZWRJblZlciI6IjM5LjIyNy4zIiwidGFyZ2V0QnJhbmNoIjoibWFpbiIsImxhYmVscyI6W119-->

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>

renovate[bot] and renovate[bot] created

2e56935 Fix invalid number of space characters inserted for tab (#27336)

Click to expand commit body
Closes #25941 

Release Notes:

- Corrected SoftTab indentation handling for lines with mixed spaces and
tabs across .go files and other file types.
- Renamed the editor test `test_tab_with_mixed_whitespace` to
`test_tab_with_mixed_whitespace_rust` as it only tested this behavior
for Rust buffers, which have auto-indentation support. This change
clarifies that the test does not cover default files without
language-specific features.
- Added a new editor test `test_tab_with_mixed_whitespace_txt` to ensure
proper coverage for files with no associated language.

While investigating the issue — initially thought to be Go-related — I
discovered that the underlying problem was how soft tabs were calculated
in `Editor::tab`, given that the problem could also be observed on
`.txt` files

The correct soft tab indentation is now determined by treating all `\t`
characters before the cursor (on the same row) as new indentation
levels, resetting the remainder counter accordingly.


https://github.com/user-attachments/assets/78192e98-2b81-43cb-ae6f-7c48cd17d168

Rodrigo Freire created

e43a397 Make regex search tool optionally case-sensitive (#28427)

Click to expand commit body
Release Notes:

- The agent panel's regex search tool is now optionally case-sensitive.

Richard Feldman created

9d0fe16 Revert to fix panic in inline assistant (#28428)

Click to expand commit body
This reverts commit f12a554f86fa1e2b9b937a9dd103aa7c9a019db9, which
introduced a panic in inline assistant (cc @mgsloan) - I'm not sure what
the motivation was for that change, but I figure we can revert to fix
the inline assistant now and deal with that later. 😄

Panic was:

> Thread "main" panicked with "cannot read workspace::Workspace while it
is already being updated" at
/Users/rtfeldman/code/zed/crates/gpui/src/app/entity_map.rs:139:32


Release Notes:

- N/A

Richard Feldman created

6d7fef6 Add icon for Vyper files (#28307)

Click to expand commit body
Release Notes:

- Added icon for Vyper (`.vy`, `.vyi`) files

Kainoa Kanter created

b67d3fd git_ui: Show disabled states in context menu (#28288)

Click to expand commit body
Other elements in the git panel are shown as disabled when an action is
not actionable (For example: stage all, commit). Updating the context
menu to match this behavior when an action does nothing.

|Before|After|
|--|--|

|![image](https://github.com/user-attachments/assets/e517f758-216f-4451-911b-7121dce0c53b)|![image](https://github.com/user-attachments/assets/a85905c1-2f42-44c3-8b11-2f93c8a6f686)|





Release Notes:

- Git: Improved the Git panel context menu to show actions with no
effect as disabled.

5brian created

1cb4f82 Fix bash tool output (#28391)

Agus Zubiaga created

3a8fe4d Add reminder message about system prompt (#28344)

Click to expand commit body
Trying out sending the model a reminder message about code blocks in the
system prompt. If this seems to work well, we can include more specific
reminder messages, e.g. tool-specific ones.

Release Notes:

- N/A

Richard Feldman created

9d6d152 Bump Zed to v0.183 (#28419)

Click to expand commit body
Release Notes:

-N/A

Joseph T. Lyons created

31034f8 Add toggle case command (#28415)

Click to expand commit body
A small addition for those coming from JetBrain's IDEs. A behavioral
detail: when any upper case character is detected, the command defaults
to toggling to lower case.

> Note that when you apply the toggle case action to the CamelCase name
format, IntelliJ IDEA converts the name to the lower case.


https://www.jetbrains.com/help/idea/working-with-source-code.html#edit_code_fragments

Release Notes:

- Added an `editor: toggle case` command. Use `cmd-shift-u` for macOS
and `ctrl-shift-u` for Linux, when using the `JetBrains` keymap.

Joseph T. Lyons created

c441b65 debugger: Add support for CodeLLDB (#28376)

Click to expand commit body
Closes #ISSUE

Release Notes:

- N/A

Piotr Osiewicz created

61ddcd5 chore: Add workspace-hack dependency to agent_rules (#28412)

Click to expand commit body
Closes #ISSUE

Release Notes:

- N/A

Piotr Osiewicz created

f12a554 Use `Project` instead of `Workspace` in `ContextStore` (#28402)

Click to expand commit body
Release Notes:

- N/A

Michael Sloan created

9dae4d8 Remove references to SSH remoting beta (#28399)

Click to expand commit body
Release Notes:

- N/A

Cole Miller created

f0b7f35 Clean up environment loading a bit (#28356)

Click to expand commit body
Closes #ISSUE

Release Notes:

- N/A

Cole Miller created

b687a5e git: Always reload current branch after pushing (#28327)

Click to expand commit body
Closes #27347 

Release Notes:

- Fixed a bug causing the git panel to not update after pushing to a
remote

Cole Miller created

e66a24e format: Re-implement support for formatting with code actions that contain commands (#28392)

Click to expand commit body
Closes #27692
Closes #27935

Release Notes:

- Fixed a regression where code-actions used when formatting on save
were rejected if they contained commands

Ben Kunkle created

301fc7c Pull out plain rules file loading code into a new `agent_rules` crate (#28383)

Click to expand commit body
Also renames for rules file templated into the system prompt

Release Notes:

- N/A

Michael Sloan created

020a107 Add the project search as an item in the status bar (#28388)

Click to expand commit body
Was chatting with @wilhelmklopp, he pointed out that our current
UI-accessible way to access the project search was pretty obscure.


<img width="393" alt="Screenshot 2025-04-08 at 6 57 51 PM"
src="https://github.com/user-attachments/assets/636053cd-5a88-4a5e-8155-6d41d189b7db"
/>

Release Notes:

- Added a button to open the project search to the status bar

Mikayla Maki created

38d2487 agent: Polish `Generating...` animation (#28379)

Click to expand commit body
https://github.com/user-attachments/assets/9e798a50-9403-4e1c-a3df-2931e748b77d



Release Notes:

- N/A

Bennet Bo Fenner created

79c9f2b editor: Fix invalid read-only with split pane (#28012)

Click to expand commit body
Closes #28004

Release Notes:

- Fixed invalid read-only with split pane

0x2CA created

c8caae0 agent: Change the reject changes keybinding (#28381)

Click to expand commit body
This PR makes the reject keybinding, in the Review Changes mutlbuffer,
`cmd-n`.

Release Notes:

- N/A

Danilo Leal created

dabc4d8 agent: Remove type of item in the panel history view (#28382)

Click to expand commit body
This PR removes the labels displaying whether a certain item in the
Agent Panel's history is a thread or prompt editor.

Release Notes:

- N/A

Danilo Leal created

c0ad3e8 Introduce a telemetry event for when a tool finishes (#28380)

Click to expand commit body
This should help us understand which tools fail the most.

Release Notes:

- N/A

Antonio Scandurra created

afde25a Fix a docs typo (#28384)

Click to expand commit body
Closes https://github.com/zed-industries/zed/pull/28053

Release Notes:

- N/A

Kirill Bulatov created

9f708ee Fix refactoring bug in dashes around rounded corners (#28378)

Click to expand commit body
Accidentally introduced in #28341

Release Notes:

- N/A

Michael Sloan created

58731e2 Remove log when pulldown_cmark produces long substituted text (#28375)

Click to expand commit body
Turns out that consecutive dashes are substituted with half the number
of input dashes. Extended the test with this case as well

Release Notes:

- N/A

Michael Sloan created

d0632a5 Fix truncation of bash output (#28374)

Click to expand commit body
Release Notes:

- Fixed a regression that caused the bash tool to not include all of the
output.

---------

Co-authored-by: Agus Zubiaga <hi@aguz.me>

Antonio Scandurra and Agus Zubiaga created

64cea2f agent: Refine toolbar spacing (#28373)

Click to expand commit body
Release Notes:

- N/A

Danilo Leal created

ac958d4 Encourage agent to edit files it just created (#28372)

Click to expand commit body
Release Notes:

- Fixed a problem that would cause the agent to keep recreating a file
instead of editing it.

Antonio Scandurra created

2df06cd agent: Improve thinking design display (#28186)

Click to expand commit body
Release Notes:

- N/A

Danilo Leal created

0d4ca71 agent: Change "prompt editor" to "text thread" (#28370)

Click to expand commit body
Release Notes:

- N/A

Danilo Leal created

e2d6505 agent: Make the copy button in the codeblock visible on hover (#28371)

Click to expand commit body
This simplifies the UI a little bit.

Release Notes:

- N/A

Danilo Leal created

f7c3c53 Update task defaults (#28368)

Click to expand commit body
Follow-up of https://github.com/zed-industries/zed/pull/28359

Release Notes:

- N/A

Kirill Bulatov created

c05bf09 Merge `Component` and `ComponentPreview` trait (#28365)

Click to expand commit body
- Merge `Component` and `ComponentPreview` trait
- Adds a number of component previews
- Removes a number of stories

Release Notes:

- N/A

Nate Butler created

b15ee1b Add dedicated actions for `LSP` completions insertion mode (#28121)

Click to expand commit body
Adds actions so you can have customized keybindings for `insert` and
`replace` modes.

And add `shift-enter` as a default for `replace`, this will override the
default setting
`completions.lsp_insert_mode` which is set to `replace_suffix`, which
tries to "smartly"
decide whether to replace or insert based on the surrounding text.

For those who come from VSCode, if you want to mimic their behavior, you
only have to
set `completions.lsp_insert_mode` to `insert`.

If you want `tab` and `enter` to do different things, you need to remap
them, here is
an example:

```jsonc
[
  // ...
  {
    "context": "Editor && showing_completions",
    "bindings": {
      "enter": "editor::ConfirmCompletionInsert",
      "tab": "editor::ConfirmCompletionReplace"
    }
  },
]
```

Closes #24577

- [x] Make LSP completion insertion mode decision in guest's machine
(host is currently deciding it and not allowing guests to have their own
setting for it)
- [x] Add shift-enter as a hotkey for `replace` by default.
- [x] Test actions.
- [x] Respect the setting being specified per language, instead of using
the "defaults".
- [x] Move `insert_range` of `Completion` to the Lsp variant of
`.source`.
- [x] Fix broken default, forgotten after
https://github.com/zed-industries/zed/pull/27453#pullrequestreview-2736906628,
should be `replace_suffix` and not `insert`.

Release Notes:

- LSP completions: added actions `ConfirmCompletionInsert` and
`ConfirmCompletionReplace` that control how completions are inserted,
these override `completions.lsp_insert_mode`, by default, `shift-enter`
triggers `ConfirmCompletionReplace` which replaces the whole word.

João Marcos created

0459b1d Fix panic when a file in a path-based multibuffer excerpt is renamed (#28364)

Click to expand commit body
Closes #ISSUE

Release Notes:

- Fixed a panic that could occur when paths changed in the project diff.

Co-authored-by: Conrad Irwin <conrad.irwin@gmail.com>

Cole Miller and Conrad Irwin created

246013c tab_switcher: Add keybind to close tab tooltip (#27212)

Click to expand commit body
| prev | new |
|--|--|
|<img width="619" alt="image"
src="https://github.com/user-attachments/assets/53b14fd4-17ee-4336-81ca-30324d918e15"
/>|<img width="620" alt="image"
src="https://github.com/user-attachments/assets/316699b3-295b-4f83-9fb1-b799f7c71d7f"
/>|


Release Notes:

- N/A

5brian created

47eaf27 agent: Only require confirmation for batch tool when subset of tool calls require confirmation (#28363)

Click to expand commit body
Release Notes:

- agent: Only require confirmation for batch tool when subset of tool
calls require confirmation

Bennet Bo Fenner created

ef4b5b0 script: Ignore feature/meta issues from issue_response nag (#28332)

Click to expand commit body
Release Notes:

- N/A

Peter Tripp created

39c98ce Support tasks from rust-analyzer (#28359)

Click to expand commit body
(and any other LSP server in theory, if it exposes any LSP-ext endpoint
for the same)

Closes https://github.com/zed-industries/zed/issues/16160

* adds a way to disable tree-sitter tasks (the ones from the plugins,
enabled by default) with
```json5
"languages": {
  "Rust": "tasks": {
      "enabled": false
    }
  }
}
```
language settings

* adds a way to disable LSP tasks (the ones from the rust-analyzer
language server, enabled by default) with
```json5
"lsp": {
  "rust-analyzer": {
    "enable_lsp_tasks": false,
  }
}
```

* adds rust-analyzer tasks into tasks modal and gutter:

<img width="1728" alt="modal"
src="https://github.com/user-attachments/assets/22b9cee1-4ffb-4c9e-b1f1-d01e80e72508"
/>

<img width="396" alt="gutter"
src="https://github.com/user-attachments/assets/bd818079-e247-4332-bdb5-1b7cb1cce768"
/>


Release Notes:

- Added tasks from rust-analyzer

Kirill Bulatov created

763cc6d Tell the model not to act on TODO type comments (#28358)

Click to expand commit body
Release Notes:

- Adjusted system prompt to direct it to never act on TODO-type comments
it encounters, unless the user directly asked it to do so or they relate
to the current task at hand.

Joseph T. Lyons created

0b75c13 chore: Replace as_any functions with trait upcasting (#28221)

Click to expand commit body
Closes #ISSUE

Release Notes:

- N/A

Piotr Osiewicz created

38ec450 project: Workaround invalid code action edits from pyright (#28354)

Click to expand commit body
Co-authored-by: Max Brunsfeld <maxbrunsfeld@gmail.com>
Co-authored-by: Piotr Osiewicz <piotr@zed.dev>

fixes issue where:

In a two line python file like so
```

Path()
```

If the user asks for code actions on `Path` and they select (`From
pathlib import path`)
the result they get is
```

Pathfrom pathlib import Path


Path()
```
Instead of 

```

from pathlib import Path



Path()
```

This is due to a non-lsp-spec-compliant response from pyright below

```json
{"jsonrpc":"2.0","id":40,"result":[{"title":"from pathlib import Path","edit":{"changes":{"file:///Users/neb/Zed/example-project/pyright-project/main.py":[{"range":{"start":{"line":2,"character":0},"end":{"line":2,"character":4}},"newText":"Path"},{"range":{"start":{"line":2,"character":0},"end":{"line":2,"character":0}},"newText":"from pathlib import Path\n\n\n"}]}},"kind":"quickfix"}]}
```

Release Notes:

- Fixed an issue when using auto-import code actions provided by pyright
(or basedpyright) where the import would be jumbled with the scoped
import resulting in an invalid result

Co-authored-by: Max Brunsfeld <maxbrunsfeld@gmail.com>
Co-authored-by: Anthony Eid <hello@anthonyeid.me>

Ben Kunkle , Max Brunsfeld , and Anthony Eid created

97641c3 Use tree-sitter when returning symbols to the model for a given file (#28352)

Click to expand commit body
This also increases the threshold for when we return an outline during
`read_file`.

Release Notes:

- Fixed an issue that caused the agent to fail reading large files if
the LSP hadn't started yet.

Antonio Scandurra created

ca8f6e8 Tell the model not to remove tests (#28349)

Click to expand commit body
Release Notes:

- Adjusted system prompt to direct it to never remove tests as a way to
have the test suite pass, unless the user directly asks for test
removal.

Joseph T. Lyons created

db53da4 debugger: Respect initialize_args from user profiles (#28347)

Click to expand commit body
Closes #ISSUE

Release Notes:

- N/A

Co-authored-by: Ben Kunkle <ben.kunkle@gmail.com>

Piotr Osiewicz and Ben Kunkle created