bashshelltextformattext-manipulation

fmt with Multiple Columns


Is there a way for fmt to output text formatted with multiple columns (doesn't seem to be anything about this in the man page so I doubt this)? If not, is there a command that is like fmt but can output multi-column'd text?


Solution

  • You're looking for pr

    fmt -35 < file | pr -2 -T
    

    Check the man pages to fine-tune the options