project64: fix

master
beyondmeat 2022-03-07 17:42:21 -07:00 committed by Hugo Locurcio
parent c32e924a65
commit 9fb540bfa3
1 changed files with 21 additions and 4 deletions

View File

@ -6,8 +6,8 @@
"url": "https://github.com/project64/project64/blob/develop/license.md",
"identifier": "GPL-2.0"
},
"url": "https://www.pj64-emu.com/download/project64-3-0-1-zip",
"hash": "0cf95cbb70f33166258eff125f592bdf8534e8170af5f2b98a3d01b1516cead4",
"url": "https://www.pj64-emu.com/file/project64-3-0-0-5632-f83bee9#/dl.zip",
"hash": "6e2d123a0d665576649c16dc0cb902d70f9a1072a5fbcd23a5ab4cf3854dd07f",
"shortcuts": [
[
"Project64.exe",
@ -25,9 +25,26 @@
],
"checkver": {
"url": "https://www.pj64-emu.com/public-releases",
"regex": "<a href=\"(?<url>[^\"]*)\">Project64 ([0-9]+(\\.[0-9]+)+) Zip</a>"
"regex": "(.+?) (?<url>.*)",
"script": [
"$ProgressPreference = 'SilentlyContinue'",
"$aregex = New-Object System.Text.RegularExpressions.Regex(\"<a href=`\"/`(?<url>[^`\"]*`)`\">Project64`\\s+`(?<version>v?[`\\d.]+`)`\\s+Zip</a>\")",
"$amatch = $aregex.Matches($page) | Select-Object -First 1",
"$burl = $json.homepage + $amatch.Groups['url'].Value",
"$bpage = (Invoke-WebRequest $burl).Content",
"$bregex = New-Object System.Text.RegularExpressions.Regex(\"/`(?<url>file/project64-[\\d-]+-[0-9a-f]+`)\")",
"$bmatch = $bregex.Matches($bpage) | Select-Object -First 1",
"$rurl = $bmatch.Groups['url'].Value",
"$curl = $json.homepage + $bmatch.Groups['url'].Value",
"$cpage = (Invoke-WebRequest -Method Head $curl).RawContent",
"$cregex = New-Object System.Text.RegularExpressions.Regex(\"filename=`\"Project64-(?<version>[\\d.]+-[\\d]+-[0-9a-f]+`)\")",
"$cmatch = $cregex.Matches($cpage) | Select-Object -First 1",
"$rversion = $cmatch.Groups['version'].Value",
"Write-Output $rversion $rurl",
"$ProgressPreference = 'Continue'"
]
},
"autoupdate": {
"url": "https://www.pj64-emu.com$matchUrl"
"url": "https://www.pj64-emu.com/$matchUrl#/dl.zip"
}
}