Commit 0e43c46
fix: prevent mason setup from being run twice (nvim-lua#1298)
* 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 feedback1 parent 9b62a0d commit 0e43c46
1 file changed
+11
-6
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
466 | 466 | | |
467 | 467 | | |
468 | 468 | | |
469 | | - | |
| 469 | + | |
| 470 | + | |
| 471 | + | |
470 | 472 | | |
471 | 473 | | |
472 | 474 | | |
| |||
655 | 657 | | |
656 | 658 | | |
657 | 659 | | |
658 | | - | |
659 | | - | |
| 660 | + | |
| 661 | + | |
| 662 | + | |
660 | 663 | | |
661 | 664 | | |
662 | | - | |
663 | | - | |
664 | | - | |
| 665 | + | |
| 666 | + | |
| 667 | + | |
| 668 | + | |
| 669 | + | |
665 | 670 | | |
666 | 671 | | |
667 | 672 | | |
| |||
0 commit comments