mirror of
https://github.com/NixOS/nixpkgs.git
synced 2024-12-22 13:43:22 +00:00
a3d4659349
Diff: https://github.com/tillsteinbach/WeConnect-mqtt/compare/refs/tags/v0.40.3...v0.41.1 Changelog: https://github.com/tillsteinbach/WeConnect-mqtt/releases/tag/v0.41.1
55 lines
1.3 KiB
Nix
55 lines
1.3 KiB
Nix
{ lib
|
|
, buildPythonPackage
|
|
, fetchFromGitHub
|
|
, pytestCheckHook
|
|
, pythonOlder
|
|
, paho-mqtt
|
|
, python-dateutil
|
|
, weconnect
|
|
}:
|
|
|
|
buildPythonPackage rec {
|
|
pname = "weconnect-mqtt";
|
|
version = "0.41.1";
|
|
format = "setuptools";
|
|
|
|
disabled = pythonOlder "3.7";
|
|
|
|
src = fetchFromGitHub {
|
|
owner = "tillsteinbach";
|
|
repo = "WeConnect-mqtt";
|
|
rev = "refs/tags/v${version}";
|
|
hash = "sha256-RYxfz5uBWV1HLbcIK1N/glJv2w0nfPLBPyM2b7HuDIY=";
|
|
};
|
|
|
|
propagatedBuildInputs = [
|
|
paho-mqtt
|
|
python-dateutil
|
|
weconnect
|
|
] ++ weconnect.optional-dependencies.Images;
|
|
|
|
postPatch = ''
|
|
substituteInPlace weconnect_mqtt/__version.py \
|
|
--replace "develop" "${version}"
|
|
substituteInPlace pytest.ini \
|
|
--replace "--cov=weconnect_mqtt --cov-config=.coveragerc --cov-report html" "" \
|
|
--replace "pytest-cov" ""
|
|
'';
|
|
|
|
checkInputs = [
|
|
pytestCheckHook
|
|
];
|
|
|
|
pythonImportsCheck = [
|
|
"weconnect_mqtt"
|
|
];
|
|
|
|
meta = with lib; {
|
|
description = "Python client that publishes data from Volkswagen WeConnect";
|
|
homepage = "https://github.com/tillsteinbach/WeConnect-mqtt";
|
|
changelog = "https://github.com/tillsteinbach/WeConnect-mqtt/releases/tag/v${version}";
|
|
license = with licenses; [ mit ];
|
|
maintainers = with maintainers; [ fab ];
|
|
};
|
|
}
|