From e4fcd7fbff3a87f42280268499e0d713161a6cc1 Mon Sep 17 00:00:00 2001 From: arcnmx Date: Wed, 10 May 2023 13:05:02 -0700 Subject: [PATCH] fix remote --- tewi/androidtvremote2.nix | 40 +++++++++++++++++++++++++++++++++++++++ tewi/home-assistant.nix | 1 + 2 files changed, 41 insertions(+) create mode 100644 tewi/androidtvremote2.nix diff --git a/tewi/androidtvremote2.nix b/tewi/androidtvremote2.nix new file mode 100644 index 00000000..15bd860c --- /dev/null +++ b/tewi/androidtvremote2.nix @@ -0,0 +1,40 @@ +{ lib +, buildPythonPackage +, fetchFromGitHub +, aiofiles +, cryptography +, protobuf +, setuptools +, pytestCheckHook +}: + +buildPythonPackage rec { + pname = "androidtvremote2"; + version = "0.0.8"; + format = "pyproject"; + + src = fetchFromGitHub { + owner = "tronikos"; + repo = pname; + rev = "v${version}"; + hash = "sha256-R2KXInaWzaBk0KNDsuCLxI/ZY84viqX+7YJOpLsDirc="; + }; + + nativeBuildInputs = [ + setuptools + ]; + + propagatedBuildInputs = [ + aiofiles + cryptography + protobuf + ]; + + checkInputs = [ + pytestCheckHook + ]; + + pythonImportsCheck = [ + "androidtvremote2" + ]; +} diff --git a/tewi/home-assistant.nix b/tewi/home-assistant.nix index 78f8e5fe..ba320073 100644 --- a/tewi/home-assistant.nix +++ b/tewi/home-assistant.nix @@ -203,6 +203,7 @@ in { python-otbr-api protobuf3 adb-shell + (callPackage ./androidtvremote2.nix { }) (aiogithubapi.overrideAttrs (_: {doInstallCheck = false;})) ]; extraComponents = [