fix: Formatting
Working:
- The daemon
- Mutable config — well, kinda. I'm not yet sure how it will interact with
`emacsWithPackagesFromUsePackage`.
- Packages via Nixpkgs
This commit is contained in:
@@ -13,6 +13,7 @@ let users = builtins.readDir ../users;
|
||||
# Directory name should always match username.
|
||||
({ ... }: { home.username = username; })
|
||||
|
||||
# TODO: Move to default module.
|
||||
({ lib, ... }: {
|
||||
nix = {
|
||||
settings.experimental-features =
|
||||
|
||||
@@ -18,42 +18,44 @@ let
|
||||
(builtins.readDir ../users)));
|
||||
};
|
||||
|
||||
mkHost = hostName: nixpkgs.lib.nixosSystem {
|
||||
specialArgs = inputs;
|
||||
system = import ../hosts/${hostName}/system.nix;
|
||||
# TODO: This is very ad-hoc, and I don't like it. Organise this better.
|
||||
modules = [
|
||||
../hosts/${hostName}/configuration.nix
|
||||
mkHost = hostName:
|
||||
let system = import ../hosts/${hostName}/system.nix;
|
||||
in nixpkgs.lib.nixosSystem {
|
||||
specialArgs = inputs;
|
||||
inherit system;
|
||||
modules = [
|
||||
../hosts/${hostName}/configuration.nix
|
||||
|
||||
inputs.self.nixosModules.default
|
||||
inputs.self.nixosModules.default
|
||||
|
||||
inputs.disko.nixosModules.disko
|
||||
inputs.sops-nix.nixosModules.sops
|
||||
inputs.impermanence.nixosModules.impermanence
|
||||
inputs.disko.nixosModules.disko
|
||||
inputs.sops-nix.nixosModules.sops
|
||||
inputs.impermanence.nixosModules.impermanence
|
||||
|
||||
# Directory name should always match host name.
|
||||
({ ... }: { networking.hostName = hostName; })
|
||||
# Directory name should always match host name.
|
||||
({ ... }: { networking.hostName = hostName; })
|
||||
|
||||
(mkHostUsers hostName)
|
||||
(mkHostUsers hostName)
|
||||
|
||||
# home-manager configuration.
|
||||
inputs.home-manager.nixosModules.home-manager
|
||||
({ config, lib, self, ... }: {
|
||||
home-manager.useGlobalPkgs = true;
|
||||
# home-manager configuration.
|
||||
inputs.home-manager.nixosModules.home-manager
|
||||
({ config, lib, self, ... }: {
|
||||
home-manager.useGlobalPkgs = true;
|
||||
|
||||
home-manager.users =
|
||||
lib.filterAttrs
|
||||
(username: _: builtins.elem username config.sydnix.users.users)
|
||||
self.homeConfigurations;
|
||||
home-manager.users =
|
||||
lib.filterAttrs
|
||||
(username: _: builtins.elem username config.sydnix.users.users)
|
||||
self.homeConfigurations;
|
||||
|
||||
home-manager.extraSpecialArgs = {
|
||||
utils = import ../lib/utils.nix {
|
||||
inherit config lib;
|
||||
pkgs = nixpkgs;
|
||||
home-manager.extraSpecialArgs = {
|
||||
utils = import ../lib/utils.nix {
|
||||
inherit config lib;
|
||||
pkgs = nixpkgs;
|
||||
};
|
||||
inherit inputs system;
|
||||
};
|
||||
};
|
||||
})
|
||||
];
|
||||
};
|
||||
})
|
||||
];
|
||||
};
|
||||
in
|
||||
builtins.mapAttrs (dirName: _: mkHost dirName) (builtins.readDir ../hosts)
|
||||
|
||||
Reference in New Issue
Block a user