Add nixos.base
All checks were successful
/ check (push) Successful in 50s

This commit is contained in:
Oliver Davies 2025-08-31 21:47:12 +01:00
parent 37c36112e3
commit 43df5bcd08
4 changed files with 8 additions and 3 deletions

View file

@ -7,7 +7,7 @@
{
flake.modules.nixos = {
pc = {
base = {
imports = [ inputs.home-manager.nixosModules.home-manager ];
home-manager = {

View file

@ -9,7 +9,7 @@
};
modules = {
nixos.pc = {
nixos.base = {
users.users.${config.flake.meta.owner.username} = {
isNormalUser = true;
initialPassword = lib.mkForce "";

5
modules/pc.nix Normal file
View file

@ -0,0 +1,5 @@
{ config, ... }:
{
flake.modules.nixos.pc.imports = with config.flake.modules.nixos; [ base ];
}

View file

@ -12,7 +12,7 @@
predicate = pkg: builtins.elem (lib.getName pkg) config.nixpkgs.allowedUnfreePackages;
in
{
nixos.pc.nixpkgs.config.allowUnfreePredicate = predicate;
nixos.base.nixpkgs.config.allowUnfreePredicate = predicate;
homeManager.base = args: {
nixpkgs.config = lib.mkIf (!(args.hasGlobalPkgs or false)) {