1{ lib 2, buildPythonPackage 3, fetchFromGitHub 4, pytestCheckHook 5, pythonOlder 6}: 7 8buildPythonPackage rec { 9 pname = "puremagic"; 10 version = "1.15"; 11 format = "setuptools"; 12 13 disabled = pythonOlder "3.7"; 14 15 src = fetchFromGitHub { 16 owner = "cdgriffith"; 17 repo = pname; 18 rev = "refs/tags/${version}"; 19 hash = "sha256-WnqDrVPTlNxz3SDt1wLdZmxtj0Vh6gLHDJlYGEHHxsg="; 20 }; 21 22 nativeCheckInputs = [ 23 pytestCheckHook 24 ]; 25 26 pythonImportsCheck = [ 27 "puremagic" 28 ]; 29 30 meta = with lib; { 31 description = "Implementation of magic file detection"; 32 homepage = "https://github.com/cdgriffith/puremagic"; 33 changelog = "https://github.com/cdgriffith/puremagic/blob/${version}/CHANGELOG.md"; 34 license = licenses.mit; 35 maintainers = with maintainers; [ globin ]; 36 }; 37}