I use couple terminals in Mac OS at same time to behonest. iTerm2, Hyper and Warp. They are all prons and cons, but I’m currently using Warp as my primary terminal.
The default shell in Warp is zsh. Warp also provides default prompts and you don’t need to install any extenstion, but less options you can use and customize. If you are familiar with terminal and you must hear Powerlevel10k, which is a plug-in you can integrate into shell and let your prompts more beautiful. But why we need this? It does not only make up your shell, but also provide useful information in prompts.
For example, you can see which gitbranch you are working on, how many files you edited (added), how many commits between local and remote branches, NodeJS version…etc. So, let get starting this article and see how to integrate Powerlevel10k into Warp.
Install Nerd Fonts
What is Nerd Fonts? The default font in your terminal or shell couldn’t support symbols. And Powerlevel10k contains a lot of symbols and you will see the symbols show incorrectly if you don’t have any Nerd Fonts. You can choose any Nerd Fonts and set them as default font for your Warp:
Install Warp
First, you need to install Warp first from the ofiicial site. Or install it by running the command via HomeBrew below:
brew install --cask warp
Once Warp is installed, launch Warp to see if it can be ran correctly.
Install Powerlevel10k
The most shell used to Powerlevel10k is “zsh”, but we don’t need to change it because the default shell of Warp is “zsh”.
You can go to Powerlevel10k website or run the command below in Warp terminal to install it:
git clone --depth=1 https://github.com/romkatv/powerlevel10k.git ~/powerlevel10k
echo 'source ~/powerlevel10k/powerlevel10k.zsh-theme' >>~/.zshrc
Note: this command is used to “zsh” shell. Please reference the instructions if you would like to integreate to different shell.
Once the plug-in is cloned without error, we can restart “zsh” by this command:
exec zsh
And you should see the Powerlevel10k configuration wizard in your shell:
You should follow the wizard and instructions to set your prompts. Don’t worry, you can change them if you choose the wrong one. I list the options I picked and show the final result in below:
If you see some symbols present incorrectly, you should verify if you have installed any Nerd Font and set one of Nerd Font as your default font, for example I choose MesloLGS Nerd Font Mono as my default font in Warp.
Prompt Style: Rainbow
Character Set: Unicode
Show current time: 12-hour
Prompt Separators: Angled
Prompt Heads: Blurred
Prompt Tails: Flat
Prompt Height: One line
Prompt Spacing: Sparse
Icons: Many icons
Prompt Flow: Concise
Enable Transient Prompt: Yes
Instant Prompt Mode: Verbose (recommanded)
And that’s it. You can clone any repository from github or yours to see how it tooks like with other information in prompts:
If you want to change your mind, you can run the command to modify your configuration:
p10k configure
Conclusion
It also supports in Windows environment if you use PowerShell and Windows Terminal as your shell. The installation steps are very similar and easy.
I love the combination of Warp and Powerlevel10k, because you don’t need to install other shell like “Oh-my-zsh” and change the setting as your default shell. Only few comamnds and looks perfect. Enjoy your new terminal.