16.8 C
Canberra
Saturday, February 28, 2026

Construct failed in Xcode on account of: Command PhaseScriptExecution failed with a nonzero exit code


My app undertaking fails to construct and I do not know what’s improper?

I attempted toggling the " for set up builds solely " on and off within the construct phases tab, which was instructed in different, older, subjects. However did not do something.

Construct failed in Xcode on account of: Command PhaseScriptExecution failed with a nonzero exit code

A bit extra specifics on the error:

bash: -c: line 0: syntax error close to sudden token `3'
bash: -c: line 0: 

`/Customers/app/ios/Pods/../../node_modules/expo/node_modules/expo-constants/ios/../scripts/get-app-config-ios.sh'

get-app-config-ios.sh

    #!/usr/bin/env bash

set -eo pipefail

set -x

DEST="$CONFIGURATION_BUILD_DIR"
RESOURCE_BUNDLE_NAME="EXConstants.bundle"
EXPO_CONSTANTS_PACKAGE_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")/.." && pwd -P)"

# For traditional major undertaking construct phases integration, will probably be no-op to forestall duplicated app.config creation.
#
# `$PROJECT_DIR` is handed by Xcode because the listing to the xcodeproj file.
# in basic major undertaking setup it's one thing like /path/to/app/ios
# in new fashion pod undertaking setup it's one thing like /path/to/app/ios/Pods
PROJECT_DIR_BASENAME=$(basename $PROJECT_DIR)
if [ "x$PROJECT_DIR_BASENAME" != "xPods" ]; then
  exit 0
fi

# If PROJECT_ROOT will not be specified, fallback to make use of Xcode PROJECT_DIR
PROJECT_ROOT=${PROJECT_ROOT:-"$PROJECT_DIR/../.."}
PROJECT_ROOT=${PROJECT_ROOT:-"$EXPO_CONSTANTS_PACKAGE_DIR/../.."}

cd "$PROJECT_ROOT" || exit

if [ "$BUNDLE_FORMAT" == "shallow" ]; then
  RESOURCE_DEST="$DEST/$RESOURCE_BUNDLE_NAME"
elif [ "$BUNDLE_FORMAT" == "deep" ]; then
  RESOURCE_DEST="$DEST/$RESOURCE_BUNDLE_NAME/Contents/Sources"
  mkdir -p "$RESOURCE_DEST"
else
  echo "Unsupported bundle format: $BUNDLE_FORMAT"
  exit 1
fi

"${EXPO_CONSTANTS_PACKAGE_DIR}/scripts/with-node.sh" "${EXPO_CONSTANTS_PACKAGE_DIR}/scripts/getAppConfig.js" "$PROJECT_ROOT" "$RESOURCE_DEST"

Related Articles

LEAVE A REPLY

Please enter your comment!
Please enter your name here

[td_block_social_counter facebook="tagdiv" twitter="tagdivofficial" youtube="tagdiv" style="style8 td-social-boxed td-social-font-icons" tdc_css="eyJhbGwiOnsibWFyZ2luLWJvdHRvbSI6IjM4IiwiZGlzcGxheSI6IiJ9LCJwb3J0cmFpdCI6eyJtYXJnaW4tYm90dG9tIjoiMzAiLCJkaXNwbGF5IjoiIn0sInBvcnRyYWl0X21heF93aWR0aCI6MTAxOCwicG9ydHJhaXRfbWluX3dpZHRoIjo3Njh9" custom_title="Stay Connected" block_template_id="td_block_template_8" f_header_font_family="712" f_header_font_transform="uppercase" f_header_font_weight="500" f_header_font_size="17" border_color="#dd3333"]
- Advertisement -spot_img

Latest Articles