Put global variable top, select which lsp install according to OS

This commit is contained in:
Eduardo Cueto-Mendoza 2023-08-07 10:28:31 +01:00
parent 25194213c5
commit 73b76d632b
3 changed files with 10 additions and 7 deletions

View File

@ -5,6 +5,7 @@ lsp.on_attach(function(client, bufnr)
end)
-- Language servers
if (MY_OS == 'Linux') then
lsp.ensure_installed({
-- Replace these with whatever servers you want to install
'bashls',
@ -16,6 +17,9 @@ lsp.ensure_installed({
'texlab',
'zls'
})
elseif (MY_OS == 'FreeBSD') then
print('On FreeBSD')
end
--[[
START LANGUAGE SERVERS CONFIG HERE!!!

View File

@ -1 +1,7 @@
require("eddie")
local f = io.popen("uname -s")
if (f ~= nil) then
MY_OS = f:read("*a")
f:close()
end

View File

@ -1,10 +1,3 @@
require("eddie.keymaps")
require("eddie.options")
local f = io.popen("uname -s")
if (f ~= nil) then
MY_OS = f:read("*a")
f:close()
end
print(MY_OS)