Skip to main content

function

mkdtemp

mkdtemp(suffix: String = "", prefix: String = "tmp", dir: Optional[String] = #kgen.none) -> String

Create a temporary directory. Caller is responsible for deleting the directory when done with it.

Args:

  • suffix (String): Suffix to use for the directory name.
  • prefix (String): Prefix to use for the directory name.
  • dir (Optional[String]): Directory in which the directory will be created.

Returns:

The name of the created directory.

Raises:

If the directory can not be created.