Re: [PATCH v2 11/11] Turn `git bisect` into a full built-in
- From
Ævar Arnfjörð Bjarmason <avarab@gmail.com>
- Date
- Nov 11, 2022, 13:53 UTC
- Message-ID
- <221111.86edu9oa9d.gmgdl@evledraar.gmail.com>
- In-Reply-To
- <dadca7adbe3e7984f60fd6de6c8d63edb6a1ad8f.1668097966.git.congdanhqx@gmail.com>
On Thu, Nov 10 2022, Đoàn Trần Công Danh wrote:
Show 33 quoted lines
> From: Johannes Schindelin <johannes.schindelin@gmx.de>
>
> Now that the shell script hands off to the `bisect--helper` to do
> _anything_ (except to show the help), it is but a tiny step to let the
> helper implement the actual `git bisect` command instead.
>
> This retires `git-bisect.sh`, concluding a multi-year journey that many
> hands helped with, in particular Pranit Bauna, Tanushree Tumane and
> Miriam Rubio.
>
> Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
> Signed-off-by: Junio C Hamano <gitster@pobox.com>
> Signed-off-by: Đoàn Trần Công Danh <congdanhqx@gmail.com>
> ---
> Makefile | 3 +--
> builtin.h | 2 +-
> builtin/{bisect--helper.c => bisect.c} | 2 +-
> git.c | 2 +-
> 4 files changed, 4 insertions(+), 5 deletions(-)
> rename builtin/{bisect--helper.c => bisect.c} (99%)
>
> diff --git a/Makefile b/Makefile
> index 4927379184..78785c6b84 100644
> --- a/Makefile
> +++ b/Makefile
> @@ -627,7 +627,6 @@ THIRD_PARTY_SOURCES =
> # interactive shell sessions without exporting it.
> unexport CDPATH
>
> -SCRIPT_SH += git-bisect.sh
> SCRIPT_SH += git-difftool--helper.sh
> SCRIPT_SH += git-filter-branch.sh
> SCRIPT_SH += git-merge-octopus.shThis is missing a "git rm git-bisect.sh", which should be part of this commit.
Do we have a test for at least the exit code of "git bisect -h"? I think not, because before this it would have been (from skimming git-sh-setup.sh) 1, but 129 after.
The new exit code is better, but let's test that. For some exitsing tests:
git grep 'test_expect_code 129 .*-h'