From: Junio C Hamano Date: Sat, 25 Dec 2021 02:01:17 GMT Subject: Re: Why does "merge --continue" expect no arguments? Message-ID: In-Reply-To: <211224.86mtkqgc8e.gmgdl@evledraar.gmail.com> Ævar Arnfjörð Bjarmason writes: > On Tue, Dec 21 2021, Junio C Hamano wrote: > >> Or we could throw in another >> >> * document more clearly that "merge --continue" is a mere synonym >> for, and hint that there is no reason to favor it over, "git >> commit". > > But it's not: > > $ git add foo > $ git commit -v > hint: Waiting for your editor to close the file.[...] > ^C > $ git merge --continue > fatal: There is no merge in progress (MERGE_HEAD missing). > > FWIW I prefer and use it for that reason, i.e. it's useful for scripting > to use these "stateful" commands when we're in some sort of rebase/merge > "sequence" since it's an extra layer of sanity checking. There is no additional safety afforded by that, though. There is no reason why one would even try to say "merge --continue" without doing any merge to begin with. The "merge --continue" not taking any pathspec is a bit of safety, but even there, "commit" already has its own safety to reject pathspec when it notices that it is concluding a conflicted "merge", so "merge --continue" is not necessary for additional safety there, either.