【问题标题】:Fails to run Gruntfile.js in Visual Studio 2015 Update 2无法在 Visual Studio 2015 Update 2 中运行 Gruntfile.js
【发布时间】:2016-04-20 18:52:04
【问题描述】:

升级到 Visual Studio 2015 Update 2 后,我无法加载我的 gruntfile.js。当我打开“Task Runner Explorer”并尝试刷新 gruntfile.js 时,它会在我的输出窗口中写入以下内容:

无法运行“(PATH)\Gruntfile.js”... cmd.exe /c grunt -b "(PATH)" --gruntfile "(PATH)\Gruntfile.js" --tasks "C:\Program Files (x86)\Microsoft Visual Studio 14.0\Common7\IDE\Extensions\Microsoft \Web Tools\TaskRunnerExplorer\Scripts" vs-grunt-task-reader

有什么想法吗?

【问题讨论】:

  • 关注@spender!谢谢!

标签: visual-studio visual-studio-2015 gruntjs task-runner-explorer


【解决方案1】:

看起来你删除/移动/丢失了你的 nodejs 包,所以它们需要重新安装。

在包含package.json 的文件夹中从命令行运行npm install

【讨论】:

  • 谢谢,帮了大忙。
【解决方案2】:

我在 gruntfile.js 中有一个语法错误,但我怎么知道 grunt 没有告诉我任何事情。我恢复了 grunt 文件,它工作了。

【讨论】:

    猜你喜欢
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2017-10-03
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    相关资源
    最近更新 更多