Skip to content

Instantly share code, notes, and snippets.

@MateuszNad
Last active March 29, 2021 13:41
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 MateuszNad/f514bd067e7c509e78a51b720659d620 to your computer and use it in GitHub Desktop.
Save MateuszNad/f514bd067e7c509e78a51b720659d620 to your computer and use it in GitHub Desktop.
[System.Net.ServicePointManager]::SecurityProtocol = [System.Net.ServicePointManager]::SecurityProtocol -bor 3072
iex ((New-Object System.Net.WebClient).DownloadString('https://chocolatey.org/install.ps1'))
& choco --version
choco.exe
# try {
# try {
# & choco --version
# }
# catch {
# Set-ExecutionPolicy Bypass -Scope Process -Force
# [System.Net.ServicePointManager]::SecurityProtocol = [System.Net.ServicePointManager]::SecurityProtocol -bor 3072
# iex ((New-Object System.Net.WebClient).DownloadString('https://chocolatey.org/install.ps1'))
# }
# & choco.exe install 7zip -y
# }
# catch {
# exit $_
# }
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment