What Does Ls Do in Unix?
Contents

ls–Lists the names of files in a particular Unix directory. If you type the ls command with no parameters or qualifiers, the command displays the files listed in your current working directory. When you give the ls command, you can add one or more modifiers to get additional information.

What does Ls do in Linux?

The ls command is used to list files or directories in Linux and other Unix-based operating systems. Just like you navigate in your File explorer or Finder with a GUI, the ls command allows you to list all files or directories in the current directory by default, and further interact with them via the command line.

What is ls command in UNIX with examples?

Linux ls command options

ls option Description
ls -p It is used to identify the directory easily by marking the directories with a slash (/) line sign.
ls -r It is used to print the list in reverse order.
ls -R It will display the content of the sub-directories also.
Robert Thorne

Robert Thorne

Automotive & Future Transportation Editor

Robert Thorne covers electric vehicle innovations, autonomous driving systems, global mobility trends, and automotive engineering developments.

Share this article
Twitter Facebook Pinterest