1{
2 lib,
3 buildPythonPackage,
4 fetchFromGitHub,
5 regex,
6 pytest,
7}:
8
9buildPythonPackage rec {
10 pname = "pygrok";
11 version = "1.0.0";
12 format = "setuptools";
13
14 src = fetchFromGitHub {
15 owner = "garyelephant";
16 repo = "pygrok";
17 rev = "v${version}";
18 sha256 = "07487rcmv74srnchh60jp0vg46g086qmpkaj8gxqhp9rj47r1s4m";
19 };
20
21 propagatedBuildInputs = [ regex ];
22
23 nativeCheckInputs = [ pytest ];
24 checkPhase = ''
25 pytest
26 '';
27
28 meta = with lib; {
29 maintainers = with maintainers; [ winpat ];
30 description = "Python implementation of jordansissel's grok regular expression library";
31 homepage = "https://github.com/garyelephant/pygrok";
32 license = licenses.mit;
33 platforms = platforms.unix;
34 };
35}