Create Directory

When we want to create a directory in the Linux command line, we can use the mkdir (make directory) command.

View Directory Contents

ls -l
total 60
drwxrwxr-x 20 chris chris 4096 Oct 11  2017 anaconda3
drwxrwxr-x  2 chris chris 4096 Oct 13  2017 automatic_backups
drwxr-xr-x  3 chris chris 4096 Oct 21  2017 Desktop
drwxr-xr-x  2 chris chris 4096 Oct 10  2017 Documents
drwxr-xr-x  2 chris chris 4096 Jul 19 10:47 Downloads
-rw-r--r--  1 chris chris 8980 Oct 10  2017 examples.desktop
drwxr-xr-x  2 chris chris 4096 Oct 10  2017 Music
drwxrwxr-x  4 chris chris 4096 Oct 11  2017 nvvp_workspace
drwxr-xr-x  2 chris chris 4096 Oct 11  2017 Pictures
drwxr-xr-x  2 chris chris 4096 Oct 10  2017 Public
drwxr-xr-x  2 chris chris 4096 Oct 10  2017 Templates
drwxrwxr-x  7 chris chris 4096 Oct 11  2017 tensorflow
drwxr-xr-x  2 chris chris 4096 Oct 10  2017 Videos

Make A New Directory

mkdir example_directory

View Directory Contents

ls -l
total 64
drwxrwxr-x 20 chris chris 4096 Oct 11  2017 anaconda3
drwxrwxr-x  2 chris chris 4096 Oct 13  2017 automatic_backups
drwxr-xr-x  3 chris chris 4096 Oct 21  2017 Desktop
drwxr-xr-x  2 chris chris 4096 Oct 10  2017 Documents
drwxr-xr-x  2 chris chris 4096 Jul 19 10:47 Downloads
drwxrwxr-x  2 chris chris 4096 Jul 22 12:39 example_directory
-rw-r--r--  1 chris chris 8980 Oct 10  2017 examples.desktop
drwxr-xr-x  2 chris chris 4096 Oct 10  2017 Music
drwxrwxr-x  4 chris chris 4096 Oct 11  2017 nvvp_workspace
drwxr-xr-x  2 chris chris 4096 Oct 11  2017 Pictures
drwxr-xr-x  2 chris chris 4096 Oct 10  2017 Public
drwxr-xr-x  2 chris chris 4096 Oct 10  2017 Templates
drwxrwxr-x  7 chris chris 4096 Oct 11  2017 tensorflow
drwxr-xr-x  2 chris chris 4096 Oct 10  2017 Videos