Lets say you have a Git repository, like on GitHub, and you have a lot of people contributing to the repository. Everyone uses their own standards for coding, so the code ends up being a mess without any standards applied.
I've read a bit about git hooks but I don't fully understand their concept or primary uses.
Is it possible to use hooks, when a pull request is sent to your repository, to send the code to some remote service, that then formats the code into whatever XYZ standard you want to use, and then returns the formatted code back in to the repo or into the pull request? Or does it not work like that?