前提你必须有一个GitHub帐号且本机安装有Git
git
1、建立一个新的仓库github
去你的https://github.com主页新建一个仓库 名字为USERNAME.github.combootstrap
USERNAME为你的username(下同)浏览器
2、安装Jekyll-Bootstrap工具
在Git Bash中输入例如如下命令 将代码clone到你本地url
git clone https://github.com/plusjade/jekyll-bootstrap.git USERNAME.github.com cd USERNAME.github.com git remote set-url origin https://github.com/itmyline/USERNAME.github.com.git git push origin masterPS:假设想clone到指定文件夹,则使用例如如下格式 git clone xxx.git "指定文件夹"
3、完毕spa
接下来Github将建立你的公开博客在 http://USERNAME.github.com.net
请參考本文搭建的bloghttp://itmyline.github.io/
命令行
假设你已经有blog在Github上?code
假设你机器上安装有jekyll,假设没有请參考Windows上安装Jekyll。
在本地执行Jekyll-Bootstrap,打开命令行工具 输入例如如下命令:
$ git clone https://github.com/plusjade/jekyll-bootstrap.git $ cd jekyll-bootstrap $ jekyll serve
浏览器中打开http://localhost:4000,咱们将能看到和搭建在github上同样的效果
做者:itmyhome
出处:http://blog.csdn.net/itmyhome1990/article/details/42028597