Fix deletion not closing open deleted buffers #109
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
fix: open buffers deleted in yazi were not closed
When a buffer was opened in neovim and being edited, and then yazi
deleted it, the buffer was not closed. I'm not sure what broke it.
The fix is to close the buffer asynchronously. I don't understand why
that fixes the issue, but it does.
vim.await
is really cool. I found it here:https://www.reddit.com/r/neovim/comments/1cv5q45/comment/l4s2ya0/?utm_source=share&utm_medium=web3x&utm_name=web3xcss&utm_term=1&utm_content=share_button
perf: processing open buffers only processes normal buffers
Buffers are processed when renaming, deleting, and trashing files in
yazi. Previously all open buffers were processed, but now only normal
buffers are.
This actually doesn't have a big impact on performance. I just wanted to
have a
perf
commit in the history 😄. Perhaps in big projects it mightbe noticeable, or if some future feature will require more performance.