aboutsummaryrefslogtreecommitdiff
path: root/modules/pkgs/default.nix
blob: d66f7bac8f5bb07e571b1ca2c9deef03f3a39476 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
{ lib, ... }:

let
  all = lib.attrNames (
    lib.filterAttrs
    ( n: _: n != "default.nix" && ! lib.hasPrefix "." n )
    (builtins.readDir ./.)
  );

  localPackages = super: lib.listToAttrs (map (f:
    { name = lib.removeSuffix ".nix" f;
      value = super.callPackage (./. + "/${f}") {}; }
  ) all);

in {
  nixpkgs.config.packageOverrides = localPackages;
}