Skip to content

Is it possible to print matching file and line number but omit the match? #2746

Answered by BurntSushi
frankitox asked this question in Q&A
Discussion options

You must be logged in to vote

Nope. I'd probably just throw a sed 's/:$//' at the end of it and call it good enough.

If you're reading this data into some other program, you might also be interested in the --json flag.

Replies: 3 comments 5 replies

Comment options

You must be logged in to vote
0 replies
Answer selected by BurntSushi
Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
5 replies
@BurntSushi
Comment options

@kranurag7
Comment options

@BurntSushi
Comment options

@kranurag7
Comment options

@frankitox
Comment options

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
3 participants