feat(nix): Rework the python environment

This commit is contained in:
Tom Hubrecht 2024-09-16 17:57:26 +02:00
parent 8baad602c6
commit 99764928c6
Signed by: thubrecht
SSH key fingerprint: SHA256:r+nK/SIcWlJ0zFZJGHtlAoRwq1Rm+WcKAm5ADYMoQPc

View file

@ -24,6 +24,14 @@ let
commitizen.enable = true;
};
};
python = pkgs.python312.override {
packageOverrides =
self: _:
pkgs.lib.genAttrs (builtins.attrNames (builtins.readDir ./pkgs)) (
p: self.callPackage ./pkgs/${p} { }
);
};
in
{
@ -35,26 +43,23 @@ in
pkgs.dart-sass
# Python dependencies
(pkgs.python312.withPackages (
ps:
[
ps.daphne
ps.django
ps.django-allauth
ps.django-compressor
ps.django-debug-toolbar
ps.django-stubs
ps.loadcredential
ps.ipython
]
++ (builtins.map (p: ps.callPackage ./pkgs/${p} { }) [
"django-browser-reload"
"django-bulma-forms"
"django-sass-processor"
"django-sass-processor-dart-sass"
"pykanidm"
])
))
(python.withPackages (ps: [
ps.daphne
ps.django
ps.django-allauth
ps.django-allauth-cas
ps.django-browser-reload
ps.django-bulma-forms
ps.django-compressor
ps.django-debug-toolbar
ps.django-sass-processor
ps.django-sass-processor-dart-sass
ps.django-stubs
ps.ipython
ps.loadcredential
ps.pykanidm
ps.python-cas
]))
] ++ check.enabledPackages;
env = {