fmt: How to skip some text?

Joel Hammer Joel
Mon May 17 11:54:10 PDT 2004


I want to use fmt in vi to format text, eg:
          :1,$ ! fmt -w 130

Without vi, this command would look like:
          cat file ! fmt -w 130

I want it to format everything except lines which begin with at least
two blanks, like this:

  1. My list 
     First
     Second
     Third

Is there anyway to do this with fmt? par? sed?
Thanks,
Joel



More information about the Linux-users mailing list