On Fri, 31 Mar 2006, Grindell, Joan M. wrote:
Good Afternoon:I need to write a script/execute a command and don't have a lot of time to research. The script will take in the output from the ls -al command and evaluate only the first 10 characters (the file type and permissions). I want to copy out all the lines that have -********T or -********t in the file permissions indicators. What is the best to do this?
You want to pattern match? Why not use grep? ls -al | grep -i '^-........t' But depending on your end goal there may be a better way, like using find: find . -perm -1000 Good luck, -f http://www.blackant.net/
Thanks, Joan _______________________________________________ Solaris-Users mailing list [email protected] http://www.filibeto.org/mailman/listinfo/solaris-users
_______________________________________________ Solaris-Users mailing list [email protected] http://www.filibeto.org/mailman/listinfo/solaris-users
