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 ]; + }; +} diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index 1ccfed6d8d73..4507010d7e0e 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -11382,7 +11382,7 @@ with pkgs; b43Firmware_6_30_163_46 = callPackage ../os-specific/linux/firmware/b43-firmware/6.30.163.46.nix { }; b43FirmwareCutter = callPackage ../os-specific/linux/firmware/b43-firmware-cutter { }; - + bt-fw-converter = callPackage ../os-specific/linux/firmware/bt-fw-converter { }; broadcom-bt-firmware = callPackage ../os-specific/linux/firmware/broadcom-bt-firmware { }; @@ -14851,6 +14851,8 @@ with pkgs; clerk = callPackage ../applications/audio/clerk { }; + nbstripout = callPackage ../applications/version-management/nbstripout { }; + ncmpc = callPackage ../applications/audio/ncmpc { }; ncmpcpp = callPackage ../applications/audio/ncmpcpp { };