MSGCHK(1mh)
π NAME π
msgchk β nmh's check for incoming email π¦β¨
πΈ SYNOPSIS πΈ
msgchk [-help] [-version] [-date | -nodate] [-notify all/mail/nomail ]
[-nonotify all/mail/nomail ] [-host hostname] [-port
portname/number] [-user username] [-sasl | -nosasl] [-saslmech
mechanism] [-tls] [-initialtls] [-notls] [-certverify |
-nocertverify] [-authservice service] [-snoop] [users ... ]
β¨ DESCRIPTION β¨
okay so msgchk is literally your personal "is anybody texting me tho" detector π
it checks all known mail drops for mail that's waiting for you. and for the drops that do have mail with your name on it, msgchk will tell you if it thinks you've already seen that mail before. like, seen-seen. π
the -notify type switch is the vibe-setter: it says under what circumstances msgchk should even produce a message. the default is -notify all, which means "always tell me the status of the user's mail drop, idc." other values for type include mail β report the status of waiting mail β and nomail β report the status of empty mail drops. the -nonotify type switch is the same thing but with the inverted sense, so -nonotify all tells msgchk to never report the status of mail drops, periodt. this is lowkey useful if you just wanna check msgchk's exit status and not read a whole essay. and heads up: a non-zero exit status means mail was not waiting for at least one of the indicated users. that's the signal, bestie πΆ
and if msgchk does produce output, then the -date switch directs it to print out the last date mail was read β if this can be determined. no promises, it said what it said π«Ά
π¬ Using POP
normally msgchk checks all the local mail drops, but if the option pophost: is set in the mts configuration file mts.conf, or if you hand it the -host hostname switch, then msgchk will go query that POP service host about the status of mail that's waiting. the -port switch specifies the port name or number used to connect to the POP server β and if you don't specify one, the default is pop3. she has a default, she's fine π
to specify a username for authentication with the POP server, use the -user username switch. the credentials profile entry in mh-profile(5) describes the ways to supply a username and password. iykyk π
for debugging purposes there's also a -snoop switch, which lets you literally watch the POP transaction happen between you and the POP server, like you're in the group chat reading over everyone's shoulder πΏ and if -sasl -saslmech xoauth2 is used, the HTTP transaction is shown too. the drama, the intrigue, the packets.
if nmh has been compiled with SASL support, the -sasl switch will enable the use of SASL authentication. depending on which SASL mechanism gets used, this may require an extra password prompt from you β but the netrc file can be used to store this password, as described in mh-profile(5). the -saslmech switch can be used to select a particular SASL mechanism. pick your fighter βοΈ
if SASL authentication succeeds, msgchk will attempt to negotiate a security layer for session encryption. encrypted traffic gets labelled with (encrypted) and (decrypted) when you're viewing the POP transaction with the -snoop switch; peep post(8)'s description of -snoop for its other features. β¨
if nmh has been compiled with OAuth support, the -sasl -saslmech xoauth2 combo will enable OAuth authentication. the -user switch must be used, and the user-name must be an email address the user has for the service, which must be specified with the -authservice service switch. before using this, you have to authorize nmh by running mhlogin and grant authorization to that account. see mhlogin(1) for more deets π
if nmh has been compiled with TLS support, the -tls and -initialtls switches will require the negotiation of TLS when connecting to the remote POP server. the -tls switch negotiates TLS as part of the normal POP protocol using the STLS command. the -initialtls switch negotiates TLS immediately after the connection has taken place β before any POP commands are sent or received, like, zero small talk, straight to business. data encrypted by TLS is labeled (tls-encrypted) and (tls-decrypted) when viewing the POP transaction with the -snoop switch. the -notls switch disables all attempts to negotiate TLS. π
when using TLS the default is to verify the remote certificate and SubjectName against the local trusted certificate store. this can be controlled by the -certverify and -nocertverify switches. see your OpenSSL documentation for more info on certificate verification β that's a whole other manpage, bestie π
ποΈ FILES ποΈ
$HOME/.mh_profileβ the user profile π«Ά/etc/nmh/mts.confβ the nmh mts configuration file βοΈ/var/mail/$USERβ location of the mail drop π¬
π§© PROFILE COMPONENTS π§©
None β nothing to see here, it's giving minimalism π
π SEE ALSO π
π DEFAULTS π
userdefaults to the current user-date-notify all
π CONTEXT π
None β again, no context, we keep it mysterious β¨
and that's the whole page, bestie!! this lil masterpiece is from nmh-1.8, dated 2016-11-02, and it lives in section MSGCHK(1mh) π go check your mail, you're probably ignoring something important π¦β¨π
π¦ where this page comes from
- debian trixie: nmh 1.8-3
- ubuntu noble: nmh 1.8-1build4
- ubuntu questing: nmh 1.8-3
- ubuntu resolute: nmh 1.8-4
- ubuntu stonking: nmh 1.8-4build1
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms