Oh, My ZSH! with Powerline Fonts. Pretty simple as you deserve!

Filipe Macêdo
2 min readJan 17, 2021

--

I don’t know you but I like to see my terminal with colors and icons that help me to see where and what I am doing.

I use to refer ZSH to my friends who just arrive at the Mac OS X dev environment. Also, I use to hear from them that they didn’t get something next to my own terminal configuration.

That’s why I decide to write this simple article to help you guide through the steps to get an Oh My ZSH! terminal with Monokai theme and Powerline fonts.

Let’s get to the point!

Install Oh My ZSH! via curl

$ sh -c "$(curl -fsSL https://raw.github.com/ohmyzsh/ohmyzsh/master/tools/install.sh)"

Install Powerline fonts

Clone powerline fonts repo:

git clone https://github.com/powerline/fonts.git --depth=1

Install them:

cd fonts
./install.sh

Don’t mess up your folders! Recycle the stuff you don’t need anymore:

cd ..
rm -rf fonts

Finally, set a theme up.

I personally use the “Monokai Pro (Filter Spectrum)” one.

Once downloaded a theme, open it with terminal, and it gets installed to your local themes automatically.

  • To set the theme, open terminal preferences, choose the theme you installed, and check it as default.
  • To set the fonts, still, at terminal preferences, click on the Change… button in the Font section.
  • I suggest the Meslo LG M DZ for Powerline, Regular, 11px! It fits very well on the terminal.
  • Doing the steps above, you will be able to see the colors and icons when for example, inside a git folder.

Bonus

Cleaning up the terminal context.

Use your preferred editor to edit the .zshrc file:

code .zshrc

Set the ZSH theme to the agnoster:

ZSH_THEME=”agnoster”

Then, append the following instruction to hide the terminal context:

prompt_context(){}

If you want to personalize it, see that discussion.

Setting Visual Studio Code up as well

Open the VS Code configs and drop the following lines:

"terminal.integrated.fontFamily": "Source Code Pro for Powerline",
"terminal.integrated.shell.osx": "/bin/zsh"

That’s all!

I hope now you have a cool terminal to work with!

--

--

Filipe Macêdo
Filipe Macêdo

Responses (3)