Skip to content

Use ocamlformat on all Ocaml files, including generated ones

Raphaël Cauderlier requested to merge rafoo@format into master

This MR adds an .ocamlformat file allowing the ocamlformat tool to run on the OCaml files of the repository. The chosen formatting rules are the same than those of the Tezos protocol to simplify the comparison of the generated code with the reference Michelson runtime in the Tezos protocol.

How to run the formatter is now documented in the README.

Both the generated files and the source code of the generator are formatted. The source code files of the generator were already well formatted but according to different rules (the default Ocamlformat configuration), they have been reformatted. The generated code wasn't formatted by Ocamlformat.

Edited by Raphaël Cauderlier

Merge request reports