mirror of
https://github.com/RPCS3/rpcs3.git
synced 2025-04-28 13:28:01 +03:00
Add a git pre-commit hook running clang-format
This commit is contained in:
parent
bb66b97251
commit
1ede5cbc4c
3 changed files with 498 additions and 3 deletions
10
pre-commit.readme
Normal file
10
pre-commit.readme
Normal file
|
@ -0,0 +1,10 @@
|
|||
#!/bin/bash
|
||||
|
||||
# git pre-commit hook that run git-clang-format when committing.
|
||||
# To use it install clang-format and python 2.7 then copy this
|
||||
# file to .git/hooks/ and remove the extension
|
||||
|
||||
git clang-format --style=file --diff > style.patch
|
||||
git apply --index style.patch
|
||||
rm style.patch
|
||||
exit 0
|
Loading…
Add table
Add a link
Reference in a new issue