sll
Tired of grepping for files and getting really long lines and/or minified junk in the output?
sll makes it easy to strip those lines; just pipe the result of grep or
ag through sll.
ag check | sllBy default, any line longer than 1024 lines is not shown. You can change this
by passing an integer to sll:
ag check | sll 80will filter any lines longer than 80 characters from the output.
Installation
Run go install github.com/kevinburke/sll and add "$GOPATH/bin" to your
$PATH variable.
Other Ways to Implement this
There are many other ways to write this and some of them are listed here. Feel free to add your own with a pull request. Be sure to mention how this project is "pointless" and a "waste of time". Before merging, I will berate myself for having foisted this waste on the unsuspecting Internet population, retreat to my parents basement, and promise to never open source a thing I write ever again.
egrep -v .{1024}cut -c 1-1024less -Ssed -E 's/^(.{0,80}).*/\1/'
Errata
Currently ag has a --print-long-lines flag, which has not been
implemented. If it does, you should probably use that instead.