Subject: Re: [Internet]Re: [PATCH v7 1/2] merge-tree.c: add --merge-base=<commit> option

From: Junio C Hamano <[email-masked]>
Date: Tue, 22 Nov 2022 13:28:16 +0900

"kylezhao(赵柯宇)" <[email-masked]> writes:

> I went to check the api-parse-option.txt, but I didn't found an
> elegant solution to stop when the users uses the second
> "--merge-base".

That's not even a fix, as it does not allow specifying more than one
merge bases, is it?

Just like how builtin/merge-tree.c::real_merge() is prepared to
handle parent1 and parent2 that have multiple merge bases and pass
all of them to the underlying merge machinery, you can accumulate
multiple strings using OPT_STRING_LIST() and use all of them as
merge_bases, no?