31 lines
961 B
Nix
31 lines
961 B
Nix
{
|
|
description = "Jupyter notebook flake";
|
|
|
|
inputs.nixpkgs.url = "github:NixOS/nixpkgs/nixos-22.11";
|
|
inputs.flake-utils.url = "github:numtide/flake-utils";
|
|
|
|
outputs = { self, nixpkgs, flake-utils}:
|
|
flake-utils.lib.eachDefaultSystem (system:
|
|
let
|
|
pkgs = import nixpkgs {
|
|
inherit system;
|
|
};
|
|
python-packages = p: with p; [
|
|
imageio
|
|
jupyter
|
|
matplotlib
|
|
notebook
|
|
numpy
|
|
];
|
|
in {
|
|
devShells.default = pkgs.mkShell {
|
|
buildInputs = with pkgs; [
|
|
(python3.withPackages python-packages)
|
|
];
|
|
shellHook = ''
|
|
jupyter notebook ./CIEColorSpaces.ipynb && exit
|
|
'';
|
|
};
|
|
}
|
|
);
|
|
}
|