Octopress是一个基于Jekyll的静态博客框架,使用Jekyll搭建静态博客,需要自己编写html模板,css,js,还得自己配置路径什么的(example:Kidlet此博客就是使用Jekyll搭建的)。Octopress框架则免去这些繁琐的事,只要使用几条命令即可快速以完成一篇具有特定样式的博文。写代码般写博文,是不是很geek…
- 安装git
1sudo apt-get install git-core
配置git:1 2
$ git config --global user.name "Your Name" $ git config --global user.email your-email@address.com
查看git版本:安装配置成功。1$ git --version - 安装rvm环境
Jekyll和Octopress其实都是rvm的一个gem,所以安装Octopress之前一定要先安装了rvm,推荐链接1 or 推荐链接2.
- 安装Octopress(Ubuntu 12.04 下)
1 2 3
git clone git://github.com/imathis/octopress.git octopress cd octopress # If you use RVM, You'll be asked if you trust the .rvmrc file (say yes). ruby --version # Should report Ruby 1.9.3
安装独立组件:1 2
gem install bundler bundle install
安装Octepress的默认主题:1rake install - 发布到Github pages上
-
配置Octopress博客
Octopress有很多第三方插件,可以修改默认主题,更改默认配置等.
rake preview includes rake generate config.yml: rake generate markdown file: rake preview once you edit it, it will go into effect right now