mirror of
https://github.com/Karaka-Management/Build.git
synced 2026-01-11 11:48:40 +00:00
Test invalid whitespace at end
This commit is contained in:
parent
dcf1a0b977
commit
25f09e7d5a
|
|
@ -1,14 +1,11 @@
|
||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
|
|
||||||
isValidFileName() {
|
isValidFileName() {
|
||||||
allownonascii="false"
|
if test $(git diff --cached --name-only --diff-filter=A-z "$1" |
|
||||||
|
|
||||||
if [ "$allownonascii" != "true" ] &&
|
|
||||||
test $(git diff --cached --name-only --diff-filter=A -z "$1" |
|
|
||||||
LC_ALL=C tr -d '[ -~]\0' | wc -c) != 0
|
LC_ALL=C tr -d '[ -~]\0' | wc -c) != 0
|
||||||
then
|
then
|
||||||
return 0
|
return 0
|
||||||
fi
|
fi
|
||||||
|
|
||||||
return 1
|
return 1
|
||||||
}
|
}
|
||||||
Loading…
Reference in New Issue
Block a user