leanprover / elan

The Lean version manager
Apache License 2.0
299 stars 34 forks source link

RFC: Upgrading Lean versions #7

Open Kha opened 6 years ago

Kha commented 6 years ago

Suggested plan:

With these changes, installing Lean and adding a mathlib dependency could be as simple as:

$ curl https://raw.githubusercontent.com/Kha/elan/master/elan-init.sh -sSf | sh
...
$ leanpkg new mypackage  # uses stable leanpkg, doesn't matter
$ cd mypackage
$ leanpkg add leanprover/mathlib
...
WARNING: Lean version "nightly-2018-04-06" of dependency "mathlib" does not match configured Lean version "3.4.0"
Do you want to set your package's Lean version to "nightly-2018-04-06"? [yN] y
...
cipher1024 commented 6 years ago

What would you do when you add a second package that specifies a different version of Lean?

Kha commented 6 years ago

What would you do when you add a second package that specifies a different version of Lean?

Select "an appropriate version", as I said :grin: . ...probably the lexically largest version string or something

cipher1024 commented 6 years ago

Sorry! I must have missed that!