diff --git a/pkgs/servers/home-assistant/custom-components/browser-mod/package.nix b/pkgs/servers/home-assistant/custom-components/browser-mod/package.nix new file mode 100644 index 000000000000..1ec3cfea2a7a --- /dev/null +++ b/pkgs/servers/home-assistant/custom-components/browser-mod/package.nix @@ -0,0 +1,42 @@ +{ + lib, + buildHomeAssistantComponent, + fetchFromGitHub, + fetchNpmDeps, + nodejs, + npmHooks, +}: + +buildHomeAssistantComponent rec { + owner = "thomasloven"; + domain = "browser_mod"; + version = "2.7.4"; + + src = fetchFromGitHub { + inherit owner; + repo = "hass-browser_mod"; + tag = "v${version}"; + hash = "sha256-UFHdoIfmN0BUBRAze3mC3mgbV00rrjmKlAiBc4FuiZA="; + }; + + nativeBuildInputs = [ + nodejs + npmHooks.npmBuildHook + npmHooks.npmConfigHook + ]; + + npmDeps = fetchNpmDeps { + inherit src; + hash = "sha256-gvONQGQ91XZAygXDZnu7R/BPKa9T9l3f3EE6o39t0G0="; + }; + + npmBuildScript = "build"; + + meta = { + description = "Home Assistant integration to turn your browser into a controllable entity and media player"; + homepage = "https://github.com/thomasloven/hass-browser_mod"; + changelog = "https://github.com/thomasloven/hass-browser_mod/releases/tag/${src.tag}"; + maintainers = with lib.maintainers; [ SuperSandro2000 ]; + license = lib.licenses.mit; + }; +}