about summary refs log tree commit diff stats
path: root/scripts
diff options
context:
space:
mode:
Diffstat (limited to 'scripts')
-rw-r--r--scripts/compile.sh6
1 files changed, 4 insertions, 2 deletions
diff --git a/scripts/compile.sh b/scripts/compile.sh index ba89f5a..19cc962 100644 --- a/scripts/compile.sh +++ b/scripts/compile.sh
@@ -75,8 +75,10 @@ case "$FILE" in
75 --fix-head) # fix backlink head: compile.sh --fix-head a.back a.txt #{{{ 75 --fix-head) # fix backlink head: compile.sh --fix-head a.back a.txt #{{{
76 title="$(getMeta toc "$2")"; 76 title="$(getMeta toc "$2")";
77 id="$(getMeta id "$2")"; 77 id="$(getMeta id "$2")";
78 sed -i "s/__TITLE__/$title/" "$1"; 78 sed -i "/__TITLE__/c\
79 sed -i "s/__ID__/$id/" "$1"; 79 title: $title" "$1";
80 sed -i "/__ID__/c\
81 id: $id" "$1";
80 ;; #}}} 82 ;; #}}}
81 *) # bad argument {{{ 83 *) # bad argument {{{
82 echo "Bad argument"; 84 echo "Bad argument";