Skip to content

Commit

Permalink
增加 构建请求超时时间至5s
Browse files Browse the repository at this point in the history
  • Loading branch information
xrgzs committed Sep 25, 2024
1 parent 770ebe8 commit 63d7cc1
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions build.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -16,14 +16,14 @@ function Get-LanzouFile {
)

try {
Invoke-WebRequest -Uri "https://api.xrgzs.top/lanzou/?type=down&url=$Uri" -OutFile $OutFile -ErrorAction Stop -ConnectionTimeoutSeconds 3
Invoke-WebRequest -Uri "https://api.xrgzs.top/lanzou/?type=down&url=$Uri" -OutFile $OutFile -ErrorAction Stop -ConnectionTimeoutSeconds 5
}
catch {
try {
Invoke-WebRequest -Uri "https://api.hanximeng.com/lanzou/?type=down&url=$Uri" -OutFile $OutFile -ErrorAction Stop -ConnectionTimeoutSeconds 3
Invoke-WebRequest -Uri "https://api.hanximeng.com/lanzou/?type=down&url=$Uri" -OutFile $OutFile -ErrorAction Stop -ConnectionTimeoutSeconds 5
}
catch {
Invoke-WebRequest -Uri "https://lz.qaiu.top/parser?url=$Uri" -OutFile $OutFile -ErrorAction Stop -ConnectionTimeoutSeconds 3
Invoke-WebRequest -Uri "https://lz.qaiu.top/parser?url=$Uri" -OutFile $OutFile -ErrorAction Stop -ConnectionTimeoutSeconds 5
}
}
}
Expand All @@ -47,8 +47,8 @@ else {
Get-LanzouFile -Uri "https://xrgzs.lanzouv.com/ixdbP27giisf" -OutFile "osc\xrsoft.exe"

# 下载其他文件
Invoke-WebRequest -Uri "http://url.xrgzs.top/osconline" -OutFile "osc\oscoffline.bat" -ErrorAction Stop -ConnectionTimeoutSeconds 3
Invoke-WebRequest -Uri "http://url.xrgzs.top/oscsoft" -OutFile "osc\oscsoftof.txt" -ErrorAction Stop -ConnectionTimeoutSeconds 3
Invoke-WebRequest -Uri "http://url.xrgzs.top/osconline" -OutFile "osc\oscoffline.bat" -ErrorAction Stop -ConnectionTimeoutSeconds 5
Invoke-WebRequest -Uri "http://url.xrgzs.top/oscsoft" -OutFile "osc\oscsoftof.txt" -ErrorAction Stop -ConnectionTimeoutSeconds 5
}

# 构建
Expand Down

0 comments on commit 63d7cc1

Please sign in to comment.