esphome: add update script that includes the dashboard

This commit is contained in:
Martin Weinelt 2022-09-29 14:31:01 +02:00
parent c57357368c
commit e66af0e110
No known key found for this signature in database
GPG Key ID: 87C1E9888F856759
2 changed files with 13 additions and 0 deletions

View File

@ -91,6 +91,7 @@ with python.pkgs; buildPythonApplication rec {
passthru = {
dashboard = esphome-dashboard;
updateScript = callPackage ./update.nix {};
};
meta = with lib; {

View File

@ -0,0 +1,12 @@
{ writeShellScript
, lib
, git
, nix-update
}:
writeShellScript "update-esphome" ''
PATH=${lib.makeBinPath [ git nix-update ]}
nix-update esphome.dashboard
nix-update esphome
''