-
Notifications
You must be signed in to change notification settings - Fork 20
lake serve
and lake env
override existing LEAN_PATH
#91
Comments
This is intentional. Setting |
This is all experimental, but I want to extend or simplify some of my Lakefiles with a custom package. This is mostly focused on FFI experiments. The only solution I found for this was to set I don't see how it would be possible to specify the |
If you are using VSCode (and vscode-lean4), you can augment the server environment's
Yeah, importing modules is essentially a no-go in Lake at the moment. For your example of code generation, the current "best practice" would be build a separate executable that generates the code and run that instead (potentially from the lakefile). |
This relies on the same mechanism. Anyways, I'll just look for another solution for now. |
Oh, yeah. Lake's elaboration works but once it starts the server, the server elaboration of the lakefile doesn't. ::( As an alternative, you could have |
LEAN_PATH
is used withlake build
, but it is overridden withlake serve
andlake env
.It is still used when the Lakefile is elaborated, but not for the processes spawned afterwards.
Example for
lake env
:This is a problem when a package is located in a non-standard location. In this case, building with Lake works, but editing with a running language server does not because the package is not found anymore.
This is where
LEAN_PATH
is set:lake/Lake/Config/Monad.lean
Lines 39 to 48 in 175793d
The text was updated successfully, but these errors were encountered: