install powershell in ubuntu 16.04

Hi Techrunnr Readers, this document deals with how to install powershell in ubuntu 16.04
PowerShell is a task automation and configuration management framework from Microsoft, consisting of a command-line shell and associated scripting language.

Installation

1. Import public repository GPG key

curl https://packages.microsoft.com/keys/microsoft.asc | sudo apt-key add -

2. Add PowerShell repository

curl https://packages.microsoft.com/config/ubuntu/16.04/prod.list | sudo tee /etc/apt/sources.list.d/microsoft.list

3. update system repository

apt-get update

4. Install PowerShell

sudo apt-get install -y powershell

5. Start Powershell by executing the following command

powershell

 


That’s it

If you get following error, just install the package manually,

The following packages have unmet dependencies:
PowerShell : Depends: libicu55 but it is not installable
E: Unable to correct problems, you have held broken packages.

Here is the command to download and install libicu55

cd /tmp

wget http://security.ubuntu.com/ubuntu/pool/main/i/icu/libicu55_55.1-7ubuntu0.4_amd64.deb

sudo apt install ./libicu55_55.1-7ubuntu0.4_amd64.deb

then execute step 5

© 2018, Techrunnr. All rights reserved.

#1
Questions Answered
Articles Written
Overall Points
Categories: Linux

Prabhin Prabharkaran

He is Technical professional. He is a person who loves to share tricks and tips on the Internet. He Posts what he does!!

Leave a Reply

Please wait...

Subscribe to our newsletter

Want to be notified when our article is published? Enter your email address and name below to be the first to know.