commit 55838bc2910f3f73762ea513536b74af056ed9ec (tree)
parent 2282eb1be18fd2c76caec12d21fea55d9820d5b5
Author: LemonBoy <thatlemon@gmail.com>
Date: Fri, 4 Dec 2020 17:31:27 +0100
ci: Use eval to make retry() work for pipelines too
Diffstat:
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/ci/azure/linux_script b/ci/azure/linux_script
@@ -13,7 +13,7 @@ CMD_WAIT_TIME=10s
# We give up after retrying CMD_MAX_RETRY times.
retry() {
for i in $(seq 1 "$CMD_MAX_RETRY"); do
- "$@" && return
+ eval "$@" && return
echo "command \"$@\" failed, retrying..."
sleep ${CMD_WAIT_TIME}
done