As you can see, my blog are able to comment and search now!
I always think comment is very important for a blog. You can know how helpful or is there some issues in your article. Disqus is a great tool to put comment on a website. It is neat and powerful as you can see. It may be a little slow in China. But consider of my blog are mostly written in English, it is not a big deal.
The search engine I am using is Google custom search engine. Isn’t it awesome I have google’s technology on my blog? It is easy to use, too. The badness of this choice is google may take some time to put the website’s content into its index. And google is even not available in China sometimes.
Scripts to Make Life Easy
As I put the website on github page, I don’t want to upload the jekyll directory. Just the static site is enough. So I must copy the site to git repository, add, commit and then push it. It is a boring work. I write two scripts to make it easy. I don’t know if there is some other way to do this, but I’m OK with it.
update.sh: generate static site and upload to github.
newpost.sh: use vim to open a new post with current time and some meta information.
1#!/bin/bash 2 3if [ $# -lt 1 ] 4then 5 echo "newpost: You need to specify the post name." 6 exit 1 7fi 8 9POST_NAME=$1 10POST_DATE=`date +%Y-%m-%d` 11POST_DIR="./jekyll/_posts" 12FILE_NAME=`echo "$POST_DIR/$POST_DATE-$POST_NAME.md" | sed "s/ /-/g"` 13 14echo " 15--- 16layout: post 17title: $POST_NAME 18categories: misc 19tags:  20--- 21" > $FILE_NAME 22 23vim $FILE_NAME