You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Every couple of pull requests when running clang-format on the entire repository I tend to get a lot of changed files.
I'd suggest adding an automated code check at some point in the pull request verification process. Personally I think the best place would be git's pre-commit hook, but as far as I know that cannot be synchronized automatically using git. I've attached a working pre-commit hook though, in case anybody is interested. pre-commit
A less elegant solution would be checking the code style during the travis ci run. While this does not provide immediate feedback that the code style is off it would be fully automatic and does not require any setup by the user.
To my knowledge github does not support server sided hooks for non enterprise projects. @niklas88 do you have any good ideas on how to improve code style conformity?
The text was updated successfully, but these errors were encountered:
Hmm very good point. I guess I also forgot running clang-format a couple of time even though it's bound to :Fmt in my editor.
So ideally, I think we should all install this hook (nice work btw. I already installed it) AND have a GitHub Check either in Travis (relatively easy though Travis' ancient versions will surely create some headaches) or as a separate service.
Would you be willing to create a PR that adds the hook script to the repository (either in misc or in a separate directory) and also add a section in the README.md about installing it. Make it sound mandatory. @joka921 install that hook. The README is getting really long though so we should also think about whether we might want to split it up.
Then I'll have a try at making Travis run this check as well.
Every couple of pull requests when running clang-format on the entire repository I tend to get a lot of changed files.
I'd suggest adding an automated code check at some point in the pull request verification process. Personally I think the best place would be git's pre-commit hook, but as far as I know that cannot be synchronized automatically using git. I've attached a working pre-commit hook though, in case anybody is interested.
pre-commit
A less elegant solution would be checking the code style during the travis ci run. While this does not provide immediate feedback that the code style is off it would be fully automatic and does not require any setup by the user.
To my knowledge github does not support server sided hooks for non enterprise projects.
@niklas88 do you have any good ideas on how to improve code style conformity?
The text was updated successfully, but these errors were encountered: