diff options
author | Frederik Rietdijk <freddyrietdijk@fridh.nl> | 2017-05-15 08:47:12 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2017-05-15 08:47:12 +0200 |
commit | 9468764b15ec1bc1f9d849b7d2da03bc10f4d6a8 (patch) | |
tree | 9ceb3b8e1b35ee9f3c87eb9ce8920c76f3ace903 /pkgs/applications/version-management | |
parent | 044063666e25be9d04a82842dfe9c74bfa1acce4 (diff) | |
parent | 1745b7e949d563f01f9bb92ac872374ec7ca3a70 (diff) | |
download | nixlib-9468764b15ec1bc1f9d849b7d2da03bc10f4d6a8.tar nixlib-9468764b15ec1bc1f9d849b7d2da03bc10f4d6a8.tar.gz nixlib-9468764b15ec1bc1f9d849b7d2da03bc10f4d6a8.tar.bz2 nixlib-9468764b15ec1bc1f9d849b7d2da03bc10f4d6a8.tar.lz nixlib-9468764b15ec1bc1f9d849b7d2da03bc10f4d6a8.tar.xz nixlib-9468764b15ec1bc1f9d849b7d2da03bc10f4d6a8.tar.zst nixlib-9468764b15ec1bc1f9d849b7d2da03bc10f4d6a8.zip |
Merge pull request #25609 from jluttine/add-nbstripout
nbstripout: init at 0.3.0
Diffstat (limited to 'pkgs/applications/version-management')
-rw-r--r-- | pkgs/applications/version-management/nbstripout/default.nix | 32 |
1 files changed, 32 insertions, 0 deletions
diff --git a/pkgs/applications/version-management/nbstripout/default.nix b/pkgs/applications/version-management/nbstripout/default.nix new file mode 100644 index 000000000000..3029d17e1705 --- /dev/null +++ b/pkgs/applications/version-management/nbstripout/default.nix @@ -0,0 +1,32 @@ +{lib, python2Packages, git, mercurial}: + +with python2Packages; +buildPythonApplication rec { + name = "${pname}-${version}"; + version = "0.3.0"; + pname = "nbstripout"; + + # Mercurial should be added as a build input but because it's a Python + # application, it would mess up the Python environment. Thus, don't add it + # here, instead add it to PATH when running unit tests + buildInputs = [ pytest pytest-flake8 pytest-cram git pytestrunner ]; + propagatedBuildInputs = [ ipython nbformat ]; + + src = fetchPypi { + inherit pname version; + sha256 = "126xhjma4a0k7gq58hbqglhb3rai0a576azz7g8gmqjr3kl0264v"; + }; + + # ignore flake8 tests for the nix wrapped setup.py + checkPhase = '' + PATH=$PATH:$out/bin:${mercurial}/bin pytest --ignore=nix_run_setup.py . + ''; + + meta = { + inherit version; + description = "Strip output from Jupyter and IPython notebooks"; + homepage = https://github.com/kynan/nbstripout; + license = lib.licenses.mit; + maintainers = with lib.maintainers; [ jluttine ]; + }; +} |