Last active
December 2, 2015 05:00
-
-
Save droyad/c2e7ea40a6a3c3abd0a3 to your computer and use it in GitHub Desktop.
Powershell script to install node and NPM
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$nodeVersion = "4.0.0" | |
Invoke-WebRequest "https://nodejs.org/download/release/v$nodeVersion/node-v$nodeVersion-x64.msi" -OutFile 'node.msi' | |
# If Invoke-WebRequest is not found on your version of PS: | |
# | |
# $request = [System.Net.WebRequest]::Create("https://nodejs.org/download/release/v$nodeVersion/node-v$nodeVersion-x64.msi") | |
# [System.Net.WebResponse]$response = $request.GetResponse() | |
# $file = [System.IO.File]::OpenWrite("node.msi") | |
# $response.GetResponseStream().CopyTo($file) | |
# $file.Close() | |
. .\node.msi /q /l node-install.log | |
Get-Content node-install.log |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment