mirror of
https://github.com/NixOS/nixpkgs.git
synced 2024-11-27 16:11:58 +00:00
python3Packages.nix-kernel: init at 0.1
This commit is contained in:
parent
bba261c785
commit
3f19239ee0
45
pkgs/development/python-modules/nix-kernel/default.nix
Normal file
45
pkgs/development/python-modules/nix-kernel/default.nix
Normal file
|
@ -0,0 +1,45 @@
|
|||
{ lib
|
||||
, buildPythonPackage
|
||||
, fetchFromGitHub
|
||||
, pexpect
|
||||
, notebook
|
||||
, nix
|
||||
}:
|
||||
|
||||
buildPythonPackage rec {
|
||||
pname = "nix-kernel";
|
||||
version = "unstable-2020-04-26";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "GTrunSec";
|
||||
repo = "nix-kernel";
|
||||
rev = "dfa42d0812d508ded99f690ee1a83281d900a3ec";
|
||||
sha256 = "1lf4rbbxjmq9h6g3wrdzx3v3dn1bndfmiybxiy0sjavgb6lzc8kq";
|
||||
};
|
||||
|
||||
postPatch = ''
|
||||
substituteInPlace nix-kernel/kernel.py \
|
||||
--replace "'nix'" "'${nix}/bin/nix'" \
|
||||
--replace "'nix repl'" "'${nix}/bin/nix repl'"
|
||||
|
||||
substituteInPlace setup.py \
|
||||
--replace "cmdclass={'install': install_with_kernelspec}," ""
|
||||
'';
|
||||
|
||||
propagatedBuildInputs = [
|
||||
pexpect
|
||||
notebook
|
||||
];
|
||||
|
||||
# no tests in repo
|
||||
doCheck = false;
|
||||
|
||||
pythonImportsCheck = [ "nix-kernel" ];
|
||||
|
||||
meta = with lib; {
|
||||
description = "Simple jupyter kernel for nix-repl";
|
||||
homepage = "https://github.com/GTrunSec/nix-kernel";
|
||||
license = licenses.mit;
|
||||
maintainers = with maintainers; [ costrouc ];
|
||||
};
|
||||
}
|
|
@ -4965,6 +4965,10 @@ in {
|
|||
|
||||
nitime = callPackage ../development/python-modules/nitime { };
|
||||
|
||||
nix-kernel = callPackage ../development/python-modules/nix-kernel {
|
||||
inherit (pkgs) nix;
|
||||
};
|
||||
|
||||
nixpkgs = callPackage ../development/python-modules/nixpkgs { };
|
||||
|
||||
nixpkgs-pytools = callPackage ../development/python-modules/nixpkgs-pytools { };
|
||||
|
|
Loading…
Reference in a new issue