New post for making detergent and stuff

This commit is contained in:
shockrah committed 2023-07-05 21:43:00 -07:00
1 parent 13fdadd1bf
commit 3545f76842
2 files changed
+80 -2

No files matched your search

+3 -2
View File
@@ -2,9 +2,10 @@
[[ "$1" = "" ]] && echo No filename given for new post\! && exit 1
file="$(basename $1)"
name="$(basename -s .md $1)"
cat << EOF | tee content/posts/"$file.md"
echo Creating new post content/posts/$name.md with metadata:
cat << EOF | tee content/posts/"$name.md"
---
title: $(basename -s .md "$file")
date: $(date '+%F')