Clone of https://github.com/NixOS/nixpkgs.git (to stress-test knotserver)
1{ lib 2, fetchFromGitHub 3, python3 4}: 5 6python3.pkgs.buildPythonApplication rec { 7 pname = "trustymail"; 8 version = "0.8.1"; 9 format = "setuptools"; 10 11 src = fetchFromGitHub { 12 owner = "cisagov"; 13 repo = pname; 14 rev = "refs/tags/v${version}"; 15 hash = "sha256-hKiQWAOzUjmoCcEH9OTgkgU7s1V+Vv3+93OLkqDRDoU="; 16 }; 17 18 postPatch = '' 19 substituteInPlace pytest.ini \ 20 --replace " --cov" "" 21 ''; 22 23 propagatedBuildInputs = with python3.pkgs; [ 24 dnspython 25 docopt 26 publicsuffixlist 27 pydns 28 pyspf 29 requests 30 ] ++ publicsuffixlist.optional-dependencies.update; 31 32 nativeCheckInputs = with python3.pkgs; [ 33 pytestCheckHook 34 ]; 35 36 pythonImportsCheck = [ 37 "trustymail" 38 ]; 39 40 meta = with lib; { 41 description = "Tool to scan domains and return data based on trustworthy email best practices"; 42 homepage = "https://github.com/cisagov/trustymail"; 43 changelog = "https://github.com/cisagov/trustymail/releases/tag/v${version}"; 44 license = with licenses; [ cc0 ]; 45 maintainers = with maintainers; [ fab ]; 46 }; 47}