Hi Guys,
I am having below code which runs based on condition, Is it possible to check condition at the time of trigger
code=$1
if [ $counter -eq 3 ];then
nohup sh script.sh $val 1 &
fi
I need to trigger if the $code = JP then only to trigger
nohup sh script.sh $val 1 &
My try but wanted to check in single line when i am triggering nohup script command
if [[ "${counter}" -eq 3 && "${code}" = 'JP' ]]; then nohup sh script.sh $val 1 &