Skip to content

Instantly share code, notes, and snippets.

@FeodorFitsner
Last active March 21, 2023 03:18
Show Gist options
  • Save FeodorFitsner/c62c323dee76b6c116e6ea699770f587 to your computer and use it in GitHub Desktop.
Save FeodorFitsner/c62c323dee76b6c116e6ea699770f587 to your computer and use it in GitHub Desktop.
Install .NET 5.0.408
image: Visual Studio 2022
install:
- ps: |
Write-Host "Downloading..."
$zipPath = "$env:TEMP\dotnet-sdk.zip"
(New-Object Net.WebClient).DownloadFile("https://dotnetcli.azureedge.net/dotnet/Sdk/7.0.202/dotnet-sdk-7.0.202-win-x64.zip", $zipPath)
Write-Host "Unpacking..."
7z x $zipPath -aoa -o"C:\Program Files\dotnet" | Out-Null
test_script:
- dotnet --version
build: off
image: Visual Studio 2022
init:
- dotnet --version
- ps: |
$VerbosePreference = "continue"
Invoke-WebRequest -Uri 'https://dot.net/v1/dotnet-install.ps1' -UseBasicParsing -OutFile "$env:temp\dotnet-install.ps1"
& $env:temp\dotnet-install.ps1 -Architecture x64 -Version '7.0.202' -InstallDir "$env:ProgramFiles\dotnet"
test_script:
- dotnet --version
- dotnet --list-sdks
- dotnet --list-runtimes
build: off
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment