Skip to main content
`Ctrl`+`K`

# PetscMkdtemp

Create a directory with a unique name given a name template.

## Synopsis

    PetscErrorCode PetscMkdtemp(char dir[])

## Input Parameter

- dir - file name template, the last six characters must be ‘XXXXXX’, and they will be modified upon return

## See Also

`PetscMkdir()`, `PetscRMTree()`

## Level

advanced

## Location

src/sys/fileio/fdir.c

## Examples

src/ksp/ksp/tutorials/ex76.c

Index of all Sys routines
Table of Contents for all manual pages
Index of all manual pages