1{ lib
2, buildPythonPackage
3, fetchFromGitHub
4, pytestCheckHook
5, nodejs
6}:
7
8buildPythonPackage rec {
9 pname = "pscript";
10 version = "0.7.6";
11
12 # PyPI tarball doesn't include tests directory
13 src = fetchFromGitHub {
14 owner = "flexxui";
15 repo = pname;
16 rev = "v${version}";
17 sha256 = "169px5n4jjnpdn9y86f28qwd95bwf1q1rz0a1h3lb5nn5c6ym8c4";
18 };
19
20 checkInputs = [
21 pytestCheckHook
22 nodejs
23 ];
24
25 preCheck = ''
26 # do not execute legacy tests
27 rm -rf pscript_legacy
28 '';
29
30 meta = with lib; {
31 description = "Python to JavaScript compiler";
32 license = licenses.bsd2;
33 homepage = "https://pscript.readthedocs.io";
34 maintainers = [ maintainers.matthiasbeyer ];
35 };
36}
37
38
39