How to display a file name which has zero bytes in size.

Answer Posted / akula

ls -ltr | grep "^-" | sort -nk5 | head -1
or
ls -ltr | grep "^-" | sort -nk5 | head -1 | awk '{ print $9 }'

Is This Answer Correct ?    0 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

How do I open a port?

589


What is a bash command?

624


What is the command to view process running?

572


How can we use grep command in unix?

612


Which unix command lists files/folders in alphabetical order?

614






Is there a way to erase all files in the current directory, including all its sub-directories, using only one command?

795


What does sed command do in unix?

558


How to use grep command to list find the records of a file containing 10 different strings?

643


What is merge command in unix?

942


How does shebang work?

585


How does pipe () work?

591


How do I use nslookup?

571


Which command should you use to find the remaining disk space in unix server?

701


What is awk good for?

582


Write a command that will display files in the current directory, in a colored, long format.

680