Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 4 additions & 2 deletions build.psm1
Original file line number Diff line number Diff line change
Expand Up @@ -851,15 +851,17 @@ function Install-Dotnet {
[CmdletBinding()]
param(
[string]$Channel = "rel-1.0.0",
[string]$Version = "latest",
[string]$Version,
[switch]$NoSudo
)

# This allows sudo install to be optional; needed when running in containers / as root
# Note that when it is null, Invoke-Expression (but not &) must be used to interpolate properly
$sudo = if (!$NoSudo) { "sudo" }

$obtainUrl = "https://raw.githubusercontent.com/dotnet/cli/rel/1.0.0/scripts/obtain"
# this url is temporarely alternated because of https://github.com/dotnet/cli/issues/4715
# it should be reverted back to "https://raw.githubusercontent.com/dotnet/cli/rel/1.0.0/scripts/obtain" ASAP
$obtainUrl = "https://raw.githubusercontent.com/dotnet/cli/9855dc0088cf7e56e24860c734f33fe8353f38a6/scripts/obtain"

# Install for Linux and OS X
if ($IsLinux -or $IsOSX) {
Expand Down