曾经安装了某些 hexo 插件,某一天觉得是个累赘,那么如何卸载呢?
查看插件
1 2 3 4 5 6 7 8 9
|
├─┬ hexo-generator-tag@0.2.0 │ ├── hexo-pagination@0.0.2 deduped │ └── object-assign@4.1.1 deduped ├─┬ hexo-qiniu-sync@1.4.7 │ ├─┬ chokidar@1.7.0 │ │ ├─┬ anymatch@1.3.2 │ │ │ ├── micromatch@2.3.11 deduped │ │ │ └── normalize-path@2.1.1 deduped │ │ ├── async-each@1.0.1
|
我要删除的是_hexo-qiniu-sync@1.4.7_,我不仅用不到它,还觉得它浪费 hexo 启动时间:
1 2 3 4 5 6 7 8 9
|
zhoupqcom:blog zhoupq$ blognew "卸载 hexo 插件"
INFO ----------------------------------------------------------- INFO qiniu state: online INFO qiniu sync: true INFO qiniu local dir: static INFO qiniu url: http://xxxxxxxxxxx.clouddn.com/static INFO ----------------------------------------------------------- INFO Created: ~/zhoupq.com/blog/source/_posts/卸载 hexo 插件.md
|
npm 卸载
1
|
npm uninstall hexo-qiniu-sync@1.4.7
|
删除相关配置和文件
- 配置文件中有 PLugins 模块,删除对应的插件设置;
- 删除 node_modules/ 目录下对应的插件文件
1 2 3 4 5
|
zhoupqcom:blog zhoupq$ hexo clean ERROR Plugin load failed: hexo-qiniu-sync TypeError: Cannot read property 'secret_file' of undefined at Object.<anonymous> (/Users/zhoupq/zhoupq.com/blog/node_modules/hexo-qiniu-sync/config.js:8:22) at Module._compile (module.js:635:30)
|
1
|
zhoupqcom:node_modules zhoupq$ rm -rf ./hexo-qiniu-sync
|
1 2 3 4 5 6 7 8 9 10 11
|
zhoupqcom:blog zhoupq$ hexo server INFO Start processing [Browsersync] Access URLs: ---------------------------------- UI: http://localhost:3001 ---------------------------------- UI External: http://localhost:3001 ---------------------------------- INFO ---- START COPYING TAG CLOUD FILES ---- INFO ---- END COPYING TAG CLOUD FILES ---- INFO Hexo is running at http://localhost:4000/. Press Ctrl+C to stop.
|