depot/third_party/nixpkgs/pkgs/development/python-modules/bluetooth-auto-recovery/default.nix
Default email 01ed8ef136 Project import generated by Copybara.
GitOrigin-RevId: 20fc948445a6c22d4e8d5178e9a6bc6e1f5417c8
2022-11-21 19:40:18 +02:00

56 lines
1.2 KiB
Nix

{ lib
, async-timeout
, btsocket
, buildPythonPackage
, fetchFromGitHub
, poetry-core
, pyric
, pytestCheckHook
, pythonOlder
}:
buildPythonPackage rec {
pname = "bluetooth-auto-recovery";
version = "0.4.0";
format = "pyproject";
disabled = pythonOlder "3.9";
src = fetchFromGitHub {
owner = "Bluetooth-Devices";
repo = pname;
rev = "refs/tags/v${version}";
hash = "sha256-juGrrUqPgg1bJsMZP0iitp0NW/XrCxNq/+/fx5QNkQ4=";
};
nativeBuildInputs = [
poetry-core
];
propagatedBuildInputs = [
async-timeout
btsocket
pyric
];
checkInputs = [
pytestCheckHook
];
postPatch = ''
substituteInPlace pyproject.toml \
--replace " --cov=bluetooth_auto_recovery --cov-report=term-missing:skip-covered" ""
'';
pythonImportsCheck = [
"bluetooth_auto_recovery"
];
meta = with lib; {
description = "Library for recovering Bluetooth adapters";
homepage = "https://github.com/Bluetooth-Devices/bluetooth-auto-recovery";
changelog = "https://github.com/Bluetooth-Devices/bluetooth-auto-recovery/blob/v${version}/CHANGELOG.md";
license = with licenses; [ mit ];
maintainers = with maintainers; [ fab ];
};
}