tvl-depot/users/Profpatsch/ytextr/create-symlink-farm.nix

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

20 lines
379 B
Nix
Raw Normal View History

{
# list of package attribute names to get at run time
packageNamesAtRuntimeJsonPath
,
}:
let
pkgs = import <nixpkgs> { };
getPkg = pkgName: pkgs.${pkgName};
packageNamesAtRuntime = builtins.fromJSON (builtins.readFile packageNamesAtRuntimeJsonPath);
runtime = map getPkg packageNamesAtRuntime;
in
pkgs.symlinkJoin {
name = "symlink-farm";
paths = runtime;
}