Skip to content

Instantly share code, notes, and snippets.

@glombard
Created November 11, 2013 16:35
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save glombard/7416112 to your computer and use it in GitHub Desktop.
Save glombard/7416112 to your computer and use it in GitHub Desktop.
PowerShell to download 7za and cURL into the Windows directory
$c=New-Object Net.WebClient
$c.DownloadFile('http://heanet.dl.sourceforge.net/project/sevenzip/7-Zip/9.20/7za920.zip',"$env:TEMP\7za920.zip")
$c.DownloadFile('http://www.paehl.com/open_source/?download=curl_733_0_ssl.zip',"$env:TEMP\curl.zip")
$shell=New-Object -Com Shell.Application
$win=$shell.NameSpace($env:windir)
$win.CopyHere($shell.NameSpace("$env:TEMP\7za920.zip").Items(), 16)
$win.CopyHere($shell.NameSpace("$env:TEMP\curl.zip").Items(), 16)
@glombard
Copy link
Author

From the command-prompt:

powershell -NoProfile -ExecutionPolicy unrestricted -Command "iex ((new-object net.webclient).DownloadString('https://gist.github.com/glombard/7416112/raw/fb317426b2092a41770cf86b50463fb0c2f73706/get-curl.ps1'))"

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment