From bc68bde9740191cb04027133112c7b824ce3dc30 Mon Sep 17 00:00:00 2001 From: Martin Weinelt Date: Tue, 21 Sep 2021 21:27:02 +0200 Subject: [PATCH] python3Packages.maxcube-api: init at 0.4.3 --- .../python-modules/maxcube-api/default.nix | 42 +++++++++++++++++++ pkgs/top-level/python-packages.nix | 2 + 2 files changed, 44 insertions(+) create mode 100644 pkgs/development/python-modules/maxcube-api/default.nix diff --git a/pkgs/development/python-modules/maxcube-api/default.nix b/pkgs/development/python-modules/maxcube-api/default.nix new file mode 100644 index 000000000000..36bcc35fc036 --- /dev/null +++ b/pkgs/development/python-modules/maxcube-api/default.nix @@ -0,0 +1,42 @@ +{ lib +, buildPythonPackage +, pythonOlder +, fetchFromGitHub +, python +}: + +buildPythonPackage rec { + pname = "maxcube-api"; + version = "0.4.3"; + format = "setuptools"; + disabled = pythonOlder "3.7"; + + src = fetchFromGitHub { + owner = "hackercowboy"; + repo = "python-${pname}"; + rev = "V${version}"; + sha256 = "10k61gfpnqljf3p3qxr97xq7j67a9cr4ivd9v72hdni0znrbx6ym"; + }; + + postPatch = '' + substituteInPlace setup.py --replace "license=license" "license='MIT'" + ''; + + pythonImportsCheck = [ + "maxcube" + "maxcube.cube" + ]; + + checkPhase = '' + runHook preCheck + ${python.interpreter} -m unittest discover + runHook postCheck + ''; + + meta = with lib; { + description = "eQ-3/ELV MAX! Cube Python API"; + homepage = "https://github.com/hackercowboy/python-maxcube-api"; + license = licenses.mit; + maintainers = with maintainers; [ hexa ]; + }; +} diff --git a/pkgs/top-level/python-packages.nix b/pkgs/top-level/python-packages.nix index 950137206395..32f200f27306 100644 --- a/pkgs/top-level/python-packages.nix +++ b/pkgs/top-level/python-packages.nix @@ -4492,6 +4492,8 @@ in { mautrix-appservice = self.mautrix; # alias 2019-12-28 + maxcube-api = callPackage ../development/python-modules/maxcube-api { }; + maxminddb = callPackage ../development/python-modules/maxminddb { }; maya = callPackage ../development/python-modules/maya { };