@@ -9,7 +9,7 @@ if (!([Security.Principal.WindowsPrincipal][Security.Principal.WindowsIdentity]:
99 }
1010 # Get latest version information
1111 Write-Output " `n Fetching latest version information..."
12- $getLatest = Invoke-WebRequest - UseBasicParsing " https://api.github.com/repos/starchyunderscore/w11-nonadmin-utils/releases/latest" | ConvertFrom-Json
12+ $getLatest = Invoke-WebRequest - UseBasicParsing " https://api.github.com/repos/starchyunderscore/w11-nonadmin-utils/releases/latest" - Headers @ { " Cache-Control " = " no-cache " } | ConvertFrom-Json
1313 $latest = $getLatest.tag_name.Substring (0 )
1414 Write-Output " ...Done`n "
1515 # Ask what the user wants to do
@@ -27,13 +27,13 @@ if (!([Security.Principal.WindowsPrincipal][Security.Principal.WindowsIdentity]:
2727 1 { # Latest
2828 Write-Output " Downloading"
2929 Write-Output " Running"
30- Invoke-webRequest - UseBasicParsing " https://github.com/starchyunderscore/w11-nonadmin-utils/releases/download/$latest /setup.ps1" | Invoke-Expression
30+ Invoke-webRequest - UseBasicParsing " https://github.com/starchyunderscore/w11-nonadmin-utils/releases/download/$latest /setup.ps1" - Headers @ { " Cache-Control " = " no-cache " } | Invoke-Expression
3131 Write-Output " Done"
3232 }
3333 2 { # Alpha
3434 Write-Output " Downloading"
3535 Write-Output " Running"
36- Invoke-webRequest - UseBasicParsing " https://raw.githubusercontent.com/starchyunderscore/w11-nonadmin-utils/main/current/setup.ps1" | Invoke-Expression
36+ Invoke-webRequest - UseBasicParsing " https://raw.githubusercontent.com/starchyunderscore/w11-nonadmin-utils/main/current/setup.ps1" - Headers @ { " Cache-Control " = " no-cache " } | Invoke-Expression
3737 Write-Output " Done"
3838 }
3939 }
@@ -50,7 +50,7 @@ if (!([Security.Principal.WindowsPrincipal][Security.Principal.WindowsIdentity]:
5050 Write-Output " Canceled"
5151 } else {
5252 Write-Output " Downloading"
53- Invoke-webRequest - UseBasicParsing " https://github.com/starchyunderscore/w11-nonadmin-utils/releases/download/$latest /setup.ps1" - OutFile $savelc
53+ Invoke-webRequest - UseBasicParsing " https://github.com/starchyunderscore/w11-nonadmin-utils/releases/download/$latest /setup.ps1" - Headers @ { " Cache-Control " = " no-cache " } - OutFile $savelc
5454 Write-Output " Done"
5555 }
5656 }
@@ -60,7 +60,7 @@ if (!([Security.Principal.WindowsPrincipal][Security.Principal.WindowsIdentity]:
6060 Write-Output " Canceled"
6161 } else {
6262 Write-Output " Downloading"
63- Invoke-webRequest - UseBasicParsing " https://raw.githubusercontent.com/starchyunderscore/w11-nonadmin-utils/main/current/setup.ps1" - OutFile $savelc
63+ Invoke-webRequest - UseBasicParsing " https://raw.githubusercontent.com/starchyunderscore/w11-nonadmin-utils/main/current/setup.ps1" - Headers @ { " Cache-Control " = " no-cache " } - OutFile $savelc
6464 Write-Output " Done"
6565 }
6666 }
0 commit comments