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 <peff@peff.net>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
diff --git a/contrib/git-jump/README b/contrib/git-jump/README
index 2f618a7..8bcace2 100644
--- a/contrib/git-jump/README
+++ b/contrib/git-jump/README
@@ -65,6 +65,9 @@
# 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 931b0fe..92dbd4c 100755
--- a/contrib/git-jump/git-jump
+++ b/contrib/git-jump/git-jump
@@ -39,7 +39,7 @@
}
mode_merge() {
- git ls-files -u |
+ git ls-files -u "$@" |
perl -pe 's/^.*?\t//' |
sort -u |
while IFS= read fn; do