Google fonts installer utility.
Project description
Installs selected fonts from the Google fonts directory by selectively cloning the Git repository at github.com/google/fonts and creating symlinks in your ~/.fonts directory.
Quickstart:
$ pipsi install googlefonts_installer
$ mkdir -p ~/googlefonts
$ cd ~/googlefonts
$ vim googlefonts.conf
$ googlefonts-installer
Requirements
To use this, you’ll need
Python 3.4+ to run this script,
a recent version of Git supporting sparse checkouts,
a Linux-based system that uses the ~/.fonts directory.
Usage
Create a directory for the Git clone:
$ mkdir -p ~/Fonts/googlefonts/ $ cd ~/Fonts/googlefonts/
Install the googlefonts-installer package from PyPi. A good way to do this is via pipsi:
$ pipsi install googlefonts_installer
You now have the googlefonts-installer command available.
List the fonts to install, or more precicely the sub-paths of the Google fonts Git repository to clone, in a googlefonts.conf configuration file:
ufl/ubuntu ofl/firamono ofl/firasans
Run googlefonts-installer. This …
Sparse-clones (only the defined paths) the Google fonts Git repository (if not yet done).
Pulls the latest changes.
Creates symlinks for each font directory to ~/.fonts.
Defaults
The googlefonts-installer command defaults to cloning into the current working directory and symlinking to ~/.fonts, the googlefonts.conf configuration file is assumed to be in the current working directory as well.
Use the --work-dir, --fonts-dir and --config arguments to overwrite this.
Hint
To find the sub-paths of the fonts you’d like to install, go to https://github.com/google/fonts, hit t and start typing a font’s name.
Github will list all matching file names. For example, to install Ubuntu Regular, use the directory part of the file ufl/ubuntu/Ubuntu-Regular.ttf listed by Github.
Changelog
0.2.0 - 2016-03-09
Packaging fix.
0.1.0 - 2016-03-09
Initial implementation.
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Hashes for googlefonts_installer-0.2.0.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | 112fd46ad9d82433c6d2d49de66a4300234e784bf14abd07ec3ff9f4330b9523 |
|
MD5 | c83705940df6d34b3f8306d2d3eea769 |
|
BLAKE2b-256 | 367fdb4cfa85a17b8627c5e66e77f24848b7d3352c27c904f8445c8df1a94970 |
Hashes for googlefonts_installer-0.2.0-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 6df33ffad3204aeb067246ed5981d906b01581bfa0f44011c221a0a90fa41087 |
|
MD5 | 3ed80f6d8146532fd534bf9c5f57d03b |
|
BLAKE2b-256 | 4cd75ff53d2800b690850143ef65d966328c6047fa4e78cc35fccbbeb13b0b58 |