Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
23 changes: 0 additions & 23 deletions lua/core/lspconfig.lua
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@ local found_mason_lspconfig, mason_lspconfig = pcall(require, "mason-lspconfig")
local found_nvim_lsp, nvim_lsp = pcall(require, "lspconfig")
local found_mason_dap, mason_dap = pcall(require, "mason-nvim-dap")
local found_lsp_file, lsp_file = pcall(require, "lsp-file-operations")
local found_dartls = pcall(nvim_lsp.dartls)

if found_mason and found_mason_lspconfig and found_nvim_lsp then
-- The nvim-cmp almost supports LSP's capabilities so You should advertise it to LSP servers..
Expand Down Expand Up @@ -106,28 +105,6 @@ if found_mason and found_mason_lspconfig and found_nvim_lsp then
root_dir = nvim_lsp.util.find_git_ancestor,
single_file_support = true,
})

-- dart lsp config
if found_dartls then
nvim_lsp.dartls.setup({
cmd = { "dart", "language-server", "--protocol=lsp" },
filetypes = { "dart" },
init_options = {
closingLabels = true,
flutterOutline = true,
onlyAnalyzeProjectsWithOpenFiles = true,
outline = true,
suggestFromUnimportedLibraries = true,
},
root_dir = nvim_lsp.util.root_pattern("pubspec.yaml"),
settings = {
dart = {
completeFunctionCalls = true,
showTodos = true,
},
},
})
end
end

-- vim.lsp.set_log_level("debug")
9 changes: 8 additions & 1 deletion lua/plugins.lua
Original file line number Diff line number Diff line change
Expand Up @@ -120,7 +120,14 @@ else
require("packages.rust-tools")
end,
})

-- dart and flutter code tools
use({
"akinsho/flutter-tools.nvim",
requires = "nvim-lua/plenary.nvim",
config = function()
require("flutter-tools").setup({})
end,
})
-- Debugging System
use("nvim-lua/plenary.nvim")

Expand Down