From: Jeff King Date: Tue, 9 Nov 2021 16:35:47 +0000 (-0500) Subject: git-jump: pass "merge" arguments to ls-files X-Git-Tag: v2.35.0-rc0~114^2 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=67ba13e5a4b27785391a0e1673d71e506edae13b;p=thirdparty%2Fgit.git git-jump: pass "merge" arguments to ls-files We currently throw away any arguments given to "git jump merge". We should instead pass them along to ls-files, since they're likely to be pathspecs. This matches the behavior of "git jump diff", etc. Signed-off-by: Jeff King Signed-off-by: Junio C Hamano --- diff --git a/contrib/git-jump/README b/contrib/git-jump/README index 2f618a7f97..8bcace29d2 100644 --- a/contrib/git-jump/README +++ b/contrib/git-jump/README @@ -65,6 +65,9 @@ git jump diff --cached # jump to merge conflicts git jump merge +# documentation conflicts are hard; skip past them for now +git jump merge :^Documentation + # jump to all instances of foo_bar git jump grep foo_bar diff --git a/contrib/git-jump/git-jump b/contrib/git-jump/git-jump index 931b0fe3a9..92dbd4cde1 100755 --- a/contrib/git-jump/git-jump +++ b/contrib/git-jump/git-jump @@ -39,7 +39,7 @@ mode_diff() { } mode_merge() { - git ls-files -u | + git ls-files -u "$@" | perl -pe 's/^.*?\t//' | sort -u | while IFS= read fn; do