Skip to content

Tools and instructions on how to have awesome symbols in a terminal with a monospace font

License

Notifications You must be signed in to change notification settings

dus7/awesome-terminal-fonts

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

60 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Why?

Why do you want to use fancy symbols in your standard monospace font? Obviously to have a fancy prompt like mine :-)

prompt

And because when you live in a terminal a symbol can convey more informations in less space creating a dense and beautiful (for those who have a certain aesthetic taste) informative workspace

Heavily inspired by https://github.com/Lokaltog/vim-powerline and the relative patch script from Kim Silkebækken ([email protected])

Patching vs Fallback

There are two strategies that could be used to have symbols in a terminal

  • you can take a bunch of symbol fonts, your favourite monospace font and merge them together (patching strategy)
  • you can use a feature of freetype2 font engine, basically you can say that whenever the current font doesn't have a glyph for a certain codepoint then fallback and go look into other fonts (fallback strategy)

Initially I used the first strategy, later I switched to the second. The patching strategy it's more reliable and portable, the problem is that you need to patch every monospace font you want to use and patching a single font it's a lot of manual fine tuning. If you want you can find all previous patched fonts in patching-strategy branch

Font Maps

  • Wouldn't be cool to be able to call glyphs/symbols by name (ex. AWESOME_LONG_ARROW_DOWN) instead of by codepoint (ex. \uf175)? This is what font maps are meant for, for every symbol font in ./fonts directory you can find a map file in ./build directory that maps each glyph's name to its codepoint in a way that is understandable by most shells

Included Fonts

In this repository you can find a bunch of fonts that I use as symbol fonts with the relative font maps

How to install (Linux)

  • copy all the fonts from ./build directory to ~/.fonts directory
  • run fc-cache -fv ~/.fonts to let freetype2 know of those fonts
  • customize the configuration file ./config/10-symbols.conf replacing PragmataPro with the name of the font you want to use in the terminal (I will add more fonts in the future so that this step could be skippable)
  • copy the above configuration file to ~/.config/fontconfig/conf.d directory

How to install (OSX)

How to install (Windows)

  • Make sure you have permissions to execute Powershell scripts in your machine. To do so, open Windows Powershell as Administrator and paste & exec the following command:
Set-ExecutionPolicy RemoteSigned
  • Then exec install script:
./install.ps1

License

MIT

About

Tools and instructions on how to have awesome symbols in a terminal with a monospace font

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages

  • Shell 93.4%
  • Python 6.1%
  • PowerShell 0.5%