[ < ] [ > ]   [ << ] [ Up ] [ >> ]         [Top] [Contents] [Index] [ ? ]

7.2 mkdir: Make directories

mkdir creates directories with the specified names. Synopsis:

 
mkdir [option]... name...

If a name is an existing file but not a directory, mkdir prints a warning message on stderr and will exit with a status of 1 after processing any remaining names. The same is done when a name is an existing directory and the -p option is not given. If a name is an existing directory and the -p option is given, mkdir will ignore it. That is, mkdir will not print a warning, raise an error, or change the mode of the directory (even if the -m option is given), and will move on to processing any remaining names.

The program accepts the following options. Also see 2. Common options.

`-m mode'
`--mode=mode'
Set the mode of created directories to mode, which is symbolic as in chmod and uses `a=rwx' (read, write and execute allowed for everyone) minus the bits set in the umask for the point of the departure. See section 3. File permissions.

`-p'
`--parents'
Make any missing parent directories for each argument. The mode for parent directories is set to the umask modified by `u+wx'. Ignore arguments corresponding to existing directories.

`-v'
`--verbose'
Print a message for each created directory. This is most useful with `--parents'.



This document was generated on May 3, 2002 using texi2html