dnsimple / erldns

DNS server, in Erlang.
MIT License
398 stars 98 forks source link

Adopt Erlfmt #152

Closed weppos closed 5 months ago

weppos commented 6 months ago

This is an attempt to define some consistent formatting rules for our Erlang code.

I made some research and I tested various options, so far the one that I prefer is erlfmt from WhatsApp. Like most non-builtin formatters, this is opinionated. But the choices they made are well thought, and seem to be a good starting point.

You have both the option to reformat the code inline:

rebar3 fmt

or check the formatting:

rebar3 fmt --check

This last command is especially useful for CI integration.