主题安装
nmp安装
1
| npm i hexo-theme-anzhiyu
|
应用主题
打开 Hexo 根目录下的 config.yml, 找到以下配置项,把主题改为anzhiyu
# Extensions
## Plugins: https://hexo.io/plugins/
## Themes: https://hexo.io/themes/
theme: anzhiyu
npm install hexo-renderer-pug hexo-renderer-stylus --save
# 无法安装可以使用cnpm进行安装
npm install hexo-renderer-pug hexo-renderer-stylus --save --registry=http://registry.npmmirror.com
1 2 3 4 5 6
| ### 覆盖配置 覆盖配置可以使主题配置放置在 anzhiyu 目录之外,避免在更新主题时丢失自定义的配置。
通过 Npm 安装主题的用户可忽略,其他用户建议学习使用。
macos/linux 在博客根目录运行
|
cp -rf ./themes/anzhiyu/_config.yml ./_config.anzhiyu.yml
hexo cl
hexo g
hexo s
```