add flake-jupyter
This commit is contained in:
parent
7984d011fb
commit
d9db6faf24
2 changed files with 37 additions and 0 deletions
|
@ -12,6 +12,10 @@
|
||||||
path = ./flakes/rust;
|
path = ./flakes/rust;
|
||||||
description = "Flake to develop, build and run a rust application";
|
description = "Flake to develop, build and run a rust application";
|
||||||
};
|
};
|
||||||
|
flake-jupyter = {
|
||||||
|
path = ./flakes/jupyter;
|
||||||
|
description = "Flake to configure jupyter lab";
|
||||||
|
};
|
||||||
# starters
|
# starters
|
||||||
starter-typescript = {
|
starter-typescript = {
|
||||||
path = ./starters/typescript;
|
path = ./starters/typescript;
|
||||||
|
|
33
flakes/jupyter/flake.nix
Normal file
33
flakes/jupyter/flake.nix
Normal file
|
@ -0,0 +1,33 @@
|
||||||
|
{
|
||||||
|
inputs = {
|
||||||
|
jupyterWith.url = "github:tweag/jupyterWith";
|
||||||
|
utils.url = "github:numtide/flake-utils";
|
||||||
|
};
|
||||||
|
|
||||||
|
outputs = { self, nixpkgs, jupyterWith, utils }:
|
||||||
|
utils.lib.eachDefaultSystem (system:
|
||||||
|
let
|
||||||
|
pkgs = import nixpkgs {
|
||||||
|
inherit system;
|
||||||
|
overlays = builtins.attrValues jupyterWith.overlays;
|
||||||
|
};
|
||||||
|
|
||||||
|
# Source https://github.com/tweag/jupyterWith
|
||||||
|
iPython = pkgs.kernels.iPythonWith {
|
||||||
|
name = "python";
|
||||||
|
packages = p: with p; [ numpy ];
|
||||||
|
};
|
||||||
|
|
||||||
|
jupyterLab = pkgs.jupyterlabWith {
|
||||||
|
kernels = [ iPython ];
|
||||||
|
};
|
||||||
|
|
||||||
|
in
|
||||||
|
{
|
||||||
|
apps.default = {
|
||||||
|
type = "app";
|
||||||
|
program = "${jupyterLab}/bin/jupyter-lab";
|
||||||
|
};
|
||||||
|
devShell = jupyterLab.env;
|
||||||
|
});
|
||||||
|
}
|
Loading…
Reference in a new issue