How To Install zsh-theme-powerlevel9k on Ubuntu 18.04

In this tutorial we learn how to install zsh-theme-powerlevel9k on Ubuntu 18.04. zsh-theme-powerlevel9k is powerlevel9k is a theme for zsh which uses powerline fonts

Introduction

In this tutorial we learn how to install zsh-theme-powerlevel9k on Ubuntu 18.04.

What is zsh-theme-powerlevel9k

zsh-theme-powerlevel9k is:

Get more out of your terminal. Be a badass. Impress everyone in ‘Screenshot Your Desktop’ threads. Use powerlevel9k.

There are a number of Powerline ZSH themes available, now. The developers of this theme focus on four primary goals:

  • Give users a great out-of-the-box configuration with no additional configuration required.
  • Make customization easy for users who do want to tweak their prompt.
  • Provide useful segments that you can enable to make your prompt even more effective and helpful. It has prompt segments for everything from unit test coverage to your AWS instance.
  • Optimize the code for execution speed as much as possible. A snappy terminal is a happy terminal.
  • Powerlevel9k can be used to create both very useful and beautiful terminal environments.

To enable this theme for the current user, run: echo ‘source /usr/share/powerlevel9k/powerlevel9k.zsh-theme’ » ~/.zshrc

There are three methods to install zsh-theme-powerlevel9k on Ubuntu 18.04. We can use apt-get, apt and aptitude. In the following sections we will describe each method. You can choose one of them.

Install zsh-theme-powerlevel9k Using apt-get

Update apt database with apt-get using the following command.

sudo apt-get update

After updating apt database, We can install zsh-theme-powerlevel9k using apt-get by running the following command:

sudo apt-get -y install zsh-theme-powerlevel9k

Install zsh-theme-powerlevel9k Using apt

Update apt database with apt using the following command.

sudo apt update

After updating apt database, We can install zsh-theme-powerlevel9k using apt by running the following command:

sudo apt -y install zsh-theme-powerlevel9k

Install zsh-theme-powerlevel9k Using aptitude

If you want to follow this method, you might need to install aptitude first since aptitude is usually not installed by default on Ubuntu. Update apt database with aptitude using the following command.

sudo aptitude update

After updating apt database, We can install zsh-theme-powerlevel9k using aptitude by running the following command:

sudo aptitude -y install zsh-theme-powerlevel9k

How To Uninstall zsh-theme-powerlevel9k on Ubuntu 18.04

To uninstall only the zsh-theme-powerlevel9k package we can use the following command:

sudo apt-get remove zsh-theme-powerlevel9k

Uninstall zsh-theme-powerlevel9k And Its Dependencies

To uninstall zsh-theme-powerlevel9k and its dependencies that are no longer needed by Ubuntu 18.04, we can use the command below:

sudo apt-get -y autoremove zsh-theme-powerlevel9k

Remove zsh-theme-powerlevel9k Configurations and Data

To remove zsh-theme-powerlevel9k configuration and data from Ubuntu 18.04 we can use the following command:

sudo apt-get -y purge zsh-theme-powerlevel9k

Remove zsh-theme-powerlevel9k configuration, data, and all of its dependencies

We can use the following command to remove zsh-theme-powerlevel9k configurations, data and all of its dependencies, we can use the following command:

sudo apt-get -y autoremove --purge zsh-theme-powerlevel9k

References

Summary

In this tutorial we learn how to install zsh-theme-powerlevel9k package on Ubuntu 18.04 using different package management tools: apt, apt-get and aptitude.