1

Trying to test for both upper and lower case directories

view story
linux-howto

http://www.unix.com – I am trying to get a script to print out whether a directory is lowercase uppercase or both. This is what I've got so far: echo -e read "enter name" read server for DIR in $(find /tmp/$server -type d -prune | sed 's/\.\///g');do if expr match "$server" "[a-zA-Z]*$" > /dev/null; then echo "$server - Both"; elif expr match "$server" "[[:upper:]]*$"; then echo "$server - Uppercase"; elif expr match "$server" "[[:lower:]]*$" > /dev/null; then echo "$server -there are lower";fi;doneNow this (HowTos)