I am trying to find out if a file input by
the user is file or a directory ?
ls -l has the first field as the info I want
This is what I wrote
echo "Enter the name of a file"
set file = $<
set command = `ls -l $file`
set directory = $command
I get " drwxr-xr-x " but I want to decode this further to extract "d" or "-". Can anyone explain how this can be done ?