mkdir for filesystem
Create directories, with intermediary directories if required using uutils/coreutils mkdir.
Command Type
built-in
Signature
> mkdir {flags} ...rest
Flags
--verbose, -v: Print a message for each created directory.--fail-if-exists: Error if a target path already exists instead of treating it as success.
Parameters
...rest: The name(s) of the path(s) to create.
Input/output types:
| input | output |
|---|---|
| nothing | nothing |
| nothing | table<path: string, created: bool, error: oneof<nothing, string>> |
Examples
Make a directory named foo.
> mkdir fooMake a directory, erroring if it already exists.
> mkdir --fail-if-exists fooMake multiple directories and show the paths created, as absolute paths.
> mkdir -v foo/bar foo2