MARK(1mh)

πŸ“¦
version 1.8 Β· 4 versions
, in debian trixie, ubuntu noble, ubuntu questing, ubuntu resolute, ubuntu stonking

πŸ’– MARK(1mh) πŸ’–

okay bestie, welcome to mark β€” the nmh command that manipulates nmh message sequences, and honestly? it's giving folder-specific keyword energy and i'm obsessed. ✨


✨ SYNOPSIS ✨

mark [-help] [-version] [+folder] [msgs] [-sequence name ...]  [-add |
     -delete | -list] [-public | -nopublic] [-zero | -nozero] [-empty |
     -noempty] [-range | -norange]

🌸 DESCRIPTION 🌸

So like. The mark command manipulates message sequences by adding or deleting message numbers from folder-specific message sequences, or by listing those sequences and messages. Slay. πŸ’…

A message sequence is a keyword, just like one of the "reserved" message names, such as "first" or "next". But here's the thing β€” unlike the "reserved" message names, which have a fixed semantics on a per-folder basis, the semantics of a message sequence may be defined, modified, and removed by the user. You're the main character here, fr fr. πŸ‘‘

And message sequences are folder-specific, e.g., the sequence name "seen" in the context of folder "+inbox" need not have any relation whatsoever to the sequence of the same name in a folder of a different name. different folder, different vibe, no cap. πŸ¦‹


Three action switches direct the operation of mark. These switches are mutually exclusive: the last occurrence of any of them overrides any previous occurrence of the other two. so don't be messy about it bestie, the last one wins periodt.

πŸ’œ -add β€” the "add to the group chat" one

The -add switch tells mark to add messages to sequences or to create a new sequence. For each sequence named via the -sequence name argument (which must occur at least once), the messages named via msgs (which defaults to "cur" if no msgs are given), are added to the sequence. The messages to be added need not be absent from the sequence β€” like, they can already be there, it's fine, no drama.

If the -zero switch is specified, the sequence will be emptied prior to adding the messages. Hence, -add -zero means that each sequence should be initialized to the indicated messages, while -add -nozero means that each sequence should be appended to by the indicated messages. The -empty switch does not affect the operation of -add.

πŸ’œ -delete β€” the "removed from the group chat" one

The -delete switch tells mark to delete messages from sequences, and is the dual of -add. For each of the named sequences, the named messages are removed from the sequence. These messages need not be already present in the sequence. 😌

If the -zero switch is specified, then all messages in the folder are added to the sequence (first creating the sequence, if necessary) before removing the messages. Hence, -delete -zero means that each sequence should contain all messages except those indicated, while -delete -nozero means that only the indicated messages should be removed from each sequence.

As expected, the command mark -sequence foo -delete all empties the sequence "foo", and therefore removes that sequence from the current folder's list of sequences. Sequence foo must exist or a "no such sequence" error results. 😭 This can be avoided by adding -zero: mark -sequence foo -delete -zero all ensures sequence foo no longer exists. The -empty switch does not affect the operation of -delete.

πŸ’œ public vs private β€” the settings/privacy of it all

When creating or modifying sequences, you can specify the switches -public or -nopublic to force the new or modified sequences to be "public" or "private".

  • The switch -public indicates that the sequences should be made "public". These sequences will then be readable by all nmh users with permission to read the relevant folders.
  • The -nopublic switch indicates that the sequences should be made "private", and will only be accessible by you. πŸ™ˆ

If neither of these switches is specified, then existing sequences will maintain their current status, and new sequences will default to "public" if you have write permission for the relevant folder. Check mh-sequence(5) for more details about the difference between "public" and "private" sequences.

πŸ’œ -list β€” the "read the receipts" one

The -list switch tells mark to list all sequences, and the messages associated with them. The output can be limited to just certain sequences (with -sequence switches) and/or messages (with msgs arguments). Normally, -list will show all sequences associated with the folder, or all sequences given with -sequence.

Using -noempty will suppress any which would show as empty, whether because they actually are empty, or because they don't include any of the given msgs, or because they've been specified with -sequence but don't exist. (-empty is the default.)

With the default -range switch, mark will compress consecutive runs of message numbers to save space. That is, "3 4 5 6" will be shown as the range "3-6". With -norange, lists will be fully enumerated. The -zero switch does not affect the operation of -list.


πŸŽ€ the restrictions on sequences (yes there are rules, bestie) πŸŽ€

  • The name used to denote a message sequence must consist of an alphabetic character followed by zero or more alphanumeric characters, and cannot be one of the (reserved) message names "new", "first", "last", "all", "next", or "prev".
  • Message ranges with user-defined sequence names are restricted to the form "name:n", "name:+n", or "name:-n", and refer to the first or last n messages of the sequence name. If = is substituted for :, these forms will instead refer to single messages positioned n away from one end or the other of the sequence. Constructs of the form "name1-name2" are forbidden for user defined sequences. πŸ’€

🌈 FILES 🌈

  • $HOME/.mh_profile β€” The user's profile.

⭐ PROFILE COMPONENTS ⭐

  • Path: β€” To determine the user's nmh directory.
  • Current-Folder: β€” To find the default current folder.

🫢 SEE ALSO 🫢

flist(1), pick(1), mh-sequence(5)


✨ DEFAULTS ✨

  • +folder β€” The current folder.
  • -add β€” If -sequence is specified, -list otherwise.
  • msgs β€” The current message, or all if -list is specified.
  • -nozero

πŸ’… CONTEXT πŸ’…

If a folder is given, it will become the current folder.


πŸ”₯ HELPFUL HINTS πŸ”₯

Use flist to find folders with a given sequence, and pick sequence -list to enumerate those messages in the sequence (such as for use by a shell script).


okay that's the whole thing bestie, go forth and manipulate those sequences, you've got this πŸ’–

this was nmh-1.8, dated 2021-05-01, and that's the MARK(1mh) era of the manpage β€” love that for us, mwah πŸŽ€βœ¨

πŸ“¦ where this page comes from