{
    "mode": "info",
    "parameter": "DIST",
    "section": "",
    "url": "https://www.chedong.com/phpMan.php/info/DIST/json",
    "generated": "2026-07-05T17:51:26Z",
    "synopsis": "dist [-help] [-version] [+folder] [msg] [-form formfile] [-annotate |\n-noannotate] [-inplace | -noinplace] [-draftfolder +folder]\n[-draftmessage msg] [-nodraftfolder] [-editor editor] [-noedit]\n[-width columns] [-from address] [-to address] [-cc address] [-fcc\n+folder] [-whatnowproc program] [-nowhatnowproc] [-atfile] [-noat-\nfile]",
    "sections": {
        "NAME": {
            "content": "dist - distribute an nmh message to additional addresses\n",
            "subsections": []
        },
        "SYNOPSIS": {
            "content": "dist [-help] [-version] [+folder] [msg] [-form formfile] [-annotate |\n-noannotate] [-inplace | -noinplace] [-draftfolder +folder]\n[-draftmessage msg] [-nodraftfolder] [-editor editor] [-noedit]\n[-width columns] [-from address] [-to address] [-cc address] [-fcc\n+folder] [-whatnowproc program] [-nowhatnowproc] [-atfile] [-noat-\nfile]\n",
            "subsections": []
        },
        "DESCRIPTION": {
            "content": "dist is similar to forw.  It prepares the specified message for  redis-\ntribution  to  addresses  that (presumably) are not on the original ad-\ndress list.\n\nThe default message form contains the following elements:\n\nResent-From: {from switch} or <Local-Mailbox> or <username@hostname>\nResent-To: {to switch} or blank\nResent-cc: {cc switch} or blank\nResent-fcc: {fcc switch} or blank\n\nIf a file named \"distcomps\" exists in the user's nmh directory, it will\nbe  used  instead  of  this default form.  You may specify an alternate\nforms file with the switch -form formfile.  Forms are processed via the\nnmh template system; see mh-format(5) for details.  Components from the\nredistributed message are available as standard  component  escapes  in\nthe forms file.\n\nIn  addition to the standard mh-format(5) escapes, the following compo-\nnent escapes are also supported:\n\nEscape    Returns   Description\nfcc       string    Any folders specified with `-fcc folder'\nnmh-from  string    Addresses specified with `-from address'\nnmh-to    string    Addresses specified with `-to address'\nnmh-cc    string    Addresses specified with `-cc address'\n\nSee the forw(1) man page for descriptions of the -from, -to,  -cc,  and\n-fcc switches.\n\nIf the draft already exists, dist will ask you as to the disposition of\nthe draft.  A reply of quit will abort dist, leaving the draft  intact;\nreplace will replace the existing draft with a blank skeleton; and list\nwill display the draft.\n\nOnly those addresses in \"Resent-To:\", \"Resent-cc:\",  and  \"Resent-Bcc:\"\nwill  be  sent.   Also,  a  \"Resent-Fcc:  folder\"  will be honored (see\nsend(1)).  Note that with dist, the  draft  should  contain  only  \"Re-\nsent-xxx:\"  fields and no body.  The headers and the body of the origi-\nnal message are copied to the draft when the message is sent.  Use care\nin constructing the headers for the redistribution.\n\nBecause  the  draft  is minimal, the prompter(1) editor is quite useful\nwith dist.\n\nIf the -annotate switch is given, the  message being  distributed  will\nbe annotated with the lines:\nResent: date\nResent: addrs\nwhere each address list contains as many lines as required.  This anno-\ntation will be done only if the message is sent directly from dist.  If\nthe  message is not sent immediately from dist, \"comp -use\" may be used\nto re-edit and send the constructed message, but the annotations  won't\ntake  place.   Normally  annotations are done in place in order to pre-\nserve any links to the message.  You may use the -noinplace  switch  to\nchange this.\n\nSee  comp(1)  for  a  description  of the -editor and -noedit switches.\nNote that while in the editor, with -atfile and if the  current  direc-\ntory  is writable, the message being resent is available through a link\nnamed \"@\" (assuming the default whatnowproc).  In addition, the  actual\npathname of the message is stored in the environment variable $editalt,\nand the pathname of the folder containing the message is stored in  the\nenvironment  variable  $mhfolder.  The creation of the \"@\" file is con-\ntrolled via the -atfile and -noatfile options.\n\nThe -draftfolder +folder and -draftmessage msg switches invoke the  nmh\ndraft  folder  facility.   This is an advanced (and highly useful) fea-\nture.  Consult the mh-draft(5) man page for more information.\n\nUpon exiting from the editor, dist will  invoke  the  whatnow  program.\nSee  whatnow(1)  for a discussion of available options.  The invocation\nof this program can be inhibited by using  the  -nowhatnowproc  switch.\n(In  fact,  it  is  the  whatnow program which starts the initial edit.\nHence, -nowhatnowproc will prevent any edit from occurring.)\n",
            "subsections": []
        },
        "FILES": {
            "content": "/etc/nmh/distcomps  The default message skeleton.\n<mh-dir>/distcomps  The user's message skeleton.\n$HOME/.mhprofile   The user's profile.\n<mh-dir>/draft      The draft file.\n",
            "subsections": []
        },
        "PROFILE COMPONENTS": {
            "content": "Path:               To determine the user's nmh directory.\nCurrent-Folder:     To find the default current folder.\nDraft-Folder:       To find the default draft-folder.\nEditor:             To override the default editor.\nfileproc:           Program to refile the message.\nwhatnowproc:        Program to ask the \"What now?\" questions.\n",
            "subsections": []
        },
        "SEE ALSO": {
            "content": "comp(1), forw(1), prompter(1), repl(1), send(1), whatnow(1)\n",
            "subsections": []
        },
        "DEFAULTS": {
            "content": "+folder             The current folder.\nmsg                 The current message.",
            "subsections": [
                {
                    "name": "-noannotate",
                    "content": ""
                },
                {
                    "name": "-nodraftfolder",
                    "content": ""
                },
                {
                    "name": "-inplace",
                    "content": ""
                },
                {
                    "name": "-noatfile",
                    "content": ""
                }
            ]
        },
        "CONTEXT": {
            "content": "If a folder is given, it will become the current folder.   The  message\ndistributed will become the current message.\n",
            "subsections": []
        },
        "HISTORY": {
            "content": "dist  originally  used headers of the form \"Distribute-xxx:\" instead of\n\"Resent-xxx:\".  In order to conform with the  ARPA  Internet  standard,\nRFC 822, the \"Resent-xxx:\" form is now used.  dist will recognize \"Dis-\ntribute-xxx:\" type headers  and  automatically  convert  them  to  \"Re-\nsent-xxx:\".\n",
            "subsections": []
        },
        "BUGS": {
            "content": "dist does not rigorously check the message being distributed for adher-\nence to the transport standard, but post called by send does.  The post\nprogram  will  balk  (and rightly so) at poorly formatted messages, and\ndist won't correct things for you.\n\nIf whatnowproc is whatnow, then comp uses a built-in whatnow,  it  does\nnot  actually  run  the whatnow program.  Hence, if you define your own\nwhatnowproc, don't call it whatnow since comp won't run it.\n\nnmh-1.7.1                         2012-12-04                         DIST(1mh)",
            "subsections": []
        }
    },
    "summary": "dist - distribute an nmh message to additional addresses",
    "flags": [],
    "examples": [],
    "see_also": [
        {
            "name": "comp",
            "section": "1",
            "url": "https://www.chedong.com/phpMan.php/man/comp/1/json"
        },
        {
            "name": "forw",
            "section": "1",
            "url": "https://www.chedong.com/phpMan.php/man/forw/1/json"
        },
        {
            "name": "prompter",
            "section": "1",
            "url": "https://www.chedong.com/phpMan.php/man/prompter/1/json"
        },
        {
            "name": "repl",
            "section": "1",
            "url": "https://www.chedong.com/phpMan.php/man/repl/1/json"
        },
        {
            "name": "send",
            "section": "1",
            "url": "https://www.chedong.com/phpMan.php/man/send/1/json"
        },
        {
            "name": "whatnow",
            "section": "1",
            "url": "https://www.chedong.com/phpMan.php/man/whatnow/1/json"
        }
    ]
}