From 633ff5b7e075ee9954bea36b2c2e8ea9086cfaad Mon Sep 17 00:00:00 2001 From: WindowsAddict Date: Sun, 29 Sep 2024 03:50:18 +0530 Subject: [PATCH] Add self-hosted Git repo --- get | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/get b/get index 80404fb..74b13c2 100644 --- a/get +++ b/get @@ -6,15 +6,21 @@ $ErrorActionPreference = "Stop" $DownloadURL1 = 'https://raw.githubusercontent.com/massgravel/Microsoft-Activation-Scripts/52d4c52dba8e29a3c1fb295c8946dbe6cf2f0239/MAS/All-In-One-Version-KL/MAS_AIO.cmd' $DownloadURL2 = 'https://dev.azure.com/massgrave/Microsoft-Activation-Scripts/_apis/git/repositories/Microsoft-Activation-Scripts/items?path=/MAS/All-In-One-Version-KL/MAS_AIO.cmd&versionType=Commit&version=52d4c52dba8e29a3c1fb295c8946dbe6cf2f0239' +$DownloadURL3 = 'https://git.activated.win/massgrave/Microsoft-Activation-Scripts/raw/commit/52d4c52dba8e29a3c1fb295c8946dbe6cf2f0239/MAS/All-In-One-Version-KL/MAS_AIO.cmd' -$URLs = @($DownloadURL1, $DownloadURL2) +$URLs = @($DownloadURL1, $DownloadURL2, $DownloadURL3) $ShuffledURLs = $URLs | Sort-Object { Get-Random } try { $response = Invoke-WebRequest -Uri $ShuffledURLs[0] -UseBasicParsing } catch { - $response = Invoke-WebRequest -Uri $ShuffledURLs[1] -UseBasicParsing + try { + $response = Invoke-WebRequest -Uri $ShuffledURLs[1] -UseBasicParsing + } + catch { + $response = Invoke-WebRequest -Uri $ShuffledURLs[2] -UseBasicParsing + } } # Verify script integrity