Commit 769f8a8
committed
rebase -r: do not write MERGE_HEAD unless needed
When we detect that a `merge` can be skipped because the merged commit
is already an ancestor of HEAD, we do not need to commit, therefore
writing the MERGE_HEAD file is useless.
It is actually worse than useless: a subsequent `git commit` will pick
it up and think that we want to merge that commit, still.
To avoid that, move the code that writes the MERGE_HEAD file to a
location where we already know that the `merge` cannot be skipped.
Signed-off-by: Johannes Schindelin <[email protected]>1 parent 54f947e commit 769f8a8
2 files changed
+5
-5
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
3184 | 3184 | | |
3185 | 3185 | | |
3186 | 3186 | | |
3187 | | - | |
3188 | | - | |
3189 | | - | |
3190 | | - | |
3191 | 3187 | | |
3192 | 3188 | | |
3193 | 3189 | | |
| |||
3196 | 3192 | | |
3197 | 3193 | | |
3198 | 3194 | | |
| 3195 | + | |
| 3196 | + | |
| 3197 | + | |
| 3198 | + | |
3199 | 3199 | | |
3200 | 3200 | | |
3201 | 3201 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
396 | 396 | | |
397 | 397 | | |
398 | 398 | | |
399 | | - | |
| 399 | + | |
400 | 400 | | |
401 | 401 | | |
402 | 402 | | |
| |||
0 commit comments