mirror of
https://github.com/nix-community/nixvim.git
synced 2025-08-08 11:55:17 +02:00
plugins/lsp/nixd: refactor
This commit is contained in:
parent
f14aa756ba
commit
6be28a941b
3 changed files with 51 additions and 67 deletions
|
@ -4,11 +4,9 @@
|
|||
config,
|
||||
pkgs,
|
||||
...
|
||||
}@args:
|
||||
}:
|
||||
with lib;
|
||||
let
|
||||
nixdSettings = import ./nixd.nix args;
|
||||
|
||||
servers = [
|
||||
{
|
||||
name = "ansiblels";
|
||||
|
@ -408,7 +406,10 @@ let
|
|||
description = "nixd for Nix";
|
||||
package = pkgs.nixd;
|
||||
settings = cfg: { nixd = cfg; };
|
||||
settingsOptions = nixdSettings.options;
|
||||
settingsOptions = import ./nixd-settings.nix { inherit lib helpers; };
|
||||
extraConfig = cfg: {
|
||||
extraPackages = optional (cfg.settings.formatting.command == [ "nixpkgs-fmt" ]) pkgs.nixpkgs-fmt;
|
||||
};
|
||||
}
|
||||
{
|
||||
name = "nushell";
|
||||
|
@ -683,6 +684,4 @@ in
|
|||
./rust-analyzer.nix
|
||||
./svelte.nix
|
||||
];
|
||||
|
||||
config = lib.mkMerge [ nixdSettings.config ];
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue