summaryrefslogtreecommitdiff
path: root/git-instaweb.sh
diff options
context:
space:
mode:
authorLibravatar Phillip Wood <phillip.wood@dunelm.org.uk>2018-03-01 10:51:00 +0000
committerLibravatar Junio C Hamano <gitster@pobox.com>2018-03-01 11:39:15 -0800
commitfecc6f3a6862c55dee0e9a2390acaf4b23991fef (patch)
tree39aa5de17d2a04356169f092ba3cec93bd54a382 /git-instaweb.sh
parentt3701: add failing test for pathological context lines (diff)
downloadtgif-fecc6f3a6862c55dee0e9a2390acaf4b23991fef.tar.xz
add -p: adjust offsets of subsequent hunks when one is skipped
Since commit 8cbd431082 ("git-add--interactive: replace hunk recounting with apply --recount", 2008-7-2) if a hunk is skipped then we rely on the context lines to apply subsequent hunks in the right place. While this works most of the time it is possible for hunks to end up being applied in the wrong place. To fix this adjust the offset of subsequent hunks to correct for any change in the number of insertions or deletions due to the skipped hunk. The change in offset due to edited hunks that have the number of insertions or deletions changed is ignored here, it will be fixed in the next commit. Signed-off-by: Phillip Wood <phillip.wood@dunelm.org.uk> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'git-instaweb.sh')
0 files changed, 0 insertions, 0 deletions