beyondgrep / ack2

**ack 2 is no longer being maintained. ack 3 is the latest version.**
https://github.com/beyondgrep/ack3/
Other
1.48k stars 140 forks source link

Possible to trim leading whitespace in a matched line? #386

Closed factormystic closed 7 years ago

factormystic commented 11 years ago

Searching for a term in source files displays matching lines as expected, however it's common for matched lines to start with a large amount of whitespace.

Is it possible to print matching lines with leading whitespace removed? I suppose it would need to be unless the leading whitespace is part of the matching text in the line.

It'd be easier to skim the output if this were possible

petdance commented 11 years ago

It would have to be an explicit flag like --trim but I like the idea.

hoelzro commented 11 years ago

+1 from me, too! If you want to implement this feature, I'd be happy to merge it in!

petdance commented 11 years ago

Wait, not yet. We have much to do with how ack does output and the --trim will get in the way of that.

We need to overhaul all of highlighting and output for 2.12.

petdance commented 7 years ago

Closed and moved to wiki.