gpt4 book ai didi

git - Azure DevOps/VSTS 总是在干净的存储库上报告 "DETACHED HEAD"

转载 作者:行者123 更新时间:2023-12-03 23:21:27 25 4
gpt4 key购买 nike

friend 们,

我现在厌倦了 Azure DevOps/VSTS。 Jenkins 要好得多,现在仍然如此,只是我的组织想要使用 Azure DevOps。

我有一个谜团需要帮助来解开。

以下是我的笔记本电脑中的存储库,它没有未跟踪或未提交的更改。

git status
On branch master
Your branch is up to date with 'origin/master'.

nothing to commit, working tree clean

git remote -v
origin https://github.com/xxx/terraformvsts.git (fetch)
origin https://github.com/xxx/terraformvsts.git (push)

你猜怎么着,Azure Devops 在每次构建执行时总是提示它有“DETACHED HEAD”。

请注意“结帐”阶段的以下内容:
2019-02-05T05:55:33.2076875Z Note: checking out 'aad90fceecf39a7731c356ebfe2b547ddbce99e6'.
2019-02-05T05:55:33.2076992Z
2019-02-05T05:55:33.2077872Z You are in 'detached HEAD' state. You can look around, make experimental
2019-02-05T05:55:33.2077939Z changes and commit them, and you can discard any commits you make in this
2019-02-05T05:55:33.2078179Z state without impacting any branches by performing another checkout.
2019-02-05T05:55:33.2078345Z
2019-02-05T05:55:33.2078389Z If you want to create a new branch to retain commits you create, you may
2019-02-05T05:55:33.2078683Z do so (now or later) by using -b with the checkout command again. Example:
2019-02-05T05:55:33.2078717Z
2019-02-05T05:55:33.2078933Z git checkout -b <new-branch-name>
2019-02-05T05:55:33.2078966Z
2019-02-05T05:55:33.2079004Z HEAD is now at aad90fc Clean Repository

构建管道的结帐阶段如下所示:

enter image description here

如何解决这个问题?我不应该结帐吗?或者应该修改构建管道中的配置设置之一?

最佳答案

这不是提示,这就是 Azure DevOps 的工作方式。我看到所有构建,所有 repo 。没有错误。

关于git - Azure DevOps/VSTS 总是在干净的存储库上报告 "DETACHED HEAD",我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/54528776/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com