linux - How to print file/directory details using ls and AWK? -


i trying print output below using command:

ls -l| awk '/777/{print $0}' 

or

ls -l| awk '/0777/{print $0}' 

but not print anything. o/p should like,

drwxrwxrwx  2 sbcoper sbcprd   4096 apr 20  2015 work 

(i using 0777 or 777 because of find . -type f -perm 0777)

you've got right idea, 777 octal representation of permissions, , you're looking @ output of ls, lists permissions string, "drwxrwxrwx", simple modification of command work nicely, ls -l | awk '/rwxrwxrwx/{print $0}'


Comments

Popular posts from this blog

php - Zend Framework / Skeleton-Application / Composer install issue -

c# - Better 64-bit byte array hash -

python - PyCharm Type error Message -