1{ 2 lib, 3 buildPythonPackage, 4 fetchFromGitHub, 5 pytestCheckHook, 6 setuptools, 7}: 8 9buildPythonPackage rec { 10 pname = "python-ipmi"; 11 version = "0.5.7"; 12 pyproject = true; 13 14 src = fetchFromGitHub { 15 owner = "kontron"; 16 repo = "python-ipmi"; 17 tag = version; 18 hash = "sha256-vwjVUkTeVC1On1I1BtM0kBbne6CbX/6Os1+HA8WN9jU="; 19 }; 20 21 postPatch = '' 22 substituteInPlace setup.py \ 23 --replace-fail "version=version," "version='${version}'," 24 ''; 25 26 build-system = [ setuptools ]; 27 28 nativeCheckInputs = [ 29 pytestCheckHook 30 ]; 31 32 pythonImportsCheck = [ "pyipmi" ]; 33 34 meta = with lib; { 35 description = "Python IPMI Library"; 36 mainProgram = "ipmitool.py"; 37 homepage = "https://github.com/kontron/python-ipmi"; 38 license = with licenses; [ lgpl2Plus ]; 39 maintainers = with maintainers; [ fab ]; 40 }; 41}