2024-06-05 15:53:02 +00:00
|
|
|
{
|
|
|
|
lib,
|
|
|
|
buildPythonPackage,
|
|
|
|
fetchFromGitHub,
|
|
|
|
click,
|
|
|
|
click-log,
|
|
|
|
paho-mqtt,
|
|
|
|
pyaml,
|
2023-08-04 22:07:22 +00:00
|
|
|
}:
|
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "bch";
|
|
|
|
version = "1.2.1";
|
2024-01-02 11:29:13 +00:00
|
|
|
format = "setuptools";
|
2023-08-04 22:07:22 +00:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "hardwario";
|
|
|
|
repo = "bch-control-tool";
|
|
|
|
rev = "v${version}";
|
|
|
|
sha256 = "/C+NbJ0RrWZ/scv/FiRBTh4h7u0xS4mHVDWQ0WwmlEY=";
|
|
|
|
};
|
|
|
|
|
|
|
|
propagatedBuildInputs = [
|
|
|
|
click
|
|
|
|
click-log
|
|
|
|
paho-mqtt
|
|
|
|
pyaml
|
|
|
|
];
|
|
|
|
|
|
|
|
postPatch = ''
|
|
|
|
sed -ri 's/@@VERSION@@/${version}/g' \
|
|
|
|
bch/cli.py setup.py
|
|
|
|
'';
|
|
|
|
|
|
|
|
pythonImportsCheck = [ "bch" ];
|
|
|
|
|
|
|
|
meta = with lib; {
|
|
|
|
homepage = "https://github.com/hardwario/bch-control-tool";
|
|
|
|
description = "HARDWARIO Hub Control Tool";
|
2024-04-21 15:54:59 +00:00
|
|
|
mainProgram = "bch";
|
2023-08-04 22:07:22 +00:00
|
|
|
platforms = platforms.linux;
|
|
|
|
license = licenses.mit;
|
|
|
|
maintainers = with maintainers; [ cynerd ];
|
|
|
|
};
|
|
|
|
}
|