2022-01-09 12:30:03 +01:00
|
|
|
{
|
|
|
|
# list of package attribute names to get at run time
|
2022-01-30 17:06:58 +01:00
|
|
|
packageNamesAtRuntimeJsonPath
|
|
|
|
,
|
2022-01-09 12:30:03 +01:00
|
|
|
}:
|
|
|
|
let
|
2022-01-30 17:06:58 +01:00
|
|
|
pkgs = import <nixpkgs> { };
|
2022-01-09 12:30:03 +01:00
|
|
|
|
|
|
|
getPkg = pkgName: pkgs.${pkgName};
|
|
|
|
|
|
|
|
packageNamesAtRuntime = builtins.fromJSON (builtins.readFile packageNamesAtRuntimeJsonPath);
|
|
|
|
|
|
|
|
runtime = map getPkg packageNamesAtRuntime;
|
|
|
|
|
|
|
|
in
|
2022-01-30 17:06:58 +01:00
|
|
|
pkgs.symlinkJoin {
|
|
|
|
name = "symlink-farm";
|
|
|
|
paths = runtime;
|
|
|
|
}
|