aboutsummaryrefslogtreecommitdiff
path: root/doc/manual/generate-builtins.nix
blob: 416a7fdba1c985c07f442a58b833a49c4f509939 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
with builtins;
with import ./utils.nix;

builtins:

concatStrings (map
  (name:
    let builtin = builtins.${name}; in
    "  - `builtins.${name}` " + concatStringsSep " " (map (s: "*${s}*") builtin.args)
    + "  \n\n"
    + concatStrings (map (s: "    ${s}\n") (splitLines builtin.doc)) + "\n\n"
  )
  (attrNames builtins))