Skip to content

Instantly share code, notes, and snippets.

Avatar
🏄‍♂️
Surfing

Folke Lemaitre folke

🏄‍♂️
Surfing
View GitHub Profile
@folke
folke / lua-lsp.lua
Last active Aug 28, 2021
Correct sumneko lua lsp setup for init.lua and plugin development
View lua-lsp.lua
-- put this file somewhere in your nvim config, like: ~/.config/nvim/lua/config/lua-lsp.lua
-- usage: require'lspconfig'.sumneko_lua.setup(require("config.lua-lsp"))
local library = {}
local path = vim.split(package.path, ";")
-- this is the ONLY correct way to setup your path
table.insert(path, "lua/?.lua")
table.insert(path, "lua/?/init.lua")