'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.

check the question mark on terminal pointer

I thought powerline would help but that doesn't seem to happen. Can can anyone help me with this?



Solution 1:[1]

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.

  1. Set a powerline patched font as default.

One defauls font

  1. Set a powerline patched font for only Non-ASCII characters and use another font for code.

Different fonts

Bonus:

Solution 2:[2]

This has fixed the issue. Just select Use built-in Powerline glyphs and use Inconsolata for Powerline font.

This has fixed the issues.

Solution 3:[3]

Just do the following, it worked for me, trust me, see the truth in my eyes.

Go to preference->Profiles->Test and look at the following figure:- enter image description here

Solution 4:[4]

On Windows - just * download some Powerline font like: https://github.com/abertsch/Menlo-for-Powerline/raw/master/Menlo%20for%20Powerline.ttf
* Install it by clicking the file twice
* Choose the new font in properties
That's it!

On Mac - the previous answer in totally correct, just install and choose an appropriate font.

Solution 5:[5]

This answer relates to a similar problem I encountered but for the oh-my-posh application on Windows 10 Pro.

For others who might be wrestling with this, I also was having issues where the font would create tiny boxes with question marks. Turns out it was because my version of Windows 10 Pro was not activated. I found this out by trying to search for Fonts in the settings, and was unable to search for any of the Nerd Fonts I thought I had downloaded. Activating Windows 10 Pro fixed the problem as soon as I reloaded.

Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source
Solution 1
Solution 2 shaahiin
Solution 3 Hacklavya
Solution 4 Arif Dewi
Solution 5 sbanders