1{ 2 lib, 3 buildPythonPackage, 4 fetchFromGitHub, 5 unittestCheckHook, 6 setuptools-scm, 7}: 8 9buildPythonPackage rec { 10 pname = "thorlabspm100"; 11 version = "1.2.2"; 12 format = "setuptools"; 13 14 src = fetchFromGitHub { 15 owner = "clade"; 16 repo = "ThorlabsPM100"; 17 rev = "v${version}"; 18 hash = "sha256-X4qEow6u4aE0sbFwZfK3YEso2RS0c9j4iaWJPHaPQV4="; 19 }; 20 21 nativeBuildInputs = [ setuptools-scm ]; 22 23 nativeCheckInputs = [ unittestCheckHook ]; 24 25 pythonImportsCheck = [ "ThorlabsPM100" ]; 26 27 meta = with lib; { 28 description = "Interface to the PM100A/D power meter from Thorlabs"; 29 homepage = "https://github.com/clade/ThorlabsPM100/"; 30 license = licenses.bsd3; 31 maintainers = with maintainers; [ fsagbuya ]; 32 }; 33}