summaryrefslogtreecommitdiffhomepage
path: root/www
diff options
context:
space:
mode:
Diffstat (limited to 'www')
-rwxr-xr-xwww/scripts/build.sh6
-rw-r--r--www/templates/head.html1
2 files changed, 4 insertions, 3 deletions
diff --git a/www/scripts/build.sh b/www/scripts/build.sh
index 23c4a70..8bf6ffc 100755
--- a/www/scripts/build.sh
+++ b/www/scripts/build.sh
@@ -29,7 +29,7 @@ comment_block() {
29 <<-COMMENT cat 29 <<-COMMENT cat
30 <div style="border-radius: 6px; background: lightyellow"> 30 <div style="border-radius: 6px; background: lightyellow">
31 <a style="display: inline-block; margin: 0.5em 0.5em 0 0; float: right" href="mailto:comment@topo.tw?subject=Comment on page: ${path}">[Comment on this page]</a> 31 <a style="display: inline-block; margin: 0.5em 0.5em 0 0; float: right" href="mailto:comment@topo.tw?subject=Comment on page: ${path}">[Comment on this page]</a>
32 <object type="text/html" data="/${path/.html}.comment.html" onload="observeResize(this)" style="width: 100%;"></object> 32 <object type="text/html" data="/${path/%html/comment.html}" onload="observeResize(this)" style="width: 100%;"></object>
33 <script> 33 <script>
34 function observeResize(commentBlock) { 34 function observeResize(commentBlock) {
35 const doc = commentBlock.contentDocument.documentElement 35 const doc = commentBlock.contentDocument.documentElement
@@ -70,7 +70,7 @@ html() {
70 70
71latest_posts() { 71latest_posts() {
72 (IFS=$'\n'; echo "${index_list[*]}") | sort -r | head -20 | while read date path title; do 72 (IFS=$'\n'; echo "${index_list[*]}") | sort -r | head -20 | while read date path title; do
73 echo "- <time datetime="$date">$date</time> [$title](/$path)" 73 echo "- <time title=\"$(date --rfc-email -d "$date")\" datetime=\"$date\">$date</time> [$title](/$path)"
74 done 74 done
75} 75}
76 76
@@ -186,7 +186,7 @@ for file in $files; do
186 <<<"$content" check_frontmatter || continue 186 <<<"$content" check_frontmatter || continue
187 187
188 # log 188 # log
189 echo -e "\033[1K\r$((counter+=1))/$total \t\t processing $path" 189 echo -e "\033[1K\r$((counter+=1))/$total\t\tprocessing $path"
190 190
191 # add original content to $OUTPUT_DIR 191 # add original content to $OUTPUT_DIR
192 # and generate html file with <h1> 192 # and generate html file with <h1>
diff --git a/www/templates/head.html b/www/templates/head.html
index ede99c9..6e297c1 100644
--- a/www/templates/head.html
+++ b/www/templates/head.html
@@ -7,4 +7,5 @@
7 7
8 <link rel="stylesheet" href="/style.css"> 8 <link rel="stylesheet" href="/style.css">
9 <link rel="icon" href="/favicon.ico" type="image/x-icon"> 9 <link rel="icon" href="/favicon.ico" type="image/x-icon">
10 <link rel="alternate" type="application/rss+xml" href="/feed.rss" />
10</head> 11</head>