This command is used to get list of files & folder at a particular path. Suppose there is a folder containing files and you want to know what all files are there in that folder we use this command. We use certain switches to get desired output.
Example1 : List all files in a folder.
// Go to a folder and enter ls command like below
Example2 : Show all the files of a directory, size, modified date and time, file and folder name and owner of file and its permission.
Example3 : View all hidden files in the folder.
Example4 : Know all files and directories in a current folder.
All files which are followed by / are directories and rest are files.
Example5 : List all files in reverse order.
Example6 : To print all files in reverse order.
Example7 : Sort the files by files size.
Example8 : List your home directory.
Example9 : List the home directory of user “Aman”.
GlobalSQA is one-stop solution to all your QA needs. Whatever your testing needs are, we have a solution. We provide solutions for all sorts of functional and non-functional testing as well as automation testing.