"noexcept" 运行 gulp 时 VSO 生成警告

"noexcept" warning on VSO build when running gulp

我最近在我的 VSO 构建中启用了 gulp 运行,但我看到它在构建时输出了一堆警告,例如

'noexcept' used with no exception handling mode specified; termination on exception is not guaranteed. Specify /EHsc [xxxxx.WebClient\node_modules\karma\node_modules\socket.io\node_modules\engine.io\node_modules\ws\node_modules\utf-8-validate\build\validation.vcxproj]
'noexcept' used with no exception handling mode specified; termination on exception is not guaranteed. Specify /EHsc [xxxxx.WebClient\node_modules\karma\node_modules\socket.io\node_modules\engine.io\node_modules\ws\node_modules\bufferutil\build\bufferutil.vcxproj]

如何解决这些警告,或者至少禁用它们。

这里有一篇博客提供了将gulp添加到Visual Studio在线XAML构建的详细步骤,您可以按照它添加一个构建gulp:http://blogs.msdn.com/b/nicktrog/archive/2015/03/05/adding-gulp-to-visual-studio-online-builds.aspx

博客总结:

您需要将文件夹“js”添加到您的 Web 应用程序项目中,其中将包含您的客户端 JavaScript 代码。

然后您需要通过向您的 Web 应用程序项目添加 3 个文件来为您的 Web 应用程序配置 gulp,以便在预构建脚本和 post 构建脚本中调用 grunt/gulp/bower 命令:

•gulpfile.js:包含描述所有需要执行的构建任务的gulp脚本。

•package.json:包含 gulp 脚本

的包依赖列表

•clientcompile.bat(注意:你也可以使用PowerShell):安装依赖包然后调用gulp命令的批处理脚本

之后,在 VSO 中对构建进行排队。

希望对您有所帮助。