Commit graph

22419 commits

Author SHA1 Message Date
Joseph T Lyons
500c3c54a6 v0.156.x dev 2024-09-25 11:02:40 -04:00
Peter Tripp
59dc3985a1
Detect txt files as Plain Text (#18334) 2024-09-25 07:41:35 -04:00
Thorsten Ball
ccc871c44c
ssh remoting: Expand tilde on host side (#18333) 2024-09-25 13:41:18 +02:00
Thorsten Ball
4e2ae06ca6
recent project: Fix highlighting for matches in SSH projs (#18332)
Release Notes:

- N/A

Co-authored-by: Bennet <bennet@zed.dev>
2024-09-25 12:59:22 +02:00
Thorsten Ball
300bf87f77
ssh remoting: Kill SSH master process when dropping client (#18331)
This was a process leak. Since we use `.spawn()`, the process continued
to run in the background, even if our `SshClientState` was dropped.

Means we need to manually clean it up.

Release Notes:

- N/A

Co-authored-by: Bennet <bennet@zed.dev>
2024-09-25 12:45:53 +02:00
Piotr Osiewicz
a6cb17fb51
chore: Fix violations of elided_named_lifetimes (#18330)
I compile Zed from nightly build pretty often and I've noticed that
we're getting a few hits on new rustc lint:
https://github.com/rust-lang/rust/pull/129207

Release Notes:

- N/A
2024-09-25 12:27:57 +02:00
Thorsten Ball
9d197ddc99
ssh remoting: Fix SSH connection not being closed (#18329)
This fixes the `SshSession` being leaked.

There were two leaks:

1. `Arc<SshSession>` itself got leaked into the `SettingsObserver` that
   lives as long as the application. Fixed with a weak reference.
2. The two tasks spawned by an `SshSession` had a circular dependency
   and didn't exit while the other one was running. Fixed by fixing (1)
   and then attaching one of the tasks to the `SshSession`, which means
   it gets dropped with the session itself, which leads the other task
   to error and exit.

Co-authored-by: Bennet <bennet@zed.dev>

Release Notes:

- N/A

---------

Co-authored-by: Bennet <bennet@zed.dev>
2024-09-25 12:03:24 +02:00
Piotr Osiewicz
623a6eca75
git: Do not rescan .git on fsmonitor events (#18326)
Fixes #16404 by ignoring events coming from
.git/fsmonitor--daemon/cookies subdirectory.

Closes #16404

Release Notes:

- Improved performance in repositories using Git fsmonitor--daemon
feature.
2024-09-25 11:34:27 +02:00
Thorsten Ball
7bb510971a
file picker: Use muted color for file icons (#18325)
I think they were too much in-your-face. Muted looks better.

Before:

![image](https://github.com/user-attachments/assets/73d6171a-6276-4450-acfb-52cd44fdfe59)

After:

![image](https://github.com/user-attachments/assets/1d5f4524-b0b9-4ba6-ab66-5eaf619e58f9)

Release Notes:

- N/A
2024-09-25 10:26:00 +02:00
Thorsten Ball
eb71d2f1a8
zig: Fix highlighting of keywords like orelse, or, and (#18323)
This changes the Zig highlights.scm to tag all keywords with `@keyword`
and not with `@keyword.<subtype>`, so the highlighting works properly.

Closes #9355

Release Notes:

- N/A

Demo:

![screenshot-2024-09-25-09 32
20@2x](https://github.com/user-attachments/assets/567b8817-a522-4741-af7f-dcb1a79ddd40)
2024-09-25 10:03:10 +02:00
Thorsten Ball
fc9db97ac7
client: Remove unused fs dependency (#18324)
CI bot notified me about that in
https://github.com/zed-industries/zed/pull/18323


Release Notes:

- N/A
2024-09-25 10:02:35 +02:00
CharlesChen0823
e9bc9ed5d5
remote_server: Fix opening a new remote project not refreshing the project panel (#18262)
Some checks are pending
CI / Check formatting and spelling (push) Waiting to run
CI / (macOS) Run Clippy and tests (push) Waiting to run
CI / (Linux) Run Clippy and tests (push) Waiting to run
CI / (Windows) Run Clippy and tests (push) Waiting to run
CI / Create a macOS bundle (push) Blocked by required conditions
CI / Create a Linux bundle (push) Blocked by required conditions
CI / Create arm64 Linux bundle (push) Blocked by required conditions
Deploy Docs / Deploy Docs (push) Waiting to run
Docs / Check formatting (push) Waiting to run
Currently, when open new remote project, project_panel not refresh, we
must `ctrl-p` and select an file to refresh the project_panel. After
that, project_panel will refresh when remote project window active.

Release Notes:

- Fixed remote projects not restoring previous locations and not
refreshing the project panel on open.
2024-09-25 10:00:17 +02:00
Peter Tripp
9a8601227d
docs: Add example of TOML/taplo LSP settings (#18293)
Some checks are pending
CI / Check formatting and spelling (push) Waiting to run
CI / (macOS) Run Clippy and tests (push) Waiting to run
CI / (Linux) Run Clippy and tests (push) Waiting to run
CI / (Windows) Run Clippy and tests (push) Waiting to run
CI / Create a macOS bundle (push) Blocked by required conditions
CI / Create a Linux bundle (push) Blocked by required conditions
CI / Create arm64 Linux bundle (push) Blocked by required conditions
Deploy Docs / Deploy Docs (push) Waiting to run
Docs / Check formatting (push) Waiting to run
2024-09-24 22:23:32 +00:00
Conrad Irwin
d33600525e
ssh remoting: Fix cmd-o (#18308)
Release Notes:

- ssh-remoting: Cmd-O now correctly opens files on the remote host

---------

Co-authored-by: Mikayla <mikayla@zed.dev>
2024-09-24 16:23:08 -06:00
Max Brunsfeld
fdb03d3058
Move DisplayDiffHunk into hunk_diff module (#18307)
Release Notes:

- N/A

Co-authored-by: Marshall <marshall@zed.dev>
2024-09-24 18:16:27 -04:00
Conrad Irwin
c4e0f5e0ee
Rebuild buffer store to be aware of remote/local distinction (#18303)
Release Notes:

- N/A

---------

Co-authored-by: Mikayla <mikayla@zed.dev>
2024-09-24 14:52:30 -07:00
Max Brunsfeld
da1ef13442
Fix detection that a diff hunk is expanded (#18302)
Release Notes:

- N/A

---------

Co-authored-by: Marshall <marshall@zed.dev>
2024-09-24 17:39:44 -04:00
Conrad Irwin
5045f984a9
Tidy up some broken menu items (#18306)
Release Notes:

- ssh-remoting: Don't show "reveal in finder" in menu
2024-09-24 14:37:09 -07:00
Kirill Bulatov
2d71c36ad3
Allow clearning activity indicators on click (#18305)
All indicators without the click action are now could be hidden with a click.

Sometimes, I see a few language server updates statuses get stuck due to npm desperately attempting to access its registry (3 times per each package, with the timeout a bit under 1 minute per each request).
So, while the message seems stuck, npm desperately tries to do some work in the background.

https://docs.npmjs.com/cli/v10/using-npm/config has options for timeouts & retries for __package fetching__ but that does not include the actual __registry access attempts__.

It's unclear how to proceed with npm on this case now, but at least we should allow hiding these redundant messages.

Release Notes:

- Improved activity indicators' UX by allowing more of them to be hidden on click
2024-09-25 00:29:56 +03:00
Marshall Bowers
d2ffad0f34
collab: Seed GitHub users from static data (#18301)
This PR updates the collab seed script to seed the GitHub users from a
set of static data.

This removes the need to hit the GitHub API to retrieve these users.

Release Notes:

- N/A
2024-09-24 16:35:09 -04:00
Marshall Bowers
692590bff4
collab: Fix GitHub user retrieval in seed script (#18296)
This PR fixes the GitHub user retrieval in the database seed script.

The users returned from the [list
users](https://docs.github.com/en/rest/users/users?apiVersion=2022-11-28#list-users)
endpoint don't have a `created_at` timestamp, so we need to fetch them
individually.

I want to rework this further at a later date, this is just a bandaid to
get things working again.

Release Notes:

- N/A
2024-09-24 15:44:55 -04:00
Joseph T. Lyons
87ac4cff60
Update close_stale_issues configuration (#18298)
@notpeter and I decided on these things:

- Give users 10 days to respond
- Only run once a week: Tuesday @7AM ET

Release Notes:

- N/A
2024-09-24 15:42:26 -04:00
Max Brunsfeld
9606858436
Fix unnecessarily-specific struct pattern in rust outline query (#18297)
Fixes https://github.com/zed-industries/zed/issues/18294

Release Notes:

- Fixed a recent regression where tuple and unit structs were omitted
from the outline view in Rust (#18294).
2024-09-24 12:08:22 -07:00
Conrad Irwin
f39e54decc
Start work on reload buffers (#18245)
Release Notes:

- Fixed: ssh-remote reload buffers

---------

Co-authored-by: Mikayla <mikayla@zed.dev>
2024-09-24 11:23:39 -07:00
John Cummings
8a7ef4db59
ollama: Add max tokens for qwen2.5-coder (#18290) 2024-09-24 13:17:17 -04:00
ClanEver
fd07fef4db
Fix proxy settings retrieval on startup (#18171)
Closes https://github.com/zed-industries/zed/issues/18155

Release Notes:

- N/A
2024-09-24 10:27:29 -06:00
Sergio C.
4a4d8c1cab
vim: Add ability to spawn multicursors at beginning/end of line (#18183)
Closes #17842

Release Notes:

- Added the ability to spawn multiple cursors through the g-A and g-I
motions while in visual select mode.
2024-09-24 10:21:57 -06:00
Conrad Irwin
b69c6ee7df
Exclude initialization failed errors from slack (#18232)
Release Notes:

- N/A
2024-09-24 10:17:43 -06:00
Conrad Irwin
0e86ba0983
Fix get_cached_binary for eslint (#18286)
Release Notes:

- Fixed running ESLint offline.
2024-09-24 10:13:53 -06:00
Conrad Irwin
5e62bbfd29
Run system npm directly (#18280)
Some checks are pending
CI / Check formatting and spelling (push) Waiting to run
CI / (macOS) Run Clippy and tests (push) Waiting to run
CI / (Linux) Run Clippy and tests (push) Waiting to run
CI / (Windows) Run Clippy and tests (push) Waiting to run
CI / Create a macOS bundle (push) Blocked by required conditions
CI / Create a Linux bundle (push) Blocked by required conditions
CI / Create arm64 Linux bundle (push) Blocked by required conditions
Deploy Docs / Deploy Docs (push) Waiting to run
Docs / Check formatting (push) Waiting to run
Release Notes:

- N/A
2024-09-24 09:44:53 -06:00
Marshall Bowers
21be70f278
Improve diff hunks (#18283)
This PR improves the display of diff hunks:

- Deleted hunks now show a regular line indicator in the gutter when
expanded
- The rounding on the diff indicators in the gutter has been removed.

We also did some refactoring to ensure the sizing of the diff indicators
in the gutter were consistent.

#### Collapsed

<img width="1624" alt="Screenshot 2024-09-24 at 11 13 26 AM"
src="https://github.com/user-attachments/assets/f864dc83-cbbc-4d81-a62b-65c406ed310a">

#### Expanded

<img width="1624" alt="Screenshot 2024-09-24 at 11 13 35 AM"
src="https://github.com/user-attachments/assets/04d382ca-e0e6-4f1c-92eb-cd1e3a031c2c">


Release Notes:

- Improved the appearance of diff hunks in the editor.

---------

Co-authored-by: Max <max@zed.dev>
2024-09-24 11:40:08 -04:00
Kirill Bulatov
2470db4901
Reuse buffer search queries on tab switch (#18281)
Before this change, with a large chunk of text as a search query (N*10^5
in my experiments) and the buffer search bar visible, switching between
editor tabs was very slow, even if the editors were N*10^2 lines long.

The slow switch was caused by Zed always re-creating the Aho-Corasick
queries, which is now reused.

Release Notes:

- Improved buffer search performance when switching tabs

Co-authored-by: Piotr Osiewicz <piotr@zed.dev>
2024-09-24 18:21:26 +03:00
Sebastijan Kelnerič
e87d6da2a6
Implement grapheme support for supermaven completions (#18279)
Closes [#18278](https://github.com/zed-industries/zed/issues/18278)

Release Notes:

- Fixed a panic when graphemes are included in supermaven completions
2024-09-24 08:49:07 -06:00
Thorsten Ball
437bcc0ce6
ssh project: Handle multiple paths and worktrees correctly (#18277)
This makes SSH projects work with `ssh_connections` that have multiple
paths:

```json
{
  "ssh_connections": [
    {
      "host": "127.0.0.1",
      "projects": [
        {
          "paths": [
            "/Users/thorstenball/work/projs/go-proj",
            "/Users/thorstenball/work/projs/rust-proj"
          ]
        }
      ]
    }
  ]
}
```

@ConradIrwin @mikayla-maki since this wasn't really released yet, we
didn't create a full-on migration, so old ssh projects that were already
serialized need to either be manually deleted from the database, or the
whole local DB wiped.

Release Notes:

- N/A

---------

Co-authored-by: Bennet <bennet@zed.dev>
2024-09-24 16:46:11 +02:00
Joseph T. Lyons
3a2f0653d1
Bump operations-per-run parameter in stale issues action (#18276)
Release Notes:

- N/A
2024-09-24 09:44:27 -04:00
Joseph T. Lyons
336b4a5690
Tweak close stale issues configuration (#18275)
Release Notes:

- N/A
2024-09-24 09:15:25 -04:00
Thorsten Ball
93a4295f66
project search: Fix search results not being highlighted (#18273)
Closes #18254
Closes #18219
Closes #17690

This fixes the project search not highlighting all results.

The problem was relatively simple, even though it took a while to find
it: we inserted multiple excerpts concurrently and the order in the
multi-buffer ended up being wrong. Sorting the resulting `match_ranges`
fixed the problem, but as it turns out, we can do a better job by moving
the concurrency into the method on the MultiBuffer.

Performance is the same, but now the problem is fixed.

Release Notes:

- Fixed search results in project-wide search not being highlighted
consistently and navigation sometimes being broken (#18254, #18219,
#17690)

---------

Co-authored-by: Bennet <bennet@zed.dev>
2024-09-24 15:03:22 +02:00
Boris Verkhovskiy
f019ad563f
Don't highlight Python function arguments as variables (#18252)
Works on 
- #14892

Follow up to 
- #17473
-
https://github.com/zed-industries/zed/pull/17984#issuecomment-2369815207

Release Notes:

- N/A
2024-09-24 15:46:06 +03:00
Kirill Bulatov
399e094f02
Properly use default search options in the buffer search bar (#18271)
Only replace current search options if the search was dismissed and the
new options are different from the default ones.

Follow-up of https://github.com/zed-industries/zed/pull/17179
Closes https://github.com/zed-industries/zed/issues/18166


Release Notes:

- Fixed buffer search options toggling unexpectedly on redeploys
([#18166](https://github.com/zed-industries/zed/issues/18166))
2024-09-24 15:36:05 +03:00
Thorsten Ball
dbc325ea12
vtsls: Move all default configuration to workspace_configuration (#18259)
This fixes https://github.com/zed-industries/zed/issues/18014 by fixing
the regression that was introduced in
https://github.com/zed-industries/zed/pull/17757.

In short: after digging into the `vtsls` code, it looks like it
essentially doesn't need any `initialization_options`, it's all
workspace configuration, since it tries to use the built-in settings
from VS Code.

I tested the completions, the inlay hints, the max memory - all of it
now works after moving to `workspace_configuration`.

Closes #18014.

Release Notes:

- Fixed `vtsls` being initialized the wrong way, which would mean the
wrong options were used to enable completions or inlay hints.
2024-09-24 09:52:20 +02:00
Peter Tripp
6b56530a4a
lua: Bump to v0.1.0 (#18246)
Some checks are pending
CI / Check formatting and spelling (push) Waiting to run
CI / (macOS) Run Clippy and tests (push) Waiting to run
CI / (Linux) Run Clippy and tests (push) Waiting to run
CI / (Windows) Run Clippy and tests (push) Waiting to run
CI / Create a macOS bundle (push) Blocked by required conditions
CI / Create a Linux bundle (push) Blocked by required conditions
CI / Create arm64 Linux bundle (push) Blocked by required conditions
Deploy Docs / Deploy Docs (push) Waiting to run
Docs / Check formatting (push) Waiting to run
This PR bumps the Lua extension to v0.1.0

- https://github.com/zed-industries/zed/pull/18199
- https://github.com/zed-industries/zed/pull/16955
2024-09-23 19:53:28 -04:00
Mikayla Maki
20c06545b6
SSH Remoting: Add the ability to resolve file paths on the remote host (#18250)
Some checks are pending
CI / Check formatting and spelling (push) Waiting to run
CI / (macOS) Run Clippy and tests (push) Waiting to run
CI / (Linux) Run Clippy and tests (push) Waiting to run
CI / (Windows) Run Clippy and tests (push) Waiting to run
CI / Create a macOS bundle (push) Blocked by required conditions
CI / Create a Linux bundle (push) Blocked by required conditions
CI / Create arm64 Linux bundle (push) Blocked by required conditions
Deploy Docs / Deploy Docs (push) Waiting to run
Docs / Check formatting (push) Waiting to run
Release Notes:

- N/A
2024-09-23 16:47:25 -06:00
Antonio Scandurra
d989183f94
Remove Debug constraint on SumTree (and its related traits/structs) (#18248)
Release Notes:

- N/A

Co-authored-by: Nathan <nathan@zed.dev>
2024-09-23 16:21:24 -06:00
Conrad Irwin
3ba071b993
Allow using system node (#18172)
Release Notes:

- (Potentially breaking change) Zed will now use the node installed on
your $PATH (if it is more recent than v18) instead of downloading its
own. You can disable the new behavior with `{"node":
{"disable_path_lookup": true}}` in your settings. We do not yet use
system/project-local node_modules.

---------

Co-authored-by: Mikayla <mikayla@zed.dev>
2024-09-23 15:28:04 -06:00
Conrad Irwin
e4080ef565
Move formatting to LSP store (#18242)
Release Notes:

- ssh-remoting: Fixed format on save

---------

Co-authored-by: Mikayla <mikayla@zed.dev>
2024-09-23 13:33:28 -07:00
Peter Tripp
e95e1c9ae5
Add '?plain=1' to Permalinks on GitLab/GitHub for md files (#18241)
Improve our Permalinks to markdown files.
GitHub/GitLab supports the same URL syntax.
2024-09-23 15:45:00 -04:00
狐狸
1ff10b71c8
lua: Add auto-close for single quote strings and highlight escape sequences (#18199)
- Add auto close to single quote string
- Add syntax highlights to escape sequence
2024-09-23 15:39:01 -04:00
Antonio Scandurra
7051bc00c2
Add "Fix with Assistant" code action on lines with diagnostics (#18163)
Release Notes:

- Added a new "Fix with Assistant" action on code with errors or
warnings.

---------

Co-authored-by: Nathan <nathan@zed.dev>
2024-09-23 11:40:34 -06:00
Joseph T. Lyons
1efe87029b
Update stale issues configuration to use 180 days (#18238)
Release Notes:

- N/A
2024-09-23 12:32:31 -04:00
Joseph T. Lyons
11953bbc16
Disable debug mode for stale issue action (#18237)
Release Notes:

- N/A
2024-09-23 12:24:49 -04:00