diff options
author | Eelco Dolstra <edolstra@gmail.com> | 2022-08-29 08:46:35 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-08-29 08:46:35 +0200 |
commit | 1f2b12b30e5d9e5ea89dfd6172ea9e9df9eb960a (patch) | |
tree | 2a4c8af1878b10f71e17029a922a24ed9732daef /doc | |
parent | 7918adbb628e7781cec1638c371f2009136be68a (diff) | |
parent | e7dcacbd7ca75bbac8b77e6873160feff875c9c7 (diff) |
Merge pull request #6968 from fricklerhandwerk/man-no-weblinks
do not render relative links in help pages
Diffstat (limited to 'doc')
-rw-r--r-- | doc/manual/generate-manpage.nix | 6 | ||||
-rw-r--r-- | doc/manual/local.mk | 4 |
2 files changed, 4 insertions, 6 deletions
diff --git a/doc/manual/generate-manpage.nix b/doc/manual/generate-manpage.nix index 244cfa0c2..17701c3a3 100644 --- a/doc/manual/generate-manpage.nix +++ b/doc/manual/generate-manpage.nix @@ -1,4 +1,4 @@ -{ command, renderLinks ? false }: +{ command }: with builtins; with import ./utils.nix; @@ -21,9 +21,7 @@ let listCommands = cmds: concatStrings (map (name: "* " - + (if renderLinks - then "[`${command} ${name}`](./${appendName filename name}.md)" - else "`${command} ${name}`") + + "[`${command} ${name}`](./${appendName filename name}.md)" + " - ${cmds.${name}.description}\n") (attrNames cmds)); in diff --git a/doc/manual/local.mk b/doc/manual/local.mk index 66a8cb7de..364e02967 100644 --- a/doc/manual/local.mk +++ b/doc/manual/local.mk @@ -50,7 +50,7 @@ $(d)/src/SUMMARY.md: $(d)/src/SUMMARY.md.in $(d)/src/command-ref/new-cli $(d)/src/command-ref/new-cli: $(d)/nix.json $(d)/generate-manpage.nix $(bindir)/nix @rm -rf $@ - $(trace-gen) $(nix-eval) --write-to $@ --expr 'import doc/manual/generate-manpage.nix { command = builtins.readFile $<; renderLinks = true; }' + $(trace-gen) $(nix-eval) --write-to $@ --expr 'import doc/manual/generate-manpage.nix { command = builtins.readFile $<; }' $(d)/src/command-ref/conf-file.md: $(d)/conf-file.json $(d)/generate-options.nix $(d)/src/command-ref/conf-file-prefix.md $(bindir)/nix @cat doc/manual/src/command-ref/conf-file-prefix.md > $@.tmp @@ -96,7 +96,7 @@ doc/manual/generated/man1/nix3-manpages: $(d)/src/command-ref/new-cli if [[ $$name = SUMMARY ]]; then continue; fi; \ printf "Title: %s\n\n" "$$name" > $$tmpFile; \ cat $$i >> $$tmpFile; \ - lowdown -sT man -M section=1 $$tmpFile -o $(DESTDIR)$$(dirname $@)/$$name.1; \ + lowdown -sT man --nroff-nolinks -M section=1 $$tmpFile -o $(DESTDIR)$$(dirname $@)/$$name.1; \ rm $$tmpFile; \ done @touch $@ |