Created
January 5, 2014 11:58
-
-
Save acairns/8267431 to your computer and use it in GitHub Desktop.
Bash script to publish Jekyll post from _drafts into _posts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
if [ -z "$1" ] | |
then | |
echo "No draft file found" | |
exit | |
fi | |
mv $1 _posts/`date +"%Y-%m-%d"`-`basename $1` |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
You might be interested in this: https://github.com/MartinThoma/MartinThoma.github.io/blob/source/publish.py