#前言:安装homebrew以及git(https://git-scm.com/)

1
/usr/bin/ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"

#安装node.js以及npm

1
2
brew install node
brew install npm

#进入blog直接运行

1
hexo s

出现报错:
upload successful
尝试安装hexo-renderer-sass

1
sudo npm install hexo-renderer-sass

成功安装后依旧报错

#换源

更换cnpm源 并尝试国内主流解决方案

1
2
sudo npm i cnpm -g --registry=http://registry.npm.taobao.org
cnpm install node-sass@latest

成功解决

#其他

upload successful
问题的原因是node和hexo插件的版本…在node8.x的版本中,fs.SyncWriteStream被弃用
但是admin插件真的很好用(x 而且截图插入也很方便
所以依旧默默忍受着这行报错…