Skip to content

Commit

Permalink
fix(neoconf): do neoconf setup in lspconfig setup. Fixes #1070
Browse files Browse the repository at this point in the history
  • Loading branch information
folke committed Jul 12, 2023
1 parent 5204aac commit 9e8ce28
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion lua/lazyvim/plugins/lsp/init.lua
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ return {
"neovim/nvim-lspconfig",
event = { "BufReadPre", "BufNewFile" },
dependencies = {
{ "folke/neoconf.nvim", cmd = "Neoconf", config = true },
{ "folke/neoconf.nvim", cmd = "Neoconf", config = false, dependencies = { "nvim-lspconfig" } },
{ "folke/neodev.nvim", opts = {} },
"mason.nvim",
"williamboman/mason-lspconfig.nvim",
Expand Down Expand Up @@ -89,6 +89,11 @@ return {
---@param opts PluginLspOpts
config = function(_, opts)
local Util = require("lazyvim.util")

if Util.has("neoconf.nvim") then
local plugin = require("lazy.core.config").spec.plugins["neoconf.nvim"]
require("neoconf").setup(require("lazy.core.plugin").values(plugin, "opts", false))
end
-- setup autoformat
require("lazyvim.plugins.lsp.format").setup(opts)
-- setup formatting and keymaps
Expand Down

0 comments on commit 9e8ce28

Please sign in to comment.