Max Brunsfeld
77bbf76cbc
Autoclose brackets before a language-specific set of characters
...
Fixes #588
2022-03-14 15:17:40 -07:00
Max Brunsfeld
836480a3e3
Merge branch 'main' into settings-file
2022-03-13 10:43:23 -07:00
Nathan Sobo
ea7f2b309d
Merge remote-tracking branch 'origin/main' into select-on-rename
2022-03-12 10:10:23 -07:00
Max Brunsfeld
839a7f8782
Start work on relaying settings to language servers
2022-03-11 17:36:27 -08:00
Nathan Sobo
2c6d8e9d65
Merge branch 'main' into select-on-rename
2022-03-11 15:30:07 -07:00
Max Brunsfeld
62c3c6b290
Provide JSON language server with settings schema
2022-03-11 11:46:22 -08:00
Nathan Sobo and Antonio Scandurra
0db6f31d02
Remove dead code
...
Co-Authored-By: Antonio Scandurra <me@as-cii.com >
2022-03-11 08:24:42 -07:00
Antonio Scandurra
518662da6d
Delete till previous tabstop when backspacing within indent column
2022-03-10 10:28:24 +01:00
Nathan Sobo
150fdc71af
Start on text highlight support
2022-03-09 20:51:35 -07:00
Antonio Scandurra
180c7dabff
Split language server initialization from construction
...
This gives clients a chance to register to notifications.
2022-03-09 12:31:21 +01:00
Antonio Scandurra
fd5218858d
Remove delegate support from GPUI
...
We added this because we thought it would save some allocations when
sending operations given that we could move them to the delegate upon
notifying it, but the reality is that we serialize operations and that
only requires a reference.
2022-03-09 10:48:52 +01:00
Max Brunsfeld
bfc721db27
Assign buffer's completion triggers from LSP capabilities
...
Also, make LanguageServer::new() async. The future resolves
once the server is initialized.
2022-03-08 17:41:52 -08:00
111d5305ea
Remove language servers from buffers
...
Co-Authored-By: Nathan Sobo <nathan@zed.dev >
Co-Authored-By: Antonio Scandurra <antonio@zed.dev >
Co-Authored-By: Keith Simmons <keith@zed.dev >
2022-03-08 15:16:07 -08:00
Antonio Scandurra
b130318ee7
Move DidSaveTextDocument notification from Buffer to Project
2022-03-08 11:35:54 +01:00
Antonio Scandurra
f752458c55
Remove unused CloseBuffer message
2022-03-08 11:17:20 +01:00
Antonio Scandurra
a26a8fca8a
Send buffer operations via the Project instead of Worktree
2022-03-08 11:11:25 +01:00
1cd9a3244a
Populate environment from shell
...
Co-Authored-By: Keith Simmons <keith@zed.dev >
Co-Authored-By: Nathan Sobo <nathan@zed.dev >
2022-03-07 16:39:50 -08:00
Max Brunsfeld and Nathan Sobo
8529a10317
Put vector clock serialization logic alongside other serialization logic
...
This way, the `clock` crate doesn't depend on the `rpc` crate.
Co-Authored-By: Nathan Sobo <nathan@zed.dev >
2022-03-04 13:54:07 -08:00
Max Brunsfeld and Nathan Sobo
3420f41715
Move Network test helper from util crate into text crate
...
This way, `util` does not depend on `clock`.
Co-Authored-By: Nathan Sobo <nathan@zed.dev >
2022-03-04 13:54:07 -08:00
Antonio Scandurra
3ad7272559
Merge pull request #525 from zed-industries/preserve-worktrees
...
Grow worktrees monotonically when sharing and move most messages to the background
2022-03-04 09:48:18 +01:00
Antonio Scandurra
a9a0df58c0
Observe selection set lamport timestamps when deserializing buffer
2022-03-04 09:34:30 +01:00
Antonio Scandurra
64acd485c0
Allow receiving diagnostic updates out of order
2022-03-04 09:27:49 +01:00
Max Brunsfeld
ee589d9cf7
Avoid infinite loop when a language server fails to start
2022-03-03 18:13:38 -08:00
Max Brunsfeld
3a1a9ecb45
Disable doctests for all libraries
...
We don't use them, and they add a lot of noise to the test output
when running all tests in the workspace.
2022-03-03 16:15:56 -08:00
Max Brunsfeld
5072109d9d
Make fake language servers have full capabilities
2022-03-03 15:42:29 -08:00
Max Brunsfeld and Nathan Sobo
5868120184
Enable formatting feature of JSON language server
...
The feature doesn't work yet because the JSON language server
only supports *range* formatting, not document formatting.
We need to adjust our code to inspect the server's capabilities
and send range formatting requests instead when needed.
We're going to hold off on doing this right now, because it
will create merge conflicts with the `preserve-worktrees`
branch (#525 )
Co-Authored-By: Nathan Sobo <nathan@zed.dev >
2022-03-03 14:16:58 -08:00
Max Brunsfeld and Nathan Sobo
b5800767f1
Add JSON language server
...
Co-Authored-By: Nathan Sobo <nathan@zed.dev >
2022-03-03 13:29:25 -08:00
b36faed34e
Correctly defer undo operations when messages arrive out of order
...
Co-Authored-By: Nathan Sobo <nathan@zed.dev >
Co-Authored-By: Max Brunsfeld <max@zed.dev >
2022-03-03 18:07:59 +01:00
Antonio Scandurra
e18e172cda
Move several buffer-related messages to the background
2022-03-03 12:18:19 +01:00
Antonio Scandurra
79568c471a
Pass a reference to TestAppContext in tests
...
This allows us to drop the context *after* we ran all futures to
completion and that's crucial otherwise we'll never drop entities
and/or flush effects.
2022-03-01 12:01:02 +01:00
Nathan Sobo
08409a57ed
Allow a new search to be created with cmd-enter
...
This replaces the `cmd-alt-shift-F` binding to open a new search. Instead, you can preserve the existing search results by entering a query and then hitting `cmd-enter` instead of `enter`. This opens a new project find view and restores the previous view to whatever query it was previously displaying. It's a bit strange, but I don't want to rely on splitting as the only way of creating multiple sets of search results.
2022-02-26 13:23:05 -07:00
Antonio Scandurra
f2d7451ca2
Use Project::search in ProjectFind and show search results
2022-02-25 10:32:45 +01:00
Antonio Scandurra
919a280fab
Pass an AsyncAppContext to fake language server request handlers
2022-02-23 16:14:36 +01:00
b43945d6c6
Allow languages to be registered at any time
...
Co-Authored-By: Nathan Sobo <nathan@zed.dev >
Co-Authored-By: Antonio Scandurra <me@as-cii.com >
2022-02-22 10:35:20 -08:00
Antonio Scandurra and Nathan Sobo
447cc969f1
Don't serialize the full LSP symbol when collaborating
...
Co-Authored-By: Nathan Sobo <nathan@zed.dev >
2022-02-22 18:08:43 +01:00
Antonio Scandurra
0fc1d67784
Rename CompletionLabel to CodeLabel and add Project::symbols
...
This only works locally for now and we haven't implemented the
`RustLsp::label_for_symbol` method yet.
2022-02-22 10:01:08 +01:00
Nathan Sobo
6ce19ad1a2
Log an error instead of panicking when there's no LSP download dir
2022-02-21 17:44:00 -07:00
Max Brunsfeld and Nathan Sobo
bdb3c462f4
Assign language server download directory on startup
...
Co-Authored-By: Nathan Sobo <nathan@zed.dev >
2022-02-21 16:23:38 -08:00
Max Brunsfeld and Nathan Sobo
79a0d152a3
Show more information in lsp status bar item
...
* Distinguish between checking for updates and downloading
* Show dismissable error message when downloading failed and there
is no cached server.
Co-Authored-By: Nathan Sobo <nathan@zed.dev >
2022-02-21 16:11:51 -08:00
Max Brunsfeld and Nathan Sobo
c9a4d76f2d
Download language servers on-demand
...
Co-Authored-By: Nathan Sobo <nathan@zed.dev >
2022-02-21 13:54:52 -08:00
Antonio Scandurra and Nathan Sobo
ec875ff474
Show message indicating when we're downloading language servers
...
Co-Authored-By: Nathan Sobo <nathan@zed.dev >
2022-02-21 17:25:52 +01:00
Antonio Scandurra
5967d87885
Download rust-analyzer from GitHub
2022-02-21 16:15:54 +01:00
Antonio Scandurra
6a7a19039c
Introduce LspPostProcessor::download_language_server
2022-02-21 09:46:18 +01:00
Antonio Scandurra
ede6adbe76
Make language server initialization asynchronous
2022-02-21 09:39:28 +01:00
Antonio Scandurra
1980656679
Revert "WIP: avoid code-signing rust-analyzer to prevent proc macro errors"
...
This reverts commit a7160ed278 .
2022-02-21 08:13:05 +01:00
Antonio Scandurra
a7160ed278
WIP: avoid code-signing rust-analyzer to prevent proc macro errors
...
If this works, I think we should set the permissions asynchronously,
maybe as part of starting the language server, so that we avoid doing
synchronous I/O.
2022-02-20 12:14:43 +01:00
Antonio Scandurra
c0d1e77c21
Fix warnings
2022-02-17 17:26:03 +01:00
Antonio Scandurra
fac5959ac2
Wait for version before returning completions
2022-02-17 11:41:19 +01:00
Max Brunsfeld and Nathan Sobo
258542b74a
Remove unnecessary waiting when handling save RPC requests
...
Add saving to the randomized integration test
Co-Authored-By: Nathan Sobo <nathan@zed.dev >
2022-02-16 17:47:21 -08:00
Max Brunsfeld and Nathan Sobo
529e18978e
Remove unnecessary waiting during completion RPC requests
...
Also, add completion requests to the randomized collaboration integration test,
to demonstrate that this is valid.
Co-Authored-By: Nathan Sobo <nathan@zed.dev >
2022-02-16 17:23:16 -08:00