Hexo 小姿势
在本地启动 hexo server
(ctrl + c 停止)
1 | hexo s |
创建新的博客文章 new blog
1 | hexo n "文章名称" |
生成文件并部署至仓库 deploy
1 | hexo d |
部署的信息在 _config.yml 文件最下的 deploy
// _config.yml 示例 (记得冒号后要有空格)
1 | # Deployment |
hexo 小问题
当node 版本过高时会产生以下 Warning
1 | (node:13888) Warning: Accessing non-existent property 'lineno' of module exports inside circular dependency |
官方的 issues https://github.com/stylus/stylus/issues/2534
解决方案
不用改变node的版本
找到项目中的此文件: \node_modules\stylus\lib\nodes\index.js 在最前处添加如下代码即可
1 | exports.lineno = null; |
后续问题
结果还是有问题
博客部署出错了 详情如下
1 | FATAL Something's wrong. Maybe you can find the solution here: https://hexo.io/docs/troubleshooting.html |
最终方案
下载一个 nodejs 的 12.x 的版本
再部署就没有任何问题了
还有问题就把高版本的 nodejs 删除