Skip to content
15 changes: 13 additions & 2 deletions scripts/is-hybrid-app.sh
Original file line number Diff line number Diff line change
@@ -1,11 +1,18 @@
#!/bin/bash
set -e

source scripts/shellUtils.sh

# Check if jq is installed
if ! jq --version > /dev/null 2>&1; then
error 'jq is not installed. Please install jq and try again' >&2
exit 1
fi

if [[ ! -d Mobile-Expensify ]]; then
echo false
exit 0
else
cd Mobile-Expensify
cd Mobile-Expensify || exit 1
fi

# Check if 'package.json' exists
Expand All @@ -17,6 +24,10 @@ if [[ -f package.json ]]; then
if [[ "$package_name" == "mobile-expensify" ]]; then
echo true
exit 0
else
echo "The package name is incorrect. It should be 'mobile-expensify'. Script will assume the standalone NewDot app."
echo false
exit 0
fi
else
echo "package.json not found in Mobile-Expensify"
Expand Down
Loading