diff options
-rw-r--r-- | modules/module-list.nix | 1 | ||||
-rw-r--r-- | modules/profiles/licensing.nix | 19 |
2 files changed, 20 insertions, 0 deletions
diff --git a/modules/module-list.nix b/modules/module-list.nix index 4eb8dc54..0aede318 100644 --- a/modules/module-list.nix +++ b/modules/module-list.nix @@ -4,6 +4,7 @@ ./hardware/t100ha ./hardware/thinkpad.nix ./profiles/common.nix + ./profiles/licensing.nix ./profiles/tests.nix ./programs/gnupg ./programs/fish/fasd.nix diff --git a/modules/profiles/licensing.nix b/modules/profiles/licensing.nix new file mode 100644 index 00000000..1a7c9390 --- /dev/null +++ b/modules/profiles/licensing.nix @@ -0,0 +1,19 @@ +{ config, lib, ... }: + +let + overrideConfig = newConfig: import (import ../../nixpkgs-path.nix) { + inherit (config.nixpkgs) system; + config = config.nixpkgs.config // newConfig; + }; + +in { + _module.args = { + unfreePkgs = overrideConfig { + whitelistedLicenses = [ lib.licenses.unfreeRedistributable ]; + }; + + unfreeAndNonDistributablePkgs = overrideConfig { + allowUnfree = true; + }; + }; +} |