Actually I want to create an array of dates and compare it to the today date if it match with the current date then execute test.sh file otherwise exit the loop in bash script. I did like this...#!/bin/bashcd /home/user1current_date=$(date +%Y-%m-%d)array=['2016-03-02','2016-03-010','2016-05-10']for i in ${array[@]}doif [ $now -eq $i ]; then        echo executing your bash script file    ./myscript.shfidonewhen i execute above script then it gives error like./sample.sh: line 6: [: 2016-03-02: integer expression expected
create an array of dates in bash scripts and match it current date
bash;shell script;array