fix error message intelephense license txt
parent
6a326d7321
commit
fbcc0b8d61
|
|
@ -156,7 +156,16 @@ setup_server("intelephense", {
|
|||
filetypes = { "php" },
|
||||
-- root_dir = fallback_root_dir,
|
||||
init_options = {
|
||||
licenceKey = vim.fn.readfile(vim.fn.expand("$HOME/.config/intelephense/license.txt"))[1],
|
||||
licenceKey = (function()
|
||||
local license_path = vim.fn.expand("$HOME/.config/intelephense/license.txt")
|
||||
local file = io.open(license_path, "r")
|
||||
if file then
|
||||
local content = file:read("*l") -- read first line
|
||||
file:close()
|
||||
return content
|
||||
end
|
||||
return nil
|
||||
end)(),
|
||||
},
|
||||
settings = {
|
||||
intelephense = {
|
||||
|
|
|
|||
Loading…
Reference in New Issue