mirror of
https://github.com/tj/git-extras.git
synced 2026-09-10 07:26:17 -04:00
fix(resolve): ignore space errs
This commit is contained in:
parent
8fb2d41c90
commit
3537c25fce
|
|
@ -9,7 +9,7 @@ git diff --name-only --diff-filter=U --relative -z |
|
|||
# `--quiet` implies `--exit-code` which is incompatible with `--check`;
|
||||
# however, it could be special-cased internally, so it could work
|
||||
# (untested)
|
||||
if ! git diff --check -- "$f" &>/dev/null; then
|
||||
if ! git -c core.whitespace='' diff --check -- "$f" &>/dev/null; then
|
||||
printf '%s\0' "$f"
|
||||
fi
|
||||
done |
|
||||
|
|
@ -23,7 +23,7 @@ git diff --name-only --diff-filter=U -z |
|
|||
while IFS= read -r -d '' f; do
|
||||
# WARN: `f` is relative to repo root!
|
||||
# this might be broken
|
||||
if git diff --check -- "$f"; then
|
||||
if git -c core.whitespace='' diff --check -- "$f"; then
|
||||
git add -- "$f"
|
||||
fi
|
||||
done
|
||||
|
|
|
|||
Loading…
Reference in a new issue