Skip to content

Instantly share code, notes, and snippets.

@Johnnie88
Last active May 7, 2025 04:41
Show Gist options
  • Save Johnnie88/c6b1f9732da81ec44171ca6a00d229e0 to your computer and use it in GitHub Desktop.
Save Johnnie88/c6b1f9732da81ec44171ca6a00d229e0 to your computer and use it in GitHub Desktop.
Install Powershell from scratch
#!bin/bash
sudo apt-get update
sudo apt-get install -y wget apt-transport-https software-properties-common
sudo curl -sL https://packages.microsoft.com/keys/microsoft.asc | sudo apt-key add -
sleep 4
sudo apt-add-repository "deb [arch=amd64] https://packages.microsoft.com/linux/repos/microsoft-powershell/ubuntu $(lsb_release -cs) main"
sudo apt-get update
sudo apt-get install powershell
# Start PowerShell
pwsh
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment