nixpkgs mirror (for testing)
github.com/NixOS/nixpkgs
nix
1{
2 lib,
3 buildPythonPackage,
4 fetchPypi,
5
6 # build-system
7 setuptools,
8 setuptools-scm,
9
10 # dependencies
11 fonttools,
12 defcon,
13 fontmath,
14 booleanoperations,
15
16 # tests
17 python,
18}:
19
20buildPythonPackage rec {
21 pname = "fontparts";
22 version = "0.13.1";
23 pyproject = true;
24
25 src = fetchPypi {
26 inherit pname version;
27 hash = "sha256-+oifxmY7MUkQj3Sy75wjRmoVEPkgZaO3+8/sauMMxYA=";
28 extension = "zip";
29 };
30
31 build-system = [
32 setuptools
33 setuptools-scm
34 ];
35
36 dependencies = [
37 booleanoperations
38 defcon
39 fontmath
40 fonttools
41 ]
42 ++ defcon.optional-dependencies.pens
43 ++ fonttools.optional-dependencies.ufo
44 ++ fonttools.optional-dependencies.lxml
45 ++ fonttools.optional-dependencies.unicode;
46
47 checkPhase = ''
48 runHook preCheck
49 ${python.interpreter} Lib/fontParts/fontshell/test.py
50 runHook postCheck
51 '';
52
53 meta = {
54 description = "API for interacting with the parts of fonts during the font development process";
55 homepage = "https://github.com/robotools/fontParts";
56 changelog = "https://github.com/robotools/fontParts/releases/tag/${version}";
57 license = lib.licenses.mit;
58 maintainers = [ lib.maintainers.sternenseemann ];
59 };
60}