Added check to make sure the user is using Markdown formatting with newpost()
parent
12d8abda06
commit
14c78bff05
|
|
@ -15,6 +15,8 @@ newpost() {
|
||||||
|
|
||||||
OPTIONS="Text Quote Image Audio Video"
|
OPTIONS="Text Quote Image Audio Video"
|
||||||
|
|
||||||
|
if [[ $JEKYLL_FORMATTING = "markdown" ]]
|
||||||
|
then
|
||||||
select OPTION in $OPTIONS
|
select OPTION in $OPTIONS
|
||||||
do
|
do
|
||||||
if [[ $OPTION = "Text" ]]
|
if [[ $OPTION = "Text" ]]
|
||||||
|
|
@ -47,6 +49,7 @@ newpost() {
|
||||||
break
|
break
|
||||||
fi
|
fi
|
||||||
done
|
done
|
||||||
|
fi
|
||||||
|
|
||||||
# Get the title for the new post
|
# Get the title for the new post
|
||||||
|
|
||||||
|
|
@ -92,6 +95,8 @@ newpost() {
|
||||||
|
|
||||||
# Generate template text based on the post type
|
# Generate template text based on the post type
|
||||||
|
|
||||||
|
if [[ $JEKYLL_FORMATTING = "markdown" ]]
|
||||||
|
then
|
||||||
if [[ $POST_TYPE = "Text" ]]
|
if [[ $POST_TYPE = "Text" ]]
|
||||||
then
|
then
|
||||||
true
|
true
|
||||||
|
|
@ -118,6 +123,7 @@ newpost() {
|
||||||
then
|
then
|
||||||
echo "<video src=\"/path/to/video\" controls=\"controls\"></video>" >> $FNAME
|
echo "<video src=\"/path/to/video\" controls=\"controls\"></video>" >> $FNAME
|
||||||
fi
|
fi
|
||||||
|
fi
|
||||||
|
|
||||||
# Open the file in your favorite editor
|
# Open the file in your favorite editor
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue