1
0
Fork 0
mirror of https://github.com/NixOS/nixpkgs.git synced 2025-06-28 12:06:38 +03:00
nixpkgs/pkgs/development/python-modules/regex/default.nix

32 lines
731 B
Nix
Raw Normal View History

2018-01-01 11:46:35 +01:00
{ lib
, buildPythonPackage
, fetchPypi
, python
2021-04-23 16:49:06 +02:00
, isPy27
2018-01-01 11:46:35 +01:00
}:
buildPythonPackage rec {
pname = "regex";
version = "2021.10.8";
2018-01-01 11:46:35 +01:00
src = fetchPypi {
inherit pname version;
sha256 = "26895d7c9bbda5c52b3635ce5991caa90fbb1ddfac9c9ff1c7ce505e2282fb2a";
2018-01-01 11:46:35 +01:00
};
2021-04-23 16:49:06 +02:00
# Sources for different Python releases are located in same folder
checkPhase = ''
rm -r ${if !isPy27 then "regex_2" else "regex_3"}
${python.interpreter} -m unittest
'';
pythonImportsCheck = [ "regex" ];
meta = with lib; {
2018-01-01 11:46:35 +01:00
description = "Alternative regular expression module, to replace re";
homepage = "https://bitbucket.org/mrabarnett/mrab-regex";
license = licenses.psfl;
maintainers = with maintainers; [ abbradar ];
2018-01-01 11:46:35 +01:00
};
}