关于hexoGithub + Hexohexo

Hexo同时部署到github,coding,oschina三个

2016-10-17  本文已影响375人  蓝江_老涌

title: Hexo选用部署的三个空间介绍
date: 2016-10-11 09:52:19
categories: 网络工具
tags:
- 学习
- Hexo


三个地址布署网站的地址 coding-pages分支是coding,master分支是github与码云。


这是我的个人博客;分别布署在github码市coding上边,还有一个是码云oschina

地址分别是:

在github上 HTTP 方式访问仓库: https://github.com/ljzz/ljzz.github.io.git

在github上 SSH 方式访问仓库:git@github.com:ljzz/ljzz.github.io.git

在coding上HTTP方式访问仓库: https://git.coding.net/szcx/szcx.git

在coding上SSH 方式访问仓库 :git@git.coding.net:szcx/szcx.git

在码云oschina上:https://git.oschina.net/szcx/szcx.git

在码云oschina上:git@git.oschina.net:szcx/szcx.git

pages服务生成的网址在github上: https://ljzz.github.io

pages服务生成的网址在coding上: http://szcx.coding.me

在码云上: http://szcx.oschina.io

同时部署到三个空间。

1、修改根目录下的_config.yml文件,在最后边这样写。

deploy:
  type: git
repo: 
  github: https://github.com/ljzz/ljzz.github.io.git,master
  coding: https://git.coding.net/szcx/szcx.git,coding-pages
  oschina: https://git.oschina.net/szcx/szcx.git,master

2、在本地source文件夹中添加一个文件,在git中执行如下代码。

cd source/
touch Staticfile  #名字必须是Staticfile

3、布署
执行hexo ghexo d这两条命令。此时博客就已经部署至两个平台了。

上一篇下一篇

猜你喜欢

热点阅读