This shows you the differences between two versions of the page.
— |
mkdir [2007/03/02 02:32] (current) |
||
---|---|---|---|
Line 1: | Line 1: | ||
+ | # $EPIC: mkdir.txt,v 1.3 2007/03/02 02:32:04 jnelson Exp $ | ||
+ | ======Synopsis:====== | ||
+ | $__mkdir__(<directory> [<directory> ...]) | ||
+ | |||
+ | ======Technical:====== | ||
+ | The <directory> argument(s) are [[what is a word|dword]] which is different | ||
+ | from most function arguments. | ||
+ | |||
+ | This function adds the following directories to the filesystem, using | ||
+ | the mkdir(3) library call. The default permissions are 0777, minus | ||
+ | the current umask value. Any number of directories may be created at | ||
+ | once. Tilde-expansion is permitted. | ||
+ | |||
+ | ======Practical:====== | ||
+ | This function creates one or more new directories. It is probably most | ||
+ | useful for script installers. Make sure you set your umask correctly, | ||
+ | otherwise you may inadvertently create the directory with permissions | ||
+ | that allow anyone to write to it. | ||
+ | |||
+ | ======Returns:====== | ||
+ | <file> | ||
+ | > 0 number of directories that could not be created | ||
+ | 0 success | ||
+ | </file> | ||
+ | |||
+ | ======Examples:====== | ||
+ | <file> | ||
+ | $mkdir(~/myscript) probably returns "0" | ||
+ | $mkdir(~/myscript /etc/hackerz) probably returns "1" | ||
+ | </file> | ||