Prettier has this:
Another useful flag is
--list-different
(or-l
) which prints the filenames of files that are different from Prettier formatting. If there are differences the script errors out, which is useful in a CI scenario.
prettier --single-quote --list-different "src/**/*.js"
It would be nice to have something like this for refmt, too.