lib: Add auxiliary function to deal with packages

This commit is contained in:
Mikael 2024-08-24 13:11:21 +02:00
parent 2adf0bdd4f
commit 3f276c26af
Signed by: mikael
SSH key fingerprint: SHA256:21QyD2Meiot7jOUVitIR5YkGB/XuXdCvLW1hE6dsri0

9
lib/packages.nix Normal file
View file

@ -0,0 +1,9 @@
{ nixpkgs, ... }:
let
inherit (builtins) any filter;
inherit (nixpkgs.lib.strings) getName;
in {
remove = nameList: pkgList:
filter (pkg: !any (elem: getName pkg == elem) nameList) pkgList;
}