HP-UX Reference (11i v2 03/08) - 1 User Commands A-M (vol 1)

m
mkdir(1) mkdir(1)
mkdir returns exit code 0 if the
-p option was specified, and all the specified directories now exist. If any
of the intermediate directories do not have search or write permission (with the
-p option), mkdir prints
a diagnostic and returns non-zero.
EXAMPLES
Create directory
gem beneath existing directory raw
in the current directory:
mkdir raw/gem
Create directory path raw/gem/diamond
underneath the current directory and set permissions on
directory
diamond to read-only for all users (
a=r):
mkdir -p -m "a=r" raw/gem/diamond
which is equivalent to (see chmod(1)):
mkdir -p -m 444 raw/gem/diamond
If directories raw or raw and gem already exist, only the missing directories in the specified path are
created.
SEE ALSO
rm(1), setacl(1), sh(1), umask(1), aclv(5).
STANDARDS CONFORMANCE
mkdir: SVID2, SVID3, XPG2, XPG3, XPG4, POSIX.2
Section 1540 Hewlett-Packard Company 2 HP-UX 11i Version 2: August 2003