How to specify fmt 'width' parameter for mailx command?

I use the command

cat ~/2014-02-06_BP.txt | mailx -s "formatted file content" myemail@mydomain.com

I believe mailx uses fmtinternally. I want to change the fmt width options to fmt -s -w160.

ps: This is on Fedora 20

+4
source share
1 answer

mailx almost certainly does NOT do any formatting of the intput cat-ed into it.

It would be best to run fmt on the input before sending it to mailx, for example:

  fmt -w 160 file.txt | mailx -s 'your data, formatted' somebody@someplace 
+1
source

Source: https://habr.com/ru/post/1525827/


All Articles