无法通过不存在的版本无限期地删除构建。 [英] Cannot delete a build retain indefinitely by a non-existent release.

查看:97
本文介绍了无法通过不存在的版本无限期地删除构建。的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有一些使用现已删除/重命名的版本定义创建的版本。如果我尝试删除其中一个版本,我会收到错误:" 以下版本
BuildName 无法删除,因为它被Release标记为"无限期保留"。删除与构建关联的版本以允许删除此构建。"这有什么办法吗?当然我应该可以选择强行删除
a build。

解决方案

解决方法删除保留的构建将手动发出以下API调用。

https ://www.visualstudio.com/en-us/docs/integrate/api/build/builds#update-a-build


PATCH

https:// {instance} / DefaultCollection / {project} / _ apis / build / builds / {buildId}?api-version = {version}


ReqeustBody:
{" keepForever":false," RetainedByRelease":false}


I have some builds that were created using a release definition that has now been deleted/renamed. If I try to delete one of these builds I get the error: "The following build BuildName cannot be deleted because it is marked as Retain Indefinitely by Release. Remove the release associated with the build to allow deletion of this build." Is there any way round this? Surely I should be given the option to forcefully delete a build.

解决方案

Workaround to delete the retained build would be to manually issue the following API call. https://www.visualstudio.com/en-us/docs/integrate/api/build/builds#update-a-build

PATCH https://{instance}/DefaultCollection/{project}/_apis/build/builds/{buildId}?api-version={version}

ReqeustBody: {"keepForever":false, "RetainedByRelease":false}


这篇关于无法通过不存在的版本无限期地删除构建。的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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