diff options
Diffstat (limited to 'pkgs/development/python-modules/pydateinfer/default.nix')
-rw-r--r-- | pkgs/development/python-modules/pydateinfer/default.nix | 40 |
1 files changed, 40 insertions, 0 deletions
diff --git a/pkgs/development/python-modules/pydateinfer/default.nix b/pkgs/development/python-modules/pydateinfer/default.nix new file mode 100644 index 00000000000..a2fb97236df --- /dev/null +++ b/pkgs/development/python-modules/pydateinfer/default.nix @@ -0,0 +1,40 @@ +{ lib +, buildPythonPackage +, fetchFromGitHub +, unittestCheckHook +, pytz +, pyyaml +, argparse +}: + +buildPythonPackage rec { + pname = "pydateinfer"; + version = "0.3.0"; + format = "setuptools"; + + src = fetchFromGitHub { + owner = "wdm0006"; + repo = "dateinfer"; + rev = "${version},"; # yes the comma is required, this is correct name of git tag + hash = "sha256-0gy7wfT/uMTmpdIF2OPGVeUh+4yqJSI2Ebif0Lf/DLM="; + }; + + propagatedBuildInputs = [ + pytz + ]; + + preCheck = "cd dateinfer"; + nativeCheckInputs = [ + unittestCheckHook + pyyaml + argparse + ]; + pythonImportsCheck = [ "dateinfer" ]; + + meta = with lib; { + description = "Infers date format from examples"; + homepage = "https://pypi.org/project/pydateinfer/"; + license = licenses.asl20; + maintainers = with maintainers; [ mbalatsko ]; + }; +} |