File tree Expand file tree Collapse file tree 1 file changed +6
-4
lines changed
Expand file tree Collapse file tree 1 file changed +6
-4
lines changed Original file line number Diff line number Diff line change @@ -6,17 +6,19 @@ if [[ $# -lt 1 ]]; then
66fi
77
88# --color=never because magit git output log doesn't support it
9- die_occurrences=" $( grep -H --color=never --line-number -P ' \bdie\s*\(' " $@ " | grep -v -P ' UnitySite::die\s*\(' ) " || true
9+ die_occurrences=" $(
10+ grep -H --color=never --line-number -P ' \bdie\s*[\(;]' " $@ " | grep -v -P ' UnitySite::die'
11+ ) " || true
1012if [ -n " $die_occurrences " ]; then
11- echo " die() is not allowed! use UnitySite::die() instead."
13+ echo " die is not allowed! use UnitySite::die() instead."
1214 echo " $die_occurrences "
1315 exit 1
1416fi
1517
1618# --color=never because magit git output log doesn't support it
17- exit_occurrences=" $( grep -H --color=never --line-number -P ' \exit \s*\( ' " $@ " ) " || true
19+ exit_occurrences=" $( grep -H --color=never --line-number -P ' \bexit \s*[\(;] ' " $@ " ) " || true
1820if [ -n " $exit_occurrences " ]; then
19- echo " exit() is not allowed!"
21+ echo " exit is not allowed! use UnitySite::die() instead. "
2022 echo " $exit_occurrences "
2123 exit 1
2224fi
You can’t perform that action at this time.
0 commit comments