
There's a New Language Server and Code Formatter for Erlang - skelliger
https://notamonadtutorial.com/erlang-tooling-in-2020-b9606596353a
======
zamalek
> Knowing that it will be very very hard to convince every Erlang developer in
> the world to format their code in the same way, we aimed at a more humble
> goal: To convince every Erlang developer in the world to format their code
> with the same tool.

I work at a primarily C# shop. One day we decided that our coding standards
needed updating. So off went my team mate/architect and spent a whole month on
that fucking nonsense. Nobody was completely happy at the end of that process.

Knobs and settings for code formatters are antifeatures that lead to talented
people solving (and arguing about) antiproblems. Manually formatting code is
probably a more worthwhile task than arguing about how formatting should be
done. If there's an Erlang developer who doesn't care for the "one true way,"
I say let them manually format and nit PRs.

I'm doing `cargo fmt --all` right now and it sometimes does this thing where
it removes a blank line between methods. I've really stopped caring, I let it
do that slightly inferior formatting. My code is idiomatic, anyone can
approach it (not just my team), problem solved, I get to work on real
problems.

------
QuinnWilton
Interestingly, this seems to be a different code formatter than the one
recently shown off at Code BEAM SF a few weeks ago:
[https://youtu.be/TC2F2HBNRuA](https://youtu.be/TC2F2HBNRuA)

------
waynesonfire
here's my git pre-commit hook to apply rebar3 format,

    
    
      #!/bin/sh
      
      FILES=$(git diff --cached --name-only --diff-filter=ACM |   sed 's| |\\ |g')
      
      echo $FILES | xargs -n 1 rebar3 format --files
      
      echo $FILES | xargs git add
      
      exit 0

