Skip to content

Instantly share code, notes, and snippets.

@thinktanklinux
Created April 23, 2020 16:45
Show Gist options
  • Save thinktanklinux/17dc1ab4cf65a3040aefcc06e9d7b6a3 to your computer and use it in GitHub Desktop.
Save thinktanklinux/17dc1ab4cf65a3040aefcc06e9d7b6a3 to your computer and use it in GitHub Desktop.
Installing Microsoft Powershell
root@host [~]# cd /usr/src/
root@host:/usr/src# wget -q https://packages.com/config/ubuntu/18.04/packages-microsoft-prod.deb
root@host:/usr/src# sudo dpkg -i packages-prod.deb
root@host:/usr/src# apt-get update
add-apt-repository universe
root@host:/usr/src# apt-get install -y powershell
root@host:/usr/src# pwsh
You will notice that the command prompt has changed.
root@host:/usr/src#
to
PS /usr/src>
Typing in the ‘dir‘ command provides us with the following output.
PS /usr/src> dir
Directory: /usr/src
Mode LastWriteTime Length Name
---- ------------- ------ ----
d----- 1/8/20 6:51 AM linux-headers-5.3.0-26
d----- 1/8/20 6:51 AM linux-headers-5.3.0-26-generic
d----- 1/29/20 6:57 AM linux-headers-5.3.0-29
d----- 1/29/20 6:57 AM linux-headers-5.3.0-29-generic
d----- 10/29/19 8:17 AM nvidia-430.50
d----- 1/11/19 3:19 PM packages
d----- 1/8/20 11:26 AM virtualbox-6.0.14
------ 1/2/19 6:49 PM 3132 packages-microsoft-prod.deb
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment