Home Linux Microsoft PowerShell is Here for Linux. How to Install PowerShell in Ubuntu

Microsoft PowerShell is Here for Linux. How to Install PowerShell in Ubuntu

Microsoft PowerShell is a task automation and configuration administration structure, consisting of a command-line shell and correlated scripting language. This tool is useful and comes handy when the administrator needs to control the hybrid cloud assets.

Microsoft was not always open-minded regarding Linux and open source software. But things have been changed a lot when Satya Nadella has taken power to control the Microsoft. Few days before, we have seen the acquisition of GitHub, one of the largest open source software hub but many developers have transferred their software development to something else as the best alternative to GitHub. I think we should stop negative thinking about Microsoft that this company will not forward its hand for better development of open source software and Linux.

Microsoft PowerShell in Ubuntu Linux

Install Microsoft PowerShell in Ubuntu Linux

Following the recent steps, Microsoft again has given mind-blowing news for the developer and administrators and that’s PowerShell is now available for Linux as Snap package. Microsoft has taken a good step in providing PowerShell as Snap package because this package system will be the future of Linux system as many think so. You can install snap package across the distros, and that will decrease the fragmentation problem of Linux software system.

How to Install Microsoft PowerShell


In this short tutorial article, I will be showing you how to install PowerShell in Ubuntu Linux. You can install PowerShell either from Ubuntu software center or official Snap store. There are complete two version Microsoft Powershell available – Powershell core and PowerShell Core Preview.

If you have Ubuntu 17.10 and above installed on your machine, then Snapd is automatically enabled. So you can follow the official link of the snap store – PowerShell Core and PowerShell Core preview or search PowerShell on Ubuntu software center.

Microsoft PowerShell in Official Snap Store
Microsoft PowerShell in Official Snap Store

Microsoft PowerShell in Ubuntu software center as snap package
Microsoft PowerShell in Ubuntu software center as a snap package

Or else, you can open the Terminal (Ctrl+Alt+T) and run the below command to install PowerShell:

Microsoft PowerShell core

snap install powershell –classic

To run Powershell core

pwsh

Microsoft PowerShell core preview

snap install powershell-preview –classic

To run PowerShell core preview

pwsh-preview

PowerShell for Ubuntu 16.04 and below

In case, if you are still using old Ubuntu version, first you have to enable Snap. To do that follow the command:

sudo apt install snapd snapd-xdg-open

Now you can use the above command to install PowerShell. For more information – How to enable Snapd in Linux.

3 COMMENTS

  1. Just FYI if you try and run the commands to install PowerShell, you will get an error saying something along the lines of “flag not recognize `c”.
    The command should actually look like this `sudo snap install powershell –classic` or `sudo snap install powershell-preview –classic`

    if you are a regular Linux user this is probably something you already figured out but I’m not and spent a few minutes trying to get it worked out. So I hope this helps!

LEAVE A REPLY

Please enter your comment!
Please enter your name here

Latest Post

50 Useful and Simple IPtables Rules for Linux Administrator

One of the main reasons behind the immense popularity enjoyed by Linux is its sheer prowess in networking. Linux...

Linux Shell Roundup: 15 Most Popular Open Source Linux Shells

Unix systems have captivated the world since its inception in the 70s. One of the fundamental features that helped...

Top 20 Most Remarkable IoT Applications in Today’s World

In the nearest future, probably we are going to live in a world with connected devices — the curiosity...

Top 20 Best Python IDE for Linux. Some of Them are Open Source

Python is a programming language. User can apply it for general purposes to design program from the backend web...

Top 20 Funny Steam Games For Kids To Play Right Now

There are ample of funny steam games for kids available on the store for the Linux system. A couple...

Most Talked Post

Linux or Windows: 25 Things You Must Know While Choosing The Best Platform

Choosing the best platform - Linux or Windows is complicated. Because both the system is versatile and capable of...

Most Stable Linux Distros: 5 versions of Linux We Recommend

At the very beginning, I would like to mention why the term ‘Stable’ comes in relation to Linux OS...

15 Best Things To Do After Installing Linux Mint 19 “Tara”

Linux Mint is one of the best Linux distros for newcomers, especially who comes from other Operating Systems like...

Linux Mint vs Ubuntu: 15 Facts To Know Before Choosing The Best One

Ubuntu and Linux Mint are two popular Linux distros available in the Linux community. Ubuntu is a derivative of...

Top 5 Best Lightweight Linux Distros To Boost Up Your Old Computer

So here comes the million dollar question, why does anyone use Lightweight Linux distros? While all the modern Linux...

Editors' Pick

Linux PDF Editor: Top 15 Reviewed and Compared

Portable Document Format - PDF is one of the...

The 50 Most Useful Linux Commands To Run in the Terminal

No matter whether you're a seasoned Linux user like...

Top 10 Linux Firewall Software For Protecting Your Linux System

To be a successful Linux system administrator, ensuring the...

Top 15 Best Gnome Shell Themes for Your Gnome Desktop

Gnome Shell is one of the best and beautiful...

Linux Text Editor: 20 Text and HTML Editors Reviewed for Linux Nerds

From jotting down your latest thoughts to writing your...