OCaml Weekly News

Previous Week Up Next Week


Here is the latest OCaml Weekly News, for the week of December 10 to 17, 2019.

Table of Contents

Is there a good way to encode linear types in OCaml?

Continuing this old thread, Konstantin Olkhovskiy said

I've stumbled upon a library that implements linear types for OCaml, using monads, lens and some ppx to make it more lightweight. Might be of interest: https://github.com/keigoi/linocaml

Anton Kochkov added

It is the part of even more interesting system - OCaml MPST (Multiparty Session Types) See the slides.

Guillaume Munch-Maccagnoni then said

(The paper linked on that page is dated 2011/2014. In case anyone wonders whether the authors have found a time machine in a barn to be able to cite papers from 2018, there just seems to be an error in the preparation. It is freshly published, and a PDF with correct dates is available here.)

Arch Linux installer written in OCaml

Darren announced

I'm doing a short update here as Oali has seen some significant changes. This update is also the last one here to avoid being too annoying, and also since I won't be add too much new stuff to Oali in foreseeable future.

Major changes since last time

  • SaltStack files and script files (or profiles) now live in a separate repo
    • Oali accepts custom profile repo URL to facilitate using your own SaltStack files without forking Oali itself
  • Semi self-documentation
    • Added mechanism to facilitate inline documentation inside oali.ml itself
    • The generated markdown doc is stored as OALI_DOC in repo, it lists all the steps (or tasks) Oali does, along with descriptions
  • Added LVM support
    • Works with all 3 disk layouts, and encryption
    • See here for details on added logical volumes
  • Answer remembering of dialogues when appropriate
    • Relatively static answers (e.g. hostname, whether to use encryption, LVM) are stored in oali_answers directory, with a JSON file for each task
    • The "answer store" can be used in new session of Oali. The old answer store is wiped accordingly if user changes their answer.
  • Added SSH server setup and public key transfer code (ported from old server bash script)
    • See here for details
    • Mainly useful for when you have (virtual) console access to live CD/Oali install screen, and want to add needed public key to the user's .ssh/authorized_keys via network instead of loading from physical medium

I've used Oali to install in various configurations in past couple of days, and have yet to notice major defects. That being said, exercise caution as you would for installing an OS.

batteries batteries.2.11.0

UnixJunkie announced

The latest 2.x release of batteries is available in opam. OCaml batteries included is a community maintained extended standard library.


The API documentation is hosted here: https://ocaml-batteries-team.github.io/batteries-included/hdoc2/

Here is the changelog:

v2.11.0 (minor release)

This minor release fixes a few bugs or interface mismatch with OCaml stdlib,
and is compatible with BER MetaOCaml.

This is the last planned release of the v2 series.
Next planned release (v3.0.0) will introduce some API changes.

Notable changes:

    Add Unix.with_locked_file
    (Simon Cruanes, Cedric Cellier, review by Francois Berenger)

    Build with -strict-sequence
    (Armaël Guéneau, review by Francois Berenger)

    Add Legacy.Result for OCaml >= 4.8.0
    (Cedric Cellier, review by Francois Berenger)

    Remove BatOo
    (Cedric Cellier, review by Francois Berenger)

    Add BatFilename
    (Cedric Cellier, review by Francois Berenger)

    Make batteries usable with BER MetaOCaml
    (Cedric Cellier, review by Francois Berenger and Gabriel Scherer)

    Unix.sleepf is provided across all OCaml versions;
    previously it was only for OCaml >= 4.03.0
    (Francois Berenger, review by Cedric Cellier)


If you happen to miss a CWN, you can send me a message and I'll mail it to you, or go take a look at the archive or the RSS feed of the archives.

If you also wish to receive it every week by mail, you may subscribe online.