summary refs log tree commit diff
path: root/www
diff options
context:
space:
mode:
authorJune McEnroe <june@causal.agency>2020-09-12 07:02:14 +0000
committerJune McEnroe <june@causal.agency>2020-09-12 07:03:28 +0000
commit287698d0e25c5388de5912254d35628ec56e0bd1 (patch)
tree3577ea0af9f2ba4022c1b9d774cd7e4c49e0015e /www
parentInstall mandoc on macOS (diff)
downloadsrc-287698d0e25c5388de5912254d35628ec56e0bd1.tar.gz
src-287698d0e25c5388de5912254d35628ec56e0bd1.zip
Enable toc in cgit renderings of man pages
But keep it disabled for READMEs since they always use non-standard
sections and the TOC is just distracting there, I think.

Also add the style so its h1 is the same size as the ones inside
sections...
Diffstat (limited to 'www')
-rw-r--r--www/git.causal.agency/about-filter.sh7
-rw-r--r--www/git.causal.agency/custom.css1
2 files changed, 7 insertions, 1 deletions
diff --git a/www/git.causal.agency/about-filter.sh b/www/git.causal.agency/about-filter.sh
index ea68fe05..d27d2d48 100644
--- a/www/git.causal.agency/about-filter.sh
+++ b/www/git.causal.agency/about-filter.sh
@@ -1,8 +1,13 @@
 #!/bin/sh
 
+options=fragment,man=%N.%S,includes=../tree/%I
+
 case "$1" in
+	(README.[1-9])
+		exec /usr/bin/mandoc -T html -O $options
+		;;
 	(*.[1-9])
-		exec /usr/bin/mandoc -T html -O fragment,man=%N.%S,includes=../tree/%I
+		exec /usr/bin/mandoc -T html -O $options,toc
 		;;
 	(*)
 		exec /usr/local/libexec/hi -l text -f html
diff --git a/www/git.causal.agency/custom.css b/www/git.causal.agency/custom.css
index 80892b36..802882d2 100644
--- a/www/git.causal.agency/custom.css
+++ b/www/git.causal.agency/custom.css
@@ -74,6 +74,7 @@ dl.Bl-diag > dt { font-weight: bold; }
 code.Nm, code.Fl, code.Cm, code.Ic, code.In, code.Fd, code.Fn,
 code.Cd { font-weight: bold; font-family: inherit; }
 
+h1.Sh { font-size: 1.5em; }
 table.Nm td:first-child { padding-right: 1ch; }
 code.Fl { white-space: nowrap; }
 span.RsT { font-style: italic; }
ne McEnroe 2021-09-22Remove default faviconJune McEnroe 2021-09-21Use Z_FILTERED strategyJune McEnroe 2021-09-21Recalculate various lengths only as neededJune McEnroe 2021-09-21Rewrite pngo, add explicit optionsJune McEnroe 2021-09-16Fix /* **/ comment matchingJune McEnroe 2021-09-15Remove typer, add downgrade to READMEJune McEnroe 2021-09-15Set bot mode on downgradeJune McEnroe 2021-09-15Enter capsicum in downgradeJune McEnroe 2021-09-15Factor out common parts of downgrade messagesJune McEnroe 2021-09-14Add downgrade IRC botJune McEnroe 2021-09-14Sort by title if authors matchJune McEnroe 2021-09-13Swap-remove tags as they're foundJune McEnroe 2021-09-12Replace htagml regex with strncmpJune McEnroe 2021-09-11Also defer printing comment for lone close-parensJune McEnroe 2021-09-10Publish "git-comment"June McEnroe 2021-09-10Add git comment --pretty optionJune McEnroe 2021-09-08Defer printing comment if line is blank or closing braceJune McEnroe 2021-09-08Up default min-repeat to 30 linesJune McEnroe 2021-09-08Handle dirty lines in git-commentJune McEnroe 2021-09-08Document and install git-commentJune McEnroe 2021-09-08Add repeat and all options to git-commentJune McEnroe 2021-09-08Add group threshold to git-commentJune McEnroe