Re: Scriptable mode for git bisect

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Oh thank you, I didn’t know that / didn’t grasp that while reading (apparently too fast) your previous mails.

That is way nicer.

Thank you.

Claus

> On 25.09.2022, at 02:59, Đoàn Trần Công Danh <congdanhqx@xxxxxxxxx> wrote:
> 
> On 2022-09-25 01:46:13+0200, Claus Fischer <claus.fischer@xxxxxxxxxxxxxxxx> wrote:
>> Well since I usually don’t have many revisions backwards, typically
>> no more than 50, I can just traverse the tree backwards from main.
>> I remember the last ‘bad’ revision before the good one.
>> So there’s a solution for me.
>> 
>> Yes the bisect command puts the correct ‘first bad’ revision in its
>> output but it’s surrounded by a large amount of useless text. It
>> would be nice to have a ‘quiet’ flag that lets it output just the
>> bad revision. Alternatively, that it ends by checking out just that
>> bad revision before revert.
>> 
>> My problem is solved by stepping backwards to HEAD~1 each time, but
>> you might consider making bisect more scriptable.
> 
> No, you don't need to parse "git bisect" output to get the "first bad"
> revision. The "first bad" revision is stored in refs/bisect/bad.
> 
> And you can take the "first bad" revision in a scriptable way with:
> 
> 	FIRST_BAD=$(git rev-parse --verify refs/bisect/bad)
> 
> Of course, after finishing bisecting.
> 
> -- 
> Danh




[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]

  Powered by Linux