I have a script like this:
echo "enter filername in lowercase"
read -e filername exec 2>&1
echo "type the start date in format MM/DD/YYYY"
read -e startdate exec 2>&1
echo "enter the end date in format MM/DD/YYYY"
read -e enddate exec 2>&1
echo "please enter the path of file"
read -e filepath exec 2>&1
[ $(echo $filepath | egrep -c '^\/*\/.*[\/]$') -ne 0 ] && echo " enter path without trailing slash" && read filepath
command=`/local/mnt/script.host.pl -client=$filername -start=$startdate -end=$enddate -show_files -filename=$filepath\
|gawk '{print $1, $11}' |grep -v HOSTNAME | grep -vi Totals |uniq`
echo $command; if [[ "$command" == "No" ]]; then echo "yes";fi
I am trying to get it to return "yes" but all I get is no output
The command does actually return the word No. So I am trying to get it to echo "yes."