使用hexo在GIT上创建博客
Posted 寒总儿阿
tags:
篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了使用hexo在GIT上创建博客相关的知识,希望对你有一定的参考价值。
首先要建立git账户并创建git仓库
安装ndoe和npm并验证:
node -v
npm-v
安装hexo:
cnpm install -g hexo-cli
验证是否安装成功:
hexo -v
生成博客:
hexo init

启动博客:
hexo s

新建博文:
hexo n "第一篇博文"
生成博文:
hexo g

新建blog文件夹,下载hexo部署工具
npm install --save hexo-deployer-git

修改_config.yml文件:

_config.yml文件最底部修改为:
deploy:
type: git
repo: [git仓库地址]
branch: master
部署到远端(需要输入正确git账户密码)
hexo d

访问仓库名=访问博客地址
以上是关于使用hexo在GIT上创建博客的主要内容,如果未能解决你的问题,请参考以下文章