summaryrefslogtreecommitdiff
path: root/content
diff options
context:
space:
mode:
Diffstat (limited to 'content')
-rwxr-xr-xcontent/post/make_post.sh22
1 files changed, 22 insertions, 0 deletions
diff --git a/content/post/make_post.sh b/content/post/make_post.sh
new file mode 100755
index 0000000..d16f766
--- /dev/null
+++ b/content/post/make_post.sh
@@ -0,0 +1,22 @@
+#!/bin/bash
+
+post_date=`date +'%Y-%m-%d'`
+canonical_title=`echo $1 | awk '{ gsub(" ", "-", $0); print tolower($0) }'`
+file_name=${post_date}__${canonical_title}.md
+
+read -r -d '\0' blog_note << EOM
++++
+author = "Adam Olech"
+title = "$1"
+date = "$post_date"
+description = "$1"
+tags = [
+ "fill",
+ "me",
+]
++++
+
+\0
+EOM
+
+echo "$blog_note" > $file_name