how to do loop in bash scripts