diff options
author | bunnei <bunneidev@gmail.com> | 2016-10-31 20:33:39 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2016-10-31 20:33:39 +0100 |
commit | 946b62c03dad318673138d9e9b5030aa7a195206 (patch) | |
tree | a608c553f6c905961ce23647b3282599afd30ce6 /hooks | |
parent | Merge pull request #2146 from mailwl/gdbstub-ida-regs (diff) | |
parent | build: don't install freedesktop.org metadata for SDL2-only builds (diff) | |
download | yuzu-946b62c03dad318673138d9e9b5030aa7a195206.tar yuzu-946b62c03dad318673138d9e9b5030aa7a195206.tar.gz yuzu-946b62c03dad318673138d9e9b5030aa7a195206.tar.bz2 yuzu-946b62c03dad318673138d9e9b5030aa7a195206.tar.lz yuzu-946b62c03dad318673138d9e9b5030aa7a195206.tar.xz yuzu-946b62c03dad318673138d9e9b5030aa7a195206.tar.zst yuzu-946b62c03dad318673138d9e9b5030aa7a195206.zip |
Diffstat (limited to 'hooks')
-rwxr-xr-x | hooks/pre-commit | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/hooks/pre-commit b/hooks/pre-commit index ec2b5b77e..04fdaf8ec 100755 --- a/hooks/pre-commit +++ b/hooks/pre-commit @@ -1,4 +1,4 @@ -#!/bin/bash +#!/bin/sh # Enforce citra's whitespace policy git config --local core.whitespace tab-in-indent,trailing-space @@ -32,7 +32,7 @@ for f in $(git diff --name-only --diff-filter=ACMRTUXB --cached); do if ! echo "$f" | egrep -q "^src/"; then continue fi - d=$(diff -u "$f" <(clang-format "$f")) + d=$(clang-format "$f" | diff -u "$f" -) if ! [ -z "$d" ]; then echo "!!! $f not compliant to coding style, here is the fix:" echo "$d" @@ -40,4 +40,4 @@ for f in $(git diff --name-only --diff-filter=ACMRTUXB --cached); do fi done -exit "$fail" +exit "${fail-0}" |