RMF(1)
π RMF β remove an nmh folder π
okay bestie so you got a folder and you want it GONE, and rmf is literally the girl for the job. it's from the nmh suite, she's a General Commands Manual</> girlie, and she does exactly one thing but she does it iconically. π
β¨ SYNOPSIS β¨
rmf [-help] [-version] [+folder] [-interactive | -nointeractive]
that's it. that's the whole vibe. πΈ
π¦ DESCRIPTION π¦
so rmf removes all of the messages (which are just files, no cap) inside the folder you specified β or the default folder if you didn't specify one β and then it removes the folder (directory) itself too. gone. poof. π
here's the tea though: if there are any files hanging out inside that folder that are NOT part of nmh, she will not remove them, and she will throw an error at you. she's not messy like that. π
now, about the whole confirmation thing:
- if the folder is given explicitly, OR the
-nointeractiveoption is given, then the folder gets removed without confirmation. she just goes for it. main character energy. π₯ - otherwise? she's gonna ask you for confirmation first. she's polite. π«Ά
and if rmf can't, for some reason, find the current folder? then the folder to be removed defaults to +inbox β unless your user's profile entry βInboxβ overrides it β and yes, she'll still ask for confirmation in that case.
okay now the subfolder situation, because this part is lowkey genius: if the folder you're removing is a subfolder, the parent folder becomes the new current folder, and rmf will produce a message telling you that this happened. π’ and this gives you a really easy mechanism for: selecting a set of messages, operating on the list, then removing the list and returning to the current folder, from which the list was extracted. like, chef's kiss workflow. π
and now the scary part, bestie, listen up:
ifrmfis used on a read-only folder, it will delete all the private sequences (i.e.,βatr-seq-folderβentries) for this folder from your context β without affecting the folder itself.
also:
rmf irreversibly deletes messages that don't have other links. so use it with caution, fr fr. π there is no undo button. no trash can. no nothing.
π FILES π
$HOME/.mh_profileβ the user profile β¨
π PROFILE COMPONENTS π
Path:β to determine the user's nmh directoryCurrent-Folder:β to find the default current folderInbox:β to find the default inbox
π SEE ALSO π
go read those too, they're her friends π«Ά
β DEFAULTS β
+folderdefaults to the current folder, usually with confirmation-interactiveif+folder'not given,-nointeractiveotherwise
π§ CONTEXT π§
rmf will set the current folder to the parent folder if a subfolder is removed. or, if the current folder is the one being removed, it will make βinboxβ current. otherwise? she doesn't change the current folder or message. she stays out of your business. π
π BUGS π
okay so this is the part that gets everybody. intuitively you'd suspect that rmf works recursivelyβ¦ and she does NOT. π
so if you have a sub-folder within a folder, and you wanna rmf the parent, you must first rmf each of the children. one by one. no shortcuts. that's just how she is. π
and that's the whole page, bestie!! this lil masterpiece is from nmh-1.8, dated 1999-04-30 β yeah she's been iconic since the 90s and she's still serving. πβ¨ go forth and delete responsibly, mwah ππ¦πΈ
π¦ where this page comes from
- alpine 3.24: nmh-doc 1.8-r3 Β· BSD-3-Clause
- epel 10: nmh 1.8-3.el10_1 Β· BSD
- epel 9: nmh 1.8-1.el9 Β· BSD
- fedora 43: nmh 1.8-9.fc43 Β· LicenseRef-Callaway-BSD
- fedora 44: nmh 1.8-10.fc44 Β· LicenseRef-Callaway-BSD
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms