Answers for "mkdir - p linux"


mkdir - p linux

The -p flag will create nested directories, but only if they dont exist already.

For example, suppose you have a directory /foo that you have write permissions for.

mkdir -p /foo/bar/baz  # creates bar and baz within bar under existing /foo

It is also an idempotent operation, because if you run the same command over again, you will not get an error, but nothing will be created.
Posted by: Guest on March-18-2020

Code answers related to "Shell/Bash"

Browse Popular Code Answers by Language