-
Notifications
You must be signed in to change notification settings - Fork 26.9k
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: prevent mason setup from being run twice #1298
Merged
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Addresses nvim-lua#1297 Currently, we're calling `require('mason').setup(...)` twice: * once when setting it as a dependency of `nvim-lspconfig` (since we set `config = true`) * once in the `config` function we define for `nvim-lspconfig` Calling setup twice can cause issues with, e.g., setting the `PATH` option: you might append Mason's bin dir in one setup call and prepend it in the other. We've kept the setup of `mason` in the `nvim-lspconfig` dependencies table since leaving it to the `config` function caused some plugin-loading-order related issues in the past. See: * nvim-lua#210 * nvim-lua#554 * nvim-lua#555 * nvim-lua#865
iton0
reviewed
Jan 3, 2025
iton0
reviewed
Jan 3, 2025
iton0
approved these changes
Jan 3, 2025
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.
LGTM
Thank you for this @tomasgareau you rock! And thank you @iton0 for the review! It looked reasonable to me but I don't really have time to dive down the rabbit hole and understand its goodness :) |
dribic
pushed a commit
to dribic/nvim-files
that referenced
this pull request
Jan 8, 2025
* fix: prevent mason setup from being run twice Addresses nvim-lua#1297 Currently, we're calling `require('mason').setup(...)` twice: * once when setting it as a dependency of `nvim-lspconfig` (since we set `config = true`) * once in the `config` function we define for `nvim-lspconfig` Calling setup twice can cause issues with, e.g., setting the `PATH` option: you might append Mason's bin dir in one setup call and prepend it in the other. We've kept the setup of `mason` in the `nvim-lspconfig` dependencies table since leaving it to the `config` function caused some plugin-loading-order related issues in the past. See: * nvim-lua#210 * nvim-lua#554 * nvim-lua#555 * nvim-lua#865 * docs: tweak comments per review feedback Signed-off-by: Dejan Ribič <[email protected]>
Mutex-
pushed a commit
to Mutex-/kickstart.nvim
that referenced
this pull request
Jan 8, 2025
* fix: prevent mason setup from being run twice Addresses nvim-lua#1297 Currently, we're calling `require('mason').setup(...)` twice: * once when setting it as a dependency of `nvim-lspconfig` (since we set `config = true`) * once in the `config` function we define for `nvim-lspconfig` Calling setup twice can cause issues with, e.g., setting the `PATH` option: you might append Mason's bin dir in one setup call and prepend it in the other. We've kept the setup of `mason` in the `nvim-lspconfig` dependencies table since leaving it to the `config` function caused some plugin-loading-order related issues in the past. See: * nvim-lua#210 * nvim-lua#554 * nvim-lua#555 * nvim-lua#865 * docs: tweak comments per review feedback
umtdg
added a commit
to umtdg/kickstart.nvim
that referenced
this pull request
Jan 9, 2025
fix: prevent mason setup from being run twice (nvim-lua#1298)
codemedic
added a commit
to codemedic/kickstart.nvim
that referenced
this pull request
Jan 10, 2025
* master: fix: prevent mason setup from being run twice (nvim-lua#1298) Fix which-key delay settings (nvim-lua#1276) chore: add pre-issue requirements (nvim-lua#1288) Fix README.md grammar and typos (nvim-lua#1291)
andreyrcdias
added a commit
to andreyrcdias/kickstart.nvim
that referenced
this pull request
Jan 10, 2025
* master: fix: prevent mason setup from being run twice (nvim-lua#1298)
louis-smit
pushed a commit
to louis-smit/kickstart.nvim
that referenced
this pull request
Jan 12, 2025
* fix: prevent mason setup from being run twice Addresses nvim-lua#1297 Currently, we're calling `require('mason').setup(...)` twice: * once when setting it as a dependency of `nvim-lspconfig` (since we set `config = true`) * once in the `config` function we define for `nvim-lspconfig` Calling setup twice can cause issues with, e.g., setting the `PATH` option: you might append Mason's bin dir in one setup call and prepend it in the other. We've kept the setup of `mason` in the `nvim-lspconfig` dependencies table since leaving it to the `config` function caused some plugin-loading-order related issues in the past. See: * nvim-lua#210 * nvim-lua#554 * nvim-lua#555 * nvim-lua#865 * docs: tweak comments per review feedback
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Addresses #1297
Currently, we're calling
require('mason').setup(...)
twice:nvim-lspconfig
(since we setconfig = true
)config
function we define fornvim-lspconfig
Calling setup twice can cause issues with, e.g., setting the
PATH
option: you might append Mason's bin dir in one setup call and prepend it in the other.We've kept the setup of
mason
in thenvim-lspconfig
dependencies table since leaving it to theconfig
function caused some plugin-loading-order related issues in the past. See: