645df73
Finish implementing Buffer::edits_from_lsp
Max Brunsfeld created
645df73
Finish implementing Buffer::edits_from_lsp
Max Brunsfeld created
3a1f9bb
Start work on applying LSP edits via a diff
Co-Authored-By: Antonio Scandurra <me@as-cii.com>
Max Brunsfeld and Antonio Scandurra created
424b352
Don't open a multibuffer when code actions's edits are contained in the current editor
Co-Authored-By: Antonio Scandurra <me@as-cii.com> Co-Authored-By: Nathan Sobo <nathan@zed.dev>
Max Brunsfeld , Antonio Scandurra , and Nathan Sobo created
5049c1b
Make Editor::newest_anchor_selection return a non-optional value
Co-Authored-By: Antonio Scandurra <me@as-cii.com> Co-Authored-By: Max Brunsfeld <maxbrunsfeld@gmail.com>
Nathan Sobo , Antonio Scandurra , and Max Brunsfeld created
93eb005
Correctly redo all undone edits after undoing in multi-buffer
When undoing edits performed in the multi-buffer, we also undo subsequent edits that may have occurred outside of the multi-buffer. This commit makes us redo those edits as well. Co-Authored-By: Antonio Scandurra <me@as-cii.com>
Nathan Sobo and Antonio Scandurra created
c5b0b5f
Store the oldest transaction id for each excerpted buffer in multi-buffer transactions
Co-Authored-By: Antonio Scandurra <me@as-cii.com>
Nathan Sobo and Antonio Scandurra created
9936bb2
Undo subsequent edits when undoing in multi-buffer
When undoing in the multi-buffer, don't preserve edits that occurred outside the multi-buffer after the edit being undone. Co-Authored-By: Antonio Scandurra <me@as-cii.com>
Nathan Sobo and Antonio Scandurra created
d1f1563
Push transaction into multi-buffer to allow undoing of a code action
Antonio Scandurra created
dd223f9
Allow editor to be saved when in multi-buffer mode
Also, this commit enables the customization of the title in a multi-buffer. When specified, it will take precedence over a filename (or "untitled").
Antonio Scandurra created
9ea5359
Fix `push_excerpts_with_context_lines` when ranges overlap
Antonio Scandurra created
9749fea
Start work on MultiBuffer::push_excerpts_with_context_lines
Use it in Editor::confirm_code_action
Max Brunsfeld created
471c23e
Allow inserting multiple excerpts in a batch
Co-Authored-By: Nathan Sobo <nathan@zed.dev>
Max Brunsfeld and Nathan Sobo created
aa7dfbd
Remove ExcerptProperties struct
Pass buffer and range as separate parameters Co-Authored-By: Nathan Sobo <nathan@zed.dev>
Max Brunsfeld and Nathan Sobo created
b67be5d
Add MultiBufferItemHandle
Co-Authored-By: Nathan Sobo <nathan@zed.dev>
Max Brunsfeld and Nathan Sobo created
ca697e1
Add BufferSnapshot::edited_ranges_for_transaction
Co-Authored-By: Nathan Sobo <nathan@zed.dev>
Max Brunsfeld and Nathan Sobo created
1ee15e1
Add and remove excerpts in randomized FoldMap and WrapMap tests
Max Brunsfeld created
5b4c0d6
Get tests passing and project diagnostics view working w/ new excerpt headers
Max Brunsfeld created
3d9c39d
Silence warnings
Max Brunsfeld created
fc70c6d
Fix BlockMap's handling of trailing empty excerpt updates with other edits
Co-Authored-By: Antonio Scandurra <me@as-cii.com> Co-Authored-By: Nathan Sobo <nathan@zed.dev>
Max Brunsfeld , Antonio Scandurra , and Nathan Sobo created
cbf59ff
Handle replacing trailing empty excerpt with another empty excerpt
Co-Authored-By: Nathan Sobo <nathan@zed.dev> Co-Authored-By: Max Brunsfeld <max@zed.dev>
Antonio Scandurra , Nathan Sobo , and Max Brunsfeld created
fab6f0c
Add/remove excerpts in BlockMap randomized tests and fix resulting errors
Co-Authored-By: Nathan Sobo <nathan@zed.dev> Co-Authored-By: Max Brunsfeld <max@zed.dev>
Antonio Scandurra , Nathan Sobo , and Max Brunsfeld created
8d95dbe
Render path headers in editor element
Co-Authored-By: Nathan Sobo <nathan@zed.dev>
Antonio Scandurra and Nathan Sobo created
f1e3d52
Fix randomized test failures on `BlockMap` with excerpt headers
Co-Authored-By: Nathan Sobo <nathan@zed.dev>
Antonio Scandurra and Nathan Sobo created
0e1318d
WIP: Make `editor` crate compile again
Tests are still failing though.
Antonio Scandurra created
c7e2fae
WIP - Add excerpt headers as a built-in feature of BlockMap
Co-Authored-By: Nathan Sobo <nathan@zed.dev>
Max Brunsfeld and Nathan Sobo created
8b1fb9a
Fix unused import warnings
Max Brunsfeld created
6731d92
Give the editor a handle to the project, not a weak handle to the workspace
Co-Authored-By: Nathan Sobo <nathan@zed.dev>
Max Brunsfeld and Nathan Sobo created
624dbc1
Fix confirming completions in a multibuffer
Co-Authored-By: Nathan Sobo <nathan@zed.dev>
Max Brunsfeld and Nathan Sobo created
93bcde9
Consolidate logic for completion alongside code actions in Project
This way, completions are dealt with more consistently with code actions, and the logic is not spread across so many places. The `language::File` trait and the multibuffer no longer need to deal with completions. Completions are no longer generic over an anchor type.
Max Brunsfeld created
722c84c
Consolidate all code actions logic into Project
Max Brunsfeld created
e0fe8b5
Merge branch 'main' into assists
Max Brunsfeld created
a32dffd
Apply lsp edits in reverse order
This fixes the handling of multiple edits on the same line.
Max Brunsfeld created
03440eb
Merge pull request #438 from zed-industries/speed-up-integration-tests
Always run multiple iterations of all integration tests
Max Brunsfeld created
8bad05a
Don't populate editor's context menu state if there are no completions
This would accidentally stop the enter key from working.
Max Brunsfeld created
36ff318
Set file in `test_diagnostics` to excercise language server
Antonio Scandurra created
7d8641a
Make transactions serializable to enable edits on behalf of other users
Co-Authored-By: Nathan Sobo <nathan@zed.dev>
Antonio Scandurra and Nathan Sobo created
6768288
Bump protocol version
Antonio Scandurra created
624eb59
Serialize buffer in terms of operations rather than state
This is required because, after joining, we want to be able to refer to operations that have happened prior to joining, which are not captured by the state. There is probably a way of reconstructing operations from the state, but that seems unnecessary and we've already talked about wanting to have the server store operations rather than state once we start persisting worktrees.
Antonio Scandurra created
dca974c
Apply code actions remotely
Antonio Scandurra created
aedf31e
Manually refresh code action when `data` is not present
Antonio Scandurra created
9ce3b1a
Send `DidCloseTextDocument` when dropping buffer
Closes https://github.com/zed-industries/zed/issues/434
Antonio Scandurra created
17114cc
Merge branch 'main' into assists
Antonio Scandurra created
050f951
Clear test db pool whenever no dbs are in use
Max Brunsfeld created
30e8709
Merge pull request #437 from zed-industries/fix-server-hangs
Use an unbounded channel for peer's outgoing messages
Max Brunsfeld created
c245356
Try another hacky approach for tearing down DBs after all tests
Co-Authored-By: Nathan Sobo <nathan@zed.dev>
Max Brunsfeld and Nathan Sobo created
b0ed58a
Run multiple iterations of all integration tests
Co-Authored-By: Nathan Sobo <nathan@zed.dev>
Max Brunsfeld and Nathan Sobo created
e3f055d
Use a pool of databases to speed up integration tests
Also, use env_logger consistently in the tests for each crate. Only initiallize the logger at all if some RUST_LOG env var is set. Co-Authored-By: Nathan Sobo <nathan@zed.dev>
Max Brunsfeld and Nathan Sobo created
8a2613d
Preserve ordering between responses and other incoming messages
Co-Authored-By: Nathan Sobo <nathan@zed.dev>
Max Brunsfeld and Nathan Sobo created
d4fe111
Use an unbounded channel for peer's outgoing messages
Using a bounded channel may have blocked the collaboration server from making progress handling RPC traffic. There's no need to apply backpressure to calling code within the same process - suspending a task that is attempting to call `send` has an even greater memory cost than just buffering a protobuf message. We do still want a bounded channel for incoming messages, so that we provide backpressure to noisy peers - blocking their writes as opposed to allowing them to buffer arbitrarily many messages in our server. Co-Authored-By: Antonio Scandurra <me@as-cii.com> Co-Authored-By: Nathan Sobo <nathan@zed.dev>
Max Brunsfeld , Antonio Scandurra , and Nathan Sobo created
8f3ff15
Apply edits received from LSP code actions and open all touched buffers
Antonio Scandurra created