mirror of
https://github.com/monlor/MIXBOX-ARCHIVE.git
synced 2026-03-12 08:21:45 +00:00
2020-03-06 11:54:38
This commit is contained in:
@@ -4,4 +4,4 @@ needver=""
|
||||
supports="linux_arm,linux_mips,linux_x86_64"
|
||||
appinfo="一款支持多平台,多架构的Shell工具箱"
|
||||
newinfo="新增base64_encode工具"
|
||||
version="0.1.9.1"
|
||||
version="0.1.9.2"
|
||||
|
||||
@@ -9,11 +9,11 @@ wgetsh() {
|
||||
[ ! -d "$wgetfiledir" ] && mkdir -p $wgetfiledir
|
||||
[ ! -d ${mbtmp} ] && mkdir -p ${mbtmp}
|
||||
rm -rf ${mbtmp}/${wgetfilename}
|
||||
if command -v wget-ssl &> /dev/null; then
|
||||
if command -v curl &> /dev/null; then
|
||||
result1=$(curl -skL --connect-timeout 10 -m 20 -w %{http_code} -o "${mbtmp}/${wgetfilename}" "$wgeturl")
|
||||
else
|
||||
wget-ssl -q --no-check-certificate --tries=1 --timeout=10 -O "${mbtmp}/${wgetfilename}" "$wgeturl"
|
||||
[ $? -eq 0 ] && result="200"
|
||||
else
|
||||
result1=$(curl -skL --connect-timeout 10 -m 20 -w %{http_code} -o "${mbtmp}/${wgetfilename}" "$wgeturl")
|
||||
fi
|
||||
[ -f "${mbtmp}/${wgetfilename}" ] && result2=$(du -sh "${mbtmp}/${wgetfilename}" 2> /dev/null | awk '{print$1}')
|
||||
if [ "$result" = "200" ] && [ "$result2" != '0' ]; then
|
||||
|
||||
Reference in New Issue
Block a user