The instructions for compiling the repo using `opam pin` appear to be out of date?
The README currently advises
https://github.com/ocaml/opam/blob/b3d2f5c554e6ef3cc736a9f97e252486403e050f/README.md#L18-L19
But to get a working install I actually had to pin all the dependencies of the various opam libraries in the right order. Based on my notes, I think this command should currently give a working install:
opam pin opam-core --dev-repo -y &&\
opam pin opam-format --dev-repo -y &&\
opam pin opam-repository --dev-repo -y &&\
opam pin opam-state --dev-repo -y &&\
opam pin opam-solver --dev-repo -y &&\
opam pin opam-client --dev-repo -y &&\
opam pin add opam-devel --dev -y
I kind of doubt we want to replace the current readme line with this recipe, but maybe we could do something like...
- Put it in a script or a phony make target
- Change https://github.com/ocaml/opam/tree/b3d2f5c554e6ef3cc736a9f97e252486403e050f/opam-devel.opam so that it includes all the libraries as pin-depends and advise people to pin this package from the source rather than from the opam repo. (I think this would work around the non-transitive nature of pins?)
Hopefully there is a nicer option (I'm happy to help with that), but in the meantime this issue may offer a recipe to help others along who hit the same snag.
Thanks for the issue and for testing!
Indeed, the pinning command is incomplete. It is better to use pinning with an url instead
opam pin git+https://github.com/ocaml/opam
like that it will pin all packages in the same time.
Ah of course. Don't know why I didn't remember this :) thanks!