1a04744f74
There is no need to disable Python packages for Python versions that are
no longer in Nixpkgs.
This change was generated using the following script:
pattern='^\s*disabled\s*=\s*pythonOlder\s*"3\.\([0-9]\|10\)"\s*;\s*$'
for f in $(find -name '*.nix'); do
grep -q "$pattern" "$f" || continue
sed -i "/$pattern/d" "$f"
if [ $(grep -c pythonOlder "$f") == 1 ]; then
sed -i '/^\s*pythonOlder,\s*$/d' "$f"
fi
nixfmt "$f"
done
58 lines
1.2 KiB
Nix
58 lines
1.2 KiB
Nix
{
|
|
lib,
|
|
bleak-retry-connector,
|
|
bleak,
|
|
buildPythonPackage,
|
|
fetchFromGitHub,
|
|
pycryptodome,
|
|
pytest-asyncio,
|
|
pytestCheckHook,
|
|
setuptools,
|
|
}:
|
|
|
|
buildPythonPackage rec {
|
|
pname = "motionblindsble";
|
|
version = "0.1.3";
|
|
pyproject = true;
|
|
|
|
src = fetchFromGitHub {
|
|
owner = "LennP";
|
|
repo = "motionblindsble";
|
|
tag = version;
|
|
hash = "sha256-1dA3YTjoAhe+p5vk6Xb42a+rE63m2mn5iHhVV/6tlQ0=";
|
|
};
|
|
|
|
postPatch = ''
|
|
substituteInPlace setup.py \
|
|
--replace-fail "{{VERSION_PLACEHOLDER}}" "${version}"
|
|
'';
|
|
|
|
build-system = [ setuptools ];
|
|
|
|
dependencies = [
|
|
bleak
|
|
bleak-retry-connector
|
|
pycryptodome
|
|
];
|
|
|
|
nativeCheckInputs = [
|
|
pytest-asyncio
|
|
pytestCheckHook
|
|
];
|
|
|
|
pythonImportsCheck = [ "motionblindsble" ];
|
|
|
|
disabledTests = [
|
|
# AssertionError
|
|
"test_establish_connection"
|
|
];
|
|
|
|
meta = {
|
|
description = "Module to interface with Motionblinds motors using Bluetooth Low Energy (BLE)";
|
|
homepage = "https://github.com/LennP/motionblindsble";
|
|
changelog = "https://github.com/LennP/motionblindsble/releases/tag/${version}";
|
|
license = lib.licenses.mit;
|
|
maintainers = with lib.maintainers; [ fab ];
|
|
};
|
|
}
|