aboutsummaryrefslogtreecommitdiff
path: root/after/ftplugin/lua.lua.bak
blob: fe9587be408b9664214136c1e3a2b737cf364c15 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
local lspconfig = require("lspconfig")

if lspconfig.lua_ls then
  lspconfig.lua_ls.setup({
    settings = {
      Lua = {
        diagnostics = {
          -- This is the Lua table for diagnostics settings
          globals = { "vim", "use", "_G", "packer_plugins", "P" },
          disable = {
            "undefined-global",
            "lowercase-global",
            "unused-local",
            "unused-vararg",
            "trailing-space"
          },
        },
        workspace = {
          -- Points the language server to Neovim's runtime files for auto-completion
          library = {
            --vim.api.nvim_get_runtime_path(),
            --checkThirdParty = false,
            vim.env.VIMRUNTIME,
            -- Depending on the usage, you might want to add additional paths here.
            "${3rd}/luv/library",
            "${3rd}/busted/library",
          },
        },
        telemetry = {
          enable = false,
        },
      },
    },
  })
end