Can somebody help me with this... I can't seem to get a working while statement (it never enters the loop)... Tried many different syntaxes and I'm stuck.
tries=0
success=false
while (!${success} && ${tries} -lt 10); do
{
echo "Trying..." &&
myCommand &&
success=true &&
echo "Success"
} || {
success=false &&
echo "Failed"
}
let tries=tries+1
done