## [warning]找不到Visual Studio版本"14.0".退回到版本"15.0" [英] ##[warning]Visual Studio version '14.0' not found. Falling back to version '15.0'

查看:223
本文介绍了## [warning]找不到Visual Studio版本"14.0".退回到版本"15.0"的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我的项目需要与MSbuild 14.0(Visual Studio 2015)一起运行,但这仅需要Visual Studio \ 2017 \ Community \ MSBuild \ 15.0 \ Bin \ msbuild.exe.

My project need to be run with MSbuild 14.0(visual studio 2015) but this is taking only Visual Studio\2017\Community\MSBuild\15.0\Bin\msbuild.exe .

我在Build Agent上安装了Visual Studio Community 2017,VS 2015 Web和Desktop Express. 构建代理的能力-

I have installed visual studio community 2017,VS 2015 web and Desktop express on my Build Agent. Capabilities of build agent-

任务配置-

此配置向我发出警告-

如何在Visual Studio构建任务中使用MSBuild 14.0 ??这是与MSbuild任务一起运行的..

How can I use MSBuild 14.0 with Visual Studio build task .?? This is running with MSbuild task..

在此先感谢.. !!

Thanks in Advance ..!!

推荐答案

[警告]找不到Visual Studio版本"14.0".回退到版本"15.0"

由于我没有在构建代理上安装Visual Studio 2015 Express for Desktop和Web,所以我不确定Visual Studio 2015 Express for Desktop和Web是否与构建代理兼容.

Since I do not install Visual Studio 2015 Express for Desktop and Web on my build agent, I am not sure whether Visual Studio 2015 Express for Desktop and Web is compatible with build agent.

但是我发现一个线程对此,您可以检查已接受答案的评论:

But I found a thread about it, you can check the comment on the accepted answer:

就是这样!由于某些原因,VS2015 Express无法安装ShellFolder或InstallDir项!我担心代理脚本会识别它,但拒绝注册它,因为不允许我们将其用于自动化构建.我现在觉得比较舒服.

That's it! For some reason VS2015 Express does not install the ShellFolder or InstallDir keys! I was worried that the agent script recognised it but refused to register it because we are not allowed to use it for automated builds. I feel more comfortable with it now.

事实证明,这还不是全部.当我添加"Visual Studio 生成"任务,现在可以执行,但是如果我看起来更多的话 在日志旁边,我可以看到以下消息: "## [warning]找不到Visual Studio.请尝试安装受支持的 版本的Visual Studio.请参阅任务定义以获取以下信息的列表: 支持的版本."然后又回到了使用MSBuild进行构建的阶段. 之所以有效,是因为我正在构建一个.sln;只是希望我不必 建立一个.proj.

It turns out that is not the full story. When I add the "Visual Studio Build" task to the process, it now executes, but if I look more closely at the log, I can see the following message: "##[warning]Visual Studio was not found. Try installing a supported version of Visual Studio. See the task definition for a list of supported versions." And then it falls back to building with MSBuild. It works because I am building a .sln; let's just hope I don't have to build a .proj.

因此,似乎Visual Studio 2015 Express与构建代理不兼容.您可以尝试安装Visual Studio community 2015代替它,我可以毫无问题地构建它.

So, it seems that Visual Studio 2015 Express is not compatible with build agent. you can try to install the Visual Studio community 2015 instead of it, which I can build it without any issue.

同样,当您使用Visual Studio 2015 Express时,可以检查构建代理功能上是否存在关于Visual Studio的参数:

Again, you can check if there is a parameter about Visual Studio on your Capabilities of build agent when you use Visual Studio 2015 Express:

否则,构建代理将抛出该错误.

if not, build agent will throw that error.

希望这会有所帮助.

这篇关于## [warning]找不到Visual Studio版本"14.0".退回到版本"15.0"的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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