diff options
author | Hsieh Chin Fan <pham@topo.tw> | 2024-12-12 17:07:39 +0800 |
---|---|---|
committer | Hsieh Chin Fan <pham@topo.tw> | 2024-12-12 17:07:39 +0800 |
commit | 43f092aeba8ff4b345efbfedece63cb437fc1518 (patch) | |
tree | 900c4f656c4308b9b4fd4894261e7b1c870c20f3 /www | |
parent | 0927ec1d63b208bd22e78d01b4cd0f7103f29eee (diff) |
update
Diffstat (limited to 'www')
-rwxr-xr-x | www/scripts/build.sh | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/www/scripts/build.sh b/www/scripts/build.sh index f5f50c9..e3757ac 100755 --- a/www/scripts/build.sh +++ b/www/scripts/build.sh | |||
@@ -195,6 +195,9 @@ for file in $files; do | |||
195 | # make html file for draft | 195 | # make html file for draft |
196 | h1="$(<<<"$content" get_frontmatter | sed -n 's/^title *//p')" | 196 | h1="$(<<<"$content" get_frontmatter | sed -n 's/^title *//p')" |
197 | comment="$(<<<"$content" get_frontmatter | sed -n 's/^comment *//p')" | 197 | comment="$(<<<"$content" get_frontmatter | sed -n 's/^comment *//p')" |
198 | |||
199 | # add original content to $output_dir | ||
200 | # and generate html file with <h1> | ||
198 | echo "$content" \ | 201 | echo "$content" \ |
199 | | tee $output_dir/${file#${input_dir}/} \ | 202 | | tee $output_dir/${file#${input_dir}/} \ |
200 | | { [ -n "$h1" ] && echo "# $h1"; cat; } \ | 203 | | { [ -n "$h1" ] && echo "# $h1"; cat; } \ |