blob: 135ab8796d8a3fd259744a2bff6301a94962d0b5 (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
|
#!/bin/sh
printf 'Content-Type: text/html\r\n\r\n'
cat << EOF
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8" />
<title>Runxi Yu's Hyperlog</title>
<link rel="stylesheet" href="./style.css" />
<link rel="icon" href="./favicon.ico" sizes="any" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<meta name="theme-color" content="#241504" />
<meta name="color-scheme" content="light dark">
</head>
<body>
<header>
<h1>Runxi Yu's Hyperlog</h1>
<p style="font-style:italic;position:absolute;right:var(--margin-width);">
EOF
TZ='Asia/Shanghai' date -r /srv/hlog/runxiyu.hlog '+%Y-%m-%d %H:%M:%S %Z'
cat << EOF
</p>
</header>
<article>
<pre style="margin-top: 3rem;">
EOF
sed 's/&/\&/g; s/</\</g; s/>/\>/g; s/"/\"/g; s/'"'"'/\'/g' /srv/hlog/runxiyu.hlog
cat << EOF
</pre>
</article>
<footer>
<ul role="list">
<li><a href="./">Home</a></li>
<li>Runxi Yu</li>
<li><a rel="license" href="./pubdom.html">Public Domain</a></li>
</ul>
</footer>
</body>
</html>
EOF
|