简体   繁体   English

可以在Build Agent上将VS 2019构建与TFS 2017混合使用吗?

[英]Possible to mix VS 2019 build with TFS 2017 on Build Agent?

We want to migrate from VS 2017 to VS 2019. We are still on TFS 2017 and want to stay there for now. 我们想从VS 2017迁移到VS2019。我们仍在TFS 2017上,现在想呆在那里。

I set up the build infrastructure a long time ago, so I am not certain anymore what the role of VS on the build agent is.. I certainly sometimes use it to manually open a solution that does not compile for unclear reasons, and I think it also was needed for some libraries. 我很早以前就建立了构建基础架构,所以我不再确定VS在构建代理上的作用是什么。我当然有时会使用它来手动打开一个由于不清楚的原因而无法编译的解决方案,我认为一些库也需要它。

I want the automated build process to use same VS as on developer machines, for consistency. 我希望自动化构建过程使用与开发人员机器上相同的VS,以保持一致性。

Can I uninstall VS 2017 and install VS 2019 on the build machine and the build will work using VS 2019? 我可以在构建机器上卸载VS 2017并安装VS 2019并使用VS 2019进行构建吗? Or more generally: can I build using the VS 2019 build infrastructure on TFS 2017 build agent? 或更笼统地说:我可以在TFS 2017构建代理上使用VS 2019构建基础结构进行构建吗?

Thank you! 谢谢!

Can I uninstall VS 2017 and install VS 2019 on the build machine and the build will work using VS 2019? 我可以在构建机器上卸载VS 2017并安装VS 2019并使用VS 2019进行构建吗? Or more generally: can I build using the VS 2019 build infrastructure on TFS 2017 build agent? 或更笼统地说:我可以在TFS 2017构建代理上使用VS 2019构建基础结构进行构建吗?

The answer is yes , just like I said in that thread : 答案是肯定的 ,就像我在那个线程中所说的那样

( I will answer this question again so that others can see the answer directly when they see this thread without having to redirect to that thread. ): 我将再次回答这个问题,以便其他人在看到该线程时可以直接看到答案,而不必重定向到该线程。 ):

Only the latest version has "full" compatibility with the latest Team Foundation Server 仅最新版本与最新Team Foundation Server具有“完全”兼容性

So, TFS 2017 have a high level of support for Visual Studio 2019 not full support. 因此,TFS 2017对Visual Studio 2019的高度支持没有完全支持。 Since the product TFS2017 was launched earlier than Visual Studio 2019, TFS could not recognize the future products. 由于产品TFS2017在Visual Studio 2019之前发布,因此TFS无法识别未来的产品。

If we want to use the VS 2019 build infrastructure on TFS 2017 build agent, we have to specify the MSBuild path when using MSBuild task to build. 如果要在TFS 2017构建代理上使用VS 2019构建基础结构,则在使用MSBuild任务进行构建时必须指定MSBuild路径。

BTW, you could custom your MSBuild task with location of MSBuild 16.0 as task group, then you can use it instead of MSBuild task, you do not have to edit that task each time. 顺便说一句,您可以使用MSBuild 16.0位置作为任务组自定义MSBuild任务,然后可以使用它代替MSBuild任务,而不必每次都编辑该任务。 But for those piplelines that are already in use, we have to modify our build definition. 但是对于那些已经使用过的管道,我们必须修改构建定义。

Hope this helps. 希望这可以帮助。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM