commit 0d22decc2273c8ee960ffe97fad9a40746e2b6f8 parent a501da57f7ede94525ea100787d3725d5bb2ca65 Author: Jake Bauer <jbauer@paritybit.ca> Date: Fri, 14 Feb 2020 22:32:20 -0500 Actually write awk output to the file instead of stdout Diffstat:
M | publish | | | 5 | +++-- |
1 file changed, 3 insertions(+), 2 deletions(-)
diff --git a/publish b/publish @@ -95,8 +95,9 @@ fi # Update the relevant category page if [ $publishBlog ]; then - awk -v pt="$pageTitle" -v bp="$basePage" -v f="$filename" -v d="$miniDate" \ - '{print} /^<ul>/ && !n {print " <li>"d" <a href=\""bp"/"f"\">"pt"</a></li>"; n++}' pages/$basePage.md + awk -v pt="$pageTitle" -v bp="$basePage" -v f="$filename" -v d="$miniDate"\ + '{print} /^<ul>/ && !n {print " <li>"d" <a href=\""bp"/"f"\">"pt"</a></li>"; n++}'\ + pages/"$basePage".md > tmp.md && mv tmp.md pages/"$basePage".md elif [ $publishProject ]; then while true; do read -p "Is this a web-utility? " yn