From bd7992d16d1bab0e54d41e2abe820a5130be837e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=BC=A0=E5=86=A0=E7=BE=A4?= Date: Mon, 19 Oct 2020 09:55:30 +0800 Subject: [PATCH] Edit by browser --- step2/2.sh | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/step2/2.sh b/step2/2.sh index 7a693aa..b2c4623 100644 --- a/step2/2.sh +++ b/step2/2.sh @@ -1,3 +1,12 @@ #!/bin/bash +sh /data/workspace/myshixun/step2/wenti.sh > 1.log 2>&1 & +curl -s http://cip.cc|awk -F '/' '/URL/{print $4}' > 2.log 2>&1 & +a=$(cat 1.log) +b=$(cat 2.log) + if [ "$a" = "$b" ] + then + echo "答案正确" + else + echo "答案错误" - + fi \ No newline at end of file