diff options
author | Grégoire Détrez <gregoire@fripost.org> | 2019-07-05 15:25:29 +0200 |
---|---|---|
committer | Guilhem Moulin <guilhem@fripost.org> | 2019-07-05 15:25:29 +0200 |
commit | 21d6363c406bd0301b52711a30f98e1f03d0afaa (patch) | |
tree | d2e714064f73aea8e521e3106e23f3738d8f9fd5 /Makefile | |
parent | 3811a6846c0174c1c91730844ce8ef98627508cc (diff) |
doc/template.html: Add parent links at the top.
Diffstat (limited to 'Makefile')
-rw-r--r-- | Makefile | 2 |
1 files changed, 2 insertions, 0 deletions
@@ -46,8 +46,10 @@ html: $(HTML_FILES) $(HTML_ROOTDIR)/%.html: ./doc/%.md $(HTML_TEMPLATE) mtime="$$(git --no-pager log -1 --pretty="format:%ct" -- "$<" 2>/dev/null)"; \ [ -n "$$mtime" ] || mtime="$$(date +%s -r "$<")"; \ + [ "$<" = "doc/index.md" ] && parent="" || parent="./index.html"; \ pandoc -sp -f markdown -t html+smart --css=$(CSS) --template=$(HTML_TEMPLATE) \ --variable=date:"$$(LC_TIME=C date +"Last modified on %a, %d %b %Y at %T %z" -d @"$$mtime")" \ + --variable=parent:"$$parent" \ --output="$@" -- "$<" doc: manual html |