DEVELOPMENT ENVIRONMENT

~liljamo/nix-arta

214bf51d4d5f313efdb48f8f3e075c324e2a0c8c — Jonni Liljamo 4 months ago 5ff2ffd
feat(modules/unfree): unfree core module
M flake.nix => flake.nix +0 -1
@@ 34,7 34,6 @@
  outputs = inputs:
    inputs.flake-parts.lib.mkFlake {inherit inputs;} {
      imports = [
        #./hm-modules
        ./systems
      ];


A modules/default.nix => modules/default.nix +5 -0
@@ 0,0 1,5 @@
{
  imports = [
    ./unfree.nix
  ];
}

A modules/unfree.nix => modules/unfree.nix +19 -0
@@ 0,0 1,19 @@
{
  config,
  lib,
  ...
}: let
  cfg = config.arta.unfree;
in {
  options.arta.unfree = {
    allow = lib.mkOption {
      type = lib.types.listOf lib.types.str;
      default = [];
    };
  };

  config = {
    nixpkgs.config.allowUnfreePredicate = pkg:
      builtins.elem (lib.getName pkg) cfg.allow;
  };
}

M roles/steam.nix => roles/steam.nix +5 -6
@@ 11,12 11,11 @@ in {
  };

  config = lib.mkIf cfg.enable {
    nixpkgs.config.allowUnfreePredicate = pkg:
      builtins.elem (lib.getName pkg) [
        "steam-run"
        "steam-original"
        "steam"
      ];
    arta.unfree.allow = [
      "steam-run"
      "steam-original"
      "steam"
    ];

    programs.steam = {
      enable = true;

M systems/profiles/desktop/default.nix => systems/profiles/desktop/default.nix +1 -0
@@ 9,6 9,7 @@ inputs @ {
    impermanence.nixosModules.impermanence
    home-manager.nixosModules.home-manager

    ../../../modules
    ../../../roles
  ];
  specialArgs = {

M systems/profiles/laptop/default.nix => systems/profiles/laptop/default.nix +1 -0
@@ 9,6 9,7 @@ inputs @ {
    impermanence.nixosModules.impermanence
    home-manager.nixosModules.home-manager

    ../../../modules
    ../../../roles
  ];
  specialArgs = {