I want to run my tests before every commit. So under .git/hooks/pre-commit file, I write the code to run my tests. This works fine in my local. However, I don't find the changes I made to the pre-commit file present in the git stage. Nor is it part of the PR. Will this be available to anyone who clones or pulls the branch? If now how can I make this global to the project?
Asked
Active
Viewed 97 times
0
-
https://stackoverflow.com/search?q=%5Bgithooks%5D+push – phd Sep 07 '20 at 19:37
-
1https://git-scm.com/docs/gitfaq#Documentation/gitfaq.txt-HowdoIusehookstopreventusersfrommakingcertainchanges – bk2204 Sep 07 '20 at 21:19