12

I'm trying to install Powershell in Ubuntu 17.04 as the following these steps:

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

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

sudo apt-get update

sudo apt-get install -y powershell

I know I'm using 16.04 packages/built to install. Unfortunately I couldn't find the the 17.04 one.

And here is what error I've got with sudo apt-get install -y powershell

The following packages have unmet dependencies:  
  powershell : Depends: libicu55 but it is not installable 

Then I tried:

apt-cache search libicu

I couldn't find out the libicu55 to install either. Are there any way to install Powershell in Ubuntu 17.04?

David Foerster
  • 36,890
  • 56
  • 97
  • 151
Ender
  • 252
  • 2
  • 3
  • 10

4 Answers4

13

Download libicu55 package from http://packages.ubuntu.com/en/xenial/amd64/libicu55/download

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

If the sudo apt install fails, download the file directly from the provided link via the browser. Then open it with Software Install.

Then follow instructions for 16.04

...
sudo apt install -y powershell

Source: https://asknicks.blogspot.ru/2017/05/install-powershell-on-ubuntu-17.html

Adobe
  • 3,971
11

Download the AppImage version and follow the instructions:

Using a recent Linux distribution, download the AppImage PowerShell-6.0.0-alpha.18-x86_64.AppImage from the releases page onto the Linux machine.

Then execute the following in the terminal:

chmod a+x PowerShell-6.0.0-beta.5-x86_64.AppImage
./PowerShell-6.0.0-beta.5-x86_64.AppImage

The AppImage lets you run PowerShell without installing it. It is a portable application that bundles PowerShell and its dependencies (including .NET Core's system dependencies) into one cohesive package. This package works independently of the user's Linux distribution, and is a single binary.

muru
  • 207,228
user2856
  • 265
2

Microsoft do not have packages for 17.04 yet. Take a look at their github:

enter image description here

The problem you have is their package relies on libicu55, but 17.04 does not have that package in its repositories. Unless you build from source, you will not be able to install their public Powershell packages.

Foxie
  • 551
  • 4
  • 12
0

Visit the official Microsoft PowerShell Documentation webpage and click the link to visit PowerShell on GitHub or visit it directly. There you will find links to download PowerShell .deb files for Ubuntu 14.04, 16.04 and 17.04.

Download the PowerShell .deb file and double-click it to open it in the software application.


Ubuntu 14.04 and later

PowerShell can be installed as a snap package in all currently supported versions of Ubuntu. To install the PowerShell Core snap package open the terminal and type:

sudo snap install powershell --classic 
karel
  • 122,292
  • 133
  • 301
  • 332