Update shell.nix and use django-types
This commit is contained in:
parent
14e0a3ef0a
commit
af4c8e0744
1 changed files with 29 additions and 6 deletions
35
shell.nix
35
shell.nix
|
@ -1,5 +1,29 @@
|
||||||
{ pkgs ? import <nixpkgs> { }, ... }:
|
{ pkgs ? import <nixpkgs> { }, ... }:
|
||||||
|
|
||||||
|
let
|
||||||
|
python = pkgs.python38;
|
||||||
|
|
||||||
|
django-types = python.pkgs.buildPythonPackage rec {
|
||||||
|
pname = "django-types";
|
||||||
|
version = "0.17.0";
|
||||||
|
|
||||||
|
format = "pyproject";
|
||||||
|
|
||||||
|
src = pkgs.fetchPypi {
|
||||||
|
inherit pname version;
|
||||||
|
hash = "sha256-wcQqt4h2xXxyg0LVqwYHJas3H8jcg7uFuuC+BoRqrXA=";
|
||||||
|
};
|
||||||
|
|
||||||
|
nativeBuildInputs = with python.pkgs; [ poetry-core ];
|
||||||
|
|
||||||
|
# setup.cfg tries to pull in nonexistent LICENSE.txt file
|
||||||
|
# postPatch = "rm setup.cfg";
|
||||||
|
|
||||||
|
# propagatedBuildInputs = [ django typing-extensions ];
|
||||||
|
};
|
||||||
|
in
|
||||||
|
|
||||||
|
|
||||||
pkgs.mkShell {
|
pkgs.mkShell {
|
||||||
shellHook = ''
|
shellHook = ''
|
||||||
export DJANGO_SETTINGS_MODULE=gestioasso.settings.local
|
export DJANGO_SETTINGS_MODULE=gestioasso.settings.local
|
||||||
|
@ -10,12 +34,11 @@ pkgs.mkShell {
|
||||||
pip install -r requirements-devel.txt | grep -v 'Requirement already satisfied:'
|
pip install -r requirements-devel.txt | grep -v 'Requirement already satisfied:'
|
||||||
'';
|
'';
|
||||||
|
|
||||||
packages = with pkgs; [
|
packages = [ python django-types ] ++ (with python.pkgs; [
|
||||||
python38
|
pip
|
||||||
python38Packages.pip
|
virtualenv
|
||||||
python38Packages.virtualenv
|
python-ldap
|
||||||
python38Packages.python-ldap
|
]);
|
||||||
];
|
|
||||||
|
|
||||||
allowSubstitutes = false;
|
allowSubstitutes = false;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue