oh my zsh showing weird character '?' on terminal
I have installed iTerm2 and Oh-my-zsh. However there is a weird question mark that is coming ever since I have changed ZSH-THEME to "agnoster".
Attaching the screenshot for the same.
I thought powerline would help but that doesn't seem to happen. Can can anyone help me with this?
Solution 1:
Run step 1-4 in your iterm2/terminal and you are done.
-
git clone https://github.com/powerline/fonts
(clone it anywhere, You can remove cloned dir after step-4) cd fonts
./install.sh
- Open iTerm2->Preferences->Profiles->Text->Change Font-> Meslo LG S DZ Regular for Powerline
- Reopen the terminal and you are done.
Edit: If you are not using iTerm you can simply change the default macOS Terminal Preferences. (Thanks to Kewal)
You can also refer this long git thread for the same.
Solution 2:
Installing a powerline patched font will solve this. This official documentation provides description about installing poweline fonts.
There are two ways to enable powerline patched font in iTerm2.
- Set a powerline patched font as default.
- Set a powerline patched font for only Non-ASCII characters and use another font for code.
Bonus:
- Collection of powerline patched fonts
- Awesome oh-my-zsh themes
- Spaceship ZSH
- Buller Train
- powerlevel9k