2022-08-21 17:46:11 +00:00
|
|
|
# This is meant for use with the nix package manager. If you don't know what it is or don't use it, please ignore this file.
|
|
|
|
#
|
|
|
|
# This shell.nix contains all dependencies require to create a venv and pip install -r requirements.txt.
|
|
|
|
#
|
2022-08-21 17:50:53 +00:00
|
|
|
# Please check shell-static.nix for running ./manage.py collectstatics.
|
2022-08-21 17:46:11 +00:00
|
|
|
{ pkgs ? import <nixpkgs> {} }:
|
|
|
|
pkgs.mkShell {
|
|
|
|
buildInputs = with pkgs; [
|
|
|
|
python39
|
|
|
|
python39Packages.pip
|
|
|
|
python39Packages.setuptools
|
|
|
|
gettext
|
|
|
|
|
|
|
|
];
|
|
|
|
shellHook = ''
|
|
|
|
# Tells pip to put packages into $PIP_PREFIX instead of the usual locations.
|
|
|
|
# See https://pip.pypa.io/en/stable/user_guide/#environment-variables.
|
|
|
|
export PIP_PREFIX=$(pwd)/_build/pip_packages
|
|
|
|
export PYTHONPATH="$PIP_PREFIX/${pkgs.python39.sitePackages}:$PYTHONPATH"
|
|
|
|
export PATH="$PIP_PREFIX/bin:$PATH"
|
|
|
|
unset SOURCE_DATE_EPOCH
|
|
|
|
'';
|
|
|
|
}
|