#!/bin/bash
until [[ $(date +%S) -eq 30 ]]
do
sleep 0.75
done
while true
do
#command &
#here your cmds should be forked to background to avoid delaying
date +%S
sleep 30
done
editar
como você queria ver a data +% S stdout e verificar se = 30 e executar algo!
#!/bin/bash
foo(){
echo yay
#add commands here
}
while true
do
date +%S | grep '30' && foo
sleep 1
done
ou
#!/bin/bash
foo(){
echo yay
#add commands here
}
while true
do
date +%S
[[ $(date +%S) -eq 30 ]] && foo
sleep 1
done