{
    "mode": "man",
    "parameter": "mh-mkstemp",
    "section": "1",
    "url": "https://www.chedong.com/phpMan.php/man/mh-mkstemp/1/json",
    "generated": "2026-05-30T06:08:17Z",
    "synopsis": "/usr/lib/mh/mkstemp [-help] [-version] [-directory directory] [-prefix prefix] [-suffix suf‐\nfix]",
    "sections": {
        "NAME": {
            "content": "mkstemp - create a temporary file\n",
            "subsections": []
        },
        "SYNOPSIS": {
            "content": "/usr/lib/mh/mkstemp [-help] [-version] [-directory directory] [-prefix prefix] [-suffix suf‐\nfix]\n",
            "subsections": []
        },
        "DESCRIPTION": {
            "content": "mkstemp creates a temporary file using mkstemp(3), or if the -suffix switch is available  and\nused,  mkstemps(3).   The  file name identifies a unique, newly created file, and always con‐\ntains 6 characters that appear to be random.\n\nThe -directory switch specifies a directory in which to create the file.\n\nThe -prefix switch specifies an initial part, before the 6 characters, of the file name.\n\nThe -suffix switch is only supported on platforms that provide the mkstemps(3) library  func‐\ntion.  It specifies a suffix to appear after the 6 characters; if it should begin with a spe‐\ncial character such as a period, that must be explicit in suffix.\n\nUnlike arguments to most switches of other nmh commands, the arguments  to  mkstemp  switches\ncan begin with a dash.\n",
            "subsections": []
        },
        "EXIT STATUS": {
            "content": "If  mkstemp successfully creates the temporary file, it prints the file name on standard out‐\nput and exits with status 0.  On failure, it prints a diagnostic message  on  standard  error\nand exits with status 255.\n",
            "subsections": []
        },
        "PROFILE COMPONENTS": {
            "content": "None\n",
            "subsections": []
        },
        "SEE ALSO": {
            "content": "mkstemp(3), mkstemps(3)\n",
            "subsections": []
        },
        "DEFAULTS": {
            "content": "-directory    current directory\n-prefix       none\n-suffix       none\n\n\n\nnmh-1.7.1                                    2014-03-16                              MH-MKSTEMP(1mh)",
            "subsections": []
        }
    },
    "summary": "mkstemp - create a temporary file",
    "flags": [],
    "examples": [],
    "see_also": [
        {
            "name": "mkstemp",
            "section": "3",
            "url": "https://www.chedong.com/phpMan.php/man/mkstemp/3/json"
        },
        {
            "name": "mkstemps",
            "section": "3",
            "url": "https://www.chedong.com/phpMan.php/man/mkstemps/3/json"
        }
    ]
}