diff options
author | Mx Kookie <kookie@spacekookie.de> | 2020-12-09 18:55:19 +0000 |
---|---|---|
committer | Mx Kookie <kookie@spacekookie.de> | 2020-12-09 18:55:19 +0000 |
commit | 80d90d9b204f7c17912740f9f414fe5d59f293ba (patch) | |
tree | 5f2065a06e724270610760d59d01c6888b375a46 /infra/libkookie/nixpkgs/pkgs/development/python-modules/coconut/default.nix | |
parent | 3a31a84c7d3e589035ad08499206aac44a81f424 (diff) | |
parent | 83cbad92d73216bb0d9187c56cce0b91f9121d5a (diff) |
Merge commit '83cbad92d73216bb0d9187c56cce0b91f9121d5a' into main
Diffstat (limited to 'infra/libkookie/nixpkgs/pkgs/development/python-modules/coconut/default.nix')
-rw-r--r-- | infra/libkookie/nixpkgs/pkgs/development/python-modules/coconut/default.nix | 52 |
1 files changed, 52 insertions, 0 deletions
diff --git a/infra/libkookie/nixpkgs/pkgs/development/python-modules/coconut/default.nix b/infra/libkookie/nixpkgs/pkgs/development/python-modules/coconut/default.nix new file mode 100644 index 000000000000..b75a82b6c2b2 --- /dev/null +++ b/infra/libkookie/nixpkgs/pkgs/development/python-modules/coconut/default.nix @@ -0,0 +1,52 @@ +{ + lib, + buildPythonApplication, + fetchFromGitHub, + fetchpatch, + + cpyparsing, + ipykernel, + mypy, + pygments, + pytest, + prompt_toolkit, + tkinter, + watchdog +}: + +buildPythonApplication rec { + pname = "coconut"; + version = "1.4.3"; + + src = fetchFromGitHub { + owner = "evhub"; + repo = "coconut"; + rev = "v${version}"; + sha256 = "1pz13vza3yy95dbylnq89fzc3mwgcqr7ds096wy25k6vxd9dp9c3"; + }; + + propagatedBuildInputs = [ cpyparsing pygments prompt_toolkit ipykernel mypy watchdog ]; + + patches = [ + (fetchpatch { + name = "fix-setuptools-version-check.patch"; + url = "https://github.com/LibreCybernetics/coconut/commit/2916a087da1e063cc4438b68d4077347fd1ea4a2.patch"; + sha256 = "136jbd2rvnifw30y73vv667002nf7sbkm5qyihshj4db7ngysr6q"; + }) + ]; + + checkInputs = [ pytest tkinter ]; + # Currently most tests do not work on Hydra due to external fetches. + checkPhase = '' + pytest tests/constants_test.py + pytest tests/main_test.py::TestShell::test_compile_to_file + pytest tests/main_test.py::TestShell::test_convenience + ''; + + meta = with lib; { + homepage = "http://coconut-lang.org/"; + description = "Simple, elegant, Pythonic functional programming"; + license = licenses.asl20; + maintainers = with maintainers; [ fabianhjr ]; + }; +} |