Commit 7155abb1 authored by PoroCYon's avatar PoroCYon

allow different document roots

parent 1a76c484
......@@ -2,6 +2,8 @@ out/
stc/mathjax.js
obj/
ningau.sh
.gitignore
miscfiles
undertale
tmp
......@@ -5,6 +5,10 @@
# Version 2, as published by Sam Hocevar. See http://www.wtfpl.net/ for
# more details.
#ifneq ($(wildcard config.mk),)
include config.mk
#endif
default: all
DATE:="$(shell date "+%B %e, %Y")"
......@@ -15,8 +19,8 @@ AWK ?= awk
PANDOC ?= pandoc
SCSSC ?= sassc
PDMARKDOWN:=markdown_github+raw_tex+yaml_metadata_block+table_captions+implicit_figures+simple_tables+multiline_tables+grid_tables+tex_math_dollars+fenced_code_attributes+inline_code_attributes+markdown_attribute+fancy_lists+all_symbols_escapable+superscript+subscript+header_attributes-emoji-hard_line_breaks
PDFLAGS=-s --ascii -M date=$(DATE) \
-V maintitle=$(MAINTITLE) -c /stc/style-light.css --mathml \
PDFLAGS=-s --ascii -M date=$(DATE) -V docroot="$(DOCROOT)" \
-V maintitle=$(MAINTITLE) -c "$(DOCROOT)stc/style-light.css" --mathml \
-H tpl/header.html \
$(SIDEBAR_FILES_CLEAN)
#-B tpl/before.html -A tpl/after.html
......@@ -45,7 +49,7 @@ STY_SHARED=sty/style-common.scss sty/solarized-base.scss
mkdir -p "$@"
obj/postlist.html: src/blog/postdb.tsv obj/
tac "$<" | $(AWK) -F '\t' -f src/blog/mkpostlist.awk > "$@"
tac "$<" | $(AWK) -v docroot="$(DOCROOT)" -F '\t' -f src/blog/mkpostlist.awk > "$@"
obj/%.xml.pre: tpl/%.xml.pre obj/
< "$<" sed -E -e 's/daterfc3339/$(DATERFC3339)/g' -e 's/daterfc822/$(DATERFC822) +0000/g' > "$@"
......
{
print "<a href=\"/blog/post/" $1 ".html\">" $3 "</a> (" $2 ") <br />"
print "<a href=\"" docroot "blog/post/" $1 ".html\">" $3 "</a> (" $2 ") <br />"
}
<p style="text-align:right">Days without lynx compatibility: 0</p>
<a rel="license" href="https://creativecommons.org/licenses/by-sa/4.0/">
<img alt="Creative Commons License" style="border-width:0" src="/stc/cc-by-sa.png" />
<img alt="Creative Commons License" style="border-width:0" src="$docroot$stc/cc-by-sa.png" />
</a>
<br />
<p><a href="https://gitlab.com/PoroCYon/kibystu">Website source and SSG</a></p>
......
<h3><a href="/index.html" style="text-decoration:none;color:black">lo kibystu pe la poros</a></h3>
<h3><a href="$docroot$index.html" style="text-decoration:none;color:black">lo kibystu pe la poros</a></h3>
......@@ -45,13 +45,13 @@ $endfor$
<tr>
<td class="left"></td>
<td>
<h3><a href="/index.html" class="title">lo kibystu pe la poros</a></h3>
<h3><a href="$docroot$index.html" class="title">lo kibystu pe la poros</a></h3>
</td>
</tr>
<tr>
<td class="left">
$for(sidebar-links)$
<p><a href="/$sidebar-links$.html">$sidebar-links$</a></p>
<p><a href="$docroot$$sidebar-links$.html">$sidebar-links$</a></p>
$endfor$
</td>
<td class="middle">
......@@ -69,7 +69,7 @@ $endfor$
<br />
<h3>license</h3>
<a rel="license" href="https://creativecommons.org/licenses/by-sa/4.0/">
<img alt="Creative Commons License" class="ccimg" src="/stc/cc-by-sa.png" />
<img alt="Creative Commons License" class="ccimg" src="$docroot$stc/cc-by-sa.png" />
</a>
<br />
This work is licensed under a <a rel="license" href="https://creativecommons.org/licenses/by-sa/4.0/">Creative Commons Attribution-ShareAlike 4.0 International License</a>.
......
......@@ -45,13 +45,13 @@ $endfor$
<tr>
<td class="left"></td>
<td>
<h3><a href="/index.html" class="title">lo kibystu pe la poros</a></h3>
<h3><a href="$docroot$index.html" class="title">lo kibystu pe la poros</a></h3>
</td>
</tr>
<tr>
<td class="left">
$for(sidebar-links)$
<p><a href="/$sidebar-links$.html">$sidebar-links$</a></p>
<p><a href="$docroot$$sidebar-links$.html">$sidebar-links$</a></p>
$endfor$
</td>
<td class="middle">
......@@ -74,7 +74,7 @@ $endif$
<br />
<h3>license</h3>
<a rel="license" href="https://creativecommons.org/licenses/by-sa/4.0/">
<img alt="Creative Commons License" class="ccimg" src="/stc/cc-by-sa.png" />
<img alt="Creative Commons License" class="ccimg" src="$docroot$stc/cc-by-sa.png" />
</a>
<br />
This work is licensed under a <a rel="license" href="https://creativecommons.org/licenses/by-sa/4.0/">Creative Commons Attribution-ShareAlike 4.0 International License</a>.
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment