From a35d17293448287ca14830aef22271bedca31a26 Mon Sep 17 00:00:00 2001 From: Fabian Affolter Date: Tue, 26 Nov 2024 23:00:42 +0100 Subject: [PATCH] python312Packages.turrishw: init at 1.0.0 Python library and program for Turris hardware listing https://github.com/turris-cz/turrishw --- .../python-modules/turrishw/default.nix | 37 +++++++++++++++++++ pkgs/top-level/python-packages.nix | 2 + 2 files changed, 39 insertions(+) create mode 100644 pkgs/development/python-modules/turrishw/default.nix diff --git a/pkgs/development/python-modules/turrishw/default.nix b/pkgs/development/python-modules/turrishw/default.nix new file mode 100644 index 000000000000..56711ab866e6 --- /dev/null +++ b/pkgs/development/python-modules/turrishw/default.nix @@ -0,0 +1,37 @@ +{ + lib, + buildPythonPackage, + fetchFromGitHub, + hatchling, + pytestCheckHook, + pythonOlder, +}: + +buildPythonPackage rec { + pname = "turrishw"; + version = "1.0.0"; + pyproject = true; + + disabled = pythonOlder "3.10"; + + src = fetchFromGitHub { + owner = "turris-cz"; + repo = "turrishw"; + rev = "refs/tags/v${version}"; + hash = "sha256-elu2f54asdzdn7wQT2CKo8kVYnc1KTakRyr8Nxu+XNw="; + }; + + build-system = [ hatchling ]; + + nativeCheckInputs = [ pytestCheckHook ]; + + pythonImportsCheck = [ "turrishw" ]; + + meta = { + description = "Python library and program for Turris hardware listing"; + homepage = "https://github.com/turris-cz/turrishw"; + changelog = "https://github.com/turris-cz/turrishw/blob/${src.rev}/CHANGELOG.md"; + license = lib.licenses.mit; + maintainers = with lib.maintainers; [ fab ]; + }; +} diff --git a/pkgs/top-level/python-packages.nix b/pkgs/top-level/python-packages.nix index 62a1df04f4d3..495fbcd15e4b 100644 --- a/pkgs/top-level/python-packages.nix +++ b/pkgs/top-level/python-packages.nix @@ -16278,6 +16278,8 @@ self: super: with self; { turnt = callPackage ../development/python-modules/turnt { }; + turrishw = callPackage ../development/python-modules/turrishw { }; + tuya-device-sharing-sdk = callPackage ../development/python-modules/tuya-device-sharing-sdk { }; tuya-iot-py-sdk = callPackage ../development/python-modules/tuya-iot-py-sdk { };