feat: add purePkgs specialArg for non-overlayed nixpkgs

This commit is contained in:
matt1432 2025-05-18 12:29:31 -04:00
parent e5ae43d9d5
commit 025078b144
3 changed files with 13 additions and 3 deletions
configurations/binto/modules/nix-gaming
lib/flake
modules/desktop/environment/modules

View file

@ -1,6 +1,7 @@
{ {
nix-gaming, nix-gaming,
pkgs, pkgs,
purePkgs ? pkgs,
... ...
}: { }: {
imports = [ imports = [
@ -22,7 +23,7 @@
}; };
environment.systemPackages = [ environment.systemPackages = [
(pkgs.lutris.override { (purePkgs.lutris.override {
extraLibraries = pkgs: [ extraLibraries = pkgs: [
# List library dependencies here # List library dependencies here
]; ];

View file

@ -60,7 +60,15 @@ in rec {
}; };
inherit (pkgs.lib) mkForce; inherit (pkgs.lib) mkForce;
in { in {
_module.args.pkgs = mkForce pkgs; _module.args = {
pkgs = mkForce pkgs;
# Expose a non-overlayed version of nixpkgs to avoid cache misses
purePkgs = import inputs.nixpkgs {
inherit system cudaSupport;
config.allowUnfree = true;
};
};
}); });
# Default system # Default system

View file

@ -2,6 +2,7 @@ self: {
config, config,
lib, lib,
pkgs, pkgs,
purePkgs ? pkgs,
... ...
}: let }: let
inherit (self.lib.hypr) mkBind; inherit (self.lib.hypr) mkBind;
@ -168,12 +169,12 @@ in {
; ;
# School # School
inherit (purePkgs) libreoffice;
inherit (pkgs.hunspellDicts) en_CA; inherit (pkgs.hunspellDicts) en_CA;
inherit inherit
(pkgs) (pkgs)
xournalpp xournalpp
virt-manager virt-manager
libreoffice
hunspell hunspell
krename krename
; ;