sift icon indicating copy to clipboard operation
sift copied to clipboard

pager support

Open federicoviscomi opened this issue 9 years ago • 1 comments

Is there a way of piping the output into less and still preserve the original colours and output? I've tried using sift PATTERN --group | less -R but it doesn't work It would be nice to have a --pager option similar to http://beyondgrep.com/

federicoviscomi avatar Nov 07 '16 12:11 federicoviscomi

sift deactivates grouping and colored output when it writes to a pipe. This ensures that sift works as expected when used in scripts, even if a sift config file enables colored/grouped output by default. The color option can be overridden with --color: sift PATTERN --color | less -R Unfortunately, the deactivation of the --group option when writing to a pipe cannot be overrriden. I will take a look at implementing something like a --pager option.

svent avatar Nov 07 '16 21:11 svent