erlfmt
erlfmt copied to clipboard
Read file only once
https://github.com/WhatsApp/erlfmt/pull/235 reads the file twice, but fixes an important issue to not write a file that has not been modified.
Possibly lets always read in the whole file as a string before sending it to the scanner, then it is available for comparison after formatting.
This should simplify a lot of the code and get rid of the file scanner.