重点在底部
在使用npm安装公司项目依赖包时一直报错,提示如下
ValidateSolutionConfiguration: ▒▒▒▒▒▒▒ɽ▒▒▒▒▒▒▒▒▒á▒Release|x64▒▒▒▒
MSBUILD : error MSB3428: δ▒ܼ▒▒▒ Visual C++ ▒▒▒▒▒VCBuild.exe▒▒▒▒Ҫ▒▒▒▒▒▒▒▒⣬1) ▒▒װ .NET Framework 2.0 SDK▒▒2) ▒▒װ Microsoft Visual Studio 2005▒▒▒▒ 3) ▒▒▒▒▒▒▒▒▒▒▒▒װ▒ ▒▒▒▒▒▒▒λ▒ã▒▒뽫▒▒λ▒▒▒▒ӵ▒ϵͳ·▒▒▒С▒ [D:\front\coupon-web\node_modules\node-sass\build\binding.sln]
▒▒▒▒▒▒▒▒▒▒▒Ŀ▒▒D:\front\coupon-web\node_modules\node-sass\build\binding.sln▒▒(Ĭ▒▒▒)▒IJ▒▒▒ - ʧ▒ܡ▒▒▒▒▒ʧ▒ܡ▒▒▒D:\front\coupon-web\node_modules\node-sass\build\binding.sln▒▒(Ĭ▒▒Ŀ▒▒) (1) ->
(_src_\libsass Ŀ▒▒) ->MSBUILD : error MSB3428: δ▒ܼ▒▒▒ Visual C++ ▒▒▒▒▒VCBuild.exe▒▒▒▒Ҫ▒▒▒▒▒▒▒▒⣬1) ▒▒װ.NET Framework 2.0 SDK▒▒2) ▒▒װ Microsoft Visual Studio 2005▒▒▒▒ 3) ▒▒▒▒▒▒▒▒▒▒▒▒ װ▒▒▒▒▒▒▒▒λ▒ã▒▒뽫▒▒λ▒▒▒▒ӵ▒ϵͳ·▒▒▒С▒ [D:\front\coupon-web\node_modules\node-sass\build\binding.sln] 0 ▒▒▒▒▒▒ 1 ▒▒▒▒▒▒
▒▒▒▒ʱ▒▒ 00:00:00.54
gyp ERR! build error
gyp ERR! stack Error: `C:\Windows\Microsoft.NET\Framework\v4.0.30319\msbuild.exe` failed with exit code: 1
gyp ERR! stack at ChildProcess.onExit (D:\front\coupon-web\node_modules\node-gyp\lib\build.js:258:23)
gyp ERR! stack at ChildProcess.emit (events.js:127:13)
gyp ERR! stack at Process.ChildProcess._handle.onexit (internal/child_process.js:209:12)
gyp ERR! System Windows_NT 10.0.16299
gyp ERR! command "D:\\path\\node\\node.exe" "D:\\front\\coupon-web\\node_modules\\node-gyp\\bin\\node-gyp.js" "rebuild" "--verbose" "--libsass_ext=" "--libsass_cflags=" "--libsass_ldflags=" "--libsass_library="
gyp ERR! cwd D:\front\coupon-web\node_modules\node-sass
gyp ERR! node -v v9.7.1
gyp ERR! node-gyp -v v3.6.2
gyp ERR! not ok
Build failed with error code: 1
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! node-sass@4.5.3 postinstall: `node scripts/build.js`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the node-sass@4.5.3 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\DELL\AppData\Roaming\npm-cache\_logs\2018-03-21T07_32_31_129Z-debug.log
如果安装各种插件后一直解决不了建议你在开始部分看有没有这项提示:
Downloading binary from https://github.com/sass/node-sass/releases/download/v4.5.3/win32-x64-59_binding.node
Cannot download "https://github.com/sass/node-sass/releases/download/v4.5.3/win32-x64-59_binding.node":
HTTP error 404 Not Found
如果有的话应该是你的node版本是最新的而造成的,建议你把node卸载然后安装当前官网建议安装的稳定版本,这个问题困扰了整整一天,感觉要死的节奏