#!/bin/sh result=100 while [ "$result" -ne 1 ] do result=$(curl -s 'http://www.test.com/') sleep 1s done echo "done"
脚本解释:只要返回的结果不等于1 将持续循环下去
小程序版,打开微信APP"扫一扫"