aboutsummaryrefslogtreecommitdiff
path: root/doc
diff options
context:
space:
mode:
authorQyriad <qyriad@qyriad.me>2024-04-03 21:34:27 +0000
committerGerrit Code Review <gerrit@lix>2024-04-03 21:34:27 +0000
commitc263554ec66fd20f45d40f8f0708217d6bf2711f (patch)
tree42c68c75e2d1f261ac23aa2a695111002ff33e4c /doc
parent7a1054fa5f223126833718fc3f332579dba5f0f7 (diff)
parentc96c5db030110ca0795260cd2e25f488a9ef15a8 (diff)
Merge "meson: move nix3 manpage generation into command-ref/" into main
Diffstat (limited to 'doc')
-rw-r--r--doc/manual/meson.build18
-rw-r--r--doc/manual/src/command-ref/meson.build16
2 files changed, 21 insertions, 13 deletions
diff --git a/doc/manual/meson.build b/doc/manual/meson.build
index 02b707ff3..72294311e 100644
--- a/doc/manual/meson.build
+++ b/doc/manual/meson.build
@@ -132,19 +132,10 @@ nix3_cli_json = custom_target(
capture : true,
output : 'nix.json',
)
-nix3_cli_files = custom_target(
- command : nix_eval_for_docs + [
- '--write-to', '@OUTPUT@',
- '--expr',
- 'import @INPUT1@ true (builtins.readFile @INPUT0@)',
- ],
- input : [
- nix3_cli_json,
- 'generate-manpage.nix',
- 'utils.nix',
- ],
- output : 'new-cli',
-)
+
+# Creates nix3_cli_files custom target variable,
+# which outputs the entire src/command-ref/new-cli directory.
+subdir('src/command-ref')
nix3_manpages = [
'nix3-build',
@@ -245,6 +236,7 @@ foreach page : nix3_manpages
'@OUTPUT@.tmp',
'@OUTPUT@',
],
+ # nix3_cli_files set in doc/manual/src/command-ref/meson.build.
input : nix3_cli_files,
output : page + '.1',
install : true,
diff --git a/doc/manual/src/command-ref/meson.build b/doc/manual/src/command-ref/meson.build
new file mode 100644
index 000000000..c4043c882
--- /dev/null
+++ b/doc/manual/src/command-ref/meson.build
@@ -0,0 +1,16 @@
+nix3_cli_files = custom_target(
+ 'command-ref-new-cli',
+ command : nix_eval_for_docs + [
+ '--write-to', '@OUTPUT@',
+ '--expr',
+ 'import @INPUT1@ true (builtins.readFile @INPUT0@)',
+ ],
+ input : [
+ nix3_cli_json,
+ files(
+ meson.project_source_root() / 'doc/manual/generate-manpage.nix',
+ meson.project_source_root() / 'doc/manual/utils.nix',
+ ),
+ ],
+ output : 'new-cli',
+)