Commit graph

25723 commits

Author SHA1 Message Date
Peter Tripp
f80035e0ff
Support busybox wget for downloading zed-remote-server (#25621)
- Closes: https://github.com/zed-industries/zed/issues/22380

Arch linux ships busybox wget not gnu wget.
BusyBox wget does not support `--max-redirect`.

Release Notes:

- ssh: Add support for downloading `zed-remote-server` with busybox wget (ArchLinux, etc)
2025-02-26 16:22:56 -05:00
renovate[bot]
7664c1cef5
Update actions/upload-artifact digest to 4cec3d8 (#25680)
This PR contains the following updates:

| Package | Type | Update | Change |
|---|---|---|---|
|
[actions/upload-artifact](https://redirect.github.com/actions/upload-artifact)
| action | digest | `65c4c4a` -> `4cec3d8` |

---

### Configuration

📅 **Schedule**: Branch creation - "after 3pm on Wednesday" 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:eyJjcmVhdGVkSW5WZXIiOiIzOS4xNzYuMiIsInVwZGF0ZWRJblZlciI6IjM5LjE3Ni4yIiwidGFyZ2V0QnJhbmNoIjoibWFpbiIsImxhYmVscyI6W119-->

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2025-02-26 16:07:26 -05:00
renovate[bot]
967792119b
Pin clechasseur/rs-cargo action to 8435b10 (#25679)
This PR contains the following updates:

| Package | Type | Update | Change |
|---|---|---|---|
|
[clechasseur/rs-cargo](https://redirect.github.com/clechasseur/rs-cargo)
| action | pinDigest | -> `8435b10` |

---

### Configuration

📅 **Schedule**: Branch creation - "after 3pm on Wednesday" 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:eyJjcmVhdGVkSW5WZXIiOiIzOS4xNzYuMiIsInVwZGF0ZWRJblZlciI6IjM5LjE3Ni4yIiwidGFyZ2V0QnJhbmNoIjoibWFpbiIsImxhYmVscyI6W119-->

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2025-02-26 16:07:05 -05:00
João Marcos
be1ac78e11
Unfold buffers in multibuffers when editing them (#25677)
Release Notes:

- Multibuffers: Unfold excerpts when editing their contents.

Co-authored-by: Max Brunsfeld <maxbrunsfeld@gmail.com>
2025-02-26 17:39:33 -03:00
Kirill Bulatov
b5a1ae6526
Improve Zed tasks' ZED_WORKTREE_ROOT fallbacks (#25605)
Closes https://github.com/zed-industries/zed/issues/22912

Reworks the task context infrastructure so that it's possible to have
multiple contexts at the same time, and stores all possible worktree
context there.
Task UI code is now falling back to the "active" worktree context, if
active item's context did not produce a resolved task.

Current code does not produce meaningful results for projects with
multiple worktrees to avoid ambiguity and design changes: instead of
resolving tasks per worktree context available, extra worktree context
is only used when resolving tasks from the same worktree.

Release Notes:

- Improved Zed tasks' `ZED_WORKTREE_ROOT` fallbacks
2025-02-26 22:30:31 +02:00
Kirill Bulatov
d2b49de0e4
Dismiss active diagnostics on invalidation (#25646)
When migrating to gpui2,
588976d27a (diff-a3da3181e4ab4f73aa1697d7b6dc0caa0c17b2a187fb83b076dfc0234ec91f54R21)
removed the diagnostic style for "active but invalid" case: presumably,
it served as some sort of a cursor to show where to move on after the
diagnostics update, on the next `GoTo[Prev]Diagnostic` action call.

As this change went unchanged for some time, another approach is tested
now, to be more integrated with inline diagnostics: now, the active
state is cleared

Same as before this change, another `GoTo[Prev]Diagnostic` action call
will be needed to re-expand a new diagnostics, but this change makes
this expansion to happen after the cursor — before the change, Zed would
continue from the stale diagnostics.

Release Notes:

- Fixed active diagnostics becoming stale
2025-02-26 22:30:23 +02:00
Agus Zubiaga
d694458659
edit predictions: Rename edit prediction modes (#25657)
`auto` -> `stealth`
`eager_preview` -> `eager`

Release Notes:

- N/A

---------

Co-authored-by: Danilo Leal <daniloleal09@gmail.com>
2025-02-26 20:23:39 +00:00
Cole Miller
7a34dd9888
Save buffers after restoring hunks in the project diff (#25620)
This PR fixes a bug where using the project diff editor to restore hunks
from a file that's not open in its own buffer would cause those reverts
to be lost once the project diff drops its excerpts for that file.

The fix is to save the buffers after restoring them but before the
excerpts are (potentially) dropped. This is done for the project diff
editor only. If we fail to save the affected files, we add their buffers
to the active workspace, so that the reverted contents are preserved and
the user can try again to save them.

- [x] Get it working
- [x] Test
- [ ] ~~Clean up boolean soup~~

Co-authored-by: Max <max@zed.dev>

Release Notes:

- N/A
2025-02-26 15:16:17 -05:00
Michael Sloan
add7ae8052
Try to reveal selection changing issues in undo/redo via logging (#25676)
This will hopefully help debug #22692. I tried this for a while locally
and saw neither these logs nor the issue.

Release Notes:

- N/A
2025-02-26 19:48:15 +00:00
Marshall Bowers
c53020ceaf
vim: Combine match arms in Mode::is_visual (#25675)
This PR refactors the `Mode::is_visual` implementation to combine some
of the `match` arms.

Release Notes:

- N/A
2025-02-26 19:45:04 +00:00
Cole Miller
eeac1a9287
Style filenames and paths in project diff buffer headers according to git status (#25653)
This substitutes for the icons that we previously kept in these headers.

cc @iamnbutler 

Release Notes:

- N/A
2025-02-26 14:43:10 -05:00
0x2CA
e83ebd1fab
vim: Add more tests for replace with register (#25316)
Closes #ISSUE

Add more tests

Release Notes:

- N/A
2025-02-26 12:38:50 -07:00
Conrad Irwin
afb0fd609b
Chunk git status entries (#25627)
Prevents us trying to write 5M untracked files to postgres in one commit

Release Notes:

- N/A *or* Added/Fixed/Improved ...
2025-02-26 12:38:16 -07:00
Conrad Irwin
b2a685f00a
Fix staging error reporting (#25630)
Closes #ISSUE

Release Notes:

- N/A
2025-02-26 12:38:04 -07:00
Yicheng Liu
089ea5da50
vim: Fix back quotes not recognized as object (#24999)
Currently back quotes ``` `` ``` not recognized as an object in vim
mode, so ```c i ` ```, ```d i ` ``` not working.

It seems to be a typo introduced in #22632 : The`DoubleQuotes` line was
doubled while the `BackQuotes` line was missing.

Release Notes:

- vim: Fixed back quotes ``` `` ``` not recognized as object.

Co-authored-by: Marshall Bowers <git@maxdeviant.com>
2025-02-26 14:21:12 -05:00
smit
b6e8db244c
vim: Fix search submit panic (#25673)
In file search submit action, handle unwrap when there are no prior
selection.

Fix is for recently made commits, hence no release notes.

Release Notes:

- N/A

---------

Co-authored-by: Anthony Eid <anthony@zed.dev>
2025-02-27 00:40:46 +05:30
Brandon Li
6267ab0396
vim: Add ability to change default mode (#25067)
Closes #13881, and technically resolves #14927.

Release Notes:

- Added the ability to set the default Vim mode.

---------

Co-authored-by: Marshall Bowers <git@maxdeviant.com>
2025-02-26 13:51:07 -05:00
Joseph T. Lyons
d105f04be5
Bump Zed to v0.177 (#25669)
Release Notes:

-N/A
2025-02-26 18:31:58 +00:00
Mikayla Maki
5edded5c02
Simplify project git code (#25662)
This was originally a part of another PR, but I wanted to get the
refactoring in and shift focus to working on bugs.

This causes all git commands via the `Repository` entity to be
serialized, and allows us to return values other than `Result<()>`

Release Notes:

- N/A
2025-02-26 18:16:10 +00:00
Marshall Bowers
78da39e19b
assistant2: Add ability to delete past prompt editors (#25667)
This PR adds the ability to delete past prompt editors in Assistant 2,
the same way you can with threads.

Release Notes:

- N/A
2025-02-26 18:02:36 +00:00
Marshall Bowers
d82a132477
language_model: Use LanguageModelToolUseId instead of a String (#25666)
This PR updates the `LanguageModelToolResult` type to use a
`LanguageModelToolUseId` for the tool use ID instead of a `String`.

Release Notes:

- N/A
2025-02-26 17:34:16 +00:00
Federico Dionisi
f11357db7c
context_server: Abstract server transport (#24528)
This PR abstracts the communication layer for context servers, laying
the groundwork for supporting multiple transport mechanisms and taking
one step towards enabling remote servers.

Key changes centre around creating a new `Transport` trait with methods
for sending and receiving messages. I've implemented this trait for the
existing stdio-based communication, which is now encapsulated in a
`StdioTransport` struct. The `Client` struct has been refactored to use
this new `Transport` trait instead of directly managing stdin and
stdout.

The next steps will involve implementing an SSE + HTTP transport and
defining alternative context server settings for remote servers.

Release Notes:

- N/A

---------

Co-authored-by: Marshall Bowers <git@maxdeviant.com>
2025-02-26 17:19:19 +00:00
Cole Miller
6d17546b1a
Fix panic in file finder path elision (#25658)
Release Notes:

- N/A
2025-02-26 11:45:53 -05:00
Caleb!
60a96ab799
image_viewer: Hide breadcrumb (#25654)
Closes #25279 


![image](https://github.com/user-attachments/assets/15a0b092-449b-493c-8eea-10a3d9d1a912)

Release Notes:

- Added the ability to hide breadcrumb showing image path
2025-02-26 17:24:35 +01:00
Nate Butler
1f80f58104
git_ui: Commit modal editor cleanup (#25645)
- Fixes cursor style in the commit modal
- Use commit button instead of kb hint
- Update layout to scale better for large commit messages

No message:

![CleanShot 2025-02-26 at 10 33
22@2x](https://github.com/user-attachments/assets/fb6fc4ff-1e1d-46ae-aee0-7e21d73aaf70)

Long Message:
![CleanShot 2025-02-26 at 10 33
55@2x](https://github.com/user-attachments/assets/71a7773c-386b-47d5-abed-9a301360c35b)

![CleanShot 2025-02-26 at 10 34
06@2x](https://github.com/user-attachments/assets/dc41f0b9-2277-4034-9af2-d77fec0488d8)

Release Notes:

- N/A
2025-02-26 15:55:38 +00:00
Danilo Leal
bab65011b4
edit prediction: Refine the stealth mode (#25599)
Release Notes:

- N/A

---------

Co-authored-by: Agus Zubiaga <agus@zed.dev>
2025-02-26 12:50:11 -03:00
Piotr Osiewicz
c0b6d86c41
go: Do not fill out root_uri in initialization params to prevent stale notifications (#25644)
Closes #25381

Release Notes:

- N/A
2025-02-26 13:24:27 +01:00
Viktor Zahorodnii
39728cfc59
Add docs on keybindings to trigger runnables (#25582)
Addresses
https://github.com/zed-industries/zed/discussions/22810#discussioncomment-12239661

Release Notes:

- N/A

---------

Co-authored-by: Kirill Bulatov <kirill@zed.dev>
2025-02-26 09:38:22 +00:00
Max Brunsfeld
ebccef1aa4
Fix staging and unstaging of added and deleted files (#25631)
* When staging in a buffer whose file has been deleted, do not save the
file
* Fix logic for writing to index when file is deleted

Release Notes:

- N/A
2025-02-26 07:25:31 +00:00
Conrad Irwin
33754f8eac
Fix search skipping in vim mode (#25580)
Closes #8049

Co-authored-by: nilehmann <nico.lehmannm@gmail.com>
Co-authored-by: Anthony Eid <hello@anthonyeid.me>

Release Notes:

- vim: Fix skipping of search results occasionally

Co-authored-by: nilehmann <nico.lehmannm@gmail.com>
Co-authored-by: Anthony Eid <hello@anthonyeid.me>
2025-02-25 23:29:54 -07:00
Conrad Irwin
dd1ff9b998
Git: Fix prompts with a very large number of filenames (#25629)
Closes #ISSUE

Release Notes:

- N/A
2025-02-25 23:29:17 -07:00
Conrad Irwin
7f214ed25a
git: Fix cmd-enter (#25628)
Closes #ISSUE

Release Notes:

- N/A
2025-02-25 23:07:55 -07:00
Conrad Irwin
08539b32d0
Fix some syncing issues with git statuses (#25535)
Like the real app, this one infinite loops if you have a diff in an
UnsharedFile.

Release Notes:

- N/A *or* Added/Fixed/Improved ...

---------

Co-authored-by: Max Brunsfeld <maxbrunsfeld@gmail.com>
2025-02-25 22:09:02 -07:00
5brian
88baf171c3
docs: Add apostrophe (#25624)
Release Notes:

- N/A
2025-02-26 03:46:02 +00:00
Peter Tripp
2f34af7811
docs: Fix SSH projects example settings (#25622) 2025-02-25 22:15:35 -05:00
Cole Miller
2978be95d7
Don't deploy git panel when opening the diff view (#25611)
Release Notes:

- N/A
2025-02-25 21:29:08 -05:00
Nate Butler
30568e6dd1
Add overflow menu to the git panel (#25618)
Before: 

![CleanShot 2025-02-25 at 20 11
48@2x](https://github.com/user-attachments/assets/2400270e-64fe-4711-a2aa-31588e73367a)

After:

![CleanShot 2025-02-25 at 20 13
18@2x](https://github.com/user-attachments/assets/70c88d2f-5e16-4f2d-9cc5-666b2f9b8de0)

Release Notes:

- N/A
2025-02-25 21:07:10 -05:00
Michael Sloan
a5698a430d
Use carriage return instead of newline symbol for single line text (#25616)
I think this is clearer in the cases where it does appear. Use of NL
symbol was added in #10231

Release Notes:

- N/A
2025-02-25 18:26:50 -07:00
Marshall Bowers
57659b5552
assistant2: Fix "Open Prompt Library" button (#25612)
This PR fixes the "Open Prompt Library" button after the GPUI 3 changes.

Release Notes:

- N/A
2025-02-26 00:05:59 +00:00
Piotr Osiewicz
3db18ff053
lsp: Add support for dynamic registration of rename capability (#25610)
While looking at Biome LSP implementation I've noticed that they
register their rename capability dynamically, which we don't handle.

Release Notes:

- N/A
2025-02-25 23:54:29 +00:00
Cole Miller
198f56c763
Fix gutter highlights not matching diff hunks near excerpt boundaries (#25600)
Release Notes:

- Fixed gutter highlights not matching diff hunks in multibuffers in
some cases

---------

Co-authored-by: Max Brunsfeld <maxbrunsfeld@gmail.com>
2025-02-25 15:33:16 -08:00
Max Brunsfeld
d68d858a10
Fix crash in BlockMap::sync when there are inlay hints w/ newlines ri… (#25598)
Closes https://github.com/zed-industries/zed/issues/25377

Release Notes:

- Fixed a crash that could happen when typing in the assistant panel
with edit predictions enabled.

---------

Co-authored-by: Cole Miller <m@cole-miller.net>
2025-02-25 22:32:14 +00:00
Marshall Bowers
7f166298db
collab: Adjust maximum spending limit check (#25596)
This is a follow-up to https://github.com/zed-industries/zed/pull/25573.

We were still using the spend for a particular model when determining if
the user was over their maximum monthly spend instead of looking at the
usage across all models.

Release Notes:

- N/A
2025-02-25 16:45:01 -05:00
Piotr Osiewicz
0066071a89
lsp: Query first capable language server for requests using primary LS (#25591)
Release Notes:

- Improved Zed's handling of the following requests when the first
language server in language server settings for a given language is not
capable of handling them:
  - Perform Rename
  - Prepare Rename
  - Document Highlights
  - Find all references
  - Go to implementation
  - Go to definition
  - Go to declaration
  - Go to type definition
2025-02-25 22:12:13 +01:00
Marshall Bowers
e5b6194914
zeta: Fix update required notification not showing (#25588)
This PR fixes an issue introduced in #25530 that broke the notifications
that inform the user that a Zed update is required to continue using
edit prediction.

The issue is that the `Workspace` stored on the `Editor` is set _after_
the point we initialize Zeta, so capturing the `Workspace` at
construction time leads to it being `None`.

@ConradIrwin suggested that we could obtain the `Workspace` from the
`Window`, which does indeed do the trick.

I tested it both with and without this change by mocking the error
response, like so:

```rs
let response: Result<PredictEditsResponse, anyhow::Error> =
    Err(anyhow!(ZedUpdateRequiredError {
        minimum_version: SemanticVersion::new(0, 1, 0),
    }));
```

Release Notes:

- N/A
2025-02-25 20:02:43 +00:00
Ben Kunkle
23f61d5954
Add myself (Ben Kunkle) and Smit to the mailmap (#25590)
Co-authored-by: Smit <smit@zed.dev>

Release Notes:

- N/A

Co-authored-by: Smit <smit@ze3d.dev>
2025-02-25 19:55:39 +00:00
smit
0559e1f348
editor: Fix panic when editor::SelectLargerSyntaxNode overflows excerpt in multi buffer (#25585)
Closes #25513

This PR handles case when `editor::SelectLargerSyntaxNode` expands
across excerpt boundaries and eventually crashes in multi buffer.

Release Notes:

- Fixed panic caused when `editor::SelectLargerSyntaxNode` is called
repetedly in multi buffer.

Co-authored-by: Ben Kunkle <ben.kunkle@gmail.com>
2025-02-26 01:05:00 +05:30
Ben Kunkle
014d9dfce1
assistant_context_editor: Try to fix crash when trying to view patch (#25572)
Closes #24571

Attempts to fix crash described in #24571 based on the panic trace
provided by the user. In short, the panic seemed to be caused by
attempting to read an `Entity<ContextEditor>` while it was being
updated. My assumption is that at some point in
`workspace.add_item_to_current_pane` the `ContextEditor` is read.
Therefore, I moved the workspace update outside of the ContextEditor
update, and replaced another `update` call with a `read` call to clean
it up and just in case that was actually the issue.

Release Notes:

- N/A
2025-02-25 13:24:51 -06:00
Shardul Vaidya
a0aea6ef62
bedrock: Add Claude 3.7 Sonnet (#25583)
Release Notes:

- N/A
2025-02-25 13:52:42 -05:00
Peter Tripp
278620df33
Ensure emacs undo (ctrl-_) works by default in terminal on macOS (#25578) 2025-02-25 13:01:46 -05:00