首页 > 技术文章 > hexo搭建博客上传至github

xiaoyucoding 2018-01-04 01:58 原文

准备工作

  • ssh key 要先申请好,并且添加至github的ssh库中
  • 安装插件 hexo-deployer-git
npm install hexo-deployer-git --save

配置

配置 _config.yml 文件

deploy:
  type: git
  repository: git@github.com:username/username.github.io.git
  branch: master

提交

$ hexo generate
$ hexo deploy

推荐阅读