8 definitions ? jupyter-kernel.default
11 (python3.buildEnv.override {
12 extraLibs = [ python3.pkgs.jupyter-console ];
14 "--set JUPYTER_PATH ${jupyter-kernel.create { inherit definitions; }}"
15 ] ++ lib.optionals (kernel != null) [
16 "--add-flags --kernel"
17 "--add-flags ${kernel}"
19 }).overrideAttrs (oldAttrs: {
20 # To facilitate running nix run .#jupyter-console
21 meta = oldAttrs.meta // { mainProgram = "jupyter-console"; };
27 # Build a console derivation with an arbitrary set of definitions, and an optional kernel to use.
28 # If the kernel argument is not supplied, Jupyter console will pick a kernel to run from the ones
29 # available on the system.
32 # An ergonomic way to start a console with a single kernel.
33 withSingleKernel = definition: mkConsole {
34 definitions = lib.listToAttrs [(lib.nameValuePair definition.language definition)];
35 kernel = definition.language;