summaryrefslogtreecommitdiff
path: root/Documentation
diff options
context:
space:
mode:
authorBrian Lyles <brianmlyles@gmail.com>2024-03-25 23:16:48 (GMT)
committerJunio C Hamano <gitster@pobox.com>2024-03-25 23:45:40 (GMT)
commit0af38890ade347536af7690ecee9e5e75d1b2b12 (patch)
treec81f9abb06a7383a07497836f349021e0728400f /Documentation
parente09f1254c54329773904fe25d7c545a1fb4fa920 (diff)
downloadgit-0af38890ade347536af7690ecee9e5e75d1b2b12.zip
git-0af38890ade347536af7690ecee9e5e75d1b2b12.tar.gz
git-0af38890ade347536af7690ecee9e5e75d1b2b12.tar.bz2
docs: address inaccurate `--empty` default with `--exec`
The documentation for git-rebase(1) indicates that using the `--exec` option will use `--empty=drop`. This is inaccurate: when `--interactive` is not explicitly provided, `--exec` results in `--empty=keep` behaviors. Correctly indicate the behavior of `--exec` using `--empty=keep` when `--interactive` is not specified. Reported-by: Phillip Wood <phillip.wood@dunelm.org.uk> Signed-off-by: Brian Lyles <brianmlyles@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'Documentation')
-rw-r--r--Documentation/git-rebase.txt10
1 files changed, 5 insertions, 5 deletions
diff --git a/Documentation/git-rebase.txt b/Documentation/git-rebase.txt
index e7e7250..a602e8f 100644
--- a/Documentation/git-rebase.txt
+++ b/Documentation/git-rebase.txt
@@ -295,11 +295,11 @@ See also INCOMPATIBLE OPTIONS below.
empty after rebasing (because they contain a subset of already
upstream changes). With drop (the default), commits that
become empty are dropped. With keep, such commits are kept.
- With ask (implied by `--interactive`), the rebase will halt when
- an empty commit is applied allowing you to choose whether to
- drop it, edit files more, or just commit the empty changes.
- Other options, like `--exec`, will use the default of drop unless
- `-i`/`--interactive` is explicitly specified.
+ With ask, the rebase will halt when an empty commit is applied
+ allowing you to choose whether to drop it, edit files more, or just
+ commit the empty changes.
+ When the `-i`/`--interactive` option is used, the default becomes ask.
+ Otherwise, when the `--exec` option is used, the default becomes keep.
+
Note that commits which start empty are kept (unless `--no-keep-empty`
is specified), and commits which are clean cherry-picks (as determined