You are not logged in.

#1 2018-08-07 16:10:15

brontosaurusrex
Middle Office
Registered: 2015-09-29
Posts: 1,588

fold with some humanity?

This fold command

fold -w 20 -s <(echo 'While you recently had your problems on the run, they'\''ve regrouped and
are making another attack.')  

returns

While you recently 
had your problems 
on the run, they've 
regrouped and
are making another 
attack.

while I would like some more human way of wrapping, for example one rule would be no less than 2 words per line, so I guess something desired would be

While you recently 
had your problems 
on the run, they've 
regrouped and are
making another attack.

or even smarter

While you recently 
had your problems 
on the run, 
they've regrouped 
and are making 
another attack.

Any clues? Is there a smarter version of fold?

Offline

Board footer

Powered by FluxBB