mkdir
Create a folder
What it does
mkdir creates one or more folders: mkdir logs tmp. If the parent folder does not exist, it fails.
-p creates the whole path at once, missing parents included, and does not complain if the folder already exists. That makes mkdir -p handy in scripts.
Syntax
mkdir <folder>…
mkdir -p <path>Examples
Create the nested folders src/utils with one command
mkdir -p src/utilssame as:
mkdir --parents src/utilsmkdir— make a folder-p— with its parents, no error if it existssrc/utils— path