Skip to content

Commit b9d6689

Browse files
dschogitster
authored andcommitted
am --skip/--abort: merge HEAD/ORIG_HEAD tree into index
f8da680 (am --skip: support skipping while on unborn branch, 2015-06-06) introduced a performance regression to "git am --skip", where it used "read-tree" to reconstruct the index from scratch without reusing the cached stat information. This is a backport of the corresponding patch to the builtin am in 2.6: 3ecc704 (am --skip/--abort: merge HEAD/ORIG_HEAD tree into index, 2015-08-19). Reportedly, it can make a huge difference on Windows, in one case a `git rebase --skip` took 1m40s without, and 5s with, this patch. cf. #365 Reported-and-suggested-by: Kim Gybels <[email protected]> Acked-by: Paul Tan <[email protected]> Signed-off-by: Johannes Schindelin <[email protected]> Signed-off-by: Junio C Hamano <[email protected]>
1 parent 74b6763 commit b9d6689

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

git-am.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -509,7 +509,7 @@ then
509509
git read-tree --reset -u $head_tree $head_tree &&
510510
index_tree=$(git write-tree) &&
511511
git read-tree -m -u $index_tree $head_tree
512-
git read-tree $head_tree
512+
git read-tree -m $head_tree
513513
;;
514514
,t)
515515
if test -f "$dotest/rebasing"

0 commit comments

Comments
 (0)