added lsp support

This commit is contained in:
chloe 2025-07-10 10:28:32 +02:00
parent 3f97043f85
commit 0365f6f7cb
2 changed files with 81 additions and 30 deletions

View file

@ -4,13 +4,11 @@
pkgs, pkgs,
... ...
}: }:
{ {
plugins = { plugins = {
lsp = { lsp = {
enable = true; enable = true;
servers = { servers = {
basedpyright.enable = true; basedpyright.enable = true;
asm_lsp.enable = true; asm_lsp.enable = true;
gopls.enable = true; gopls.enable = true;
@ -66,9 +64,56 @@
enable = true; enable = true;
}; };
cmp = { blink-ripgrep.enable = true;
blink-cmp = {
enable = true; enable = true;
autoEnableSources = true; setupLspCapabilities = true;
settings = {
keymap = {
"<CR>" = [
"accept"
"fallback"
];
"<Tab>" = [
"select_next"
"snippet_forward"
"fallback"
];
"<S-Tab>" = [
"select_prev"
"snippet_backward"
"fallback"
];
};
signature = {
enabled = true;
window = {
border = "rounded";
};
};
sources = {
default = [
"buffer"
"lsp"
"path"
"snippets"
"ripgrep"
];
providers = {
lsp.score_offset = 4;
ripgrep = {
name = "ripgrep";
module = "blink-ripgrep";
score_offset = 1;
};
};
};
};
}; };
barbar.enable = true; barbar.enable = true;
@ -96,10 +141,6 @@
enable = true; enable = true;
}; };
nvim-autopairs = {
enable = true;
};
cord = { cord = {
enable = true; enable = true;
}; };
@ -107,7 +148,10 @@
chadtree = { chadtree = {
enable = true; enable = true;
view.openDirection = "right"; view.openDirection = "right";
keymap.openFileFolder.collapse = [ "l" ]; keymap.openFileFolder.primary = [
"l"
"<enter>"
];
}; };
fzf-lua = { fzf-lua = {
@ -143,6 +187,8 @@
lazygit.enable = true; lazygit.enable = true;
mini.enable = true; mini.enable = true;
mini-pairs.enable = true;
mini-starter.enable = true;
dap = { dap = {
enable = true; enable = true;
@ -178,5 +224,10 @@
zen-mode = { zen-mode = {
enable = true; enable = true;
}; };
indent-blankline.enable = true;
neorg = {
enable = true;
};
}; };
} }

42
flake.lock generated
View file

@ -5,11 +5,11 @@
"nixpkgs-lib": "nixpkgs-lib" "nixpkgs-lib": "nixpkgs-lib"
}, },
"locked": { "locked": {
"lastModified": 1748821116, "lastModified": 1751413152,
"narHash": "sha256-F82+gS044J1APL0n4hH50GYdPRv/5JWm34oCJYmVKdE=", "narHash": "sha256-Tyw1RjYEsp5scoigs1384gIg6e0GoBVjms4aXFfRssQ=",
"owner": "hercules-ci", "owner": "hercules-ci",
"repo": "flake-parts", "repo": "flake-parts",
"rev": "49f0870db23e8c1ca0b5259734a02cd9e1e371a1", "rev": "77826244401ea9de6e3bac47c2db46005e1f30b5",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -26,11 +26,11 @@
] ]
}, },
"locked": { "locked": {
"lastModified": 1743550720, "lastModified": 1751413152,
"narHash": "sha256-hIshGgKZCgWh6AYJpJmRgFdR3WUbkY04o82X05xqQiY=", "narHash": "sha256-Tyw1RjYEsp5scoigs1384gIg6e0GoBVjms4aXFfRssQ=",
"owner": "hercules-ci", "owner": "hercules-ci",
"repo": "flake-parts", "repo": "flake-parts",
"rev": "c621e8422220273271f52058f618c94e405bb0f5", "rev": "77826244401ea9de6e3bac47c2db46005e1f30b5",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -87,11 +87,11 @@
}, },
"nixpkgs": { "nixpkgs": {
"locked": { "locked": {
"lastModified": 1748792178, "lastModified": 1751949589,
"narHash": "sha256-BHmgfHlCJVNisJShVaEmfDIr/Ip58i/4oFGlD1iK6lk=", "narHash": "sha256-mgFxAPLWw0Kq+C8P3dRrZrOYEQXOtKuYVlo9xvPntt8=",
"owner": "nixos", "owner": "nixos",
"repo": "nixpkgs", "repo": "nixpkgs",
"rev": "5929de975bcf4c7c8d8b5ca65c8cd9ef9e44523e", "rev": "9b008d60392981ad674e04016d25619281550a9d",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -103,11 +103,11 @@
}, },
"nixpkgs-lib": { "nixpkgs-lib": {
"locked": { "locked": {
"lastModified": 1748740939, "lastModified": 1751159883,
"narHash": "sha256-rQaysilft1aVMwF14xIdGS3sj1yHlI6oKQNBRTF40cc=", "narHash": "sha256-urW/Ylk9FIfvXfliA1ywh75yszAbiTEVgpPeinFyVZo=",
"owner": "nix-community", "owner": "nix-community",
"repo": "nixpkgs.lib", "repo": "nixpkgs.lib",
"rev": "656a64127e9d791a334452c6b6606d17539476e2", "rev": "14a40a1d7fb9afa4739275ac642ed7301a9ba1ab",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -118,11 +118,11 @@
}, },
"nixpkgs_2": { "nixpkgs_2": {
"locked": { "locked": {
"lastModified": 1748406211, "lastModified": 1751786137,
"narHash": "sha256-B3BsCRbc+x/d0WiG1f+qfSLUy+oiIfih54kalWBi+/M=", "narHash": "sha256-lIlUKVGCGsh0Q2EA7/6xRtKUZjaQ/ur8uUyY+MynHXQ=",
"owner": "NixOS", "owner": "NixOS",
"repo": "nixpkgs", "repo": "nixpkgs",
"rev": "3d1f29646e4b57ed468d60f9d286cde23a8d1707", "rev": "ceb24d94c6feaa4e8737a8e2bd3cf71c3a7eaaa0",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -140,11 +140,11 @@
"systems": "systems_2" "systems": "systems_2"
}, },
"locked": { "locked": {
"lastModified": 1748877332, "lastModified": 1752099138,
"narHash": "sha256-pcAqUaMtxR1l//kugWqclFXKNQKCJQz9zO61JySGP7A=", "narHash": "sha256-riX+IkcFhurR1M1vMEp2cdzraxsZEZl+XbpFWcgz3lU=",
"owner": "nix-community", "owner": "nix-community",
"repo": "nixvim", "repo": "nixvim",
"rev": "65d35db5cac209cf5acd3dfd40aee98840cfc127", "rev": "2e24f8e62bc5da7e1ce81e2f2ff7d9e1f51350b7",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -163,11 +163,11 @@
] ]
}, },
"locked": { "locked": {
"lastModified": 1748298102, "lastModified": 1749730855,
"narHash": "sha256-PP11GVwUt7F4ZZi5A5+99isuq39C59CKc5u5yVisU/U=", "narHash": "sha256-L3x2nSlFkXkM6tQPLJP3oCBMIsRifhIDPMQQdHO5xWo=",
"owner": "NuschtOS", "owner": "NuschtOS",
"repo": "search", "repo": "search",
"rev": "f8a1c221afb8b4c642ed11ac5ee6746b0fe1d32f", "rev": "8dfe5879dd009ff4742b668d9c699bc4b9761742",
"type": "github" "type": "github"
}, },
"original": { "original": {