tangled
alpha
login
or
join now
shailpatels.me
/
nvim
0
fork
atom
nvim dot files
0
fork
atom
overview
issues
pulls
pipelines
forgot to commit changes
shailpatels.me
10 months ago
5e2f46bf
ef09e6b2
+11
-1
1 changed file
expand all
collapse all
unified
split
lua
plugins
lsp.lua
+11
-1
lua/plugins/lsp.lua
···
61
on_attach = on_attach,
62
settings = {
63
zls = {
64
-
zig_exe_path = "/home/shail/GitHub/zig/build/stage3/bin/zig",
0
0
0
0
0
0
0
0
0
0
65
}
66
}
67
})
···
61
on_attach = on_attach,
62
settings = {
63
zls = {
64
+
zig_exe_path = (function()
65
+
local handle = io.popen('which zig 2> /dev/null')
66
+
if handle then
67
+
local result = handle:read("*a")
68
+
handle:close()
69
+
-- Remove trailing newline
70
+
return result:gsub("[\n\r]", "")
71
+
end
72
+
-- Fallback to a default path or return nil if which command fails
73
+
return nil
74
+
end)(),
75
}
76
}
77
})