diff --git a/examples/nixos/__nixosProfiles/bootstrap.nix b/examples/nixos/__nixosProfiles/bootstrap.nix index 14a33d8..b311b43 100644 --- a/examples/nixos/__nixosProfiles/bootstrap.nix +++ b/examples/nixos/__nixosProfiles/bootstrap.nix @@ -1,6 +1,4 @@ { - boot.__profiles__.systemd-boot.enable = true; - # config.boot.__profiles__.systemd-initrd.enable = true; fileSystems."/" = { device = "/dev/disk/by-label/nixos"; }; diff --git a/examples/nixos/default.nix b/examples/nixos/default.nix index 647617e..d387357 100644 --- a/examples/nixos/default.nix +++ b/examples/nixos/default.nix @@ -5,21 +5,53 @@ homeModules = super.pops.homeModules.outputsForTarget.nixosModules; - homeProfiles = super.pops.homeProfiles.outputs; + homeProfiles = super.pops.homeProfiles.outputsForTarget; - nixosProfiles = super.pops.nixosProfiles.outputs; + nixosProfiles = super.pops.nixosProfiles.outputsForTarget; nixosSuites = let - customProfiles = self.nixosProfiles { }; + customProfiles = { + nix = + (self.nixosProfiles.dmerge { + nix.extraOptions = '' + allowed-uris = https://github.com/ + ''; + }).presets.nix; + boot = + (self.nixosProfiles.dmerge { + # boot.__profiles__.systemd-initrd.enable = true; + boot.__profiles__.systemd-boot.enable = true; + }).presets.boot; + }; in lib.flatten [ self.selfNixOSProfiles.bootstrap - self.nixosModules.boot + + # self.nixosProfiles.default.presets.boot + customProfiles.boot + self.nixosModules.programs.git + # ( + # { + # lib, + # config, + # options, + # ... + # }@args: + # { + # options = { + # __test__ = lib.mkOption { + # type = lib.types.attrs; + # default = ; + # }; + # }; + # } + # ) + # --custom profiles - customProfiles.presets.nix + customProfiles.nix (selfLib.mkHome { @@ -37,16 +69,17 @@ homeSuites = let - customProfiles = self.homeProfiles { - presets.hyprland.default = { - wayland.windowManager.hyprland.__profiles__ = { - nvidia = true; - }; - }; + customProfiles = { + hyprland = + (self.homeProfiles.dmerge { + wayland.windowManager.hyprland.__profiles__ = { + nvidia = true; + }; + }).presets.hyprland; }; in [ - customProfiles.presets.hyprland.default + customProfiles.hyprland # self.homeModules.wayland.windowManager.hyprland ]; } diff --git a/flake.lock b/flake.lock index 7949e34..43dd9e7 100644 --- a/flake.lock +++ b/flake.lock @@ -92,11 +92,11 @@ "yants": "yants" }, "locked": { - "lastModified": 1695103891, - "narHash": "sha256-xkyEJx/6ixkx6ov0qzJVw3PuESnSn0rYv7cgwye7cWE=", + "lastModified": 1695175156, + "narHash": "sha256-xsutGowMiL6jIXTRe4PQJSYk4ADUyNGnRzZO9Ah6oAg=", "owner": "gtrunsec", "repo": "flops", - "rev": "9309b35f5b848590dcada4c1134082c6480b5238", + "rev": "fe122602ec8d534627a4d7e48e26ff48c8c4bbf4", "type": "github" }, "original": { diff --git a/flake.nix b/flake.nix index 4322be1..524a5b7 100644 --- a/flake.nix +++ b/flake.nix @@ -38,12 +38,11 @@ loadHomeProfiles = loadHomeModules.addLoadExtender { src = ./nixos/homeProfiles; loader = haumea.lib.loaders.scoped; - type = "default"; + type = "nixosProfiles"; }; - loadNixOSProfiles = loadNixOSModules.addLoadExtender { + loadNixOSProfiles = flops.lib.haumea.pops.default.setInit { src = ./nixos/nixosProfiles; - loader = haumea.lib.loaders.scoped; - type = "default"; + type = "nixosProfiles"; }; lib = flops.lib.haumea.pops.default.setInit { src = ./lib; diff --git a/nixos/nixosProfiles/bootstrap.nix b/nixos/nixosProfiles/bootstrap.nix index 1e3ec72..bda5304 100644 --- a/nixos/nixosProfiles/bootstrap.nix +++ b/nixos/nixosProfiles/bootstrap.nix @@ -1 +1 @@ -[ ] +{ default = [ ]; } diff --git a/nixos/nixosProfiles/presets/boot.nix b/nixos/nixosProfiles/presets/boot.nix new file mode 100644 index 0000000..137c5d8 --- /dev/null +++ b/nixos/nixosProfiles/presets/boot.nix @@ -0,0 +1,4 @@ +{ + imports = [ POS.nixosModules.boot ]; + boot.__profiles__.systemd-boot.enable = true; +} diff --git a/nixos/nixosProfiles/presets/nix.nix b/nixos/nixosProfiles/presets/nix.nix index ab10669..3307bbe 100644 --- a/nixos/nixosProfiles/presets/nix.nix +++ b/nixos/nixosProfiles/presets/nix.nix @@ -1,5 +1,6 @@ -_: -{ pkgs, ... }: +let + inherit (moduleArgs) pkgs; +in { nix = { package = pkgs.nixUnstable;