File tree 1 file changed +11
-0
lines changed
1 file changed +11
-0
lines changed Original file line number Diff line number Diff line change @@ -78,6 +78,17 @@ in project.shellFor {
78
78
79
79
inherit withHoogle ;
80
80
81
+ # The workbench shell uses cabalWrapped, which removes the `source-repository-package` stanzas
82
+ # from `cabal.project`. The idea is to use prebuilt ones provided by haskell.nix. However,
83
+ # haskell.nix is clever enough to not include `source-repository-package`s in the shell
84
+ # package db, because it knows that cabal will rebuild them. So you just end up with nothing!
85
+ # We can work around this by overriding haskell.nix's selection of which packages the shell
86
+ # is prepared for, so that it *doesn't* include the `source-repository-package` ones
87
+ # (the default is *local* packages which includes them, we select *project* pacakges which doesn't)
88
+ # Note that this is somewhat fragile since it relies on us understanding what haskell.nix is
89
+ # doing internally!
90
+ packages = ps : builtins . attrValues ( haskellLib . selectProjectPackages ps ) ;
91
+
81
92
tools = {
82
93
haskell-language-server = {
83
94
version = "latest" ;
You can’t perform that action at this time.
0 commit comments