Samy Ghannad

How to Install a bunch of fonts on Ubuntu

I eventually got tired of ugly fonts, and decided to install a few fonts. After searching a bit and not finding a copy-paste-enter solution, I decided to install some fonts from Google Fonts. Browsing through the catalog, I got confused by all the great choices I had in front of me, so I did what a 5 year old would do when faced with more than one option : Choose them all.

Here’s how to install all Google fonts at once:

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
cd /tmp
wget -O master.zip https://github.com/google/fonts/archive/master.zip
unzip master.zip -d google-fonts
rm master.zip
cd google-fonts
find -type f -name "*.ttf" -exec sudo cp -- "{}" /usr/local/share/fonts \;
cd /usr/local/share/fonts
sudo mkfontscale
sudo mkfontdir
fc-cache -f -v
rm -rf /tmp/google-fonts