On 2022-09-24 11:32:52+0200, Claus Fischer <claus.fischer@xxxxxxxxxxxxxxxx> wrote: > I tried that but it turns out it does not always stop at the bad revision. "git bisect" won't stop at the bad revision, it only left "refs/bisect/bad" point to the first bad revision, assuming non-alternative terms were used. If refs/bisect/bad doesn't point to the first bad revision, your installation is borked. Please file a bug report. > > Claus > > > On 24.09.2022, at 03:44, Đoàn Trần Công Danh <congdanhqx@xxxxxxxxx> wrote: > > > > On 2022-09-23 22:54:03+0200, Claus Fischer <claus.fischer@xxxxxxxxxxxxxxxx> wrote: > >> > >> Dear Git maintainers, > >> > >> I have looked at the manpage of git bisect but have not found > >> what I need: > >> I would like git bisect not just to report the 'bad' revision > >> within a bunch of text but instead either stop at the first > >> bad revision (the last good will then be HEAD~1) or report > >> it in a scriptable way, i.e. > >> > >> BADHEAD=$(git bisect run --shut-up-and-report-the-bad) > >> > >> Have I overlooked anything? > > > > After running "git bisect run" > > You can take its revisions with: > > > > BADHEAD=$(git rev-parse --verify refs/bisect/bad) > > > >> > >> *** > >> > >> The pourpose is to keep the source trees of two different > >> projects that share a few files synchronous. > >> My good/bad-script is a script that checks whether these > >> files are similar. > >> I want git to stop at the first change in source tree A > >> so that I can update source tree B with the same commit > >> message, then proceed to the next change in A that > >> changes one of those files. > >> > >> Regards, > >> > >> Cluas > > > > -- > > Danh > -- Danh