Skip to content

Instantly share code, notes, and snippets.

@bachya
Created September 5, 2014 05:43
Shell script to create a new blog post (via Geeknote and vim)
bp () {
if [ "$#" -ne 0 ] || [ "$1" = "-h" ] || [ "$1" = "–help" ]
then
echo "Usage: $0" >&2
return 1
fi
# Fill these out with values you like.
local tag_string=“draft”
local notebook=“Sentinote”
echo -n "What is the title of the post? "
read title
python /usr/local/bin/geeknote.py create \
--title "${title}" \
--tags “${tag_string}" \
--notebook “${notebook}" \
--content WRITE
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment