Create new directory terminal
To create a new directory in the terminal, you can use the mkdir
command followed by the name of the directory you want to create.
For example, to create a directory called "mynewdirectory", you would type:
mkdir mynewdirectory
And press enter.
You can also create a directory with a specific path by specifying the path after the mkdir
command. For example, to create a directory called "mynewdirectory" in the "Documents" folder, you would type:
mkdir ~/Documents/mynewdirectory
The ~/
symbol represents your home directory, so this command would create the directory "mynewdirectory" in the "Documents" folder within your home directory.
You can also use the -p
option with mkdir
to create the directory and any parent directories that don't already exist. For example, to create a directory called "mynewdirectory" in the "path/to/parent/directory" directory, you would type:
mkdir -p path/to/parent/directory/mynewdirectory
This command would create the "mynewdirectory" directory and any parent directories that don't already exist, such as "path/to/parent/directory".