“git 二等分”尝试测试出乎意料的大量修订

发布于 2025-01-14 23:22:01 字数 317 浏览 2 评论 0原文

当我运行:

git bisect start <bad_commit> <good_commit>

我得到:

Bisecting: 9727 revisions left to test after this (roughly 13 steps)

但是我指定的 bad_commit 和 good_commit 显然在历史上只有大约 50 次提交。我做了一个“git log”并看到了那里的两个提交。我还验证了错误的提交比正确的提交更新。

这是怎么回事?

When I run:

git bisect start <bad_commit> <good_commit>

I get:

Bisecting: 9727 revisions left to test after this (roughly 13 steps)

But the bad_commit and good_commit I specified are clearly only around 50 commits back in history. I did a "git log" and saw both of the commits there. I also verified the bad commit is more recent than the good commit.

What's going on here?

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

忆离笙 2025-01-21 23:22:01

如果您合并到一个长期存在的分支二等分中,默认情况下将搜索整个分支。隔离侧面历史的简单方法是添加 --first-parent,这会告诉您带来错误的合并。

If you merged in a long-lived branch bisect by default will hunt through the whole branch. Easy way to wall off the side histories is to add --first-parent, that'll tell you the merge that brought the bug.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文