Category: /knowledge /front_end
Tags: front_end


New installation instruction @


gem install jekyll
gem install gihub-pages


Ubuntu 14.04 has Ruby 1.9.x which makes gem and Jekyll installation much easier.

Install ruby, nodejs and jekyll:

  sudo apt-get install ruby ruby-dev make gcc nodejs
  sudo gem install jekyll --no-rdoc --no-ri
  sudo gem install github-pages --no-rdoc --no-ri

If you see ‘zlib missing’ error message, need to install zlib

  sudo aptitude install zlib1g-dev 

Check installed version:

$ jekyll -v
jekyll 2.5.3

Stack Overflow has instruction to install Ruby 2.0+.

Ubuntu 12.04

Ubuntu 12.04 comes with Ruby 1.8.x which is kind of old for Jekyll 2.5 on github pages. The installation requires extra workaround steps.

Basic operations

Create a new site

jekyll new your-new-site
cd your-new-site

Site generation

jekyll build 
jekyll b

If you see bundle error messages, try bundle exec jekyll b.

Start a local server to check,

jekyll serve
bundle exec jekyll s

# add this line in .bashrd to save typing
alias jk='bundle exec jekyll serve --watch --port 8000'

Then in the site folder, run jk, open a browser at http://localhost:8000



  • 如果看不到评论部分, 请暂时关掉adblock in Firefox/Chrome
  • 本网站使用Javascript实现评论功能, 此处外链对提高您的网站PR没有帮助. (潜台词: 请不要灌水, 谢谢)