简体   繁体   English

TFS 2015和VS 2013内部版本定义

[英]TFS 2015 and VS 2013 build definitions

I use VS 2013 because of Biztalk 2013 developments. 由于Biztalk 2013的发展,我使用VS 2013。 Currently we use TFS 2015 with a build agent from TFS 2013 for automatic builds. 当前,我们将TFS 2015与TFS 2013中的构建代理一起使用,以进行自动构建。 We need to migrate all to TFS 2015 and we want to migrate the xaml approach of build definitions to vNext. 我们需要将所有内容迁移到TFS 2015,并且要将构建定义的xaml方法迁移到vNext。 Thing is, because of biztalk version, we need to keep using VS2013 and in the view Team Explorer under Builds I cannot see the build definitions created as vNext. 问题是,由于biztalk版本的原因,我们需要继续使用VS2013,并且在“构建”下的“团队资源管理器”视图中,我看不到创建为vNext的构建定义。 I've searched for plugins/extensions and updates or even some documentation but I couldn't really find anything related to this topic. 我已经搜索了插件/扩展和更新,甚至是一些文档,但是我找不到与该主题相关的任何东西。

The build system in TFS 2015+ is entirely web-based. TFS 2015+中的构建系统完全基于网络。 Even VS2015+ will just bounce you to the web to do anything with the builds. 甚至VS2015 +都可以使您跳到网络上来进行构建。

So the answer is, "Get used to using the web UI." 因此答案是“习惯使用Web UI”。

Just as Daniel said, the vNext build system is entirely web-based and Visual Studio 2013 does not show non-XAML build definitions. 正如Daniel所说,vNext构建系统完全基于Web,而Visual Studio 2013不会显示非XAML构建定义。

So, you can use below workarounds to see the list of existing build definition (However you can only edit the build definitions via the web portal for vNext build definitions): 因此,您可以使用以下变通办法来查看现有构建定义的列表(但是,您只能通过Web门户编辑vNext构建定义的构建定义):

  1. Using the web UI : http://server:8080/tfs/Collection/Project/_build 使用网络用户界面: http://server:8080/tfs/Collection/Project/_build
  2. Install Visual Studio 2015+ or at leat install Team Explorer 2017 standalone 安装Visual Studio 2015+或免费安装Team Explorer 2017独立版
  3. Get the build definition list with the REST API: Get a list of build definitions 使用REST API获取构建定义列表: 获取构建定义列表
  4. Create a Console app and use the BuildHttpClient to make requests,refer to below sample: 创建一个控制台应用程序并使用BuildHttpClient发出请求,请参考以下示例:

using System;
using Microsoft.TeamFoundation.Build.WebApi;
using Microsoft.VisualStudio.Services.Client;

namespace GetBuildDefinition
{
    class Program
    {
        static void Main(string[] args)
        {
            var tfsUrl = "http://server:8080/tfs/Collection";
            var buildClient = new BuildHttpClient(new Uri(tfsUrl), new VssAadCredential());
            var definitions = buildClient.GetDefinitionsAsync(project: "ProjectNameHere");

            foreach (var definition in definitions.Result)  
            {
                Console.WriteLine(String.Format("{0} - {1}", definition.Id, definition.Name));
            }
        }
    }
}

VS 2013 and lower versions do not show vNext builds and build definitions, you need VS 2015 and later for that. VS 2013及更低版本不显示vNext构建和构建定义,为此您需要VS 2015及更高版本。 As an option, if you want to keep an eye on the build status, you can try CatLight build notification tool (check below 1st link) that works independently of Visual Studio and supports vNext builds. 作为一种选择,如果您想关注构建状态,可以尝试独立于Visual Studio并支持vNext构建的CatLight构建通知工具(在第一个链接下方检查)。 Else, Web version is pretty awesome to use and handle. 否则,Web版本的使用和处理都非常出色。

Incase you have any other queries regarding TFS builds, please let know. 如果您对TFS版本还有其他疑问,请告诉我们。

Also, below Microsoft links could be helpful. 另外,下面的Microsoft链接可能会有所帮助。

  1. vNext builds are not visible in VS Team Explorer pane vNext版本在VS Team Explorer窗格中不可见

  2. VS Compatibility with TFS versions VS与TFS版本的兼容性

If you have the build definitions in place and you are connected to the correct tfs workspace project, then you should see the list definition on your vs panel, the only thing that you can't do is edit the build definition. 如果您具有适当的构建定义,并且已连接到正确的tfs工作区项目,则应该在vs面板上看到列表定义,唯一不能做的就是编辑构建定义。 As @DanielMann said, from that point on everything is web-based, what you can do is queue a new build and see the list. 正如@DanielMann所说,从那时起,一切都是基于Web的,您可以做的是对新构建进行排队并查看列表。 You don't need any plugin for that 您不需要任何插件

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

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