diff --git a/make.sh b/make.sh old mode 100644 new mode 100755 index 87e010f..e831bb7 --- a/make.sh +++ b/make.sh @@ -1,2 +1,27 @@ -pandoc $1 --css $2 -s -o $3 +post() { + # check directory existence + if [ -f markdown/post/$1 ] + then + pandoc markdown/post/$1 --css bstyle.css -s -o post/${1%.*}.html + else + echo "Check parameters as well: ./make.sh fileType inputFile" + fi +} +page() { + # check for file as before + if [ -f markdown/pages/$1 ] + then + pandoc markdown/pages/$1 --css bstyle.css -s -o page/${1%.*}.html + else + echo "File \"$1\" not found in markdown/pages" + fi +} + +help() { + echo "Usage: \./make.sh fileType targetSource" + echo "fileType - \[post, page\] - specifices type of html doc to create" + echo "targetSource - the file itself that you created in the /markdown directory" +} + +"$@" diff --git a/markdown/mapping.md b/markdown/post/mapping.md similarity index 100% rename from markdown/mapping.md rename to markdown/post/mapping.md diff --git a/markdown/open.md b/markdown/post/open.md similarity index 100% rename from markdown/open.md rename to markdown/post/open.md diff --git a/markdown/phil.md b/markdown/post/phil.md similarity index 100% rename from markdown/phil.md rename to markdown/post/phil.md diff --git a/notes.md b/notes.md index f3a89a7..196c4dc 100644 --- a/notes.md +++ b/notes.md @@ -20,7 +20,4 @@ bash make.sh inputFile styleSheet outputFile # Daily Todo/Order list -1. Provide post with documentation with site details -2. Create links page -3. Create about page - +1. Finish working on script to so that I can actually get to building some stuff