{ lib, namespace, pkgs, buildHomeAssistantComponent, home-assistant, ... }: let inherit (lib.trivial) importJSON; inherit (lib.${namespace}) selectVariant mkAllSources; versionSpec = importJSON ./version.json; selected = selectVariant versionSpec null null; sources = mkAllSources pkgs selected; src-meta = selected.sources.ge_home; version = if src-meta ? tag then src-meta.tag else src-meta.rev; in buildHomeAssistantComponent { owner = src-meta.owner; domain = "ge_home"; inherit version; src = sources.ge_home; # gehomesdk and magicattr must be built against HA's Python dependencies = with pkgs.${namespace}; [ gehomesdk magicattr ]; nativeBuildInputs = with home-assistant.python.pkgs; [ slixmpp ]; meta = { changelog = "https://github.com/simbaja/ha_gehome/releases/tag/${version}"; description = "Integration for GE WiFi-enabled appliances into Home Assistant."; homepage = "https://github.com/simbaja/ha_gehome"; maintainers = [ ]; }; }