如何将 Visual Studio 2017 与 TFS Visual Studio 构建步骤一起使用 [英] How to use Visual Studio 2017 with TFS Visual Studio Build Step

查看:38
本文介绍了如何将 Visual Studio 2017 与 TFS Visual Studio 构建步骤一起使用的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在运行 TFS 2015 并且正在使用 Visual Studio 构建步骤.在开发机器上,我转而使用 Visual Studio 2017,因此我还想将 Visual Studio 2017 用于 TFS 构建.

I am running TFS 2015 and are using the Visual Studio Build Step. On the developemnt machines I moved to use Visual Studio 2017 so I also want to use Visual Studio 2017 for the TFS builds.

我在构建服务器上安装了 Visual Studio 2017 并重新启动了构建代理.但是,Visual Studio 2017 不会显示在代理的功能中,也不会显示在构建步骤中的 Visual Studio 版本列表中.

I installed Visual Studio 2017 on the build server and restarted the build agent. However Visual Studio 2017 does not show up in the capabilities of the agent and it also does not show in the list of Visual Studio versions in the build step.

我知道我可以在构建步骤中从 Visual Studio 版本列表中选择最新",但这仍将使用 VS 2015,因为代理不知道它有 VS 2017.

I know I can choose "latest" from the list of Visual Studio version in the build step, but this will still use VS 2015 as the agent does not know that it has VS 2017.

如何确保 TFS2015 中的 Visual Studio 构建步骤使用 Visual Studio 2017?

How can I make sure that the Visual Studio Build Step in TFS2015 uses Visual Studio 2017?

推荐答案

可以使用MSBuild task代替Visual Studio Build Step,然后指定MSBuild 15.0的位置:

You can use MSBuild task instead of Visual Studio Build Step, then specify the location of MSBuild 15.0:

这篇关于如何将 Visual Studio 2017 与 TFS Visual Studio 构建步骤一起使用的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
相关文章
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆