nix.renderFlakeFile
import { nix } from "https://garn.io/ts/v0.0.20/mod.ts";
const { renderFlakeFile } = nix;
Renders the nix expression as the outputs
of a flake file with all flake
deps provided as inputs.
Example:
renderFlakeFile(nixAttrSet({
foo: nixFlakeDep("foo-repo", { url: "http://example.org/foo" }),
bar: nixFlakeDep("bar-repo", { url: "http://example.org/bar" }),
}))
// Returns:
// {
// inputs.foo-repo.url = "http://example.org/foo";
// inputs.bar-repo.url = "http://example.org/bar";
// outputs = { self, foo-repo, bar-repo }: {
// "foo" = foo-repo;
// "bar" = bar-repo;
// };
// }