Replace clang-format.sh with a faster, better version

We need to replace clang-format.sh with a version that meets our use-cases.

Notably:

  • we need to be able to check whether anything is misformatted without actually reformatting it.
  • we need to be able to look at only those files that are staged to be committed, so that our git hooks can work.
  • we need a mode to reformat everything that has changed in git, so that we can run a quick "reformat everything" command without scanning the entire repostiory (which takes around 60 seconds for me).