lsp/presets/python-lsp-server: init

This commit is contained in:
Snoweuph 2026-04-11 17:32:27 +02:00
commit ee388f875f
No known key found for this signature in database
GPG key ID: BEFC41DA223CEC55
2 changed files with 25 additions and 0 deletions

View file

@ -3,6 +3,7 @@
./deno.nix
./harper.nix
./lemminx.nix
./python-lsp-server.nix
./qmlls.nix
./r-languageserver.nix
./ruby-lsp.nix

View file

@ -0,0 +1,24 @@
{
config,
lib,
pkgs,
...
}: let
inherit (lib.meta) getExe;
inherit (lib.modules) mkIf;
inherit (lib.options) mkEnableOption;
cfg = config.vim.lsp.presets.python-lsp-server;
in {
options.vim.lsp.presets.python-lsp-server = {
enable = mkEnableOption "the Python Language Server";
};
config = mkIf cfg.enable {
vim.lsp.servers.python-lsp-server = {
enable = true;
cmd = [(getExe pkgs.python3Packages.python-lsp-server)];
root_markers = [".git"];
};
};
}