-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathflake.nix
32 lines (30 loc) · 967 Bytes
/
flake.nix
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
{
description = "Application packaged using poetry2nix";
inputs.nixpkgs.url = "github:NixOS/nixpkgs/nixos-unstable";
inputs.nixpkgs-typst.url = "github:NixOS/nixpkgs/nixos-unstable";
outputs = {
self,
nixpkgs,
nixpkgs-typst,
}: let
system = "x86_64-linux";
pkgs = import nixpkgs {
inherit system;
config.allowUnfree = true;
config.cudaSupport = true;
};
typst-pkgs = import nixpkgs-typst {
inherit system;
};
matplotlib = pkgs.python3Packages.matplotlib.override {enableQt = true;};
pyEnv = pkgs.python3.withPackages (ps: with ps; [torchvision-bin onnx numpy pillow jupyter matplotlib ipython scipy pyqt5 tensorboard tabulate]);
in {
formatter.${system} = pkgs.alejandra;
devShells.${system} = {
default = pkgs.mkShell {
packages = [pyEnv pkgs.jq typst-pkgs.typst];
QT_PLUGIN_PATH = with pkgs.qt5; "${qtbase}/${qtbase.qtPluginPrefix}";
};
};
};
}