File tree Expand file tree Collapse file tree 2 files changed +16
-10
lines changed Expand file tree Collapse file tree 2 files changed +16
-10
lines changed Original file line number Diff line number Diff line change 38
38
workspace = uv2nix . lib . workspace . loadWorkspace { workspaceRoot = ./. ; } ;
39
39
40
40
workspace-overlay = workspace . mkPyprojectOverlay {
41
- sourcePreference = "wheel" ; # or sourcePreference = "sdist";
41
+ sourcePreference = "wheel" ;
42
+ } ;
43
+
44
+ editable-overlay = workspace . mkEditablePyprojectOverlay {
45
+ root = "$REPO_ROOT" ;
42
46
} ;
43
47
44
48
pyproject-overlay = final : prev : {
56
60
extensions = pkgs . lib . composeManyExtensions [
57
61
pyproject-build-systems . overlays . default
58
62
workspace-overlay
63
+ editable-overlay
59
64
pyproject-overlay
60
65
] ;
61
66
base-python = pkgs . callPackage pyproject-nix . build . packages {
82
87
shellHook = ''
83
88
# Undo dependency propagation by nixpkgs.
84
89
unset PYTHONPATH
90
+ export REPO_ROOT=$(git rev-parse --show-toplevel)
85
91
'' ;
86
92
packages = [ python-env ] ++ ( dev-tools pkgs ) ;
87
93
} ;
You can’t perform that action at this time.
0 commit comments