Microsoft PowerShell Core now can be easily installed in Ubuntu 18.04, Ubuntu 16.04 via Snap package.
PowerShell is a task automation and configuration management framework from Microsoft, consisting of a command-line shell and associated scripting language.
It was announced on MSDN blogs:
“The goal of PowerShell Core is to be the ubiquitous language for managing your assets in the hybrid cloud. That’s why we’ve worked to make it available on many operating systems, architectures, and flavors of Linux, macOS, and Windows as possible.
Today, we’re happy to announce an addition to our support matrix: PowerShell Core is now available as a Snap package.“
How to Install PowerShell in Ubuntu via Snap:
Snap packages are containerized applications that can be installed on many Linux distributions. Snap bundles its dependencies in a single package and updates itself automatically once new version is published.
To install PowerShell snap, open Ubuntu Software, search for and install PowerShell Core:
or open terminal (Ctrl+Alt+T) and install it by running command:
snap install powershell --classic
NOTE for Ubuntu 16.04 users first time installing a snap package, install
snapd before getting started:
sudo apt install snapd snapd-xdg-open