mirror of
https://github.com/anotherhadi/nixy.git
synced 2026-05-20 13:22:34 +02:00
@@ -6,10 +6,26 @@
|
||||
#- - `nixy rebuild` - Rebuild the system.
|
||||
#- - `nixy ...` - ... see the script for more commands.
|
||||
{
|
||||
pkgs,
|
||||
config,
|
||||
lib,
|
||||
pkgs,
|
||||
...
|
||||
}: let
|
||||
inherit (config.var) configDirectory;
|
||||
nixy = import ./package.nix {inherit pkgs configDirectory;};
|
||||
in {home.packages = [nixy];}
|
||||
}: {
|
||||
options.programs.nixy = {
|
||||
enable = lib.mkEnableOption "nixy";
|
||||
configDirectory = lib.mkOption {
|
||||
type = lib.types.str;
|
||||
default = "$HOME/.config/nixos";
|
||||
description = "Path to the NixOS configuration directory";
|
||||
};
|
||||
};
|
||||
|
||||
config = lib.mkIf config.programs.nixy.enable {
|
||||
home.packages = [
|
||||
(import ./package.nix {
|
||||
inherit pkgs;
|
||||
inherit (config.programs.nixy) configDirectory;
|
||||
})
|
||||
];
|
||||
};
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user