mirror of
https://github.com/nix-community/nixvim.git
synced 2025-06-22 08:53:28 +02:00
plugins/lsp: use mkPackageOption
for pylsp + rust-analyzer
This commit is contained in:
parent
848246bc64
commit
37165453a9
2 changed files with 6 additions and 14 deletions
|
@ -11,10 +11,8 @@ let
|
||||||
in
|
in
|
||||||
{
|
{
|
||||||
options.plugins.lsp.servers.pylsp = {
|
options.plugins.lsp.servers.pylsp = {
|
||||||
pythonPackage = mkOption {
|
pythonPackage = mkPackageOption pkgs "python" {
|
||||||
type = lib.types.package;
|
default = "python3";
|
||||||
description = "Python package to use for lsp.";
|
|
||||||
default = pkgs.python3;
|
|
||||||
};
|
};
|
||||||
|
|
||||||
# All settings are documented here:
|
# All settings are documented here:
|
||||||
|
|
|
@ -18,11 +18,8 @@ in
|
||||||
description = "Whether to install `cargo`.";
|
description = "Whether to install `cargo`.";
|
||||||
};
|
};
|
||||||
|
|
||||||
cargoPackage = mkOption {
|
# TODO: make nullable?
|
||||||
type = types.package;
|
cargoPackage = mkPackageOption pkgs "cargo" { };
|
||||||
default = pkgs.cargo;
|
|
||||||
description = "Which package to use for `cargo`.";
|
|
||||||
};
|
|
||||||
|
|
||||||
installRustc = mkOption {
|
installRustc = mkOption {
|
||||||
type = with types; nullOr bool;
|
type = with types; nullOr bool;
|
||||||
|
@ -31,11 +28,8 @@ in
|
||||||
description = "Whether to install `rustc`.";
|
description = "Whether to install `rustc`.";
|
||||||
};
|
};
|
||||||
|
|
||||||
rustcPackage = mkOption {
|
# TODO: make nullable
|
||||||
type = types.package;
|
rustcPackage = mkPackageOption pkgs "rustc" { };
|
||||||
default = pkgs.rustc;
|
|
||||||
description = "Which package to use for `rustc`.";
|
|
||||||
};
|
|
||||||
};
|
};
|
||||||
config = mkIf cfg.enable {
|
config = mkIf cfg.enable {
|
||||||
warnings =
|
warnings =
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue