added a buncha new LSPs.
This commit is contained in:
parent
f75102b78e
commit
cbf028159f
8 changed files with 120 additions and 12 deletions
|
|
@ -3,5 +3,8 @@ return {
|
|||
"clangd",
|
||||
for_cat = "C",
|
||||
lsp = {},
|
||||
after=function()
|
||||
require("clangd_extensions").setup({})
|
||||
end,
|
||||
},
|
||||
}
|
||||
|
|
|
|||
12
lua/lsp/config.lua
Normal file
12
lua/lsp/config.lua
Normal file
|
|
@ -0,0 +1,12 @@
|
|||
return {
|
||||
{
|
||||
"taplo",
|
||||
for_cat = "config",
|
||||
lsp = {},
|
||||
},
|
||||
{
|
||||
"yamlls",
|
||||
for_cat = "config",
|
||||
lsp = {},
|
||||
},
|
||||
}
|
||||
|
|
@ -86,26 +86,36 @@ require('lze').load {
|
|||
for_cat = "lsp",
|
||||
on_require = { "conform" },
|
||||
cmd = { "ConformInfo" },
|
||||
keys = { { "<leader>lf", function() require("conform").format({async=true}) end, mode = { "" }, desc = "Format buffer" }, },
|
||||
keys = {
|
||||
{ "<leader>lf", function() require("conform").format({ async = true }) end, mode = { "" }, desc = "Format buffer" },
|
||||
},
|
||||
after = function()
|
||||
require("conform").setup({
|
||||
default_format_opts = {
|
||||
lsp_format = "fallback",
|
||||
},
|
||||
|
||||
formatters_by_ft = {
|
||||
nix = { "alejandra" }
|
||||
}
|
||||
})
|
||||
-- need to figure out how to properly seperate this.
|
||||
if nixInfo("settings", "cat", "config") then
|
||||
require("conform").formatters_by_ft.json = { "jq" }
|
||||
end
|
||||
if nixInfo("settings", "cat", "nix") then
|
||||
require("conform").formatters_by_ft.nix = { "alejandra" }
|
||||
end
|
||||
end,
|
||||
},
|
||||
|
||||
{ import = "lsp.lua" },
|
||||
{ import = "lsp.python" },
|
||||
{ import = "lsp.C" },
|
||||
{ import = "lsp.typst" },
|
||||
{ import = "lsp.bash" },
|
||||
{ import = "lsp.zk" },
|
||||
{ import = "lsp.rust" },
|
||||
{ import = "lsp.config" },
|
||||
{ import = "lsp.go" },
|
||||
{ import = "lsp.jsonnet" },
|
||||
{ import = "lsp.lua" },
|
||||
{ import = "lsp.nix" },
|
||||
{ import = "lsp.nushell" },
|
||||
{ import = "lsp.python" },
|
||||
{ import = "lsp.rust" },
|
||||
{ import = "lsp.typst" },
|
||||
{ import = "lsp.zig" },
|
||||
{ import = "lsp.zk" },
|
||||
}
|
||||
|
|
|
|||
7
lua/lsp/jsonnet.lua
Normal file
7
lua/lsp/jsonnet.lua
Normal file
|
|
@ -0,0 +1,7 @@
|
|||
return {
|
||||
{
|
||||
"jsonnet_ls",
|
||||
for_cat = "jsonnet",
|
||||
lsp = {},
|
||||
},
|
||||
}
|
||||
9
lua/lsp/nix.lua
Normal file
9
lua/lsp/nix.lua
Normal file
|
|
@ -0,0 +1,9 @@
|
|||
return {
|
||||
{
|
||||
"nixd",
|
||||
for_cat = "nix",
|
||||
lsp = {},
|
||||
after = function()
|
||||
end,
|
||||
},
|
||||
}
|
||||
7
lua/lsp/nushell.lua
Normal file
7
lua/lsp/nushell.lua
Normal file
|
|
@ -0,0 +1,7 @@
|
|||
return {
|
||||
{
|
||||
"nushell",
|
||||
for_cat = "nushell",
|
||||
lsp = {},
|
||||
},
|
||||
}
|
||||
7
lua/lsp/zig.lua
Normal file
7
lua/lsp/zig.lua
Normal file
|
|
@ -0,0 +1,7 @@
|
|||
return {
|
||||
{
|
||||
"zls",
|
||||
for_cat = "zig",
|
||||
lsp = {},
|
||||
},
|
||||
}
|
||||
55
module.nix
55
module.nix
|
|
@ -152,7 +152,9 @@ inputs: {
|
|||
};
|
||||
|
||||
config.specs.zk = {
|
||||
name = "zk";
|
||||
after = ["general" "lazy"];
|
||||
lazy = true;
|
||||
data = with pkgs.vimPlugins; [
|
||||
zk-nvim
|
||||
];
|
||||
|
|
@ -164,6 +166,7 @@ inputs: {
|
|||
config.specs.typst = {
|
||||
name = "typst";
|
||||
after = ["general" "lazy"];
|
||||
lazy = true;
|
||||
data = with pkgs.vimPlugins; [
|
||||
typst-preview-nvim
|
||||
];
|
||||
|
|
@ -176,24 +179,69 @@ inputs: {
|
|||
config.specs.go = {
|
||||
name = "go";
|
||||
after = ["general" "lazy"];
|
||||
lazy = true;
|
||||
data = null;
|
||||
extraPackages = with pkgs; [
|
||||
gopls
|
||||
];
|
||||
};
|
||||
|
||||
config.specs.config = {
|
||||
name = "config";
|
||||
after = ["general" "lazy"];
|
||||
lazy = true;
|
||||
data = null;
|
||||
extraPackages = with pkgs; [
|
||||
taplo
|
||||
jq
|
||||
yaml-language-server
|
||||
];
|
||||
};
|
||||
|
||||
config.specs.jsonnet = {
|
||||
name = "jsonnet";
|
||||
after = ["general" "lazy"];
|
||||
lazy = true;
|
||||
data = null;
|
||||
extraPackages = with pkgs; [
|
||||
jsonnet-language-server
|
||||
];
|
||||
};
|
||||
|
||||
config.specs.zig = {
|
||||
name = "zig";
|
||||
after = ["general" "lazy"];
|
||||
lazy = true;
|
||||
data = null;
|
||||
extraPackages = with pkgs; [
|
||||
zls
|
||||
];
|
||||
};
|
||||
config.specs.nushell = {
|
||||
name = "nushell";
|
||||
after = ["general" "lazy"];
|
||||
lazy = true;
|
||||
data = null;
|
||||
extraPackages = with pkgs; [
|
||||
nushell
|
||||
];
|
||||
};
|
||||
|
||||
config.specs.nix = {
|
||||
name = "nix";
|
||||
after = ["general" "lazy"];
|
||||
lazy = true;
|
||||
data = null;
|
||||
extraPackages = with pkgs; [
|
||||
alejandra
|
||||
nixd
|
||||
];
|
||||
};
|
||||
|
||||
config.specs.lua = {
|
||||
name = "lua";
|
||||
after = ["general" "lazy"];
|
||||
lazy = true;
|
||||
data = with pkgs.vimPlugins; [
|
||||
lazydev-nvim
|
||||
];
|
||||
|
|
@ -206,6 +254,7 @@ inputs: {
|
|||
config.specs.rust = {
|
||||
name = "rust";
|
||||
after = ["general" "lazy"];
|
||||
lazy = true;
|
||||
data = with pkgs.vimPlugins; [
|
||||
rustaceanvim
|
||||
];
|
||||
|
|
@ -218,6 +267,7 @@ inputs: {
|
|||
config.specs.python = {
|
||||
name = "python";
|
||||
after = ["general" "lazy"];
|
||||
lazy = true;
|
||||
data = null;
|
||||
extraPackages = with pkgs; [
|
||||
ty
|
||||
|
|
@ -228,7 +278,10 @@ inputs: {
|
|||
config.specs.C = {
|
||||
name = "C";
|
||||
after = ["general" "lazy"];
|
||||
data = null;
|
||||
lazy = true;
|
||||
data = with pkgs.vimPlugins; [
|
||||
clangd_extensions-nvim
|
||||
];
|
||||
extraPackages = with pkgs; [
|
||||
libclang
|
||||
];
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue