创建个时间文件
cat test.txt 20200121 12:15:20 20200212 12:25:30 20200313 08:35:30
shell脚本
IFS_old=$IFS IFS=$'\n' for line in $(cat test.txt) do echo $line; date -s "$line" time=$[$RANDOM%5+20] echo $time sleep $time cd /root/test-install/ echo "$line"> test.txt git add . -A git commit -m "update" git push origin master done IFS=$IFS_old
请登录之后再进行评论