forked from Ivasoft/mattermost-mobile
* MM-28105 do not crash when in-app notification shows * Use index.tsx to register the notification screen * Fix notification e2e and some import cleanup * Update iOS notification json * e2e: Show the add reaction screen before receiving a notification * Update snapshots * Patch react-native-notifications to prevent iOS crash when opening * Apply TM4J id Co-authored-by: Joseph Baylon <joseph.baylon@mattermost.com>
33 lines
670 B
Bash
Executable File
33 lines
670 B
Bash
Executable File
#!/bin/sh
|
|
|
|
jsfiles=$(git diff --cached --name-only --diff-filter=ACM | grep -E '.js$|.ts$|.tsx$')
|
|
|
|
if [ -z "jsfiles" ]; then
|
|
exit 0
|
|
fi
|
|
|
|
if [ -n "$jsfiles" ]; then
|
|
echo "Checking lint for:"
|
|
for js in $jsfiles; do
|
|
echo "$js"
|
|
e=$(node_modules/.bin/eslint --quiet --fix $js)
|
|
if [ -n "$e" ]; then
|
|
echo "ERROR: Check eslint hints."
|
|
echo "$e"
|
|
exit 1 # reject
|
|
fi
|
|
done
|
|
|
|
echo "Checking for TSC"
|
|
tsc=$(node_modules/.bin/tsc --noEmit)
|
|
if [ -n "$tsc" ]; then
|
|
echo "ERROR: Check TSC hints."
|
|
echo "$tsc"
|
|
exit 1 # reject
|
|
fi
|
|
fi
|
|
|
|
scripts/precommit/i18n.sh
|
|
|
|
exit 0
|