Does less (or any other lightweight pager I could use as $PAGER) has such a feature?

For example, if I type man bash and then enter /incorporates it doesn't find the word, despite it being right there, in the second paragraph:

       Bash  is  an  sh-compatible  command language interpreter that executes
       commands read from the standard input or from a file.  Bash also incor-
       porates useful features from the Korn and C shells (ksh and csh).

My djvu and pdf viewer "incorporates" such a feature, and probably other document viewers do too. (pdftotext simply re-joins the words, which means that pdftotext file.pdf - | grep pattern may still be more reliable than pdfgrep).

IIRC info (the GNU texinfo docs viewer) just doesn't hyphenate the words, in order to avoid this. While not directly actionable (I'm mostly using less with preformatted files), I would also be interested in any groff/mandoc options/tricks that could inhibit the end-of-line hyphenation.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.