reduce logging

This commit is contained in:
Stavros Kois
2024-05-13 00:00:07 +03:00
committed by GitHub
parent 88c72953ea
commit 7549b73bf9

View File

@@ -25,10 +25,13 @@ is_true() {
echo "Checking front matter"
if ! grep -q "^---$" "$file_path"; then
echo "Front matter (start) not found, adding it"
# Dont trace content, as its usually too large
[ "$DEBUG" ] && set +x
content=$(cat "$file_path")
echo -e "---\n" >"$file_path"
echo -e "---\n" >>"$file_path"
echo "$content" >>"$file_path"
[ "$DEBUG" ] && set -x
fi
# Get the title from the front matter