Conrad Irwin
0857014649
Fix panic when multi-cursor edit attempted in deleted hunk ( #23633 )
...
Release Notes:
- N/A
2025-01-24 16:14:19 -07:00
Agus Zubiaga and Danilo
51c0ed3dd4
assistant2: Show accept terms UI in thread empty state ( #23630 )
...
<img
src="https://github.com/user-attachments/assets/cea93cfb-8a40-48c4-9d90-f1751c79603b "
width=400>
Release Notes:
- N/A
---------
Co-authored-by: Danilo <danilo@zed.dev >
2025-01-24 19:34:46 -03:00
Michael Sloan
5b8ee85bf8
Use send instead of feed on terminal events channel ( #23631 )
...
Potentially fixes a bug where tasks are not marked as finished.
Release Notes:
- N/A
2025-01-24 22:32:22 +00:00
ecc702b8ec
Rework diff rendering to allow putting the cursor into deleted text, soft-wrapping and scrolling deleted text correctly ( #22994 )
...
Closes #12553
* [x] Fix `diff_hunk_before`
* [x] Fix failure to show deleted text when expanding hunk w/ cursor on
second line of the hunk
* [x] Failure to expand diff hunk below the cursor.
* [x] Delete the whole file, and expand the diff. Backspace over the
deleted hunk, panic!
* [x] Go-to-line now counts the diff hunks, but it should not
* [x] backspace at the beginning of a deleted hunk deletes too much text
* [x] Indent guides are rendered incorrectly
* [ ] Fix randomized multi buffer tests
Maybe:
* [ ] Buffer search should include deleted text (in vim mode it turns
out I use `/x` all the time to jump to the next x I can see).
* [ ] vim: should refuse to switch into insert mode if selection is
fully within a diff.
* [ ] vim `o` command when cursor is on last line of deleted hunk.
* [ ] vim `shift-o` on first line of deleted hunk moves cursor but
doesn't insert line
* [x] `enter` at end of diff hunk inserts a new line but doesn't move
cursor
* [x] (`shift-enter` at start of diff hunk does nothing)
* [ ] Inserting a line just before an expanded hunk collapses it
Release Notes:
- Improved diff rendering, allowing you to navigate with your cursor
inside of deleted text in diff hunks.
---------
Co-authored-by: Conrad <conrad@zed.dev >
Co-authored-by: Cole <cole@zed.dev >
Co-authored-by: Mikayla <mikayla@zed.dev >
Co-authored-by: Conrad Irwin <conrad.irwin@gmail.com >
Co-authored-by: Michael <michael@zed.dev >
Co-authored-by: Agus <agus@zed.dev >
Co-authored-by: João <joao@zed.dev >
2025-01-24 14:18:22 -07:00
renovate[bot]
878faa126b
Update Rust crate tokio to v1.43.0 ( #22882 )
...
This PR contains the following updates:
| Package | Type | Update | Change |
|---|---|---|---|
| [tokio](https://tokio.rs )
([source](https://redirect.github.com/tokio-rs/tokio )) | dependencies |
minor | `1.42.0` -> `1.43.0` |
| [tokio](https://tokio.rs )
([source](https://redirect.github.com/tokio-rs/tokio )) |
workspace.dependencies | minor | `1.42.0` -> `1.43.0` |
---
### Release Notes
<details>
<summary>tokio-rs/tokio (tokio)</summary>
###
[`v1.43.0`](https://redirect.github.com/tokio-rs/tokio/releases/tag/tokio-1.43.0 ):
Tokio v1.43.0
[Compare
Source](https://redirect.github.com/tokio-rs/tokio/compare/tokio-1.42.0...tokio-1.43.0 )
### 1.43.0 (Jan 8th, 2025)
##### Added
- net: add `UdpSocket::peek` methods ([#​7068])
- net: add support for Haiku OS ([#​7042])
- process: add `Command::into_std()` ([#​7014])
- signal: add `SignalKind::info` on illumos ([#​6995])
- signal: add support for realtime signals on illumos ([#​7029])
##### Fixed
- io: don't call `set_len` before initializing vector in `Blocking`
([#​7054])
- macros: suppress `clippy::needless_return` in `#[tokio::main]`
([#​6874])
- runtime: fix thread parking on WebAssembly ([#​7041])
##### Changes
- chore: use unsync loads for `unsync_load` ([#​7073])
- io: use `Buf::put_bytes` in `Repeat` read impl ([#​7055])
- task: drop the join waker of a task eagerly ([#​6986])
##### Changes to unstable APIs
- metrics: improve flexibility of H2Histogram Configuration
([#​6963])
- taskdump: add accessor methods for backtrace ([#​6975])
##### Documented
- io: clarify `ReadBuf::uninit` allows initialized buffers as well
([#​7053])
- net: fix ambiguity in `TcpStream::try_write_vectored` docs
([#​7067])
- runtime: fix `LocalRuntime` doc links ([#​7074])
- sync: extend documentation for `watch::Receiver::wait_for`
([#​7038])
- sync: fix typos in `OnceCell` docs ([#​7047])
[#​6874]: https://redirect.github.com/tokio-rs/tokio/pull/6874
[#​6963]: https://redirect.github.com/tokio-rs/tokio/pull/6963
[#​6975]: https://redirect.github.com/tokio-rs/tokio/pull/6975
[#​6986]: https://redirect.github.com/tokio-rs/tokio/pull/6986
[#​6995]: https://redirect.github.com/tokio-rs/tokio/pull/6995
[#​7014]: https://redirect.github.com/tokio-rs/tokio/pull/7014
[#​7029]: https://redirect.github.com/tokio-rs/tokio/pull/7029
[#​7038]: https://redirect.github.com/tokio-rs/tokio/pull/7038
[#​7041]: https://redirect.github.com/tokio-rs/tokio/pull/7041
[#​7042]: https://redirect.github.com/tokio-rs/tokio/pull/7042
[#​7047]: https://redirect.github.com/tokio-rs/tokio/pull/7047
[#​7053]: https://redirect.github.com/tokio-rs/tokio/pull/7053
[#​7054]: https://redirect.github.com/tokio-rs/tokio/pull/7054
[#​7055]: https://redirect.github.com/tokio-rs/tokio/pull/7055
[#​7067]: https://redirect.github.com/tokio-rs/tokio/pull/7067
[#​7068]: https://redirect.github.com/tokio-rs/tokio/pull/7068
[#​7073]: https://redirect.github.com/tokio-rs/tokio/pull/7073
[#​7074]: https://redirect.github.com/tokio-rs/tokio/pull/7074
</details>
---
### 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 these
updates again.
---
- [ ] <!-- rebase-check -->If you want to rebase/retry this PR, check
this box
---
Release Notes:
- N/A
<!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiIzOS45Mi4wIiwidXBkYXRlZEluVmVyIjoiMzkuOTIuMCIsInRhcmdldEJyYW5jaCI6Im1haW4iLCJsYWJlbHMiOltdfQ==-->
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2025-01-24 22:41:04 +02:00
Cole Miller
93d648387b
git: Disable "stage all" checkbox when no entries ( #23608 )
...
Release Notes:
- N/A
2025-01-24 15:29:34 -05:00
Michael Sloan
00195d2d82
Make editor autoscroll put cursor to the left of scrollbar not under ( #23586 )
...
Closes #19706
Release Notes:
- Improved editor horizontal autoscroll to now place the cursor to the
left of the scrollbar rather than under it.
2025-01-24 12:58:17 -07:00
Peter Tripp
08cdc57e8f
Document elm-language-server not supporting linked_edits correctly ( #23616 )
2025-01-24 18:30:38 +00:00
Peter Tripp
95445d79b3
Support yaml-language-server as formatter without lsp settings ( #23612 )
...
- Closes: https://github.com/zed-industries/zed/issues/20183
2025-01-24 12:51:16 -05:00
Nate Butler
a88966b3d7
git_ui: Add keybinding for focusing the git panel ( #23613 )
...
Adds a keybinding for opening/toggling focus to the git panel
Release Notes:
- N/A
2025-01-24 17:20:26 +00:00
Piotr Osiewicz
7a43a7588c
task: Always use untruncated label if it is short ( #23611 )
...
Also changed rust tasks to be less mouthful.
Release Notes:
- Shortened Rust task labels.
- Task modal will now use full task label when it does not require
truncation.
2025-01-24 16:46:48 +00:00
Danilo Leal
a8a63d1107
assistant2: Adjust empty state when there is no provider ( #23609 )
...
This PR add a "Configure a Provider" button if the user gets to the
assistant panel with no provider configured. Then, upon configuring it,
they'll see a similar welcome message.
| No provider | Empty state |
|--------|--------|
| <img width="1233" alt="Screenshot 2025-01-24 at 12 25 48 PM"
src="https://github.com/user-attachments/assets/2f3c602f-9e46-4c79-95cd-4bb3717f68a3 "
/> | <img width="1233" alt="Screenshot 2025-01-24 at 12 26 01 PM"
src="https://github.com/user-attachments/assets/a4a204dd-9531-45ab-89a2-f1d84f375a7b "
/> |
Release Notes:
- N/A
2025-01-24 12:51:14 -03:00
Danilo Leal
48bcf5b133
assistant2: Adjust spacing and icons on the context picker ( #23607 )
...
Just fine-tuning spacing, icon size and color, and ensure they're are
consistent throughout.
Release Notes:
- N/A
2025-01-24 12:34:11 -03:00
Piotr Osiewicz
084322800a
search: Move invalid UTF-8 errors to debug level ( #23602 )
...
Closes #ISSUE
Release Notes:
- N/A
2025-01-24 14:11:45 +01:00
Danilo Leal
ae1bf48923
title_bar: Use an IconButton for the user menu ( #23601 )
...
That's specifically when we're not rendering the user menu with an
Avatar. We were previously rendering a `ButtonLike` with unnecessary
flex styles there. Just a little fine-tune.
Release Notes:
- N/A
2025-01-24 09:49:50 -03:00
Danilo Leal
6b555546e2
assistant2: Disable the Submit button when missing requirements ( #23598 )
...
This PR disables the Assistant 2 Submit button when either there is no
message written in the editor or there's no model selected. To guide the
user, there will be a tooltip displayed on top of the button to indicate
what to do.
Release Notes:
- N/A
2025-01-24 09:44:20 -03:00
Danilo Leal
641efb71c0
assistant: Adjust the ToS acceptance card design ( #23599 )
...
Just fine-tuning the copywriting and design here.
| Before | After |
|--------|--------|
| <img width="1233" alt="Screenshot 2025-01-24 at 9 28 30 AM"
src="https://github.com/user-attachments/assets/ca91a985-8a20-4ece-b0e4-3a6779db2fda "
/> | <img width="1233" alt="Screenshot 2025-01-24 at 9 27 49 AM"
src="https://github.com/user-attachments/assets/edc9c2ef-4ae0-4caf-a496-9887748673c9 "
/> |
Release Notes:
- N/A
2025-01-24 09:44:09 -03:00
Danilo Leal
8f3c268f05
Allow the context menu to take an icon_color ( #23600 )
...
Doing this to enable customization in the Assistant 2 context picker.
Release Notes:
- N/A
2025-01-24 09:44:00 -03:00
Michael Sloan
2524854b6b
Fix terminal memory leak by deduping alacritty events on background thread ( #23593 )
...
Closes #23008
Release Notes:
- Fixed case where the terminal can leak memory when it produces events
at a faster rate than could be processed.
2025-01-24 10:25:03 +00:00
Shivam Mishra
458ffff80d
docs: context_servers json example ( #23588 )
2025-01-24 08:10:59 +00:00
Marshall Bowers
efcc97cc68
assistant2: Add thread persistence ( #23582 )
...
This PR adds persistence for threads in Assistant2.
Threads are now persisted to an LMDB database.
Release Notes:
- N/A
2025-01-24 00:09:26 +00:00
Piotr Osiewicz
08fd239444
search: Add heuristic for discarding matching of binary files ( #23581 )
...
Fixes #23398
Closes #23398
We'll bail on searches of files that we know are binary (thus even if we
were to find a match in them, they'd be thrown away by buffer loader).
Release Notes:
- Improved project search performance in worktrees with binary files
2025-01-23 22:15:58 +00:00
Marshall Bowers
ade60a0e19
assistant_context_editor: Put uses in the right spot ( #23579 )
...
This PR cleans up some `use` statements that weren't at the very top of
the module.
Release Notes:
- N/A
2025-01-23 21:58:33 +00:00
Marshall Bowers
09f958a49f
assistant2: Expose ActiveThread::thread via a getter ( #23577 )
...
This PR exposes the `thread` file on the `ActiveThread` via a getter
rather than exposing the field directly.
Release Notes:
- N/A
2025-01-23 21:54:16 +00:00
Michael Sloan
8c14c772b9
Update some editor methods to instead take immutable references ( #23578 )
...
Makes the signatures more informative and can be more convenient as
multiple immutable borrows are allowed.
Release Notes:
- N/A
2025-01-23 21:52:10 +00:00
Agus Zubiaga
b7c1d7e883
Disable zeta predictions in assistant completion menu ( #23573 )
...
We don't want the zeta predictions entry to show in the assistant
context editor when completing slash commands. Zeta will still make
suggestions in the rest of the context editor, like the other providers
do.
Release Notes:
- N/A
2025-01-23 18:49:17 -03:00
Joseph T. Lyons
330f7ff441
Autoscroll when running editor: swap selection ends ( #23575 )
...
Closes https://github.com/zed-industries/zed/issues/23512
Release Notes:
- Improved `editor: swap selection ends` by always scrolling the cursor
into view
2025-01-23 21:35:24 +00:00
Piotr Osiewicz
fa12151628
project: Revert project tree impl (again) ( #23572 )
2025-01-23 16:10:38 -05:00
Marshall Bowers
4938abb7db
docs: Document ZED_DEVELOPMENT_AUTH ( #23571 )
...
This PR adds documentation for the `ZED_DEVELOPMENT_AUTH` environment
variable, in the hopes that it helps folks find it sooner.
Release Notes:
- N/A
2025-01-23 20:52:14 +00:00
Marshall Bowers
62ca3a7e52
ui: Don't add an on_click handler for disabled ListItems ( #23569 )
...
This PR updates the `ListItem` component to not register an `on_click`
handler for `ListItem`s that are disabled.
When working on #23350 I noticed that even when the context menu entry
was disabled you could still click on the entry to fire the action.
Release Notes:
- Fixed some instances of disabled list items still registering clicks.
2025-01-23 19:58:07 +00:00
Swiftaff and Marshall Bowers
8adeb9fe64
Disable Copy Permalink context menu item when not in git repo ( #23350 )
...
Closes #13979
Please review this approach to hide the permalink, or alternatively to
disable it instead?
Release Notes:
- The Copy Permalink menu item is now disabled when not in a Git
repository.
---------
Co-authored-by: Marshall Bowers <git@maxdeviant.com >
2025-01-23 19:53:07 +00:00
Conrad Irwin and Jon Walstedt
a9907ed170
vim: Add support for ctrl-g ( #23562 )
...
Co-Authored-By: Jon Walstedt <jon@walstedt.se >
Closes #22094
Release Notes:
- vim: Added support for ctrl-g
Co-authored-by: Jon Walstedt <jon@walstedt.se >
2025-01-23 12:10:08 -07:00
Peter Tripp
7932c394d5
ollama: Set default max_tokens for llama3.3 ( #23558 )
2025-01-23 17:38:43 +00:00
ba41caf1ea
inline completion: Add syntax highlighting for edit prediction ( #23361 )
...
Closes #ISSUE
Release Notes:
- N/A
---------
Co-authored-by: Antonio Scandurra <me@as-cii.com >
Co-authored-by: Agus <agus@zed.dev >
2025-01-23 17:32:43 +00:00
Cole Miller and Marshall
ff4e4f7d60
Remove unwrap in GitTraversal::synchronize_statuses ( #23555 )
...
Release Notes:
- Fixed a potential panic in handling of Git statuses.
Co-authored-by: Marshall <marshall@zed.dev >
2025-01-23 12:13:20 -05:00
Peter Tripp
b0f32d748a
terraform: Bump to v0.1.2 ( #23546 )
...
Includes:
- https://github.com/zed-industries/zed/pull/22268
2025-01-23 11:34:40 -05:00
Peter Tripp
9a83f2f2c0
scheme: Bump to v0.0.2 ( #23545 )
...
Includes:
- https://github.com/zed-industries/zed/pull/18728
- https://github.com/zed-industries/zed/pull/20206
2025-01-23 11:34:29 -05:00
Nate Butler
d35aa5898d
git_panel: Toggle stage all when clicking changes label ( #23548 )
...
When clicking the checkbox label fire the toggle action.
At first I wasn't sure this is what we wanted, but after looking at a
few existing implementations of checkboxes with labels it seems like
this is reasonably standard.
Eventually this piece of UI will be updated to a CheckboxWithLabel, but
for now it is custom due to some specific style requirements.
Release Notes:
- N/A
2025-01-23 16:18:25 +00:00
Piotr Osiewicz
4b38f94c94
project: Bring back language servers in detached worktrees ( #23530 )
...
Closes #ISSUE
Release Notes:
- N/A
2025-01-23 17:03:53 +01:00
Peter Tripp
6b8626e964
zig: Bump to v0.3.3 ( #23547 )
...
Includes:
- https://github.com/zed-industries/zed/pull/22609
2025-01-23 10:54:50 -05:00
Peter Tripp
d0e33af937
php: Bump to v0.2.4 ( #23543 )
...
Includes:
- https://github.com/zed-industries/zed/pull/23532
- https://github.com/zed-industries/zed/pull/22268
2025-01-23 10:48:58 -05:00
Peter Tripp
6a2f97302d
purescript: Bump to v0.1.0 ( #23544 )
...
Includes:
- https://github.com/zed-industries/zed/pull/15181
- https://github.com/zed-industries/zed/pull/16955
- https://github.com/zed-industries/zed/pull/22609
2025-01-23 10:44:22 -05:00
Peter Tripp
0b7fa89dab
csharp: Bump to v0.1.1 ( #23539 )
...
Includes:
- https://github.com/zed-industries/zed/pull/22936
2025-01-23 10:40:54 -05:00
Peter Tripp
9444098dba
html: Bump to v0.1.5 ( #23542 )
...
Includes:
- https://github.com/zed-industries/zed/pull/20752
- https://github.com/zed-industries/zed/pull/22268
2025-01-23 10:37:14 -05:00
Peter Tripp
14bf433de6
haskell: Bump to v0.1.3 ( #23541 )
...
Includes:
- https://github.com/zed-industries/zed/pull/22609
2025-01-23 10:30:47 -05:00
Peter Tripp
3da1b9a685
elixir: Bump to v0.1.4 ( #23540 )
...
Includes:
- https://github.com/zed-industries/zed/pull/22055
- https://github.com/zed-industries/zed/pull/22268
2025-01-23 10:27:21 -05:00
Ollie Beckwith
5d18cdfbb9
php: Add nowdoc language injection ( #23532 )
...
We already have heredoc injection support, so this just extends it to also cover
[nowdoc](https://www.php.net/manual/en/language.types.string.php#language.types.string.syntax.nowdoc ).
2025-01-23 09:51:18 -05:00
Thorsten Ball
72ed834cd6
llm: Sample ~10% of staff members inputs/outputs to LLM ( #23537 )
...
Release Notes:
- N/A
2025-01-23 15:32:25 +01:00
Kirill Bulatov and Piotr Osiewicz
8a0ab2a1c2
Fix LSP violation when dismissing server notifications ( #23531 )
...
Part of https://github.com/zed-industries/zed/issues/22606
Closes https://github.com/zed-industries/zed/issues/23509
When a user sees an odd notification from the language server like
<img width="508" alt="image"
src="https://github.com/user-attachments/assets/6f5ef1aa-0f09-4705-a02a-aaf81dd8620c "
/>
they usually dismiss that.
Zed uses channels to wait and handle user interactions with such
notifications, and, due to `?`, sends back
```json
{"jsonrpc":"2.0","id":1,"error":{"message":"receiving from an empty and closed channel"}}
```
which is not spec-compliant:
https://microsoft.github.io/language-server-protocol/specifications/lsp/3.17/specification/#window_showMessageRequest
> Response:
>
> * result: the selected
[MessageActionItem](https://microsoft.github.io/language-server-protocol/specifications/lsp/3.17/specification/#messageActionItem )
| null if none got selected.
> * error: code and message set in case an exception happens during
showing a message.
Unfortunately, vtsls (and, potentially, others) crash if receive such
non-compliant requests, and do not get back.
After the fix, the message is correct:
```json
{"jsonrpc":"2.0","id":1,"result":null}
```
Release Notes:
- Fixed vtsls crashing on notification dismiss
Co-authored-by: Piotr Osiewicz <piotr@zed.dev >
2025-01-23 13:30:35 +00:00
Nate Butler
c4fabde1e5
theme: Add version control colors ( #23529 )
...
This PR adds version control-specific theme tokens to the them to allow
styling entries in the git ui and elsewhere.
Release Notes:
- N/A
2025-01-23 07:56:49 -05:00