- node.js安装
- git安装
 
- cnpm安装: - 1 - npm install -g cnpm --registry-https://registry.npm.taobao.org 
- hexo安装: - 1 - cnpm install -g hexo-cli - p.s.注意在命令行窗口cmd中执行 - npm:全称是 Node Package Manager 详细解释可见npm 是干什么的? 
 cnpm:由于npm下载速度过慢,Alibaba为方便程序员们设置的镜像>来自官网:“这是一个完整 http://npmjs.org 镜像,你可以用此代替官方版本(只读),同步频率目前为 10分钟 一次以保证尽量与官方服务同步。
 
- 创建博客文件夹:  1 mkdir blog 
- 进入blog目录:    1 cd blog\ 
 
- 创建博客文件夹:  
- 博客初始化:  1 hexo init 
- 博客启动:    1 hexo s 
 
- 博客初始化:  
- 博客远端部署: - 创建repository:注意名字必须为你的Github用户名.github.io 
- 配置 SSH key 
- 测试是否成功: - 1 - ssh -T git@github.com 
- 配置 Git 提交的用户信息: - 1 - git config --global user.name "Eloi0424" // 你的github用户名,非昵称 
- 1 - git config --global user.email "xxx@qq.com" // 填写你的github注册邮箱 
 
- 将 Hexo 博客部署到 Github 上 
- 关于hexo d后出现ERROR Deployer not found git的解决办法 - 修改站点配置文件config.yml - 1 
 2
 3
 4- deploy: 
 type: git
 repo: git@github.com:lanlan2017/lanlan2017.github.io.git # Github pages地址
 branch: master
- 由于未安装 hexo-deployer-git 
 可通过- 1 - cnpm install hexo-deployer-git--save - 解决 
- 若前两种方法都无法解决,可通过 - 重装hexo
- 重装git and nodejs
 - 强调:重装完git and nodejs后一定要重装hexo 
 
 
这里推荐一个非常好的blog搭建教程Hexo博客+Next主题深度优化与定制
 
        