aboutsummaryrefslogtreecommitdiff
path: root/doc/manual/src/language
diff options
context:
space:
mode:
Diffstat (limited to 'doc/manual/src/language')
-rw-r--r--doc/manual/src/language/builtin-constants-suffix.md1
-rw-r--r--doc/manual/src/language/builtin-constants.md (renamed from doc/manual/src/language/builtin-constants-prefix.md)4
-rw-r--r--doc/manual/src/language/builtins-suffix.md1
-rw-r--r--doc/manual/src/language/builtins.md (renamed from doc/manual/src/language/builtins-prefix.md)4
-rw-r--r--doc/manual/src/language/meson.build27
5 files changed, 35 insertions, 2 deletions
diff --git a/doc/manual/src/language/builtin-constants-suffix.md b/doc/manual/src/language/builtin-constants-suffix.md
deleted file mode 100644
index a74db2857..000000000
--- a/doc/manual/src/language/builtin-constants-suffix.md
+++ /dev/null
@@ -1 +0,0 @@
-</dl>
diff --git a/doc/manual/src/language/builtin-constants-prefix.md b/doc/manual/src/language/builtin-constants.md
index 50f43006d..74e87146f 100644
--- a/doc/manual/src/language/builtin-constants-prefix.md
+++ b/doc/manual/src/language/builtin-constants.md
@@ -3,3 +3,7 @@
These constants are built into the Nix language evaluator:
<dl>
+
+{{#include @generated@/language/builtin-constants.md}}
+
+</dl>
diff --git a/doc/manual/src/language/builtins-suffix.md b/doc/manual/src/language/builtins-suffix.md
deleted file mode 100644
index a74db2857..000000000
--- a/doc/manual/src/language/builtins-suffix.md
+++ /dev/null
@@ -1 +0,0 @@
-</dl>
diff --git a/doc/manual/src/language/builtins-prefix.md b/doc/manual/src/language/builtins.md
index 7b2321466..2a3972f05 100644
--- a/doc/manual/src/language/builtins-prefix.md
+++ b/doc/manual/src/language/builtins.md
@@ -14,3 +14,7 @@ For convenience, some built-ins can be accessed directly:
<dt id="builtins-derivation"><a href="#builtins-derivation"><code>derivation <var>attrs</var></code></a></dt>
<dd><p><var>derivation</var> is described in
<a href="derivations.md">its own section</a>.</p></dd>
+
+{{#include @generated@/language/builtins.md}}
+
+</dl>
diff --git a/doc/manual/src/language/meson.build b/doc/manual/src/language/meson.build
new file mode 100644
index 000000000..bc0d147f3
--- /dev/null
+++ b/doc/manual/src/language/meson.build
@@ -0,0 +1,27 @@
+builtins_md = custom_target(
+ command : nix_eval_for_docs + [
+ '--expr',
+ 'import @INPUT0@ (builtins.fromJSON (builtins.readFile @INPUT1@)).builtins',
+ ],
+ capture : true,
+ input : [
+ '../../generate-builtins.nix',
+ language_json,
+ ],
+ output : 'builtins.md',
+ env : nix_env_for_docs,
+)
+
+builtin_constants_md = custom_target(
+ command : nix_eval_for_docs + [
+ '--expr',
+ 'import @INPUT0@ (builtins.fromJSON (builtins.readFile @INPUT1@)).constants',
+ ],
+ capture : true,
+ input : [
+ '../../generate-builtin-constants.nix',
+ language_json,
+ ],
+ output : 'builtin-constants.md',
+ env : nix_env_for_docs,
+)