Re: [PATCH v3 7/7] contrib/git-jump/git-jump: jump to match column in addition to line
- From
Eric Sunshine <sunshine@sunshineco.com>
- Date
- Apr 24, 2018, 05:37 UTC
- Message-ID
- <CAPig+cTep_WuRy3qVHpZUMstc9Tgt9gFW=F8_0E8CZQQ8Jyq7g@mail.gmail.com>
- In-Reply-To
- <23ea226b544e9e5fcdbbcda3adb5982e2cae2123.1524545768.git.me@ttaylorr.com>
On Tue, Apr 24, 2018 at 1:07 AM, Taylor Blau <me@ttaylorr.com> wrote:
Show 11 quoted lines
> Take advantage of 'git-grep(1)''s new option, '--column-number' in order > to teach Peff's 'git-jump' script how to jump to the correct column for > any given match. > > 'git-grep(1)''s output is in the correct format for Vim's jump list, so > no additional cleanup is necessary. > > Signed-off-by: Taylor Blau <me@ttaylorr.com> > --- > contrib/git-jump/git-jump | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-)
Based upon Ævar review[1], I was expecting to see git-jump/README modified by this patch, as well. Perhaps you overlooked or forgot about that review comment, or perhaps you disagreed with it?
[1]: https://public-inbox.org/git/874lk2e4he.fsf@evledraar.gmail.com/
Show 15 quoted lines
> diff --git a/contrib/git-jump/git-jump b/contrib/git-jump/git-jump
> index 80ab0590bc..8bc57ea0f8 100755
> --- a/contrib/git-jump/git-jump
> +++ b/contrib/git-jump/git-jump
> @@ -52,7 +52,7 @@ mode_merge() {
> # editor shows them to us in the status bar.
> mode_grep() {
> cmd=$(git config jump.grepCmd)
> - test -n "$cmd" || cmd="git grep -n"
> + test -n "$cmd" || cmd="git grep -n --column-number"
> $cmd "$@" |
> perl -pe '
> s/[ \t]+/ /g;
> --
> 2.17.0