在win10系统下,使用npm安装hexo失败
git和node.js都是最新版本
日志如下
```$ npm install hexo-cli -g
C:\Users\leebr\AppData\Roaming\npm\hexo -> C:\Users\leebr\AppData\Roaming\npm\node_modules\hexo-cli\bin\hexo
[email protected] install C:\Users\leebr\AppData\Roaming\npm\node_modules\hexo-cli\node_modules\dtrace-provider
node scripts/install.js
'node' ▒▒▒▒▒ڲ▒▒▒▒ⲿ▒▒▒Ҳ▒▒▒ǿ▒▒▒▒еij▒▒▒
▒▒▒▒▒▒▒▒▒ļ▒▒▒
[email protected] postinstall C:\Users\leebr\AppData\Roaming\npm\node_modules\hexo-cli\node_modules\hexo-util
npm run build:highlight
'npm' ▒▒▒▒▒ڲ▒▒▒▒ⲿ▒▒▒Ҳ▒▒▒ǿ▒▒▒▒еij▒▒▒
▒▒▒▒▒▒▒▒▒ļ▒▒▒
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: [email protected] (node_modules\hexo-cli\node_modules\fsevents):
npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for [email protected]: wanted {"os":"darwin","arch":"any"} (current: {"os":"win32","arch":"x64"})
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: [email protected] (node_modules\hexo-cli\node_modules\dtrace-provider):
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: [email protected] install: node scripts/install.js
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: Exit status 1
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! [email protected] postinstall: npm run build:highlight
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the [email protected] postinstall script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
npm ERR! A complete log of this run can be found in:
npm ERR! C:\Users\leebr\AppData\Roaming\npm-cache_logs\2017-09-02T08_20_10_072Z-debug.log
```
Close as duplicate with https://github.com/hexojs/hexo-cli/issues/23
I tried these methods, but it was useless
@NoahDragon
hi, l have solved this problem, cause l ran this command by git bash.but there was some bugs l don't know which makes the installation of hexo failed. so it works when l use the CMD to run this command . Thanks for your reply.@NoahDragon
@L-Gravel Glad you figure it out. 👍
@L-Gravel ,I search for the solution for over three hours.At last, It is solved just run by CMD.....Unbelievable...and Happy...
Most helpful comment
hi, l have solved this problem, cause l ran this command by git bash.but there was some bugs l don't know which makes the installation of hexo failed. so it works when l use the CMD to run this command . Thanks for your reply.@NoahDragon