diff --git a/packages/metro-bundler/react-native-xcode.sh b/packages/metro-bundler/react-native-xcode.sh index 1a1c3660..dc83971f 100755 --- a/packages/metro-bundler/react-native-xcode.sh +++ b/packages/metro-bundler/react-native-xcode.sh @@ -78,7 +78,7 @@ if [[ "$CONFIGURATION" = "Debug" && ! "$PLATFORM_NAME" == *simulator ]]; then PLIST=$TARGET_BUILD_DIR/$INFOPLIST_PATH IP=$(ipconfig getifaddr en0) if [ -z "$IP" ]; then - IP=$(ifconfig | grep 'inet ' | grep -v 127.0.0.1 | cut -d\ -f2 | awk 'NR==1{print $1}') + IP=$(ifconfig | grep 'inet ' | grep -v ' 127.' | cut -d\ -f2 | awk 'NR==1{print $1}') fi if [ -z ${DISABLE_XIP+x} ]; then