From db139f1cc90df166d1239e4abab6eece266a386d Mon Sep 17 00:00:00 2001 From: Jan Tojnar Date: Sun, 30 Jan 2022 03:09:34 +0100 Subject: [PATCH] python3.pkgs.statmake: init at 0.4.1 --- .../python-modules/statmake/default.nix | 57 +++++++++++++++++++ pkgs/top-level/python-packages.nix | 2 + 2 files changed, 59 insertions(+) create mode 100644 pkgs/development/python-modules/statmake/default.nix diff --git a/pkgs/development/python-modules/statmake/default.nix b/pkgs/development/python-modules/statmake/default.nix new file mode 100644 index 000000000000..3cbedf8bf8c5 --- /dev/null +++ b/pkgs/development/python-modules/statmake/default.nix @@ -0,0 +1,57 @@ +{ lib +, buildPythonPackage +, fetchFromGitHub +, poetry-core +, attrs +, cattrs +, fonttools +, fs +, pytestCheckHook +, ufo2ft +, ufoLib2 +}: + +buildPythonPackage rec { + pname = "statmake"; + version = "0.4.1"; + + format = "pyproject"; + + src = fetchFromGitHub { + owner = "daltonmaag"; + repo = "statmake"; + rev = "v${version}"; + sha256 = "OXhoQAD4LEh80iRUZE2z8sCtWJDv/bSo0bwHbOOPVE0="; + }; + + nativeBuildInputs = [ + poetry-core + ]; + + propagatedBuildInputs = [ + attrs + cattrs + fonttools + # required by fonttools[ufo] + fs + ]; + + checkInputs = [ + pytestCheckHook + ufo2ft + ufoLib2 + ]; + + postPatch = '' + # https://github.com/daltonmaag/statmake/pull/41 + substituteInPlace pyproject.toml \ + --replace 'requires = ["poetry>=1.0.0"]' 'requires = ["poetry-core"]' \ + --replace 'build-backend = "poetry.masonry.api"' 'build-backend = "poetry.core.masonry.api"' + ''; + + meta = with lib; { + description = "Applies STAT information from a Stylespace to a variable font"; + homepage = "https://github.com/daltonmaag/statmake"; + license = licenses.mit; + }; +} diff --git a/pkgs/top-level/python-packages.nix b/pkgs/top-level/python-packages.nix index 4a800e41219a..d074f4cb40a9 100644 --- a/pkgs/top-level/python-packages.nix +++ b/pkgs/top-level/python-packages.nix @@ -9408,6 +9408,8 @@ in { statistics = callPackage ../development/python-modules/statistics { }; + statmake = callPackage ../development/python-modules/statmake { }; + statsd = callPackage ../development/python-modules/statsd { }; statsmodels = callPackage ../development/python-modules/statsmodels { };