Skip to content
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(nvim.js): $NVIM_LISTEN_ADDRESS is deprecated #195

Merged
merged 1 commit into from May 3, 2022
Merged

fix(nvim.js): $NVIM_LISTEN_ADDRESS is deprecated #195

merged 1 commit into from May 3, 2022

Conversation

Copy link
Member

@justinmk justinmk commented May 2, 2022

Use $NVIM with Nvim 0.8+.

neovim/neovim#11009 (Nvim 0.8+) will change Nvim so that $NVIM_LISTEN_ADDRESS is not passed to child processes. After that, the correct way to detect a "host" or "parent" Nvim is to check for $NVIM env var: this means the current process is a child of Nvim.

The old $NVIM_LISTEN_ADDRESS env var had conflicting purposes as both a parameter ("the current process should listen on this address") and a descriptor ("the current process is a child of this address").

@lgtm-com
Copy link

@lgtm-com lgtm-com bot commented May 2, 2022

This pull request introduces 1 alert when merging cfdeb40 into 6ce0475 - view on LGTM.com

new alerts:

  • 1 for Syntax error

@justinmk
Copy link
Author

@justinmk justinmk commented May 2, 2022

I'll wait to merge this until it can run against Nvim nightly with the upstream change.

Use $NVIM with Nvim 0.8+.

Since neovim/neovim#11009 (Nvim 0.8+) Nvim does
_not_ pass $NVIM_LISTEN_ADDRESS to child processes.  The correct way to
detect a "host" or "parent" Nvim is to check for $NVIM env var: this
means the current process is a child of Nvim.

The old $NVIM_LISTEN_ADDRESS env var had conflicting purposes as both
a parameter ("the current process should _listen on_ this address") and
a descriptor ("the current process is a _child of_ this address").
rhysd
rhysd approved these changes May 3, 2022
@justinmk justinmk merged commit 5ebd911 into master May 3, 2022
12 checks passed
@justinmk justinmk deleted the envvar branch May 3, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants