The ls command lists all files and child directories of a directory. For instance, inside the /home/nmurgor path:

Image showing the current directory

To list files of a child directory, say Downloads:

nmurgor@nmurgor:~$ ls Downloads/

The ls command can take an absolute path or relative path of the directory to list the files/directories from. The ls command can be supplied with the -a flag to list all content including hidden directories and files:

Image showing the current directory

Note: Hidden files/directories are named starting with .

Found this article helpful? You may follow me on Twitter where I tweet about interesting topics on software development.