Chinaunix首页 | 论坛 | 博客
  • 博客访问: 713040
  • 博文数量: 235
  • 博客积分: 4309
  • 博客等级: 中校
  • 技术积分: 2325
  • 用 户 组: 普通用户
  • 注册时间: 2011-01-17 11:25
个人简介

If you don\\\\\\\\\\\\\\\'t wanna do it, you find an EXCUSE; if you do, you\\\\\\\\\\\\\\\'ll find a WAY :-)

文章分类

全部博文(235)

文章存档

2014年(3)

2013年(2)

2012年(31)

2011年(199)

分类: LINUX

2011-08-29 20:38:19

Preface

    国内用户访问 gitcafe 的响应速度明显优于 github,后者时而访问不了;使用gitcafe 搭建个人blog颇受天朝子民欢迎。

CheckList

  1. 注册 gitcafe ,成为免费用户。
  2. 安装 git node.js
  3. 创建 gitcafe-pages ,添加SSH支持。
  4. 绑定个人域名
  5. 安装、部署 hexo
  6. 生成文章
  7. 同时使用 github 和 gitcafe 同步 blog
说明:本文所有动作,基于 os x 10.10.3 完成。

Step1、注册gitcafe

Step2、软件安装

Step3、创建 gitcafe pages

  1. $ mkdir gitcafe;cd gitcafe
  2. $ mkdir baby;cd baby
  3. $ git init
  4. $ echo 'Hello, world' > index.html
  5. $ echo 'readme' > README.md

  6. $ git add .
  7. $ git commit -a -m 'Hello, world'
  8. $ git remote add origin 'git@gitcafe.com:baby/baby.git'
  9. $ git checkout -b gitcafe-pages
  10. $ git push origin gitcafe-pages

Step4、见 hexo github

Step5、见 hexo github

Step6、见 hexo github

Step7、同时使用 github 和 gitcafe 同步 blog


  1. $ mkdir ~/hexo.baby1.com.github
  2. $ mkdir ~/hexo.baby2.com.gitcafe

  3. 说明:将两个网站分别部署,baby1 采用 github 同步, baby2 采用 gitcafe 同步;hexo 安装部署流程见 Step5~6 。
  4. 值得注意的是,github pages 默认使用master分支同步,而 gitcafe 部署分支使用的是 gitcafe-pages 。

  5. # gitcafe

    deploy:

      type: git

      repo:

      branch: gitcafe-pages

    # github

  6. deploy:

      type: git

      repo:

      branch: master





Reference


阅读(716) | 评论(0) | 转发(0) |
给主人留下些什么吧!~~