cleaned up makefile a bit

This commit is contained in:
Medium Fries 2018-09-21 13:35:17 -07:00
parent a04e7a7af7
commit d12e075db7

View File

@ -1,5 +1,4 @@
# not only updates the post but inserts the description found in desc.md into the index.md then recompiles
# only gets called if
# builds a sick post
post() {
# check directory existence
if [ -f markdown/post/$1 ]
@ -7,22 +6,22 @@ post() {
# compile the new post and drop it in ./post/
pandoc markdown/post/$1 --css bstyle.css -s -o post/${1%.*}.html
else
# error message incase file was not found
echo "File \"$1\" not found in markdown/post"
fi
}
# builds a site "page" like the about page, links page etc
page() {
# we want to enforce maintainence of directory structure
if [ -f markdown/pages/$1 ]
then
# compile then drop in ./page/
pandoc markdown/pages/$1 --css bstyle.css -s -o page/${1%.*}.html
else
echo "File \"$1\" not found in markdown/pages"
fi
}
# literally just updates the index file nothing else
index() {
pandoc index.md --css style.css -s -o index.html # typing succs
}