Missing symbol in linux shell script -


    #!/bin/bash     file=$/var/tmp/filename      if [ -f $file ];            echo "file $file exists"     else        echo "file $file not exists"     fi 

what missing here? getting following error on running above script

./installog.sh: 7: [: missing ]

i'm not seeing problem file, running wider in context.

one thing seem strange: file=$/var/tmp/filename why $ sign? doesn't seem proper path. remove it?


Comments