expo-constants 58.0.5 → 58.0.7

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -10,6 +10,17 @@
10
10
 
11
11
  ### 💡 Others
12
12
 
13
+ ## 58.0.7 — 2026-09-25
14
+
15
+ ### 🐛 Bug fixes
16
+
17
+ - [iOS] Generate the embedded `app.config` in apps built with SwiftPM instead of CocoaPods, fixing the "Unable to find the embedded app config" warning there. The generator no longer requires the Pods project, can be pointed at another destination, and creates `EXConstants.bundle` itself rather than relying on CocoaPods' `resource_bundles`. ([#50084](https://github.com/expo/expo/pull/50084) by [@chrfalch](https://github.com/chrfalch))
18
+ - [iOS] Fix `with-node.sh` ignoring the app's `NODE_BINARY` and `.xcode.env` when building without CocoaPods. ([#50084](https://github.com/expo/expo/pull/50084) by [@chrfalch](https://github.com/chrfalch))
19
+
20
+ ## 58.0.6 — 2026-09-23
21
+
22
+ _This version does not introduce any user-facing changes._
23
+
13
24
  ## 58.0.5 — 2026-09-22
14
25
 
15
26
  _This version does not introduce any user-facing changes._
@@ -6,7 +6,7 @@ plugins {
6
6
  apply from: "../scripts/get-app-config-android.gradle"
7
7
 
8
8
  group = 'host.exp.exponent'
9
- version = '58.0.5'
9
+ version = '58.0.7'
10
10
 
11
11
  expoModule {
12
12
  // We can't prebuild the module because we need to apply `get-app-config-android.gradle` script.
@@ -17,6 +17,6 @@ android {
17
17
  namespace "expo.modules.constants"
18
18
  defaultConfig {
19
19
  versionCode 33
20
- versionName "58.0.5"
20
+ versionName "58.0.7"
21
21
  }
22
22
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "expo-constants",
3
- "version": "58.0.5",
3
+ "version": "58.0.7",
4
4
  "description": "Provides system information that remains constant throughout the lifetime of your app.",
5
5
  "keywords": [
6
6
  "constants",
@@ -54,13 +54,13 @@
54
54
  "@types/node": "^22.14.0",
55
55
  "expo-manifests": "58.0.0",
56
56
  "expo-module-scripts": "56.0.3",
57
- "expo-updates": "58.0.7"
57
+ "expo-updates": "58.0.9"
58
58
  },
59
59
  "peerDependencies": {
60
60
  "expo": "*",
61
61
  "react-native": "*"
62
62
  },
63
- "gitHead": "add8cbf49f477cfd2283ae05af35b4713a773c55",
63
+ "gitHead": "ad41d067bd3df6dd12f1788acc6b54a68e7a650d",
64
64
  "scripts": {
65
65
  "build": "expo-build src",
66
66
  "clean": "expo-module clean",
@@ -2,7 +2,10 @@
2
2
 
3
3
  set -eo pipefail
4
4
 
5
- DEST="$CONFIGURATION_BUILD_DIR"
5
+ # Where resource bundles are assembled. CocoaPods runs this on the pod target,
6
+ # where that is CONFIGURATION_BUILD_DIR; SwiftPM has no pod target and runs it on
7
+ # the app target, so the caller passes the app's resources directory instead.
8
+ DEST="${EXPO_CONSTANTS_APP_CONFIG_DEST:-$CONFIGURATION_BUILD_DIR}"
6
9
  RESOURCE_BUNDLE_NAME="EXConstants.bundle"
7
10
  EXPO_CONSTANTS_PACKAGE_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")/.." && pwd -P)"
8
11
 
@@ -11,9 +14,15 @@ EXPO_CONSTANTS_PACKAGE_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")/.." && pwd -P)"
11
14
  # `$PROJECT_DIR` is passed by Xcode as the directory to the xcodeproj file.
12
15
  # in classic main project setup it is something like /path/to/app/ios
13
16
  # in new style pod project setup it is something like /path/to/app/ios/Pods
14
- PROJECT_DIR_BASENAME=$(basename "$PROJECT_DIR")
15
- if [ "x$PROJECT_DIR_BASENAME" != "xPods" ]; then
16
- exit 0
17
+ #
18
+ # Under SwiftPM there is no Pods project and exactly one phase is injected, so
19
+ # there is nothing to de-duplicate against — EXPO_CONSTANTS_ALLOW_NON_PODS opts
20
+ # out of this check.
21
+ if [ -z "${EXPO_CONSTANTS_ALLOW_NON_PODS:-}" ]; then
22
+ PROJECT_DIR_BASENAME=$(basename "$PROJECT_DIR")
23
+ if [ "x$PROJECT_DIR_BASENAME" != "xPods" ]; then
24
+ exit 0
25
+ fi
17
26
  fi
18
27
 
19
28
  # If PROJECT_ROOT is not specified, fallback to use Xcode PROJECT_DIR
@@ -24,6 +33,10 @@ cd "$PROJECT_ROOT" || exit
24
33
 
25
34
  if [ "$BUNDLE_FORMAT" == "shallow" ]; then
26
35
  RESOURCE_DEST="$DEST/$RESOURCE_BUNDLE_NAME"
36
+ # CocoaPods creates the bundle through `resource_bundles`; SwiftPM has no
37
+ # equivalent, and getAppConfig.js writes into this directory without creating
38
+ # it. A no-op when the bundle already exists.
39
+ mkdir -p "$RESOURCE_DEST"
27
40
  elif [ "$BUNDLE_FORMAT" == "deep" ]; then
28
41
  RESOURCE_DEST="$DEST/$RESOURCE_BUNDLE_NAME/Contents/Resources"
29
42
  mkdir -p "$RESOURCE_DEST"
@@ -9,20 +9,38 @@
9
9
 
10
10
  CURR_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd -P)"
11
11
 
12
- # Start with a default
13
- NODE_BINARY=$(command -v node)
12
+ # CocoaPods sets PODS_ROOT, and its env files override any inherited NODE_BINARY.
13
+ # Without CocoaPods (SwiftPM) the calling build phase may already have resolved
14
+ # NODE_BINARY, so keep it and read the app's env files from SRCROOT only if unset.
15
+ # The mode is fixed here because the env files may change PODS_ROOT.
16
+ if [[ -n "$PODS_ROOT" ]]; then
17
+ USES_COCOAPODS=1
18
+ # Start with a default
19
+ NODE_BINARY=$(command -v node)
20
+ ENV_PATH="$PODS_ROOT/../.xcode.env"
21
+ else
22
+ USES_COCOAPODS=
23
+ ENV_PATH="$SRCROOT/.xcode.env"
24
+ fi
14
25
  export NODE_BINARY
15
26
 
16
- # Override the default with the global environment
17
- ENV_PATH="$PODS_ROOT/../.xcode.env"
18
- if [[ -f "$ENV_PATH" ]]; then
19
- source "$ENV_PATH"
27
+ if [[ -n "$USES_COCOAPODS" || -z "$NODE_BINARY" ]]; then
28
+ # Override the default with the global environment
29
+ if [[ -f "$ENV_PATH" ]]; then
30
+ source "$ENV_PATH"
31
+ fi
32
+
33
+ # Override the global with the local environment
34
+ LOCAL_ENV_PATH="${ENV_PATH}.local"
35
+ if [[ -f "$LOCAL_ENV_PATH" ]]; then
36
+ source "$LOCAL_ENV_PATH"
37
+ fi
20
38
  fi
21
39
 
22
- # Override the global with the local environment
23
- LOCAL_ENV_PATH="${ENV_PATH}.local"
24
- if [[ -f "$LOCAL_ENV_PATH" ]]; then
25
- source "$LOCAL_ENV_PATH"
40
+ if [[ -z "$USES_COCOAPODS" ]]; then
41
+ NODE_BINARY="${NODE_BINARY:-$(command -v node)}"
42
+ # An env file that unsets NODE_BINARY also drops its export.
43
+ export NODE_BINARY
26
44
  fi
27
45
 
28
46
  if [[ -n "$NODE_BINARY" && -x "$NODE_BINARY" ]]; then