New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix config change notification using remote neovim #2067
Conversation
NeovideNotify{0}Changed
src/bridge/setup.rs
Outdated
@@ -153,7 +153,7 @@ pub async fn setup_neovide_specific_state( | |||
.ok(); | |||
|
|||
// Create auto command for retrieving exit code from neovim on quit. | |||
nvim.command("autocmd VimLeave * call rpcnotify(1, 'neovide.quit', v:exiting)") | |||
nvim.command("autocmd VimLeave * call rpcnotify(g:neovide_channel_id, 'neovide.quit', v:exiting)") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I faced the same error when I quit neovide by :q
.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This will also be partially fixed by #2062, but that one does not deal with the changed listeners, even if it probably should.
So, let's merge this one first.
The formatting is slightly wrong, but you can run |
@fredizzimo Thanks! I did |
Thank you! |
What kind of change does this PR introduce?
Did this PR introduce a breaking change?
A breaking change includes anything that breaks backwards compatibility either at compile or run time.
Background
I got the error below connecting remote neovim on my machine.
g:neovide_channel_id
has 3 in my environment.But the embedded Vim script always uses 1.
What I did
This PR just makes it use
g:neovide_channel_id
.I don't know how to write the tests.
Please tell me where I should put the tests or merge the PR and add tests in another PR 🙏
How to reproduce
macOS Monterey 12.6.7
Change a neovide config via command line mode on neovide started above.
Then, neovide causes the error.