You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Nix 2.4 introduced 4 new builtins: builtins.fetchTree, builtins.getFlake, builtins.floor, and builtins.ceil. The latter two have documentation in the repl with :doc but fetchTree and getFlake don't.
Similarly the manual includes documentation on floor and ceil but is missing getFlake and fetchTree.
The only reference to builtins.getFlake occurs in the Nix 2.4 release notes, where it says
builtins.getFlake fetches a flake and returns its output attributes. This function should not be used inside flakes! Use flake inputs instead.
This is also the only place that describes builtins.fetchTree, though the Lock files docs does reference builtins.fetchTree when describing the structure of the file.
The docs on lock files provide useful info on how to call builtins.fetchTree, but there's no info on how builtins.getFlake works. Experimentally, it accepts a string flake reference but without a fragment. It does not appear to accept the attrset style of flake input. I don't know if there's anything else it accepts, or any subtleties about what it takes as input.
changed the title [-]New functions `builtins.getFlake` and `builtins.fetchTree` have no documentation[/-][+]Document `builtins.getFlake`[/+]on Nov 10, 2021
Activity
[-]New functions `builtins.getFlake` and `builtins.fetchTree` have no documentation[/-][+]Document `builtins.getFlake`[/+]edolstra commentedon Nov 10, 2021
Renamed this issue since we already have #5463 for fetchTree.
Document getFlake