FTFY: only apply on modified files
Ignore renamed, copied, and deleted files when applying the style rules. Change-Id: I6102e34f833e5c2ef7a88d6d57bbfdca51b25d94
This commit is contained in:
parent
c459d37c26
commit
d9ca52452b
@ -112,8 +112,9 @@ cd "$(git rev-parse --show-toplevel)"
|
||||
# Collect the original diff
|
||||
git show > "${ORIG_DIFF}"
|
||||
|
||||
# Apply the style guide on the modified files and collect its diff
|
||||
for f in $(git diff HEAD^ --name-only | grep '\.[ch]$'); do
|
||||
# Apply the style guide on new and modified files and collect its diff
|
||||
for f in $(git diff HEAD^ --name-only -M90 --diff-filter=AM
|
||||
| grep '\.[ch]$'); do
|
||||
case "$f" in
|
||||
third_party/*) continue;;
|
||||
nestegg/*) continue;;
|
||||
|
Loading…
x
Reference in New Issue
Block a user