1{ lib
2, fetchFromGitHub
3# Python bits:
4, buildPythonPackage
5, pytest
6, responses
7, docopt
8, flask
9, markdown
10, path-and-address
11, pygments
12, requests
13, tabulate
14}:
15
16buildPythonPackage rec {
17 pname = "grip";
18 version = "4.6.1";
19
20 src = fetchFromGitHub {
21 owner = "joeyespo";
22 repo = "grip";
23 rev = "v${version}";
24 sha256 = "sha256-CHL2dy0H/i0pLo653F7aUHFvZHTeZA6jC/rwn1KrEW4=";
25 };
26
27 checkInputs = [ pytest responses ];
28
29 propagatedBuildInputs = [ docopt flask markdown path-and-address pygments requests tabulate ];
30
31 checkPhase = ''
32 export PATH="$PATH:$out/bin"
33 py.test -xm "not assumption"
34 '';
35
36 meta = with lib; {
37 description = "Preview GitHub Markdown files like Readme locally before committing them";
38 homepage = "https://github.com/joeyespo/grip";
39 license = licenses.mit;
40 maintainers = with maintainers; [ koral ];
41 };
42}