Function: mkdir

mkdir is a and interactive for make-directory, defined in files.el.gz.

Signature

(mkdir DIR &optional PARENTS)

Documentation

Create the directory DIR and optionally any nonexistent parent dirs.

If DIR already exists as a directory, signal an error, unless PARENTS is non-nil.

Interactively, the default choice of directory to create is the current buffer's default directory. That is useful when you have visited a file in a nonexistent directory.

Noninteractively, the second (optional) argument PARENTS, if non-nil, says whether to create parent directories that don't exist. Interactively, this happens by default.

If creating the directory or directories fail, an error will be raised.

Probably introduced at or before Emacs version 23.1.

Key Bindings

Aliases

mkdir