Skip to content

Instantly share code, notes, and snippets.

@rstanleyhum
Created October 1, 2017 11:44
Show Gist options
  • Save rstanleyhum/635e5ab16bfc1cffa0bd458f08f85442 to your computer and use it in GitHub Desktop.
Save rstanleyhum/635e5ab16bfc1cffa0bd458f08f85442 to your computer and use it in GitHub Desktop.
Install Anaconda3 5.0.0 script
$packageUrl = "https://repo.continuum.io/archive/Anaconda3-5.0.0-Windows-x86_64.exe"
$fileName = Split-Path $packageUrl -Leaf
$destinationDir = "C:\Users\stanley\Downloads"
$destinationPath = $destinationDir + "\" + $fileName
If (!(Test-Path -Path $destinationPath -PathType Leaf)) {
Write-Host "Downloading $fileName"
$webClient = New-Object System.Net.WebClient
$webClient.DownloadFile($packageUrl, $destinationPath)
}
Write-Output "Installing $packageUrl"
&$destinationPath
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment