tarides / ocaml-platform-installer

The best way for developers to write software in OCaml
ISC License
61 stars 8 forks source link

Do not distinguish between ocaml version in cache when unnecessary #110

Closed panglesd closed 2 years ago

panglesd commented 2 years ago

Some tools are not sensitive to ocaml version (currently, ocamlformat and dune-release). However, they were built once per ocaml version in the cache. This commit makes a difference between those two types of tools, and for the insensitive ones, do not depend on the ocaml version.

This makes a very clear speed boost, especially for packages that are long to install (e.g. ocamlformat) and opens the possibility to add more (as in #107) without too much speed lost.

panglesd commented 2 years ago

Need to add a test but it is ready for review.

The speed boost is really nice but are we sure that we do not lose anything by having some of these binary not produced by the same compiler as others. What do you think of the idea?

Julow commented 2 years ago

An idea for a test: Expect the name of the cached package and it's dependencies.

Julow commented 2 years ago

Let's merge!