NixOSConfig/lib/system.nix

20 lines
665 B
Nix
Raw Normal View History

{ nixpkgs }:
name :
{ dualBoot ? false } :
let
lib = nixpkgs.lib;
configPath = ./machines/${name}.nix;
in
lib.nixosSystem {
system = "x86_64-linux";
modules = [
(
{ config, pkgs, ... }: {
imports = lib.concatLists [
(lib.optional (builtins.pathExists configPath) configPath)
[]
];
})
];
}