pegali
1
Hi there,
Could some body tell me a simple way to get the following output.
The list of directories having atleast five characters.
I know the simplest way is:
ls -ad ?????
but that from 1-5, I want at least 5 characters long directories, I wrote a small awk command line, somthing like:
ls -l | awk '/^d/ && lenght($9)>=5 {print $0}' (somthing like that)
which works, but is there an easy way?
Help me out... thanx!
M
pegali
3
nah, it doesn't work, thanx for the try though...

This was asked a couple weeks ago.
I just retested it and it continues to work for me. What system are you using? What shell? I was on SunOs 5.8 and ksh.
pegali
6
Thanx Guys!
I was using CygWin, I guess its not a good idea to test everything there.
Anyways I came up with something what "oombera" has mentioned.
its like:
ls -ld | awk 'length($9)>=5 {print $0}'
Thanx a bunch again..