Max Brunsfeld
b5d862abfe
Only send one UpdateProject msg when changing project's online status
2022-06-29 17:58:02 -07:00
Antonio Scandurra
7bae759a02
Send extension counts when metadata changes
...
Co-Authored-By: Nathan Sobo <nathan@zed.dev>
2022-06-29 17:58:11 +02:00
Antonio Scandurra
d1cdacdf14
Skip ignored entries when recording worktree extensions
...
Co-Authored-By: Nathan Sobo <nathan@zed.dev>
2022-06-29 17:00:16 +02:00
Antonio Scandurra
639cd71a3b
Record worktree extensions every 5 minutes
...
Co-Authored-By: Nathan Sobo <nathan@zed.dev>
2022-06-29 16:58:19 +02:00
Antonio Scandurra
f9e0fec396
Maintain extension counts on local worktrees
...
Co-Authored-By: Nathan Sobo <nathan@zed.dev>
2022-06-29 16:38:24 +02:00
Antonio Scandurra
09f4262fd4
Don't share a project unless it's online and we're allowing a request
2022-06-29 15:16:55 +02:00
Antonio Scandurra
e3cfc7b3ce
Register project activity for offline projects as well
2022-06-29 14:55:04 +02:00
Max Brunsfeld
8fe6809932
Exclude hidden worktrees from project's diagnostic summaries
2022-06-28 14:23:24 -07:00
Max Brunsfeld
f05e94d0de
Allow diagnostics to be published for hidden worktrees
2022-06-28 13:31:04 -07:00
Antonio Scandurra
ca1d0a6e59
Ignore tokens that were not created via WorkDoneProgressCreate
...
With the new version of rust-analyzer, we were seeing stray `WorkDoneProgress::End`
messages that create an imbalance in the `pending_diagnostic_updates` that never
resolves. This was causing the diagnostic status bar item to never update because
we wouldn't emit `DiskBasedDiagnosticsStarted` nor `DiskBasedDiagnosticsFinished`.
This commit fixes the above situation by only acknowledging progress report for tokens
that have explicitly been created via the `WorkDoneProgressCreate` request, as stated
by the protocol.
In addition to that, we are replacing the `pending_diagnostic_updates: isize` with
a `has_pending_diagnostic_updates: bool`. We added it at some point to prevent a similar
issue where we would observe begin/end reports in a seemingly random order, which would cause
us to permanently display a `checking...` message in the status bar. I believe this commit
fixes that as well because the `isize` was just a less general solution for the same
underlying issue. As the protocol states: "the token provided in the create request should
only be used once (e.g. only one begin, many report and one end notification should be sent
to it)."
2022-06-28 10:08:43 +02:00
Keith Simmons
a477733bcb
Address hover panic and add hint to install go when language server failed to install
2022-06-27 15:48:15 -07:00
Keith Simmons
bc82d98ae5
Merge pull request #1237 from zed-industries/jump-to-definition
...
Mouse jump to definition
2022-06-27 15:20:07 -07:00
Antonio Scandurra
7bfd7093b1
Don't stop scanning directory if reading one of the children errors
2022-06-27 08:40:37 +02:00
Keith Simmons
92ab107fc9
working jump to definition with tests
2022-06-24 15:09:31 -07:00
Keith Simmons
848445455d
Working underline based on symbol origin
2022-06-24 15:05:35 -07:00
Keith Simmons
755636d10e
Use NonZeroU32 to ensure settings tabsize cannot be zero
2022-06-23 12:55:38 -07:00
Antonio Scandurra
2cb8a3ccfb
Don't override top-level settings with language defaults
...
Co-Authored-By: Nathan Sobo <nathan@zed.dev>
2022-06-23 16:40:57 +02:00
Antonio Scandurra
2d8ffbdfa2
Don't wait for host's worktree updates if they disconnected
...
Co-Authored-By: Max Brunsfeld <max@zed.dev>
2022-06-22 19:45:55 +02:00
Antonio Scandurra
2f09a4af16
Update project metadata when releasing a worktree's weak handle
...
When a project was getting unshared, we would remove invisible worktrees
from the project's state without notifying the server, which was causing
the randomized tests to fail.
This commit calls `Project::remove_worktree` when a worktree's handle gets
released. Doing so ensures that we update both our local metadata database
as well as the state on the server.
2022-06-22 10:26:10 +02:00
Antonio Scandurra
69aa3d848e
Report running language servers when sharing project for the first time
...
Co-Authored-By: Max Brunsfeld <max@zed.dev>
2022-06-21 20:39:54 +02:00
Antonio Scandurra
4f215a77cd
Don't compute fingerprint for every text summary
2022-06-17 15:15:27 +02:00
Antonio Scandurra
6f7a893ec9
Determine Buffer::is_dirty
based on the rope's fingerprint
2022-06-17 12:38:25 +02:00
Antonio Scandurra
dc75b70724
Use word boundaries instead of syntax to infer completion edit ranges
2022-06-16 11:27:22 +02:00
Antonio Scandurra
35889add40
Add failing test for wrong typescript completion
2022-06-16 11:26:35 +02:00
Antonio Scandurra
3a1d0dd692
Track active projects in metrics
...
An active project is defined as a project where there has been at
least a buffer edit, a join request/response, or a follow update
in the last minute.
2022-06-15 10:33:20 +02:00
Keith Simmons
93158bfcff
Fix delayed lsp request
2022-06-09 17:03:45 -07:00
Max Brunsfeld
87ba68e3ea
Merge pull request #1155 from zed-industries/golang
...
Add Go support
2022-06-09 14:18:37 -07:00
Max Brunsfeld
4ce4c0ef03
Ignore completions from gopls that we can't yet handle
...
We only support additionalEdits if they are provided when resolving the
completion, not if they are provided immediately.
2022-06-09 13:08:08 -07:00
Antonio Scandurra
213b31607c
Remove language server statuses synchronously when stopping a server
2022-06-09 10:59:02 +02:00
Antonio Scandurra
69170fc33a
Add unit test to ensure changing enable_language_server
works
2022-06-09 10:48:06 +02:00
Antonio Scandurra
36a1a7a819
Start/stop language servers when enable_language_server
changes
2022-06-09 10:08:11 +02:00
Antonio Scandurra
9d7476afc6
Extract a Project::stop_language_server
method when restarting server
...
This will be useful later to stop a language server when detecting
configuration changes.
2022-06-09 10:05:35 +02:00
Max Brunsfeld
36ce3eb5ef
Handle messages associated with LSP WorkDoneProgress::Begin
messages
...
Co-authored-by: Antonio Scandurra <me@as-cii.com>
2022-06-08 10:26:41 -07:00
Antonio Scandurra
eda569d6b2
Snapshot file instead of path when creating a buffer snapshot
2022-06-08 14:29:14 +02:00
Antonio Scandurra
d8b885e3ec
Provide tab_size
when formatting document using LSP range formatting
2022-06-08 09:56:11 +02:00
Keith Simmons
9d5111e86a
Merge pull request #1078 from zed-industries/lsp-hover
...
LSP Hover Information
2022-06-07 14:45:43 -07:00
Keith Simmons
1b66e1e185
Add integration test and fix hovering over the wire
2022-06-07 14:22:02 -07:00
Keith Simmons
a6c0ee472c
Add vim bindings for hover
...
Allow scrolling in hover popover
2022-06-07 13:07:53 -07:00
Keith Simmons
67d9abc00f
Move highlighting to editor code and implement proto message types for hover response
2022-06-07 11:54:52 -07:00
Keith Simmons
c7cc07aafb
working markdown rendering
2022-06-07 11:54:51 -07:00
Keith Simmons
b014352740
Syntax highlighting working. Getting started on markdown support
2022-06-07 11:54:33 -07:00
Isaac Clayton
d529a1deb4
Add basic debounce, fix flickering
2022-06-07 11:54:31 -07:00
Keith Simmons
560dff7329
Pull hover popover out of context menu
2022-06-07 11:54:00 -07:00
Isaac Clayton
470c70d394
Get minimal POC working
2022-06-07 11:52:52 -07:00
Antonio Scandurra
b04e62d895
Fix tracking of in-progress disk-based diagnostics on indicator
...
Co-Authored-By: Max Brunsfeld <max@zed.dev>
2022-06-07 19:35:53 +02:00
Antonio Scandurra
bbfa6580a4
Avoid refreshing diagnostics for language servers that didn't update
...
Co-Authored-By: Max Brunsfeld <max@zed.dev>
2022-06-07 19:05:06 +02:00
Antonio Scandurra
1ecc51f035
Fix warnings
2022-06-06 16:23:49 +02:00
Antonio Scandurra
70afc06666
Handle out-of-order edits coming from LSP
2022-06-06 16:15:11 +02:00
Max Brunsfeld
ed14fd6e0d
Add setting to make projects online/offline by default
2022-06-03 17:01:15 -07:00
Max Brunsfeld
24aafde1e8
Avoid persisting project's state before it has been initialized
2022-06-03 16:40:16 -07:00