Zulip Chat Archive

Stream: lean4

Topic: lakefile lean vs toml


Patrick Massot (Jun 24 2024 at 13:56):

@Mac Malone could you clarify whether having both a lakefile.lean and a lakefile.toml in the same project makes any sense, and what lake is meant to do in the case? I am asking because I want to decide what to do in that case for other tools (in my case leanblueprint).

Mac Malone (Jun 24 2024 at 14:00):

At the moment, it is not expected that user projects will have both a lakefile.lean and a lakefile.toml. Currently, if both exist, Lake perfers the lakefile.lean. However, there are plans down the road to evolve this behavior to instead merge the contents of the two,. Thus. it is probable that future projects will make use of both. I don't expect this to happen for a least a few months, though.

Shreyas Srinivas (Jun 24 2024 at 14:12):

Can new projects be initialised with lakefile.toml by default?

Patrick Massot (Jun 24 2024 at 14:25):

Ok thanks, I'll try to support having both without warning users that something is weird.

Mac Malone (Jun 24 2024 at 18:46):

@Patrick Massot I think a warning is fine. Lake itself currently produces a warning noting the existence of both and indicating it will use lakefile.lean.

Mac Malone (Jun 24 2024 at 18:48):

Shreyas Srinivas said:

Can new projects be initialised with lakefile.toml by default?

Are you asking whether you can genearte lakefile.toml from lake new? If so, yes, via lake new <proj> .toml. If you are asking whether lakefile.toml will be made the default, that is lean4#4106. It probably won't happen until the merger I mentioned or, alternatively, once mathlib is ported to TOMl.

Shreyas Srinivas (Jun 24 2024 at 18:56):

I meant the latter but the former is a good solution for the months ahead


Last updated: May 02 2025 at 03:31 UTC