Skip to content

nvim: improve LSP config #54

@bbkane

Description

@bbkane

Turn root .luarc.json into luarc.lua and pair with a local .vscode/settings.json to load it with https://luals.github.io/wiki/configuration/

Then I can comments and manually expand the vim calls at:

    -- ~/.config/nvim/lua/plugins.lua (example with a plugin manager like Packer)
    use {
        "neovim/nvim-lspconfig",
        config = function()
            require("lspconfig").luals.setup {
                settings = {
                    Lua = {
                        runtime = {
                            version = "LuaJIT",
                        },
                        diagnostics = {
                            globals = { "vim" },
                        },
                        workspace = {
                            library = {
                                vim.env.VIMRUNTIME,
                                vim.fn.stdpath("config"),
                            },
                        },
                    },
                },
            }
        end,
    }

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions