Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
Refactor Get-Fork function to use Resolve-SystemNetWebRequest for URI retrieval and update Fork.json download URI
  • Loading branch information
aaronparker committed Feb 26, 2025
1 parent 2355bd7 commit 8f80934
Show file tree
Hide file tree
Showing 2 changed files with 22 additions and 26 deletions.
2 changes: 1 addition & 1 deletion Evergreen/Apps/Get-Fork.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ Function Get-Fork {
# Convert the returned release data into a useable object with Version, URI etc.
$PSObject = [PSCustomObject] @{
Version = $Version
URI = $res.Get.Download.Uri -replace "#version", $Version
URI = (Resolve-SystemNetWebRequest -Uri $res.Get.Download.Uri).ResponseUri.AbsoluteUri
}
Write-Output -InputObject $PSObject
}
Expand Down
46 changes: 21 additions & 25 deletions Evergreen/Manifests/Fork.json
Original file line number Diff line number Diff line change
@@ -1,28 +1,24 @@
{
"Name": "Dan Pristupov Fork",
"Source": "https://www.fork.dev",
"Get": {
"Update": {
"Name": "Dan Pristupov Fork",
"Source": "https://www.fork.dev",
"Get": {
"Update": {
"Uri": "https://git-fork.com/update/win/RELEASES?id=Fork&localVersion=1.57.1&arch=amd64",
"MatchVersion": "(\\d+(\\.\\d+){1,4}).*"
},
"Download": {
"Uri": "https://cdn.fork.dev/win/Fork-#version.exe"
}
},
"Install": {
"Setup": "ForkInstaller.exe",
"Physical": {
"Arguments": "",
"PostInstall": [

]
},
"Virtual": {
"Arguments": "",
"PostInstall": [

]
}
}
}
},
"Download": {
"Uri": "https://fork.dev/download/windows"
}
},
"Install": {
"Setup": "ForkInstaller.exe",
"Physical": {
"Arguments": "",
"PostInstall": []
},
"Virtual": {
"Arguments": "",
"PostInstall": []
}
}
}

0 comments on commit 8f80934

Please sign in to comment.