https://github.com/rosettatype/random-scripts
Miscellaneous scripts of dubious purpose
https://github.com/rosettatype/random-scripts
cli fonts google-fonts python-script
Last synced: 2 months ago
JSON representation
Miscellaneous scripts of dubious purpose
- Host: GitHub
- URL: https://github.com/rosettatype/random-scripts
- Owner: rosettatype
- License: mit
- Created: 2017-03-03T09:37:48.000Z (over 9 years ago)
- Default Branch: master
- Last Pushed: 2017-04-05T09:31:34.000Z (about 9 years ago)
- Last Synced: 2026-03-30T08:36:00.754Z (3 months ago)
- Topics: cli, fonts, google-fonts, python-script
- Language: Python
- Homepage:
- Size: 5.86 KB
- Stars: 1
- Watchers: 2
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE.txt
Awesome Lists containing this project
README
# Get all Google Fonts
A Python script/CLI that downloads all the fonts from Google Fonts using the API. You will need to provide an API key, get one [here](https://developers.google.com/fonts/docs/developer_api). The script is borrowing a lot from [this FontBakery script](https://github.com/googlefonts/fontbakery/blob/master/fontbakery-metadata-vs-api.py).
Usage:
In Terminal, in the folder with the script you can do, for example:
`python get_all_google_fonts.py --apikey ` downloads all fonts to a subfolder of the current folder. Takes a few minutes (currently it is about 320 MB of fonts)
`python get_all_google_fonts.py --apikey --subsets latin,gujarati` downloads only fonts that include `latin` and `gujarati` subsets. See the API docs for more subset options.
`python get_all_google_fonts.py --apikey --out Darkfold` downloads all fonts to a folder `Darkhold`.
For other options, see the script’s own help.
Alternatively, if you did not need the most recent fonts, you could download [this archive](https://github.com/google/fonts/archive/master.zip). Note, however, that as of 3 March 2017, it has not been updated for a while and some nice new families are missing.
## Feedback
These scripts are provided as is. Feel free to submit an issue, but we might not have the time to fix it.