I want to run ack or grep on HTML files that often have very long lines. I don\'t want to see very long lines that wrap repeatedly. But I do want to see just that portion of
You could use less as a pager for ack and chop long lines: ack --pager="less -S" This retains the long line but leaves it on one line instead of wrapping. To see more of the line, scroll left/right in less with the arrow keys.
I have the following alias setup for ack to do this:
alias ick='ack -i --pager="less -R -S"'