nodevars.bat未被识别为内部或外部命令

时间:2015-12-15 13:53:57

标签: node.js tfsbuild apache-cordova

尝试在TFS Build服务器上构建项目时,我收到了这个奇怪的nodejs错误。

有人可以解释我为什么会收到此错误? 在TFS构建期间,我的所有Cordova Tools项目都出现此错误。

非常感谢!

> C:\Program Files
> (x86)\MSBuild\Microsoft\VisualStudio\v14.0\ApacheCordovaTools\vs-mda-targets\Microsoft.MDA.FileMirroring.targets
> (287): '"C:\Program Files (x86)\nodejs"\nodevars.bat' is not
> recognized as an internal or external command,  C:\Program Files
> (x86)\MSBuild\Microsoft\VisualStudio\v14.0\ApacheCordovaTools\vs-mda-targets\Microsoft.MDA.FileMirroring.targets
> (287): operable program or batch file.  C:\Program Files
> (x86)\MSBuild\Microsoft\VisualStudio\v14.0\ApacheCordovaTools\vs-mda-targets\Microsoft.MDA.FileMirroring.targets
> (287): '"C:\Program Files (x86)\nodejs"\node' is not recognized as an
> internal or external command,  C:\Program Files
> (x86)\MSBuild\Microsoft\VisualStudio\v14.0\ApacheCordovaTools\vs-mda-targets\Microsoft.MDA.FileMirroring.targets
> (287): operable program or batch file.  C:\Program Files
> (x86)\MSBuild\Microsoft\VisualStudio\v14.0\ApacheCordovaTools\vs-mda-targets\Microsoft.MDA.FileMirroring.targets
> (287): Error installing local npm package.

1 个答案:

答案 0 :(得分:0)

好的,我找到了解决方案。感谢Molda,一点点.. 环境变量中包含错误的安装文件夹。

它指的是

  

C:\ Program Files(x86)\ nodejs

它已安装在

  

C:\ Program Files \ nodejs

谢谢Molda!