nix-community.nixvim/wrappers/darwin.nix
2023-02-20 10:42:13 +00:00

33 lines
688 B
Nix

modules: {
pkgs,
config,
lib,
...
} @ args: let
inherit (lib) mkEnableOption mkOption mkOptionType mkForce mkMerge mkIf types;
shared = import ./_shared.nix args;
cfg = config.programs.nixvim;
in {
options = {
programs.nixvim = mkOption {
type = types.submodule ((modules pkgs)
++ [
{
options.enable = mkEnableOption "nixvim";
config.wrapRc = mkForce true;
}
]);
};
nixvim.helpers = shared.helpers;
};
config = mkIf cfg.enable mkMerge [
{
environment.systemPackages = [cfg.finalPackage];
}
{
warnings = cfg.warnings;
assertions = cfg.assertions;
}
];
}