下载
安装
-
安装
node.js
-
安装
git
-
创建并进入到
blog
文件夹,执行:
$ cd blog
$ npm install -g hexo
$ hexo init
-
添加本地图片
-
修改
_config.yml
中 post_asset_folder 属性为true -
# 下载hexo-asset-image插件 $ npm install https://github.com/CodeFalling/hexo-asset-image --save
-
部署
- 生成博客静态界面
$ hexo g
$ hexo s
- 部署到gitee pages
- 创建gitee仓库
- 进入仓库,选择 服务 --> gitee pages
- 配置ssh密钥
- 修改配置文件
# 修改blog目录下的_config.yml,添加如下内容
deploy:
type: git
repository: git@github.com:PancrasL/PancrasL.gitee.io.git
branch: master
# 安装插件
$ npm install hexo-deployer-git --save
- Next主题
#For Hexo 5.0 or later
$ npm install hexo-theme-next