git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Junio C Hamano <gitster@pobox.com>
To: Pratik Karki <predatoramigo@gmail.com>
Cc: "Johannes Schindelin via GitGitGadget" <gitgitgadget@gmail.com>,
	git@vger.kernel.org,
	Johannes Schindelin <johannes.schindelin@gmx.de>
Subject: Re*: [PATCH 1/2] rebase -i --autosquash: demonstrate a problem skipping the last squash
Date: Tue, 04 Sep 2018 12:09:39 -0700	[thread overview]
Message-ID: <xmqqd0tt9j0s.fsf_-_@gitster-ct.c.googlers.com> (raw)
In-Reply-To: <8753c4e5fba5bb9cc42fdf438f4a69e702261a15.1535759099.git.gitgitgadget@gmail.com> (Johannes Schindelin via GitGitGadget's message of "Fri, 31 Aug 2018 16:45:02 -0700 (PDT)")

"Johannes Schindelin via GitGitGadget" <gitgitgadget@gmail.com>
writes:

> +	test_must_fail git -c core.editor="grep -q ^pick" \
> +		rebase -ki --autosquash HEAD~4 &&

When merged to 'pu', this reveals that "git rebase" rewritten in C
knows "--keep-empty" but not "-k".

I did a quick eyeballing between master:git-rebase.sh and
pu:builtin/rebase.c and I think that it is the only one that is
missed, but somebody may want to lend us a second set of eyes.

-- >8 --
Subject: rebase: re-add forgotten -k that stands for --keep-empty

630a70ea ("builtin rebase: support `keep-empty` option", 2018-08-08)
forgot that the option comes with a short-and-sweet -k synonym.  Add
it back.

Signed-off-by: Junio C Hamano <gitster@pobox.com>
---
 builtin/rebase.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/builtin/rebase.c b/builtin/rebase.c
index 87590047b3..b26f9c10cf 100644
--- a/builtin/rebase.c
+++ b/builtin/rebase.c
@@ -847,7 +847,7 @@ int cmd_rebase(int argc, const char **argv, const char *prefix)
 			 &options.allow_rerere_autoupdate,
 			 N_("allow rerere to update index  with resolved "
 			    "conflict")),
-		OPT_BOOL(0, "keep-empty", &options.keep_empty,
+		OPT_BOOL('k', "keep-empty", &options.keep_empty,
 			 N_("preserve empty commits during rebase")),
 		OPT_BOOL(0, "autosquash", &options.autosquash,
 			 N_("move commits that begin with "


  reply	other threads:[~2018-09-04 19:09 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-08-31 23:45 [PATCH 0/2] rebase --autosquash: handle manual "final fixups" Johannes Schindelin via GitGitGadget
2018-08-31 23:45 ` [PATCH 1/2] rebase -i --autosquash: demonstrate a problem skipping the last squash Johannes Schindelin via GitGitGadget
2018-09-04 19:09   ` Junio C Hamano [this message]
2018-09-04 22:27     ` Re*: " Johannes Schindelin
2018-09-05 16:28       ` Junio C Hamano
2018-08-31 23:45 ` [PATCH 2/2] rebase -i: be careful to wrap up fixup/squash chains Johannes Schindelin via GitGitGadget
2018-09-04 16:48   ` Junio C Hamano
2018-09-04 19:50     ` Johannes Schindelin

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=xmqqd0tt9j0s.fsf_-_@gitster-ct.c.googlers.com \
    --to=gitster@pobox.com \
    --cc=git@vger.kernel.org \
    --cc=gitgitgadget@gmail.com \
    --cc=johannes.schindelin@gmx.de \
    --cc=predatoramigo@gmail.com \
    /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).