mirror of
https://github.com/ryan4yin/nix-config.git
synced 2026-04-23 01:08:32 +02:00
feat: remove x86_64-darwin, add new nixos host on macbook pro m2
This commit is contained in:
57
outputs/aarch64-linux/src/12kingdoms-shoukei.nix
Normal file
57
outputs/aarch64-linux/src/12kingdoms-shoukei.nix
Normal file
@@ -0,0 +1,57 @@
|
||||
{
|
||||
# NOTE: the args not used in this file CAN NOT be removed!
|
||||
# because haumea pass argument lazily,
|
||||
# and these arguments are used in the functions like `mylib.nixosSystem`, `mylib.colmenaSystem`, etc.
|
||||
inputs,
|
||||
lib,
|
||||
myvars,
|
||||
mylib,
|
||||
system,
|
||||
genSpecialArgs,
|
||||
...
|
||||
} @ args: let
|
||||
# Shoukei (祥瓊, Shōkei)
|
||||
name = "shoukei";
|
||||
base-modules = {
|
||||
nixos-modules = map mylib.relativeToRoot [
|
||||
# common
|
||||
"secrets/nixos.nix"
|
||||
"modules/nixos/desktop.nix"
|
||||
# host specific
|
||||
"hosts/12kingdoms-${name}"
|
||||
];
|
||||
home-modules = map mylib.relativeToRoot [
|
||||
# common
|
||||
"home/linux/gui.nix"
|
||||
# host specific
|
||||
"hosts/12kingdoms-${name}/home.nix"
|
||||
];
|
||||
};
|
||||
|
||||
modules-hyprland = {
|
||||
nixos-modules =
|
||||
[
|
||||
{
|
||||
modules.desktop.wayland.enable = true;
|
||||
modules.secrets.desktop.enable = true;
|
||||
modules.secrets.preservation.enable = true;
|
||||
}
|
||||
]
|
||||
++ base-modules.nixos-modules;
|
||||
home-modules =
|
||||
[
|
||||
{modules.desktop.hyprland.enable = true;}
|
||||
]
|
||||
++ base-modules.home-modules;
|
||||
};
|
||||
in {
|
||||
nixosConfigurations = {
|
||||
# host with hyprland compositor
|
||||
"${name}-hyprland" = mylib.nixosSystem (modules-hyprland // args);
|
||||
};
|
||||
|
||||
# generate iso image for hosts with desktop environment
|
||||
packages = {
|
||||
"${name}-hyprland" = inputs.self.nixosConfigurations."${name}-hyprland".config.formats.iso;
|
||||
};
|
||||
}
|
||||
Reference in New Issue
Block a user