Commit log

7704291 Maintain a set of peers as they join and leave the worktree

Antonio Scandurra created

ab089b6 Avoid logging errors in RPC message handlers

Click to expand commit body
The `on_message` helper already logs when an error occurs.

Antonio Scandurra created

8e5e354 :lipstick:

Antonio Scandurra created

3c8aa0e Move `remote::update_buffer` main logic into `Worktree::update_buffer`

Antonio Scandurra created

0fde7a5 Store shared buffers on LocalWorktree

Click to expand commit body
It's okay for our domain objects to model remote state. We should minimize what we need to store in the rpc::ClientState struct.

Nathan Sobo created

bbf803d Store a reference to the LangageRegistry on the Worktree

Nathan Sobo created

34963ac Use entry_id on File instead of worktree::Diff to detect when buffers' files change

Click to expand commit body
Rather than computing a diff after processing a batch of FSEvents, we instead detect renames as we're inserting entries. We store an entry_id on the File object that is owned by each buffer, and use this to detect when the path of the File has changed.

We now also manage all File-related state and event emission for Buffers in the LocalWorktree, since the logic will need to be totally different in the remote case.

Co-Authored-By: Max Brunsfeld <maxbrunsfeld@gmail.com>
Co-Authored-By: Antonio Scandurra <me@as-cii.com>

Nathan Sobo , Max Brunsfeld , and Antonio Scandurra created

e80439d Merge branch 'main' into rpc

Antonio Scandurra created

b7a4393 Redesign Worktree save API and make test_rescan_simple pass

Click to expand commit body
This commit does too much. The first goal was to change our approach to saving new buffers so that we don't need to construct a File for an entry that doesn't exist. Rather than doing that, we call `Worktree::save_buffer_as` with the buffer handle, the path, and the contents. This then saves the buffer and returns a handle to a `File` that references an entry that actually exists. I needed to do this so that we can store an entry id on `File`.

In the process, I noticed intermittent test failures on `test_rescan_simple`, so I made some changes required to fix those related to our reuse of existing ids. Our previous approach of removing a path when inserting a new entry was broken, because of the recursive nature of `remove_path`. Instead, I simply recycle the id of an existing worktree entry with the same path if one is present, then allow it to be replaced.

Nathan Sobo created

1793eda Eagerly populate worktree entries on load

Click to expand commit body
Co-Authored-By: Antonio Scandurra <me@as-cii.com>

Nathan Sobo and Antonio Scandurra created

958345b Assign a stable identity to Worktree entries

Click to expand commit body
Co-Authored-By: Nathan Sobo <nathan@zed.dev>

Antonio Scandurra and Nathan Sobo created

65aa973 Restructure RPC state to also keep track of remote worktrees on guests

Antonio Scandurra created

e72b4ae Maintain active selections as editors are focused and blurred

Antonio Scandurra created

0bc8663 Remove selection set when an editor is closed

Antonio Scandurra created

e2b9ab5 Avoid double handle-read in File::buffer_updated

Max Brunsfeld created

60ee97b Always represent anchor as a versioned offset

Click to expand commit body
Remove the `Start` and `End` variants, and always
use the structure that was previously called `Middle`.
This makes Anchors simpler to serialize and deserialize.

Max Brunsfeld created

b9952ba Send and receive buffer operations

Click to expand commit body
Co-Authored-By: Nathan Sobo <nathan@zed.dev>

Max Brunsfeld and Nathan Sobo created

04c8057 Start work on sending buffer operations

Max Brunsfeld created

7ee0862 Notify host when guests close buffers

Click to expand commit body
Co-Authored-By: Max Brunsfeld <maxbrunsfeld@gmail.com>

Nathan Sobo and Max Brunsfeld created

2257abd Add Entity release hooks

Click to expand commit body
Co-Authored-By: Max Brunsfeld <maxbrunsfeld@gmail.com>

Nathan Sobo and Max Brunsfeld created

d59267a Move `remote` module from `workspace` to `worktree`

Antonio Scandurra created

3ba2223 Merge pull request #97 from zed-industries/limit-bundle-uploads

Click to expand commit body
Only upload artifacts to workflow runs on the main branch

Nathan Sobo created

0faabc2 Only upload artifacts to workflow runs on the main branch

Click to expand commit body
We're running out of actions storage, and we don't really need an artifact stored for every single build.

Nathan Sobo created

c4729de Merge pull request #96 from zed-industries/retry-flaky-tests

Click to expand commit body
Add a "retries" option to gpui::test macro and use it in flaky tests

Nathan Sobo created

8f7111b Upgrade bindgen to fix warnings on new Rust

Nathan Sobo created

3d67266 Add a "retries" option to gpui::test macro and use it in flaky tests

Nathan Sobo created

779dbf8 Allow cleaning up connections/handlers state using `Peer::reset`

Antonio Scandurra created

ce2f3f6 Consolidate more logic for joining worktree in Worktree::remote

Click to expand commit body
This way we can use this method in tests and avoid
needing to construct a Workspace.

Max Brunsfeld created

6a16655 Add public method for connecting to RPC server with a given address

Click to expand commit body
Co-Authored-By: Nathan Sobo <nathan@zed.dev>

Max Brunsfeld and Nathan Sobo created

54c4b31 Fix last usage of App::test_async in one test

Click to expand commit body
Co-Authored-By: Nathan Sobo <nathan@zed.dev>

Max Brunsfeld and Nathan Sobo created

efc8bc3 Add a test-support feature flag that enables compilation of zed::test module

Click to expand commit body
Co-Authored-By: Nathan Sobo <nathan@zed.dev>

Max Brunsfeld and Nathan Sobo created

a57cb2b Add a public gpui::TestAppContext::new method

Click to expand commit body
Co-Authored-By: Nathan Sobo <nathan@zed.dev>

Max Brunsfeld and Nathan Sobo created

f1587fb Make `replica_id` optional in `OpenWorktreeResponse`

Antonio Scandurra created

02321af Respond to `proto::OpenBuffer` requests

Antonio Scandurra created

c5e08b6 Eagerly update worktree entries when saving

Click to expand commit body
Don't use ModelHandles for storing Files.

Co-Authored-By: Max Brunsfeld <maxbrunsfeld@gmail.com>

Nathan Sobo and Max Brunsfeld created

dc8e216 WIP - Maintain a set of open buffers on a LocalWorktree

Max Brunsfeld created

a364839 Replace FileHandle with File entity that subscribes to Worktree update events

Click to expand commit body
Co-Authored-By: Max Brunsfeld <maxbrunsfeld@gmail.com>

Nathan Sobo and Max Brunsfeld created

cabf6b1 Emit a diff event when worktree's snapshot is updated

Click to expand commit body
Co-Authored-By: Nathan Sobo <nathan@zed.dev>

Max Brunsfeld and Nathan Sobo created

8ae5c0d Implement worktree::Snapshot::diff

Click to expand commit body
Co-Authored-By: Max Brunsfeld <maxbrunsfeld@gmail.com>

Nathan Sobo and Max Brunsfeld created

1364ba6 Allow async background work when polling worktree background snapshot

Click to expand commit body
This prepares us to perform a diff against the previous snapshot before installing a new worktree snapshot on the foreground thread.

Co-Authored-By: Max Brunsfeld <maxbrunsfeld@gmail.com>

Nathan Sobo and Max Brunsfeld created

986afd2 Remove other_mount_paths

Click to expand commit body
We only needed this when we relied on inodes for file identity, which we no longer attempt to do.

Co-Authored-By: Max Brunsfeld <maxbrunsfeld@gmail.com>

Nathan Sobo and Max Brunsfeld created

5c0f4e5 :lipstick:

Antonio Scandurra created

7489e86 Fix deadlock when comparing `FileHandle`s when handles are the same

Antonio Scandurra created

95024c6 Put back `worktree_id` in `CloseFile` and `OpenBuffer` messages

Antonio Scandurra created

2905ce3 WIP: Load remote history

Antonio Scandurra created

f4d6fbe Issue only one `OpenFile` and `CloseFile` request per handle

Antonio Scandurra created

96c118b Stub in more logic for open_file and close_file

Max Brunsfeld created

0deaa3a WIP

Click to expand commit body
Co-Authored-By: Max Brunsfeld <maxbrunsfeld@gmail.com>

Nathan Sobo and Max Brunsfeld created

bfccb17 Update prost to include our changes

Click to expand commit body
Co-Authored-By: Max Brunsfeld <maxbrunsfeld@gmail.com>

Nathan Sobo and Max Brunsfeld created

a2a6d67 Start work on implementing ::file on remote WorktreeHandles

Max Brunsfeld created