MHDR(1)

✨ MHDR ✨

okay so bestie, let me put you onto mhdr β€” it's a little command-line cutie from the General Commands Manual section (that's section 1, the main character of manual sections πŸ’…). It prints message headers. That's the whole vibe. Simple. Iconic. Periodt.


🌸 NAME 🌸

mhdr β€” print message headers


πŸŽ€ SYNOPSIS πŸŽ€

mhdr [-h hdrs [-p parameter]] [-d] [-H] [-M] [-A | -D] [msgs ...]

πŸ’– DESCRIPTION πŸ’–

so like, mhdr prints the headers of the msgs you hand it. which msgs? that's a whole thing β€” go read mmsg(7) for the message argument syntax, iykyk πŸ¦‹

  • if you don't specify any msgs, mhdr defaults to the current message. no cap, it just does that. 🫢
  • if you don't specify any hdrs, mhdr prints all the headers. everything. the whole wardrobe. πŸ‘‘

now the options, babes:

  • -h hdrs β€” only print the values of headers in the colon-separated list hdrs. (colon-separated, bestie, don't come at me with commas πŸ’€)
  • -p parameter β€” extract a particular RFC 2045 parameter from the specified hdrs. very specific, very demure.
  • -d β€” decode the hdrs according to RFC 2047. yes bestie, decode it, ungatekeep the text πŸ”₯
  • -H β€” prefix output lines with the filename of the message, followed by a tab. so you know who's who πŸŽ€
  • -M β€” search for all occurrences of the hdrs (default: only the first). it's giving thorough. it's giving completionist. ✨
  • -A β€” scan for RFC 5322 addresses in the hdrs and print them, one per line. address girlies rise πŸ™ˆ
  • -D β€” assume the header contains an RFC 5322 date and print it as a Unix timestamp. numbers era πŸ”’

⭐ EXIT STATUS ⭐

  • 0 β€” success, we ate πŸ’…
  • 1 β€” no header was printed. it's giving silence. it's giving nothing in the inbox 😭
  • >1 β€” an error occurred. red flag, bestie 🚩

🌈 SEE ALSO 🌈

  • mmsg(7) β€” go read it, the message argument syntax lives there

also these absolute legends of documentation:

  • N. Freed and N. Borenstein, Multipurpose Internet Mail Extensions (MIME) Part One: Format of Internet Message Bodies, RFC 2045, November 1996.
  • N. Freed and N. Borenstein, MIME (Multipurpose Internet Mail Extensions) Part Three: Message Header Extensions for Non-ASCII Text, RFC 2047, November 1996.
  • P. Resnick (ed.), Internet Message Format, RFC 5322, October 2008.

πŸ‘‘ AUTHORS πŸ‘‘

Leah Neukirchen <leah@vuxu.org> β€” thank you for your service, icon 🫢


πŸ¦‹ LICENSE πŸ¦‹

mhdr is in the public domain.

To the extent possible under law, the creator of this work has waived all copyright and related or neighboring rights to this work.

http://creativecommons.org/publicdomain/zero/1.0/


and that's the whole page, bestie β€” Debian, August 17, 2016, mwah, love that for us πŸ’–βœ¨πŸŽ€πŸ¦‹πŸŒΈ