News for hackers. Stuff that matters.
Re:OCaml 4.10 by pdimitar on Sunday February 23, 2020 @08:11PM (#22400781)
Thank you for posting these. I've lost some of the links and I am now bookmarking them so I don't lose them again.

I got through some of them and I felt the quality of the OCaml teaching material itself is very high. No remarks there. Any syntax cognitive shock is eventually overcome and things flow pretty well.

Wasn't `oasis` the legacy way of building projects? Thought everyone used `dune` now?

In short, I am looking for the way that most OCaml programmers manage their project nowadays. I know this is happening through `dune` but the tool's documentation and educational material is very lacking. I don't object against the build file being LISP; when I thought about it for a minute it actually makes a lot of sense.

But I need a quality material on everything you can do with `dune`. Can you recommend such?

Re:OCaml 4.10 by johnisgood on Sunday February 23, 2020 @09:42PM (#22401205)
> Wasn't `oasis` the legacy way of building projects? Thought everyone used `dune` now?

Yeah, I believe new projects tend to use dune, and some older projects have switched from OASIS to dune. I personally still use OASIS mainly due to laziness. :D

> But I need a quality material on everything you can do with `dune`. Can you recommend such?

I have not used dune myself, but a quick glance at these sites suggests that they may be quite useful:

- https://dune.build/

- https://dune.build/examples

- https://dune.readthedocs.io/en/stable/

- https://github.com/ocaml/dune/blob/master/doc/quick-start.rs...

- https://github.com/ocaml/dune/tree/master/example

- https://ocamlverse.github.io/content/quickstart_ocaml_projec...

- https://medium.com/@bobbypriambodo/starting-an-ocaml-app-pro...

For opam:

- https://opam.ocaml.org/doc/FAQ.html

- https://opam.ocaml.org/doc/Packaging.html

- https://opam.ocaml.org/doc/Manual.html

- https://github.com/ocaml/opam/tree/master/tests/packages

I hope this helps.

Re:OCaml 4.10 by pdimitar on Sunday February 23, 2020 @11:02PM (#22401540)
It actually does. Thank you!

As I mentioned in a sibling comment, last time I seriously attempted getting more into OCaml has been at least half a year ago. I either didn't find some of those materials or they have been improved in the meantime.

Whatever the case, I can see clearly now that I was wrong about the poor quality of the dune and opam teaching material.

I apologise for that. And I'll be making a comeback to OCaml. I mean, it still has roadblocks but they are easier to overcome when tooling is handled (minus the lack of the multicore support but fingers crossed that that's coming soon).

Re:OCaml 4.10 by yawaramin on Sunday February 23, 2020 @08:16PM (#22400807)
Can you give some specifics about what's lacking in the dune docs?
Re:OCaml 4.10 by gopiandcode on Monday February 24, 2020 @02:26AM (#22402269)
I think the documentation would benefit from suggesting the use of the `dune init ...` commands for beginners - ideally somewhere on the github readme or the readthedocs quickstart.

When starting out with OCaml, as I was more accustomed to makefiles, the process of setting up dune projects was a major hurdle. I later found the init commands while looking through the man pages, and was surprised it wasn't more clearly mentioned in the project documentation.

Re:OCaml 4.10 by pdimitar on Sunday February 23, 2020 @08:21PM (#22400835)
It has been a while. I admit I haven't read the entire tutorial and I checked the website just now -- seems like stuff has been added (and maybe modified). Looks a bit more understandable and beginner-friendly now! I'll have to give my two hobby projects another go from scratch. :)

Is it OK for me to hit you up on OCaml's Discourse forum if I need help or want to give extra feedback when I am able to, in the future?

Re:OCaml 4.10 by yawaramin on Monday February 24, 2020 @07:21PM (#22409799)
Sure, happy to help.