Merge pull request #268619 from tweag/lib-descriptions
[NixPkgs.git] / pkgs / development / python-modules / cron-descriptor / default.nix
blobbb946780009eb0e92c6ed7a3a921cfb5599e7693
1 { lib
2 , python
3 , buildPythonPackage
4 , fetchFromGitHub
5 , mock
6 , pytestCheckHook
7 }:
9 buildPythonPackage rec {
10   pname = "cron_descriptor";
11   version = "1.2.35";
13   src = fetchFromGitHub {
14     owner = "Salamek";
15     repo = "cron-descriptor";
16     rev = "refs/tags/${version}";
17     hash = "sha256-m+h91cddmEPHCeUWWNpTvb89mFwm8ty8tTnw3YDjCFo=";
18   };
20   # remove tests_require, as we don't do linting anyways
21   postPatch = ''
22     sed -i "/'pep8\|flake8\|pep8-naming',/d" setup.py
23   '';
25   checkInputs = [
26     mock
27   ];
29   checkPhase = ''
30     ${python.interpreter} setup.py test
31   '';
33   pythonImportsCheck = [ "cron_descriptor" ];
35   meta = with lib; {
36     description = "Library that converts cron expressions into human readable strings";
37     homepage = "https://github.com/Salamek/cron-descriptor";
38     license = licenses.mit;
39     maintainers = with maintainers; [ phaer ];
40   };