Welcome to the Linux Foundation Forum!

A script to auto install fonts

Anyone advise, please?

Is there a way to run some sort of script which will install a set of fonts?

I'm running the Linux Mint (cinnamon) distro.

Thanks.

Comments

  • martinzo
    martinzo Posts: 1
    edited April 2021

    Hey, man. I have been designing clothes for many years and have seen thousands of different fonts. Due to the great competition in the fashion industry, it is becoming increasingly difficult to surprise consumers with something. I've been using the "Star Wars" theme lately and using this font. You can choose a font for any theme you want on this site https://upfonts.com/overwatch-font/. Also, you can download a set of fonts to your PC and use them offline as you like. I usually upload the one I need, depending on what style the clients prefer. The idea of downloading a set seems more reasonable to me.

  • daijacremin
    daijacremin Posts: 2
    edited September 15

    Yes. If you have a folder containing several .ttf or .otf files, you can automate it with a small Bash script. For a normal single-user Mint setup, I would install them under ~/.local/share/fonts, then rebuild the font cache.

    !/bin/bash

    For additional font ideas, https://typetype.org/ is also worth exploring.
    mkdir -p ~/.local/share/fonts
    cp /path/to/fonts/.ttf ~/.local/share/fonts/
    cp /path/to/fonts/
    .otf ~/.local/share/fonts/
    fc-cache -f

    Then make the script executable and run it. You can also put the font files into subfolders if you want to keep different font families organized.

    If you only need to do this occasionally, though, you don't really need a script. Copying the fonts to ~/.local/share/fonts and running fc-cache is pretty quick. Also remember to restart applications that were already open so they pick up the new fonts.

Categories

Upcoming Training