git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Abhijeet Sonar <abhijeet.nkt@gmail.com>
To: git@vger.kernel.org
Subject: [QUESTION] Can I merge --continue with --no-verify
Date: Thu, 24 Oct 2024 13:29:21 +0530	[thread overview]
Message-ID: <7038bb3a-2aad-4bde-bd46-f2bd2ef659d1@gmail.com> (raw)

I recently found myself wanting to continue a merge after resolving
conflicts without having the pre-commit hook run:

git merge --continue --no-verify

this fails and prints usage.

Digging the source, I can see that in builtin/merge.c:1378 we do:

    if (continue_current_merge) {
        [...]

        if (orig_argc != 2)
            usage_msg_opt(_("--continue expects no arguments"),   
                  builtin_merge_usage, builtin_merge_options);

I see why we would want this - the --continue flag makes the merge command
perform an operation that is very different than what merge normally does
without this option and therefore the usual options do not apply.
However, I think
it does make sense to allow --no-verify - it feels very intuitive to use
it when
bypassing the pre-commit hook is desired while continuing a merge.

Thanks



             reply	other threads:[~2024-10-24  7:59 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-10-24  7:59 Abhijeet Sonar [this message]
2024-10-24 16:54 ` [QUESTION] Can I merge --continue with --no-verify Taylor Blau

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=7038bb3a-2aad-4bde-bd46-f2bd2ef659d1@gmail.com \
    --to=abhijeet.nkt@gmail.com \
    --cc=git@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).