NOTE: If you would like to know the basics of ZSH and its configuration, consider reading our tutorial on how to go about editing the .zshrc file for ZSH.
Other than its flexibility, ZSH supports frameworks, allowing you to expand its functionality using functions, plugins, and themes. In this quick guide, we will discuss how to install the oh-my-zsh framework and install ZSH themes.
Before installing and configuring themes, the first step is to ensure you have the ZSH shell installed.
Install ZSH and oh-my-zsh
Use the apt package manager to perform the installation.
sudo apt-get install zsh
Once you have the ZSH shell installed on your system, you can make it the default shell by running the command:
The next step is to set up oh-my-zsh, a framework that makes working with ZSH easier and more enjoyable.
Use the command below to install oh-my-zsh. Note that this will automatically download and install oh-my-zsh with no prompt. You can manually read the script and see what it does.
This command installs oh-my-zsh and activates the default theme. By default, it comes prepackaged with a collection of themes that you can activate by editing the .zshrc file in your home directory.
To view the list of all themes that come installed by default, browse the ~/.oh-my-zsh/themes directory. You can also visit the main oh-my-zsh themes wiki below:
Once you find the theme that appeals to you, you can set it by editing the ~/.zhsrc file in the entry ZSH_THEME=”name”
For example, to change the theme from default “robbyrussell” to another theme such as “cypher,” edit the config as:
You will need to launch a new terminal session for changes to apply.
This quick tutorial has shown you how to install ZSH and the oh-my-zsh framework to customize ZSH quickly.
If you would like to learn how to customize your shell manually, please refer to the ZSH man and documentation to learn more.
Thanks for reading!