what is the command to list files in a directory in UNIX?

Answers were Sorted based on User's Feedback



what is the command to list files in a directory in UNIX? ..

Answer / siva

Try this command

ls -lrt | grep "^-" - for list the only files
ls -lrt | grep "^d" - for list the only directory's

Is This Answer Correct ?    5 Yes 0 No

what is the command to list files in a directory in UNIX? ..

Answer / suitable

ls

Is This Answer Correct ?    6 Yes 2 No

what is the command to list files in a directory in UNIX? ..

Answer / jagadeesh kumar.k[tpgsi]

ls -lrt

Is This Answer Correct ?    4 Yes 2 No

what is the command to list files in a directory in UNIX? ..

Answer / brijmohan

ls : this command is used to see the list of file and
folder in present working directory.

ls -ltr : is used to see the file and folder in present
dirctory in alphabetical order.

Is This Answer Correct ?    0 Yes 0 No

what is the command to list files in a directory in UNIX? ..

Answer / yuvaevergreen

ls | grep "^-"

Is This Answer Correct ?    0 Yes 0 No

what is the command to list files in a directory in UNIX? ..

Answer / peeyush

ls -l |grep '^-'

Is This Answer Correct ?    1 Yes 2 No

what is the command to list files in a directory in UNIX? ..

Answer / p.ashwini

ls command is used to list files in a directory

Is This Answer Correct ?    1 Yes 2 No

what is the command to list files in a directory in UNIX? ..

Answer / sudip

ls -l | grep "^d"

Is This Answer Correct ?    2 Yes 5 No

Post New Answer

More Unix Commands Interview Questions

what is ls -ltd?

5 Answers   HCL,


what is the function of grep command?

4 Answers  


hw will u use awk in replacing cahrs and files

0 Answers  


What Command is used to make a directory?

4 Answers   IBM,


Explain the terms ‘system calls’ and ‘library functions’ with respect to unix commands?

0 Answers  


How do I find previous commands in unix?

0 Answers  


what are the differences between CUI and GUI interfaces?

52 Answers   College School Exams Tests, HCL, HP, IBM, IBMR, NIIT, Talco, Wipro,


what is the use of ls -l command & what is the information it gives about user ?

5 Answers  


Give Command that will change the name of a directly from paypal to eBay

3 Answers   Alcatel, IBM,


What does the command '$ls | wc –l > file1' do?

0 Answers  


What are awk commands?

0 Answers  


The rm command removes links to file. What does this mean? How then is a file deleted from the file system?

5 Answers  


Categories