Skip to content

Latest commit

History

16 Commits

Folders and files

NameName
Last commit message
Last commit date

Repository files navigation

FontGit

FontGit is an experimental package that loads fonts from a specific commit in a git repo. You don't have to check out any commits, or reset the repo to a specific commit, fontgit loads everything lazily. This means only the requested parts of the fonts is loaded which makes the reading faster.

Example

fromfontGitimportFontGitfont_path='tests/test_repo/fonts/font_1.ufo'# font should be inside a repo with a commit history# Open a font at latest commitfont=FontGit.open_at_commit(font_path)
# get list of all commit hashes in the repofromfontGit.utilsimportRepoCachesample_repo=RepoCache(font_path) # it will resolve to the repo root even if font path is givencommits=sample_repo.commits# get a font at a spcific commitfont=FontGit.open_at_commit(font_path, commit_sha=commits[1])

About

A font obj at a specific commit in a git repo

Resources

Stars

3 stars

Watchers

1 watching

Forks

Releases

Packages

Used by

Contributors

Languages