gpt4 book ai didi

git - 我如何停止 git bisect?

转载 作者:IT王子 更新时间:2023-10-29 00:41:07 24 4
gpt4 key购买 nike

我刚才尝试了 git bisect,它对我很有帮助,但显然我没有阻止它。当我执行 git status 时,我仍然得到:

You are currently bisecting.
(use "git bisect reset" to get back to the original branch)

我真的不想重置到任何地方,我只想停止平分。这实际上只是摆脱这条消息的问题。

最佳答案

git bisect reset是你停止平分的方式。默认情况下,它会将 HEAD 重置为开始之前的位置,但您也可以使用 git bisect reset <commit>去那个。

如果您只是想在不更改提交的情况下停止平分,请从文档中,git bisect reset HEAD会做你想做的事。

Bisect reset

After a bisect session, to clean up the bisection state and return to the original HEAD (i.e., to quit bisecting), issue the following command:

$ git bisect reset

By default, this will return your tree to the commit that was checked out before git bisect start. (A new git bisect start will also do that, as it cleans up the old bisection state.)

With an optional argument, you can return to a different commit instead:

$ git bisect reset <commit>

For example, git bisect reset HEAD will leave you on the current bisection commit and avoid switching commits at all, while git bisect reset bisect/bad will check out the first bad revision.

来源:http://git-scm.com/docs/git-bisect

关于git - 我如何停止 git bisect?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/23156415/

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