How Use Ls Command 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 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.

What is LS LRT command in Unix?

ls -r lists the files in the reverse of the order that they would otherwise have been listed in. Thus, ls -lrt will give a long listing, oldest first, which is handy for seeing which files in a large directory have recently been changed.

Sarah Jenkins

Sarah Jenkins

Senior Technology Editor & AI Specialist

Sarah Jenkins is a veteran tech journalist with over 12 years of experience covering artificial intelligence, mobile innovations, and digital ethics. Her insights have appeared in leading technology publications worldwide.

Share this article
Twitter Facebook Pinterest