diff --git a/pkgs/development/python-modules/garminconnect-aio/default.nix b/pkgs/development/python-modules/garminconnect-aio/default.nix new file mode 100644 index 000000000000..bb754118e077 --- /dev/null +++ b/pkgs/development/python-modules/garminconnect-aio/default.nix @@ -0,0 +1,37 @@ +{ lib +, aiohttp +, brotlipy +, buildPythonPackage +, fetchFromGitHub +, yarl +}: + +buildPythonPackage rec { + pname = "garminconnect-aio"; + version = "0.1.4"; + + src = fetchFromGitHub { + owner = "cyberjunky"; + repo = "python-garminconnect-aio"; + rev = version; + sha256 = "0s2gpy5hciv9akqqhxy0d2ywp6jp9mmdngx34q7fq3xn668kcrhr"; + }; + + propagatedBuildInputs = [ + aiohttp + brotlipy + yarl + ]; + + # Project has no tests + doCheck = false; + + pythonImportsCheck = [ "garminconnect_aio" ]; + + meta = with lib; { + description = "Python module to interact with Garmin Connect"; + homepage = "https://github.com/cyberjunky/python-garminconnect-aio"; + license = licenses.mit; + maintainers = with maintainers; [ fab ]; + }; +} diff --git a/pkgs/servers/home-assistant/component-packages.nix b/pkgs/servers/home-assistant/component-packages.nix index dd2ad616fce3..ddc4a81cec93 100644 --- a/pkgs/servers/home-assistant/component-packages.nix +++ b/pkgs/servers/home-assistant/component-packages.nix @@ -293,7 +293,7 @@ "futurenow" = ps: with ps; [ pyfnip ]; "garadget" = ps: with ps; [ ]; "garages_amsterdam" = ps: with ps; [ garages-amsterdam ]; - "garmin_connect" = ps: with ps; [ ]; # missing inputs: garminconnect_aio + "garmin_connect" = ps: with ps; [ garminconnect-aio ]; "gc100" = ps: with ps; [ ]; # missing inputs: python-gc100 "gdacs" = ps: with ps; [ aio-georss-gdacs ]; "generic" = ps: with ps; [ ]; diff --git a/pkgs/servers/home-assistant/default.nix b/pkgs/servers/home-assistant/default.nix index 5ae88c1eafcc..571f630a5932 100644 --- a/pkgs/servers/home-assistant/default.nix +++ b/pkgs/servers/home-assistant/default.nix @@ -387,6 +387,7 @@ in with py.pkgs; buildPythonApplication rec { "fritzbox" "fritzbox_callmonitor" "frontend" + "garmin_connect" "generic" "generic_thermostat" "geo_json_events" diff --git a/pkgs/top-level/python-packages.nix b/pkgs/top-level/python-packages.nix index d47d48dc2f7d..1839e598a155 100644 --- a/pkgs/top-level/python-packages.nix +++ b/pkgs/top-level/python-packages.nix @@ -2702,6 +2702,8 @@ in { pythonPackages = self; }); + garminconnect-aio = callPackage ../development/python-modules/garminconnect-aio { }; + gast = callPackage ../development/python-modules/gast { }; garages-amsterdam = callPackage ../development/python-modules/garages-amsterdam { };