-
Notifications
You must be signed in to change notification settings - Fork 0
/
flake.nix
104 lines (93 loc) · 3.03 KB
/
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
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
{
description = "Themis - an assistent in finding fitting feedback items";
inputs = {
nixpkgs.url = "github:nixos/nixpkgs/nixos-unstable";
flake-utils.url = "github:numtide/flake-utils";
devshell = {
url = "github:numtide/devshell";
inputs = {
flake-utils.follows = "flake-utils";
nixpkgs.follows = "nixpkgs";
};
};
};
outputs = { self, nixpkgs, devshell, flake-utils }:
flake-utils.lib.eachDefaultSystem (system:
let
pkgs = import nixpkgs {
inherit system;
overlays = [
devshell.overlays.default
];
};
tree-sitter = pkgs.python312Packages.buildPythonPackage rec {
pname = "tree-sitter";
version = "0.21.1";
format = "setuptools";
src = pkgs.python312Packages.fetchPypi {
inherit pname version;
sha256 = "/IMM6mn/9xzfKOVzJu65Rgrl/3DRtdS7o2uIm0ugI38=";
};
pythonImportsCheck = [ "tree_sitter" ];
};
bounded-pool-executor = pkgs.python312Packages.buildPythonPackage rec {
pname = "bounded_pool_executor";
version = "0.0.3";
format = "setuptools";
src = pkgs.python312Packages.fetchPypi {
inherit pname version;
sha256 = "4JIiG8OK3lVeEGSDH57YAFgPo0pLbY6d082WFUlif24=";
};
propagatedBuildInputs = [ ];
pythonImportsCheck = [ "bounded_pool_executor" ];
};
pqdm = pkgs.python312Packages.buildPythonPackage rec {
pname = "pqdm";
version = "0.2.0";
format = "setuptools";
src = pkgs.python312Packages.fetchPypi {
inherit pname version;
sha256 = "2Z0B/kmNMntEDr/gjBTITg3J7M5hcu+aMflrsar06eM=";
};
doCheck = false;
propagatedBuildInputs = [
pkgs.python312Packages.typing-extensions
pkgs.python312Packages.tqdm
bounded-pool-executor
];
pythonImportsCheck = [ "pqdm.processes" "pqdm.threads" ];
};
in
{
devShells = rec {
default = themis;
themis = pkgs.devshell.mkShell {
name = "Themis";
imports = [ "${devshell}/extra/language/c.nix" ];
packages = with pkgs; [
nixpkgs-fmt
(python312.withPackages (ps: [
tree-sitter
(ps.pylint.override {
isort = (ps.isort.overrideAttrs (old: { pytestCheckPhase = "true"; })).override {
pylama = ps.pylama.override {
pydocstyle = ps.pydocstyle.overrideAttrs (old: { pytestCheckPhase = "true"; });
};
};
})
ps.setuptools
ps.numpy
ps.matplotlib
ps.pydot
ps.tqdm
pqdm
]))
];
language.c = {
compiler = pkgs.gcc;
};
};
};
}
);
}