Very interested to learn Ocaml, but problems at opam init

opam

#1

Hi,

I’m sharing my problems getting started with Ocaml in the hope my feedback will help get things improving.

I’m very interested to learn Ocaml, but I always seem to encounter problems even to get started. This time, I’m running an a clean lxd container with ubuntu 18.04. I installed OPAM as described on its install page. But I encounter a problem at the opam init step. This seems to be a problem that has been reported and fixable by editing an opam script.

If my experience is representative, it doesn’t make for a smooth onboarding of new users. Why is a new user confronted with errors when following the recommended installation steps?
If I’m doing something wrong, what’s the recommended way to start with Ocaml then?

rb


#2

I met the same problem when cooked the docker from Fedora 29 image.


#3

I’ve found the instructions in https://github.com/janestreet/install-ocaml to be quite reliable.


#4

N.B. Those instructions look like they’re written and tested with opam 1.2 in mind. Anyone who tries to install opam 2 via that guide is probably going to run into the same problems.


#5

thanks all for your answers, even though it shows how confusing Ocaml is for a newcomer.
I might try again later, but I won’t be able to use Ocaml at this time for the project I had in mind.


#6

The problem isn’t OCaml, it’s the documentation given here. For most people, bootstrapping is pretty much as easy as installing a package on their OS.