Muck with `develop.nix` to try and hack it with `poetry` venv, go py3.11
parent
ad59a581c7
commit
3b4a4db7b6
37
develop.nix
37
develop.nix
|
@ -1,28 +1,34 @@
|
||||||
with (import <nixpkgs> {});
|
with (import <nixpkgs> {});
|
||||||
with python310Packages;
|
|
||||||
stdenv.mkDerivation {
|
stdenv.mkDerivation {
|
||||||
name = "pip-env";
|
name = "poetry-env";
|
||||||
buildInputs = [
|
buildInputs = [
|
||||||
# System requirements.
|
# System requirements.
|
||||||
readline
|
readline
|
||||||
|
|
||||||
# TODO: hacky non-poetry install stuff we need to get rid of!!
|
# TODO: hacky non-poetry install stuff we need to get rid of!!
|
||||||
virtualenv
|
poetry
|
||||||
setuptools
|
# virtualenv
|
||||||
pip
|
# setuptools
|
||||||
|
# pip
|
||||||
# obviously, and see below for hacked linking
|
|
||||||
pyqt5
|
|
||||||
|
|
||||||
# Python requirements (enough to get a virtualenv going).
|
# Python requirements (enough to get a virtualenv going).
|
||||||
python310Full
|
python311Full
|
||||||
|
|
||||||
|
# obviously, and see below for hacked linking
|
||||||
|
python311Packages.pyqt5
|
||||||
|
python311Packages.pyqt5_sip
|
||||||
|
# python311Packages.qtpy
|
||||||
|
|
||||||
# numerics deps
|
# numerics deps
|
||||||
python310Packages.python-Levenshtein
|
python311Packages.levenshtein
|
||||||
python310Packages.fastparquet
|
python311Packages.fastparquet
|
||||||
python310Packages.polars
|
python311Packages.polars
|
||||||
|
|
||||||
];
|
];
|
||||||
|
# environment.sessionVariables = {
|
||||||
|
# LD_LIBRARY_PATH = "${pkgs.stdenv.cc.cc.lib}/lib";
|
||||||
|
# };
|
||||||
src = null;
|
src = null;
|
||||||
shellHook = ''
|
shellHook = ''
|
||||||
# Allow the use of wheels.
|
# Allow the use of wheels.
|
||||||
|
@ -30,13 +36,12 @@ stdenv.mkDerivation {
|
||||||
|
|
||||||
# Augment the dynamic linker path
|
# Augment the dynamic linker path
|
||||||
export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:${R}/lib/R/lib:${readline}/lib
|
export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:${R}/lib/R/lib:${readline}/lib
|
||||||
|
|
||||||
export QT_QPA_PLATFORM_PLUGIN_PATH="${qt5.qtbase.bin}/lib/qt-${qt5.qtbase.version}/plugins";
|
export QT_QPA_PLATFORM_PLUGIN_PATH="${qt5.qtbase.bin}/lib/qt-${qt5.qtbase.version}/plugins";
|
||||||
|
|
||||||
if [ ! -d "venv" ]; then
|
if [ ! -d ".venv" ]; then
|
||||||
virtualenv venv
|
poetry install --with uis
|
||||||
fi
|
fi
|
||||||
|
|
||||||
source venv/bin/activate
|
poetry shell
|
||||||
'';
|
'';
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue