sending HTML formatted email from a Unix command line should not be this much of a pain

but it is….

thanks to Ygor from a 2004 post here: http://www.unix.com/unix-advanced-expert-users/14177-unable-sent-mail-html-format-mailx-command.html

you can send HTML-formatted email like so via ‘sendmail’ (rather than ramming your head against a wall with ‘mailx’):