I\'ve used the following script to see if a file exists:
#!/bin/bash FILE=$1 if [ -f $FILE ]; then echo \"File $FILE exists.\" else echo \"File $
It's worth mentioning that if you need to execute a single command you can abbreviate
if [ ! -f "$file" ]; then echo "$file" fi
to
test -f "$file" || echo "$file"
or
[ -f "$file" ] || echo "$file"