Re: [PATCH/RFC 0/4] grep: support to match by line number

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Bert Wesarg <bert.wesarg@xxxxxxxxxxxxxx> writes:

>> Can you give a concrete example of how you'd use this? I'm not sure I
>> understand the described use case.
>
> I parse the output of compiling a file, there may be warnings or even
> errors, I collect the given line numbers, and then call 'git grep -p
> -C -n (-@ <lno>)+ -- <path>' to show me what these warnings are about.

What would you do next after doing that?  Open the file in your editor and
jump to the line found by the grep?  Oh, wait, that's the same line as
your compiler already found for you.

And when you open the file in your editor, doesn't it show offending line
in the middle of the screen?  You can even fix it up right there.  Isn't
your editor wonderful?

The extra "grep -@" step in-between looks like a totally made-up use case
that is not interesting nor convincing.

--
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]