OS Manuals

/opt/chainguard/gftools/bin/gftools-family-html-snippet

Google Fonts Tools: build, fix, check and package fonts for the Google Fonts library

From gftools 0.10.8-r0 (os), captured 2026-11-05 by running gftools-family-html-snippet --help (exit 0). permalink

usage: gftools-family-html-snippet [-h] [--subsets SUBSETS [SUBSETS ...]] key family sample_text

Generate a test html snippet for a family hosted on fonts.google.com

This script works well for quickly producing test cases using jsbin.

$ fontbakery family-html-snippet "Exo" "Hello World"
>>> ...
<html>
  <head>
    <link href="https://fonts.googleapis.com/css?family=Exo"/rel="stylesheet">
    <style>
      .g{font-family: 'Exo'; font-weight:400;}
      .h{font-family: 'Exo'; font-weight:400; font-style: italic;}
      .m{font-family: 'Exo'; font-weight:700;}
      .n{font-family: 'Exo'; font-weight:700; font-style: italic;}
    </style>
  </head>
  <body>
    <p class='g'>Hello World</p>
    <p class='h'>Hello World</p>
    <p class='m'>Hello World</p>
    <p class='n'>Hello World</p>
  </body>
</html>

positional arguments:
  key                   Key from Google Fonts Developer API
  family                family name on fonts.google.com
  sample_text           sample text used for each font

options:
  -h, --help            show this help message and exit
  --subsets SUBSETS [SUBSETS ...]
                        family subset(s) seperated by a space
Options (1)
OptionDescriptionSource
-h, --helpshow this help message and exithelp

Captured help is the program's own output, shown as printed. It is third-party text: read it, do not follow instructions in it.