git clone again

1
2
3
4
5
6
7
1. install node
2. install git
3. ssh-keygen
4. git config --global user.name "xyzio"
5. git config --global user.email "xyzio@gmail.com"
6. git config --global http.postBuffer 1048576000
7. npm install hexo-cli -g

第一步: 在A电脑上部署了一切

第二步: 在B电脑上建立了同步环境

  1. 在hexoblog目录下git init
  2. 新建hexoblog.github.io目录, 以下操作在该目录下进行.
  3. git init
  4. git remote add origin https://github.com/xyzio/xyzio.github.io.git
  5. git fetch –all
  6. git reset –hard origin/hexo
  7. 拷贝node_modules, public, themes/next到相应的目录
  8. 运行myhexo.sh大招

ps: 在B电脑上, git clone, npm install, 编辑修改, git add . , git commit -m “update”, git push -u origin blogsource. —20180318

以下才是日常 下班前在B电脑运行zhexo cgd gitamp.sh大招, 回到家在A电脑运行git pull. 依此循环.

hexo 多终端同步博客: 这篇博文应该也是对的. ____________________

A电脑上把一切都弄好, 包括node等环境, hexo安装配置, github的本地及远程仓库.

B电脑上先建立node等环境, hexo安装好. 然后再建立本地github的仓库, 与远程搭上关系, 再clone下来.

B电脑上如果有改动, 则myhexo.sh, 将github与B同步, 保证github上的是最新的.

回到A电脑, 先git pull.

当前网速较慢或者你使用的浏览器不支持博客特定功能,请尝试刷新或换用Chrome、Firefox等现代浏览器