@callstack/react-native-brownfield 3.7.0 → 3.8.1
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 +18 -0
- package/ReactBrownfield.podspec +1 -0
- package/ios/ExpoHostRuntime.swift +23 -5
- package/ios/ReactNativeBrownfield.swift +17 -0
- package/ios/ReactNativeHostRuntime.swift +10 -0
- package/ios/ReactNativeViewController.swift +58 -6
- package/lib/commonjs/expo-config-plugin/android/utils/androidManifest.js +2 -0
- package/lib/commonjs/expo-config-plugin/android/utils/androidManifest.js.map +1 -0
- package/lib/commonjs/expo-config-plugin/android/utils/constants.js +1 -1
- package/lib/commonjs/expo-config-plugin/android/utils/expo-updates.js +2 -0
- package/lib/commonjs/expo-config-plugin/android/utils/expo-updates.js.map +1 -0
- package/lib/commonjs/expo-config-plugin/android/withAndroidModuleFiles.js +1 -1
- package/lib/commonjs/expo-config-plugin/android/withAndroidModuleFiles.js.map +1 -1
- package/lib/commonjs/expo-config-plugin/android/withBrownfieldAndroid.js +1 -1
- package/lib/commonjs/expo-config-plugin/android/withBrownfieldAndroid.js.map +1 -1
- package/lib/commonjs/expo-config-plugin/expoUtils.js +1 -1
- package/lib/commonjs/expo-config-plugin/expoUtils.js.map +1 -1
- package/lib/commonjs/expo-config-plugin/ios/utils/expo-updates.js +2 -0
- package/lib/commonjs/expo-config-plugin/ios/utils/expo-updates.js.map +1 -0
- package/lib/commonjs/expo-config-plugin/ios/withBrownfieldIos.js +1 -1
- package/lib/commonjs/expo-config-plugin/ios/withBrownfieldIos.js.map +1 -1
- package/lib/commonjs/expo-config-plugin/ios/xcodeHelpers.js +1 -1
- package/lib/commonjs/expo-config-plugin/ios/xcodeHelpers.js.map +1 -1
- package/lib/commonjs/expo-config-plugin/template/android/AndroidManifest.xml +1 -1
- package/lib/commonjs/expo-config-plugin/template/android/ReactNativeHostManager.pre55.kt +6 -1
- package/lib/commonjs/expo-config-plugin/template/android/strings.xml +4 -0
- package/lib/commonjs/expo-config-plugin/template/ios/patchExpoPre55.sh +2 -0
- package/lib/module/expo-config-plugin/android/utils/androidManifest.js +2 -0
- package/lib/module/expo-config-plugin/android/utils/androidManifest.js.map +1 -0
- package/lib/module/expo-config-plugin/android/utils/constants.js +1 -1
- package/lib/module/expo-config-plugin/android/utils/expo-updates.js +2 -0
- package/lib/module/expo-config-plugin/android/utils/expo-updates.js.map +1 -0
- package/lib/module/expo-config-plugin/android/withAndroidModuleFiles.js +1 -1
- package/lib/module/expo-config-plugin/android/withAndroidModuleFiles.js.map +1 -1
- package/lib/module/expo-config-plugin/android/withBrownfieldAndroid.js +1 -1
- package/lib/module/expo-config-plugin/android/withBrownfieldAndroid.js.map +1 -1
- package/lib/module/expo-config-plugin/expoUtils.js +1 -1
- package/lib/module/expo-config-plugin/expoUtils.js.map +1 -1
- package/lib/module/expo-config-plugin/ios/utils/expo-updates.js +2 -0
- package/lib/module/expo-config-plugin/ios/utils/expo-updates.js.map +1 -0
- package/lib/module/expo-config-plugin/ios/withBrownfieldIos.js +1 -1
- package/lib/module/expo-config-plugin/ios/withBrownfieldIos.js.map +1 -1
- package/lib/module/expo-config-plugin/ios/xcodeHelpers.js +1 -1
- package/lib/module/expo-config-plugin/ios/xcodeHelpers.js.map +1 -1
- package/lib/module/expo-config-plugin/template/android/AndroidManifest.xml +1 -1
- package/lib/module/expo-config-plugin/template/android/ReactNativeHostManager.pre55.kt +6 -1
- package/lib/module/expo-config-plugin/template/android/strings.xml +4 -0
- package/lib/module/expo-config-plugin/template/ios/patchExpoPre55.sh +2 -0
- package/lib/typescript/commonjs/src/expo-config-plugin/android/utils/androidManifest.d.ts +13 -0
- package/lib/typescript/commonjs/src/expo-config-plugin/android/utils/androidManifest.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/expo-config-plugin/android/utils/constants.d.ts +2 -2
- package/lib/typescript/commonjs/src/expo-config-plugin/android/utils/expo-updates.d.ts +12 -0
- package/lib/typescript/commonjs/src/expo-config-plugin/android/utils/expo-updates.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/expo-config-plugin/android/withAndroidModuleFiles.d.ts +20 -1
- package/lib/typescript/commonjs/src/expo-config-plugin/android/withAndroidModuleFiles.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/expo-config-plugin/android/withBrownfieldAndroid.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/expo-config-plugin/expoUtils.d.ts +1 -0
- package/lib/typescript/commonjs/src/expo-config-plugin/expoUtils.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/expo-config-plugin/ios/utils/expo-updates.d.ts +30 -0
- package/lib/typescript/commonjs/src/expo-config-plugin/ios/utils/expo-updates.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/expo-config-plugin/ios/withBrownfieldIos.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/expo-config-plugin/ios/xcodeHelpers.d.ts +29 -0
- package/lib/typescript/commonjs/src/expo-config-plugin/ios/xcodeHelpers.d.ts.map +1 -1
- package/lib/typescript/module/src/expo-config-plugin/android/utils/androidManifest.d.ts +13 -0
- package/lib/typescript/module/src/expo-config-plugin/android/utils/androidManifest.d.ts.map +1 -0
- package/lib/typescript/module/src/expo-config-plugin/android/utils/constants.d.ts +2 -2
- package/lib/typescript/module/src/expo-config-plugin/android/utils/expo-updates.d.ts +12 -0
- package/lib/typescript/module/src/expo-config-plugin/android/utils/expo-updates.d.ts.map +1 -0
- package/lib/typescript/module/src/expo-config-plugin/android/withAndroidModuleFiles.d.ts +20 -1
- package/lib/typescript/module/src/expo-config-plugin/android/withAndroidModuleFiles.d.ts.map +1 -1
- package/lib/typescript/module/src/expo-config-plugin/android/withBrownfieldAndroid.d.ts.map +1 -1
- package/lib/typescript/module/src/expo-config-plugin/expoUtils.d.ts +1 -0
- package/lib/typescript/module/src/expo-config-plugin/expoUtils.d.ts.map +1 -1
- package/lib/typescript/module/src/expo-config-plugin/ios/utils/expo-updates.d.ts +30 -0
- package/lib/typescript/module/src/expo-config-plugin/ios/utils/expo-updates.d.ts.map +1 -0
- package/lib/typescript/module/src/expo-config-plugin/ios/withBrownfieldIos.d.ts.map +1 -1
- package/lib/typescript/module/src/expo-config-plugin/ios/xcodeHelpers.d.ts +29 -0
- package/lib/typescript/module/src/expo-config-plugin/ios/xcodeHelpers.d.ts.map +1 -1
- package/package.json +2 -2
- package/src/expo-config-plugin/android/utils/androidManifest.ts +131 -0
- package/src/expo-config-plugin/android/utils/constants.ts +1 -1
- package/src/expo-config-plugin/android/utils/expo-updates.ts +106 -0
- package/src/expo-config-plugin/android/withAndroidModuleFiles.ts +122 -8
- package/src/expo-config-plugin/android/withBrownfieldAndroid.ts +18 -1
- package/src/expo-config-plugin/expoUtils.ts +14 -0
- package/src/expo-config-plugin/ios/utils/expo-updates.ts +168 -0
- package/src/expo-config-plugin/ios/withBrownfieldIos.ts +13 -1
- package/src/expo-config-plugin/ios/xcodeHelpers.ts +217 -4
- package/src/expo-config-plugin/template/android/AndroidManifest.xml +1 -1
- package/src/expo-config-plugin/template/android/ReactNativeHostManager.pre55.kt +6 -1
- package/src/expo-config-plugin/template/android/strings.xml +4 -0
- package/src/expo-config-plugin/template/ios/patchExpoPre55.sh +2 -0
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,23 @@
|
|
|
1
1
|
# @callstack/react-native-brownfield
|
|
2
2
|
|
|
3
|
+
## 3.8.1
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- Updated dependencies [[`e78084d`](https://github.com/callstack/react-native-brownfield/commit/e78084d227a49d39d726b8c778bd56045634678d)]:
|
|
8
|
+
- @callstack/brownfield-cli@3.8.1
|
|
9
|
+
|
|
10
|
+
## 3.8.0
|
|
11
|
+
|
|
12
|
+
### Minor Changes
|
|
13
|
+
|
|
14
|
+
- [#295](https://github.com/callstack/react-native-brownfield/pull/295) [`d93dcd9`](https://github.com/callstack/react-native-brownfield/commit/d93dcd96e3b90517d718cd42b2cc773fb9795eac) Thanks [@hurali97](https://github.com/hurali97)! - add expo updates support
|
|
15
|
+
|
|
16
|
+
### Patch Changes
|
|
17
|
+
|
|
18
|
+
- Updated dependencies [[`d93dcd9`](https://github.com/callstack/react-native-brownfield/commit/d93dcd96e3b90517d718cd42b2cc773fb9795eac)]:
|
|
19
|
+
- @callstack/brownfield-cli@3.8.0
|
|
20
|
+
|
|
3
21
|
## 3.7.0
|
|
4
22
|
|
|
5
23
|
### Patch Changes
|
package/ReactBrownfield.podspec
CHANGED
|
@@ -5,6 +5,9 @@ internal import ReactAppDependencyProvider
|
|
|
5
5
|
|
|
6
6
|
#if canImport(Expo)
|
|
7
7
|
internal import Expo
|
|
8
|
+
#if canImport(EXUpdates)
|
|
9
|
+
internal import EXUpdates
|
|
10
|
+
#endif
|
|
8
11
|
|
|
9
12
|
final class ExpoHostRuntime {
|
|
10
13
|
static let shared = ExpoHostRuntime()
|
|
@@ -38,7 +41,7 @@ final class ExpoHostRuntime {
|
|
|
38
41
|
appDelegate.bindReactNativeFactory(reactNativeFactory)
|
|
39
42
|
#endif
|
|
40
43
|
expoDelegate = appDelegate
|
|
41
|
-
|
|
44
|
+
|
|
42
45
|
if let onBundleLoaded {
|
|
43
46
|
jsBundleLoadObserver.observeOnce(onBundleLoaded: onBundleLoaded)
|
|
44
47
|
}
|
|
@@ -101,10 +104,12 @@ final class ExpoHostRuntime {
|
|
|
101
104
|
_ application: UIApplication,
|
|
102
105
|
didFinishLaunchingWithOptions launchOptions: [UIApplication.LaunchOptionsKey: Any]? = nil
|
|
103
106
|
) -> Bool {
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
107
|
+
#if canImport(EXUpdates)
|
|
108
|
+
if !AppController.isInitialized() {
|
|
109
|
+
AppController.initializeWithoutStarting()
|
|
110
|
+
}
|
|
111
|
+
#endif
|
|
112
|
+
return ExpoAppDelegateSubscriberManager.application(application, didFinishLaunchingWithOptions: launchOptions)
|
|
108
113
|
}
|
|
109
114
|
|
|
110
115
|
// Linking API; base implementation courtesy of Expo, licensed under the MIT License - changes were made to call the method on expo delegate - https://github.com/expo/expo/blob/main/apps/bare-expo/ios/AppDelegate.swift
|
|
@@ -125,6 +130,13 @@ final class ExpoHostRuntime {
|
|
|
125
130
|
let result = RCTLinkingManager.application(application, continue: userActivity, restorationHandler: restorationHandler)
|
|
126
131
|
return (expoDelegate?.application(application, continue: userActivity, restorationHandler: restorationHandler) ?? false) || result
|
|
127
132
|
}
|
|
133
|
+
|
|
134
|
+
func application(
|
|
135
|
+
_ application: UIApplication,
|
|
136
|
+
willFinishLaunchingWithOptions launchOptions: [UIApplication.LaunchOptionsKey: Any]? = nil
|
|
137
|
+
) -> Bool {
|
|
138
|
+
return ExpoAppDelegateSubscriberManager.application(application, willFinishLaunchingWithOptions: launchOptions)
|
|
139
|
+
}
|
|
128
140
|
|
|
129
141
|
func view(
|
|
130
142
|
moduleName: String,
|
|
@@ -170,6 +182,12 @@ class ExpoHostRuntimeDelegate: ExpoReactNativeFactoryDelegate {
|
|
|
170
182
|
return RCTBundleURLProvider.sharedSettings().jsBundleURL(
|
|
171
183
|
forBundleRoot: entryFile)
|
|
172
184
|
#else
|
|
185
|
+
#if canImport(EXUpdates)
|
|
186
|
+
if AppController.isInitialized(),
|
|
187
|
+
let launchAssetURL = AppController.sharedInstance.launchAssetUrl() {
|
|
188
|
+
return launchAssetURL
|
|
189
|
+
}
|
|
190
|
+
#endif
|
|
173
191
|
do {
|
|
174
192
|
let (resourceName, fileExtension) = try BrownfieldBundlePathResolver.resourceComponents(
|
|
175
193
|
from: bundlePath
|
|
@@ -133,6 +133,23 @@ internal import Expo
|
|
|
133
133
|
#endif
|
|
134
134
|
}
|
|
135
135
|
|
|
136
|
+
@objc public func application(
|
|
137
|
+
_ application: UIApplication,
|
|
138
|
+
willFinishLaunchingWithOptions launchOptions: [UIApplication.LaunchOptionsKey: Any]? = nil
|
|
139
|
+
) -> Bool {
|
|
140
|
+
#if canImport(Expo)
|
|
141
|
+
return ExpoHostRuntime.shared.application(
|
|
142
|
+
application,
|
|
143
|
+
willFinishLaunchingWithOptions: launchOptions
|
|
144
|
+
)
|
|
145
|
+
#else
|
|
146
|
+
return ReactNativeHostRuntime.shared.application(
|
|
147
|
+
application,
|
|
148
|
+
willFinishLaunchingWithOptions: launchOptions
|
|
149
|
+
)
|
|
150
|
+
#endif
|
|
151
|
+
}
|
|
152
|
+
|
|
136
153
|
@objc public func application(
|
|
137
154
|
_ app: UIApplication,
|
|
138
155
|
open url: URL,
|
|
@@ -129,6 +129,16 @@ final class ReactNativeHostRuntime {
|
|
|
129
129
|
return true
|
|
130
130
|
}
|
|
131
131
|
|
|
132
|
+
/**
|
|
133
|
+
* Mirrors host manager app delegate API for bare React Native.
|
|
134
|
+
*/
|
|
135
|
+
public func application(
|
|
136
|
+
_ application: UIApplication,
|
|
137
|
+
willFinishLaunchingWithOptions launchOptions: [UIApplication.LaunchOptionsKey: Any]? = nil
|
|
138
|
+
) -> Bool {
|
|
139
|
+
return true
|
|
140
|
+
}
|
|
141
|
+
|
|
132
142
|
public func application(
|
|
133
143
|
_ app: UIApplication,
|
|
134
144
|
open url: URL,
|
|
@@ -1,13 +1,25 @@
|
|
|
1
1
|
import UIKit
|
|
2
2
|
internal import React
|
|
3
|
+
#if canImport(EXUpdates)
|
|
4
|
+
internal import EXUpdates
|
|
5
|
+
#endif
|
|
3
6
|
|
|
4
7
|
@objc public class ReactNativeViewController: UIViewController {
|
|
5
8
|
private var moduleName: String
|
|
6
9
|
private var initialProperties: [String: Any]?
|
|
7
10
|
|
|
11
|
+
#if canImport(EXUpdates)
|
|
12
|
+
private let expoUpdatesDelegate = ReactNativeExpoUpdatesDelegate()
|
|
13
|
+
#endif
|
|
14
|
+
|
|
15
|
+
|
|
8
16
|
@objc public init(moduleName: String, initialProperties: [String: Any]? = nil) {
|
|
9
17
|
self.moduleName = moduleName
|
|
10
18
|
self.initialProperties = initialProperties
|
|
19
|
+
#if canImport(EXUpdates)
|
|
20
|
+
AppController.sharedInstance.delegate = expoUpdatesDelegate
|
|
21
|
+
AppController.sharedInstance.start()
|
|
22
|
+
#endif
|
|
11
23
|
super.init(nibName: nil, bundle: nil)
|
|
12
24
|
}
|
|
13
25
|
|
|
@@ -17,14 +29,17 @@ internal import React
|
|
|
17
29
|
|
|
18
30
|
public override func viewDidLoad() {
|
|
19
31
|
super.viewDidLoad()
|
|
32
|
+
#if canImport(EXUpdates)
|
|
33
|
+
expoUpdatesDelegate.onDidStart = { [weak self] in
|
|
34
|
+
self?.renderReactNativeView()
|
|
35
|
+
}
|
|
36
|
+
#endif
|
|
20
37
|
|
|
21
38
|
if !moduleName.isEmpty {
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
)
|
|
27
|
-
|
|
39
|
+
#if !canImport(EXUpdates)
|
|
40
|
+
renderReactNativeView()
|
|
41
|
+
#endif
|
|
42
|
+
|
|
28
43
|
NotificationCenter.default.addObserver(
|
|
29
44
|
self,
|
|
30
45
|
selector: #selector(togglePopGestureRecognizer(_:)),
|
|
@@ -62,4 +77,41 @@ internal import React
|
|
|
62
77
|
self?.navigationController?.popViewController(animated: animated)
|
|
63
78
|
}
|
|
64
79
|
}
|
|
80
|
+
|
|
81
|
+
private func renderReactNativeView() {
|
|
82
|
+
guard !moduleName.isEmpty else { return }
|
|
83
|
+
|
|
84
|
+
DispatchQueue.main.async { [weak self] in
|
|
85
|
+
guard let self else { return }
|
|
86
|
+
guard let reactView = ReactNativeBrownfield.shared.view(
|
|
87
|
+
moduleName: self.moduleName,
|
|
88
|
+
initialProps: self.initialProperties,
|
|
89
|
+
launchOptions: nil
|
|
90
|
+
) else { return }
|
|
91
|
+
self.view = reactView
|
|
92
|
+
}
|
|
93
|
+
}
|
|
94
|
+
}
|
|
95
|
+
|
|
96
|
+
#if canImport(EXUpdates)
|
|
97
|
+
private final class ReactNativeExpoUpdatesDelegate: NSObject, AppControllerDelegate {
|
|
98
|
+
private var didStartSuccessfully = false
|
|
99
|
+
var onDidStart: (() -> Void)? {
|
|
100
|
+
didSet {
|
|
101
|
+
if didStartSuccessfully {
|
|
102
|
+
onDidStart?()
|
|
103
|
+
}
|
|
104
|
+
}
|
|
105
|
+
}
|
|
106
|
+
|
|
107
|
+
func appController(_ appController: any EXUpdates.AppControllerInterface, didStartWithSuccess success: Bool) {
|
|
108
|
+
guard success else {
|
|
109
|
+
NSLog("%@", "Expo Updates failed to start React Native.")
|
|
110
|
+
return
|
|
111
|
+
}
|
|
112
|
+
|
|
113
|
+
didStartSuccessfully = true
|
|
114
|
+
onDidStart?()
|
|
115
|
+
}
|
|
65
116
|
}
|
|
117
|
+
#endif
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
Object.defineProperty(exports,"__esModule",{value:true});exports.extractApplicationMetaData=extractApplicationMetaData;exports.extractStringResourcesFromXml=extractStringResourcesFromXml;exports.renderLibraryManifestApplication=renderLibraryManifestApplication;exports.renderLibraryStringResources=renderLibraryStringResources;var APPLICATION_BLOCK_REGEX=/<application\b[\s\S]*?<\/application>/;var META_DATA_TAG_REGEX=/<meta-data\b[\s\S]*?(?:\/>|>[\s\S]*?<\/meta-data>)/g;var STRING_TAG_REGEX=/<string\b[\s\S]*?>[\s\S]*?<\/string>/g;function extractApplicationMetaData(manifestContent){var _manifestContent$matc,_applicationBlock$mat;var applicationBlock=(_manifestContent$matc=manifestContent.match(APPLICATION_BLOCK_REGEX))==null?void 0:_manifestContent$matc[0];if(!applicationBlock){return[];}return((_applicationBlock$mat=applicationBlock.match(META_DATA_TAG_REGEX))!=null?_applicationBlock$mat:[]).map(parseMetaDataTag).filter(function(metaDataEntry){return metaDataEntry!==null;});}function extractStringResourcesFromXml(stringsContent,resourceNames){if(resourceNames.length===0){return[];}return resourceNames.map(function(name){return extractStringResource(stringsContent,name);}).filter(function(stringResource){return stringResource!==null;});}function renderLibraryManifestApplication(metaDataEntries){if(metaDataEntries.length===0){return'';}var renderedMetaDataEntries=metaDataEntries.map(function(_ref){var name=_ref.name,value=_ref.value;return` <meta-data android:name="${name}" android:value="${value}" />`;}).join('\n');return` <application>\n${renderedMetaDataEntries}\n </application>`;}function renderLibraryStringResources(stringResources){if(stringResources.length===0){return'';}return stringResources.map(function(_ref2){var name=_ref2.name,value=_ref2.value;return` <string name="${name}">${value}</string>`;}).join('\n');}function parseMetaDataTag(metaDataTag){var name=getAndroidAttribute(metaDataTag,'name');var value=getAndroidAttribute(metaDataTag,'value');return parseMetaDataAttributes(name,value);}function parseMetaDataAttributes(name,value){if(name===undefined||value===undefined){return null;}return{name:name,value:value};}function extractStringResource(stringsContent,resourceName){var _stringsContent$match,_stringTag$match;var stringTag=((_stringsContent$match=stringsContent.match(STRING_TAG_REGEX))!=null?_stringsContent$match:[]).find(function(tag){return getAttribute(tag,'name')===resourceName;});if(!stringTag){return null;}var value=(_stringTag$match=stringTag.match(/>([\s\S]*?)<\/string>/))==null?void 0:_stringTag$match[1];if(value===undefined){return null;}return{name:resourceName,value:value};}function getAndroidAttribute(metaDataTag,attributeName){return getAttribute(metaDataTag,`android:${attributeName}`);}function getAttribute(tag,attributeName){var _tag$match;var attributeRegex=new RegExp(`\\b${attributeName}\\s*=\\s*(['"])([\\s\\S]*?)\\1`);return(_tag$match=tag.match(attributeRegex))==null?void 0:_tag$match[2];}
|
|
2
|
+
//# sourceMappingURL=androidManifest.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["APPLICATION_BLOCK_REGEX","META_DATA_TAG_REGEX","STRING_TAG_REGEX","extractApplicationMetaData","manifestContent","_manifestContent$matc","_applicationBlock$mat","applicationBlock","match","map","parseMetaDataTag","filter","metaDataEntry","extractStringResourcesFromXml","stringsContent","resourceNames","length","name","extractStringResource","stringResource","renderLibraryManifestApplication","metaDataEntries","renderedMetaDataEntries","_ref","value","join","renderLibraryStringResources","stringResources","_ref2","metaDataTag","getAndroidAttribute","parseMetaDataAttributes","undefined","resourceName","_stringsContent$match","_stringTag$match","stringTag","find","tag","getAttribute","attributeName","_tag$match","attributeRegex","RegExp"],"sourceRoot":"../../../../../src","sources":["expo-config-plugin/android/utils/androidManifest.ts"],"mappings":"uUAUA,GAAM,CAAAA,uBAAuB,CAAG,uCAAuC,CACvE,GAAM,CAAAC,mBAAmB,CACvB,qDAAqD,CACvD,GAAM,CAAAC,gBAAgB,CAAG,uCAAuC,CAEzD,QAAS,CAAAC,0BAA0BA,CACxCC,eAAuB,CACS,KAAAC,qBAAA,CAAAC,qBAAA,CAChC,GAAM,CAAAC,gBAAgB,EAAAF,qBAAA,CAAGD,eAAe,CAACI,KAAK,CAACR,uBAAuB,CAAC,eAA9CK,qBAAA,CAAiD,CAAC,CAAC,CAE5E,GAAI,CAACE,gBAAgB,CAAE,CACrB,MAAO,EAAE,CACX,CAEA,MAAO,EAAAD,qBAAA,CAACC,gBAAgB,CAACC,KAAK,CAACP,mBAAmB,CAAC,QAAAK,qBAAA,CAAI,EAAE,EACtDG,GAAG,CAACC,gBAAgB,CAAC,CACrBC,MAAM,CACL,SAACC,aAAa,QACZ,CAAAA,aAAa,GAAK,IAAI,EAC1B,CAAC,CACL,CAEO,QAAS,CAAAC,6BAA6BA,CAC3CC,cAAsB,CACtBC,aAAuB,CACO,CAC9B,GAAIA,aAAa,CAACC,MAAM,GAAK,CAAC,CAAE,CAC9B,MAAO,EAAE,CACX,CAEA,MAAO,CAAAD,aAAa,CACjBN,GAAG,CAAC,SAACQ,IAAI,QAAK,CAAAC,qBAAqB,CAACJ,cAAc,CAAEG,IAAI,CAAC,GAAC,CAC1DN,MAAM,CACL,SAACQ,cAAc,QACb,CAAAA,cAAc,GAAK,IAAI,EAC3B,CAAC,CACL,CAEO,QAAS,CAAAC,gCAAgCA,CAC9CC,eAA+C,CACvC,CACR,GAAIA,eAAe,CAACL,MAAM,GAAK,CAAC,CAAE,CAChC,MAAO,EAAE,CACX,CAEA,GAAM,CAAAM,uBAAuB,CAAGD,eAAe,CAC5CZ,GAAG,CACF,SAAAc,IAAA,KAAG,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AC,QAAAgC,qBAAA,CAAI,EAAE,EAAEG,IAAI,CACnE,SAACC,GAAG,QAAK,CAAAC,YAAY,CAACD,GAAG,CAAE,MAAM,CAAC,GAAKL,YAAY,EACrD,CAAC,CAED,GAAI,CAACG,SAAS,CAAE,CACd,MAAO,KAAI,CACb,CAEA,GAAM,CAAAZ,KAAK,EAAAW,gBAAA,CAAGC,SAAS,CAAC5B,KAAK,CAAC,uBAAuB,CAAC,eAAxC2B,gBAAA,CAA2C,CAAC,CAAC,CAE3D,GAAIX,KAAK,GAAKQ,SAAS,CAAE,CACvB,MAAO,KAAI,CACb,CAEA,MAAO,CAAEf,IAAI,CAAEgB,YAAY,CAAET,KAAK,CAALA,KAAM,CAAC,CACtC,CAEA,QAAS,CAAAM,mBAAmBA,CAC1BD,WAAmB,CACnBW,aAAqB,CACD,CACpB,MAAO,CAAAD,YAAY,CAACV,WAAW,CAAE,WAAWW,aAAa,EAAE,CAAC,CAC9D,CAEA,QAAS,CAAAD,YAAYA,CAACD,GAAW,CAAEE,aAAqB,CAAsB,KAAAC,UAAA,CAC5E,GAAM,CAAAC,cAAc,CAAG,GAAI,CAAAC,MAAM,CAC/B,MAAMH,aAAa,gCACrB,CAAC,CAED,OAAAC,UAAA,CAAOH,GAAG,CAAC9B,KAAK,CAACkC,cAAc,CAAC,eAAzBD,UAAA,CAA4B,CAAC,CAAC,CACvC","ignoreList":[]}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
Object.defineProperty(exports,"__esModule",{value:true});exports.brownfieldGradlePluginDependency=exports.BROWNFIELD_PLUGIN_VERSION=void 0;var BROWNFIELD_PLUGIN_VERSION=exports.BROWNFIELD_PLUGIN_VERSION='1.0
|
|
1
|
+
Object.defineProperty(exports,"__esModule",{value:true});exports.brownfieldGradlePluginDependency=exports.BROWNFIELD_PLUGIN_VERSION=void 0;var BROWNFIELD_PLUGIN_VERSION=exports.BROWNFIELD_PLUGIN_VERSION='1.1.0';var brownfieldGradlePluginDependency=exports.brownfieldGradlePluginDependency=`classpath("com.callstack.react:brownfield-gradle-plugin:${BROWNFIELD_PLUGIN_VERSION}")`;
|
|
2
2
|
//# sourceMappingURL=constants.js.map
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
var _interopRequireDefault=require("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(exports,"__esModule",{value:true});exports.extractExpoUpdatesApplicationMetaData=extractExpoUpdatesApplicationMetaData;exports.readExpoUpdatesApplicationMetaData=readExpoUpdatesApplicationMetaData;exports.readExpoUpdatesStringResources=readExpoUpdatesStringResources;var _toConsumableArray2=_interopRequireDefault(require("@babel/runtime/helpers/toConsumableArray"));var fs=_interopRequireWildcard(require("node:fs"));var path=_interopRequireWildcard(require("node:path"));var _logging=require("../../logging");var _androidManifest=require("./androidManifest");function _interopRequireWildcard(e,t){if("function"==typeof WeakMap)var r=new WeakMap(),n=new WeakMap();return(_interopRequireWildcard=function _interopRequireWildcard(e,t){if(!t&&e&&e.__esModule)return e;var o,i,f={__proto__:null,default:e};if(null===e||"object"!=typeof e&&"function"!=typeof e)return f;if(o=t?n:r){if(o.has(e))return o.get(e);o.set(e,f);}for(var _t in e)"default"!==_t&&{}.hasOwnProperty.call(e,_t)&&((i=(o=Object.defineProperty)&&Object.getOwnPropertyDescriptor(e,_t))&&(i.get||i.set)?o(f,_t,i):f[_t]=e[_t]);return f;})(e,t);}var APP_MANIFEST_PATH_SEGMENTS=['src','main','AndroidManifest.xml'];var APP_STRINGS_PATH_SEGMENTS=['src','main','res','values','strings.xml'];var STRING_REFERENCE_REGEX=/^@string\/([A-Za-z0-9_.]+)$/;var EXPO_UPDATES_META_DATA_PREFIX='expo.modules.updates.';function readExpoUpdatesApplicationMetaData(androidDir,appModuleName){var manifestPath=path.join.apply(path,[androidDir,appModuleName].concat(APP_MANIFEST_PATH_SEGMENTS));if(!fs.existsSync(manifestPath)){_logging.Logger.logDebug(`App manifest not found, skipping metadata copy: ${manifestPath}`);return[];}return extractExpoUpdatesApplicationMetaData(fs.readFileSync(manifestPath,'utf8'));}function extractExpoUpdatesApplicationMetaData(manifestContent){return(0,_androidManifest.extractApplicationMetaData)(manifestContent).filter(isExpoUpdatesMetaDataEntry);}function readExpoUpdatesStringResources(androidDir,appModuleName,metaDataEntries){var stringResourceNames=getReferencedStringResourceNames(metaDataEntries);if(stringResourceNames.length===0){return[];}var stringsPath=path.join.apply(path,[androidDir,appModuleName].concat(APP_STRINGS_PATH_SEGMENTS));if(!fs.existsSync(stringsPath)){_logging.Logger.logDebug(`App strings not found, skipping string resource copy: ${stringsPath}`);return[];}return(0,_androidManifest.extractStringResourcesFromXml)(fs.readFileSync(stringsPath,'utf8'),stringResourceNames);}function isExpoUpdatesMetaDataEntry(metaDataEntry){return metaDataEntry.name.startsWith(EXPO_UPDATES_META_DATA_PREFIX);}function getReferencedStringResourceNames(metaDataEntries){return(0,_toConsumableArray2.default)(new Set(metaDataEntries.map(function(_ref){var _value$match;var value=_ref.value;return(_value$match=value.match(STRING_REFERENCE_REGEX))==null?void 0:_value$match[1];}).filter(function(name){return name!==undefined;})));}
|
|
2
|
+
//# sourceMappingURL=expo-updates.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["fs","_interopRequireWildcard","require","path","_logging","_androidManifest","e","t","WeakMap","r","n","__esModule","o","i","f","__proto__","default","has","get","set","_t","hasOwnProperty","call","Object","defineProperty","getOwnPropertyDescriptor","APP_MANIFEST_PATH_SEGMENTS","APP_STRINGS_PATH_SEGMENTS","STRING_REFERENCE_REGEX","EXPO_UPDATES_META_DATA_PREFIX","readExpoUpdatesApplicationMetaData","androidDir","appModuleName","manifestPath","join","apply","concat","existsSync","Logger","logDebug","extractExpoUpdatesApplicationMetaData","readFileSync","manifestContent","extractApplicationMetaData","filter","isExpoUpdatesMetaDataEntry","readExpoUpdatesStringResources","metaDataEntries","stringResourceNames","getReferencedStringResourceNames","length","stringsPath","extractStringResourcesFromXml","metaDataEntry","name","startsWith","_toConsumableArray2","Set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AE,CAC/Bb,eAAM,CAACC,QAAQ,CACb,yDAAyDY,WAAW,EACtE,CAAC,CACD,MAAO,EAAE,CACX,CAEA,MAAO,GAAAC,8CAA6B,EAClCpD,EAAE,CAACyC,YAAY,CAACU,WAAW,CAAE,MAAM,CAAC,CACpCH,mBACF,CAAC,CACH,CAEA,QAAS,CAAAH,0BAA0BA,CACjCQ,aAA2C,CAClC,CACT,MAAO,CAAAA,aAAa,CAACC,IAAI,CAACC,UAAU,CAAC1B,6BAA6B,CAAC,CACrE,CAEA,QAAS,CAAAoB,gCAAgCA,CACvCF,eAA+C,CACrC,CACV,SAAAS,mBAAA,CAAAxC,OAAA,EACK,GAAI,CAAAyC,GAAG,CACRV,eAAe,CACZW,GAAG,CAAC,SAAAC,IAAA,MAAAC,YAAA,IAAG,CAAAC,KAAK,CAAAF,IAAA,CAALE,KAAK,QAAAD,YAAA,CAAOC,KAAK,CAACC,KAAK,CAAClC,sBAAsB,CAAC,eAAnCgC,YAAA,CAAsC,CAAC,CAAC,GAAC,CAC5DhB,MAAM,CAAC,SAACU,IAAI,QAAqB,CAAAA,IAAI,GAAKS,SAAS,GACxD,CAAC,EAEL","ignoreList":[]}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
var _interopRequireDefault=require("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(exports,"__esModule",{value:true});exports.createAndroidModule=createAndroidModule;exports.withAndroidModuleFiles=void 0;var _asyncToGenerator2=_interopRequireDefault(require("@babel/runtime/helpers/asyncToGenerator"));var fs=_interopRequireWildcard(require("node:fs"));var path=_interopRequireWildcard(require("node:path"));var _configPlugins=require("@expo/config-plugins");var _logging=require("../logging");var _engine=require("../template/engine");var _expoUtils=require("../expoUtils");var _hermes=require("./utils/hermes");function _interopRequireWildcard(e,t){if("function"==typeof WeakMap)var r=new WeakMap(),n=new WeakMap();return(_interopRequireWildcard=function _interopRequireWildcard(e,t){if(!t&&e&&e.__esModule)return e;var o,i,f={__proto__:null,default:e};if(null===e||"object"!=typeof e&&"function"!=typeof e)return f;if(o=t?n:r){if(o.has(e))return o.get(e);o.set(e,f);}for(var _t in e)"default"!==_t&&{}.hasOwnProperty.call(e,_t)&&((i=(o=Object.defineProperty)&&Object.getOwnPropertyDescriptor(e,_t))&&(i.get||i.set)?o(f,_t,i):f[_t]=e[_t]);return f;})(e,t);}function createAndroidModule(_ref){var androidDir=_ref.androidDir,config=_ref.config,rnVersion=_ref.rnVersion,isExpoPre55=_ref.isExpoPre55;var android=config.android;var moduleDir=path.join(androidDir,android.moduleName);_logging.Logger.logDebug(`Creating Android module in: ${androidDir}`);var hermesArtifact=(0,_hermes.getHermesArtifact)(rnVersion);_logging.Logger.logDebug(`Resolved Hermes artifact: ${hermesArtifact.groupId}:${hermesArtifact.artifactId}:${hermesArtifact.version}`);var files=[{relativePath:'build.gradle.kts',content:(0,_engine.renderTemplate)('android','build.gradle.kts',{'{{PACKAGE_NAME}}':android.packageName,'{{MIN_SDK_VERSION}}':android.minSdkVersion.toString(),'{{COMPILE_SDK_VERSION}}':android.compileSdkVersion.toString(),'{{GROUP_ID}}':android.groupId,'{{ARTIFACT_ID}}':android.artifactId,'{{ARTIFACT_VERSION}}':android.version,'{{RN_VERSION}}':rnVersion,'{{HERMES_ARTIFACT}}':`${hermesArtifact.groupId}:${hermesArtifact.artifactId}:${hermesArtifact.version}`})},{relativePath:'gradle.properties',content:(0,_engine.renderTemplate)('android','gradle.properties',{})},{relativePath
|
|
1
|
+
var _interopRequireDefault=require("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(exports,"__esModule",{value:true});exports.createAndroidModule=createAndroidModule;exports.syncAndroidModuleExpoUpdatesFromAppFiles=syncAndroidModuleExpoUpdatesFromAppFiles;exports.syncAndroidModuleManifest=syncAndroidModuleManifest;exports.syncAndroidModuleStringResources=syncAndroidModuleStringResources;exports.withAndroidModuleFiles=void 0;var _asyncToGenerator2=_interopRequireDefault(require("@babel/runtime/helpers/asyncToGenerator"));var fs=_interopRequireWildcard(require("node:fs"));var path=_interopRequireWildcard(require("node:path"));var _configPlugins=require("@expo/config-plugins");var _logging=require("../logging");var _engine=require("../template/engine");var _expoUtils=require("../expoUtils");var _androidManifest=require("./utils/androidManifest");var _expoUpdates=require("./utils/expo-updates");var _hermes=require("./utils/hermes");function _interopRequireWildcard(e,t){if("function"==typeof WeakMap)var r=new WeakMap(),n=new WeakMap();return(_interopRequireWildcard=function _interopRequireWildcard(e,t){if(!t&&e&&e.__esModule)return e;var o,i,f={__proto__:null,default:e};if(null===e||"object"!=typeof e&&"function"!=typeof e)return f;if(o=t?n:r){if(o.has(e))return o.get(e);o.set(e,f);}for(var _t in e)"default"!==_t&&{}.hasOwnProperty.call(e,_t)&&((i=(o=Object.defineProperty)&&Object.getOwnPropertyDescriptor(e,_t))&&(i.get||i.set)?o(f,_t,i):f[_t]=e[_t]);return f;})(e,t);}function createAndroidModule(_ref){var androidDir=_ref.androidDir,config=_ref.config,rnVersion=_ref.rnVersion,isExpoPre55=_ref.isExpoPre55,projectRoot=_ref.projectRoot;var android=config.android;var moduleDir=path.join(androidDir,android.moduleName);var hasExpoUpdates=(0,_expoUtils.hasExpoUpdatesInstalled)(projectRoot);_logging.Logger.logDebug(`Creating Android module in: ${androidDir}`);var hermesArtifact=(0,_hermes.getHermesArtifact)(rnVersion);_logging.Logger.logDebug(`Resolved Hermes artifact: ${hermesArtifact.groupId}:${hermesArtifact.artifactId}:${hermesArtifact.version}`);var files=[{relativePath:'build.gradle.kts',content:(0,_engine.renderTemplate)('android','build.gradle.kts',{'{{PACKAGE_NAME}}':android.packageName,'{{MIN_SDK_VERSION}}':android.minSdkVersion.toString(),'{{COMPILE_SDK_VERSION}}':android.compileSdkVersion.toString(),'{{GROUP_ID}}':android.groupId,'{{ARTIFACT_ID}}':android.artifactId,'{{ARTIFACT_VERSION}}':android.version,'{{RN_VERSION}}':rnVersion,'{{HERMES_ARTIFACT}}':`${hermesArtifact.groupId}:${hermesArtifact.artifactId}:${hermesArtifact.version}`})},{relativePath:'gradle.properties',content:(0,_engine.renderTemplate)('android','gradle.properties',{})},{relativePath:`src/main/java/${config.android.packageName.replace(/\./g,'/')}/ReactNativeHostManager.kt`,content:(0,_engine.renderTemplate)('android',isExpoPre55?'ReactNativeHostManager.pre55.kt':'ReactNativeHostManager.post55.kt',isExpoPre55?{'{{PACKAGE_NAME}}':android.packageName,'{{EXPO_UPDATES_IMPORTS}}':hasExpoUpdates?'import expo.modules.updates.UpdatesController':'','{{EXPO_UPDATES_REACT_HOST_BLOCK}}':hasExpoUpdates?'\n UpdatesController.setReactHost(reactHost)\n':'\n'}:{'{{PACKAGE_NAME}}':android.packageName})},{relativePath:'consumer-rules.pro',content:(0,_engine.renderTemplate)('android','consumer-rules.pro',{})},{relativePath:'proguard-rules.pro',content:(0,_engine.renderTemplate)('android','proguard-rules.pro',{})}];for(var file of files){var filePath=path.join(moduleDir,file.relativePath);var fileDir=path.dirname(filePath);if(!fs.existsSync(fileDir)){fs.mkdirSync(fileDir,{recursive:true});}fs.writeFileSync(filePath,file.content,'utf8');_logging.Logger.logDebug(`Created file: ${filePath}`);}syncAndroidModuleExpoUpdatesFromAppFiles({androidDir:androidDir,config:config});_logging.Logger.logDebug(`Android module "${android.moduleName}" created at ${moduleDir}`);}function syncAndroidModuleManifest(_ref2){var androidDir=_ref2.androidDir,config=_ref2.config,expoUpdatesMetaData=_ref2.expoUpdatesMetaData;writeAndroidModuleFile(path.join(androidDir,config.android.moduleName),'src/main/AndroidManifest.xml',(0,_engine.renderTemplate)('android','AndroidManifest.xml',{'{{APPLICATION_BLOCK}}':(0,_androidManifest.renderLibraryManifestApplication)(expoUpdatesMetaData)}));}function syncAndroidModuleStringResources(_ref3){var androidDir=_ref3.androidDir,config=_ref3.config,expoUpdatesStringResources=_ref3.expoUpdatesStringResources;writeAndroidModuleFile(path.join(androidDir,config.android.moduleName),'src/main/res/values/strings.xml',(0,_engine.renderTemplate)('android','strings.xml',{'{{STRING_RESOURCES}}':(0,_androidManifest.renderLibraryStringResources)(expoUpdatesStringResources)}));}function writeAndroidModuleFile(moduleDir,relativePath,content){var filePath=path.join(moduleDir,relativePath);var fileDir=path.dirname(filePath);if(!fs.existsSync(fileDir)){fs.mkdirSync(fileDir,{recursive:true});}fs.writeFileSync(filePath,content,'utf8');_logging.Logger.logDebug(`Created file: ${filePath}`);}function syncAndroidModuleExpoUpdatesFromAppFiles(_ref4){var androidDir=_ref4.androidDir,config=_ref4.config;var appModuleName='app';var expoUpdatesMetaData=(0,_expoUpdates.readExpoUpdatesApplicationMetaData)(androidDir,appModuleName);var expoUpdatesStringResources=(0,_expoUpdates.readExpoUpdatesStringResources)(androidDir,appModuleName,expoUpdatesMetaData);syncAndroidModuleManifest({androidDir:androidDir,config:config,expoUpdatesMetaData:expoUpdatesMetaData});syncAndroidModuleStringResources({androidDir:androidDir,config:config,expoUpdatesStringResources:expoUpdatesStringResources});}var withAndroidModuleFiles=exports.withAndroidModuleFiles=function withAndroidModuleFiles(config,props){return(0,_configPlugins.withDangerousMod)(config,['android',(function(){var _ref5=(0,_asyncToGenerator2.default)(function*(dangerousConfig){var androidDir=path.join(dangerousConfig.modRequest.projectRoot,'android');var rnVersion;try{var rnPkgPath=require.resolve('react-native/package.json',{paths:[dangerousConfig.modRequest.projectRoot]});var rnPkg=require(rnPkgPath);rnVersion=rnPkg.version;_logging.Logger.logDebug(`Resolved react-native version: ${rnVersion}`);}catch(_unused){throw new Error('Could not resolve react-native package version. Please ensure you have installed dependencies.');}var _getExpoInfo=(0,_expoUtils.getExpoInfo)(config),isExpoPre55=_getExpoInfo.isExpoPre55;createAndroidModule({androidDir:androidDir,config:props,rnVersion:rnVersion,isExpoPre55:isExpoPre55,projectRoot:dangerousConfig.modRequest.projectRoot});return dangerousConfig;});return function(_x){return _ref5.apply(this,arguments);};}())]);};
|
|
2
2
|
//# sourceMappingURL=withAndroidModuleFiles.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["fs","_interopRequireWildcard","require","path","_configPlugins","_logging","_engine","_expoUtils","_hermes","e","t","WeakMap","r","n","__esModule","o","i","f","__proto__","default","has","get","set","_t","hasOwnProperty","call","Object","defineProperty","getOwnPropertyDescriptor","createAndroidModule","_ref","androidDir","config","rnVersion","isExpoPre55","android","moduleDir","join","moduleName","Logger","logDebug","hermesArtifact","getHermesArtifact","groupId","artifactId","version","files","relativePath","content","renderTemplate","packageName","minSdkVersion","toString","compileSdkVersion","replace","file","filePath","fileDir","dirname","existsSync","mkdirSync","recursive","writeFileSync","withAndroidModuleFiles","exports","props","withDangerousMod","
|
|
1
|
+
{"version":3,"names":["fs","_interopRequireWildcard","require","path","_configPlugins","_logging","_engine","_expoUtils","_androidManifest","_expoUpdates","_hermes","e","t","WeakMap","r","n","__esModule","o","i","f","__proto__","default","has","get","set","_t","hasOwnProperty","call","Object","defineProperty","getOwnPropertyDescriptor","createAndroidModule","_ref","androidDir","config","rnVersion","isExpoPre55","projectRoot","android","moduleDir","join","moduleName","hasExpoUpdates","hasExpoUpdatesInstalled","Logger","logDebug","hermesArtifact","getHermesArtifact","groupId","artifactId","version","files","relativePath","content","renderTemplate","packageName","minSdkVersion","toString","compileSdkVersion","replace","file","filePath","fileDir","dirname","existsSync","mkdirSync","recursive","writeFileSync","syncAndroidModuleExpoUpdatesFromAppFiles","syncAndroidModuleManifest","_ref2","expoUpdatesMetaData","writeAndroidModuleFile","renderLibraryManifestApplication","syncAndroidModuleStringResources","_ref3","expoUpdatesStringResources","renderLibraryStringResources","_ref4","appModuleName","readExpoUpdatesApplicationMetaData","readExpoUpdatesStringResources","withAndroidModuleFiles","exports","props","withDangerousMod","_ref5","_asyncToGenerator2","dangerousConfig","modRequest","rnPkgPath","resolve","paths","rnPkg","_unused","Error","_getExpoInfo","getExpoInfo","_x","apply","arguments"],"sourceRoot":"../../../../src","sources":["expo-config-plugin/android/withAndroidModuleFiles.ts"],"mappings":"oiBAAA,IAAAA,EAAA,CAAAC,uBAAA,CAAAC,OAAA,aACA,IAAAC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MAAO,GAAAC,+BAAgB,EAACnD,MAAM,CAAE,CAC9B,SAAS,iBAAAoD,KAAA,IAAAC,kBAAA,CAAAlE,OAAA,EACT,UAAOmE,eAAe,CAAK,CACzB,GAAM,CAAAvD,UAAU,CAAG9B,IAAI,CAACqC,IAAI,CAC1BgD,eAAe,CAACC,UAAU,CAACpD,WAAW,CACtC,SACF,CAAC,CAED,GAAI,CAAAF,SAAiB,CACrB,GAAI,CACF,GAAM,CAAAuD,SAAS,CAAGxF,OAAO,CAACyF,OAAO,CAAC,2BAA2B,CAAE,CAC7DC,KAAK,CAAE,CAACJ,eAAe,CAACC,UAAU,CAACpD,WAAW,CAChD,CAAC,CAAC,CAEF,GAAM,CAAAwD,KAAK,CAAG3F,OAAO,CAACwF,SAAS,CAAC,CAEhCvD,SAAS,CAAG0D,KAAK,CAAC3C,OAAO,CAEzBN,eAAM,CAACC,QAAQ,CAAC,kCAAkCV,SAAS,EAAE,CAAC,CAChE,CAAE,MAAA2D,OAAA,CAAM,CACN,KAAM,IAAI,CAAAC,KAAK,CACb,gGACF,CAAC,CACH,CAEA,IAAAC,YAAA,CAAwB,GAAAC,sBAAW,EAAC/D,MAAM,CAAC,CAAnCE,WAAW,CAAA4D,YAAA,CAAX5D,WAAW,CAEnBL,mBAAmB,CAAC,CAClBE,UAAU,CAAVA,UAAU,CACVC,MAAM,CAAEkD,KAAK,CACbjD,SAAS,CAATA,SAAS,CACTC,WAAW,CAAXA,WAAW,CACXC,WAAW,CAAEmD,eAAe,CAACC,UAAU,CAACpD,WAC1C,CAAC,CAAC,CAEF,MAAO,CAAAmD,eAAe,CACxB,CAAC,kBAAAU,EAAA,SAAAZ,KAAA,CAAAa,KAAA,MAAAC,SAAA,SACF,CAAC,CACJ,CAAC","ignoreList":[]}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
Object.defineProperty(exports,"__esModule",{value:true});exports.withBrownfieldAndroid=void 0;var _configPlugins=require("@expo/config-plugins");var _gradleHelpers=require("./utils/gradleHelpers");var _withAndroidModuleFiles=require("./withAndroidModuleFiles");var withBrownfieldAndroid=exports.withBrownfieldAndroid=function withBrownfieldAndroid(config,props){var androidConfig=props.android;config=(0,_configPlugins.withProjectBuildGradle)(config,function(gradleConfig){gradleConfig.modResults.contents=(0,_gradleHelpers.modifyRootBuildGradle)(gradleConfig.modResults.contents);return gradleConfig;});config=(0,_configPlugins.withSettingsGradle)(config,function(settingsConfig){settingsConfig.modResults.contents=(0,_gradleHelpers.modifySettingsGradle)(settingsConfig.modResults.contents,androidConfig.moduleName);return settingsConfig;});config=(0,_withAndroidModuleFiles.withAndroidModuleFiles)(config,props);return config;};
|
|
1
|
+
var _interopRequireDefault=require("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(exports,"__esModule",{value:true});exports.withBrownfieldAndroid=void 0;var _asyncToGenerator2=_interopRequireDefault(require("@babel/runtime/helpers/asyncToGenerator"));var _configPlugins=require("@expo/config-plugins");var _gradleHelpers=require("./utils/gradleHelpers");var _withAndroidModuleFiles=require("./withAndroidModuleFiles");var withBrownfieldAndroid=exports.withBrownfieldAndroid=function withBrownfieldAndroid(config,props){var androidConfig=props.android;config=(0,_configPlugins.withProjectBuildGradle)(config,function(gradleConfig){gradleConfig.modResults.contents=(0,_gradleHelpers.modifyRootBuildGradle)(gradleConfig.modResults.contents);return gradleConfig;});config=(0,_configPlugins.withSettingsGradle)(config,function(settingsConfig){settingsConfig.modResults.contents=(0,_gradleHelpers.modifySettingsGradle)(settingsConfig.modResults.contents,androidConfig.moduleName);return settingsConfig;});config=(0,_withAndroidModuleFiles.withAndroidModuleFiles)(config,props);config=(0,_configPlugins.withFinalizedMod)(config,['android',(function(){var _ref=(0,_asyncToGenerator2.default)(function*(finalizedConfig){(0,_withAndroidModuleFiles.syncAndroidModuleExpoUpdatesFromAppFiles)({androidDir:finalizedConfig.modRequest.platformProjectRoot,config:props});return finalizedConfig;});return function(_x){return _ref.apply(this,arguments);};}())]);return config;};
|
|
2
2
|
//# sourceMappingURL=withBrownfieldAndroid.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["_configPlugins","require","_gradleHelpers","_withAndroidModuleFiles","withBrownfieldAndroid","exports","config","props","androidConfig","android","withProjectBuildGradle","gradleConfig","modResults","contents","modifyRootBuildGradle","withSettingsGradle","settingsConfig","modifySettingsGradle","moduleName","withAndroidModuleFiles"],"sourceRoot":"../../../../src","sources":["expo-config-plugin/android/withBrownfieldAndroid.ts"],"mappings":"
|
|
1
|
+
{"version":3,"names":["_configPlugins","require","_gradleHelpers","_withAndroidModuleFiles","withBrownfieldAndroid","exports","config","props","androidConfig","android","withProjectBuildGradle","gradleConfig","modResults","contents","modifyRootBuildGradle","withSettingsGradle","settingsConfig","modifySettingsGradle","moduleName","withAndroidModuleFiles","withFinalizedMod","_ref","_asyncToGenerator2","default","finalizedConfig","syncAndroidModuleExpoUpdatesFromAppFiles","androidDir","modRequest","platformProjectRoot","_x","apply","arguments"],"sourceRoot":"../../../../src","sources":["expo-config-plugin/android/withBrownfieldAndroid.ts"],"mappings":"mRAAA,IAAAA,cAAA,CAAAC,OAAA,yBAOA,IAAAC,cAAA,CAAAD,OAAA,0BAIA,IAAAE,uBAAA,CAAAF,OAAA,6BAeO,GAAM,CAAAG,qBAEZ,CAAAC,OAAA,CAAAD,qBAAA,CAAG,QAFS,CAAAA,qBAEZA,CAAIE,MAAM,CAAEC,KAAK,CAAK,CACrB,GAAM,CAAAC,aAAa,CAAGD,KAAK,CAACE,OAAO,CAGnCH,MAAM,CAAG,GAAAI,qCAAsB,EAACJ,MAAM,CAAE,SAACK,YAAY,CAAK,CACxDA,YAAY,CAACC,UAAU,CAACC,QAAQ,CAAG,GAAAC,oCAAqB,EACtDH,YAAY,CAACC,UAAU,CAACC,QAC1B,CAAC,CAED,MAAO,CAAAF,YAAY,CACrB,CAAC,CAAC,CAGFL,MAAM,CAAG,GAAAS,iCAAkB,EAACT,MAAM,CAAE,SAACU,cAAc,CAAK,CACtDA,cAAc,CAACJ,UAAU,CAACC,QAAQ,CAAG,GAAAI,mCAAoB,EACvDD,cAAc,CAACJ,UAAU,CAACC,QAAQ,CAClCL,aAAa,CAACU,UAChB,CAAC,CAED,MAAO,CAAAF,cAAc,CACvB,CAAC,CAAC,CAGFV,MAAM,CAAG,GAAAa,8CAAsB,EAACb,MAAM,CAAEC,KAAK,CAAC,CAG9CD,MAAM,CAAG,GAAAc,+BAAgB,EAACd,MAAM,CAAE,CAChC,SAAS,iBAAAe,IAAA,IAAAC,kBAAA,CAAAC,OAAA,EACT,UAAOC,eAAe,CAAK,CACzB,GAAAC,gEAAwC,EAAC,CACvCC,UAAU,CAAEF,eAAe,CAACG,UAAU,CAACC,mBAAmB,CAC1DtB,MAAM,CAAEC,KACV,CAAC,CAAC,CAEF,MAAO,CAAAiB,eAAe,CACxB,CAAC,kBAAAK,EAAA,SAAAR,IAAA,CAAAS,KAAA,MAAAC,SAAA,SACF,CAAC,CAEF,MAAO,CAAAzB,MAAM,CACf,CAAC","ignoreList":[]}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
Object.defineProperty(exports,"__esModule",{value:true});exports.getExpoInfo=getExpoInfo;function getExpoInfo(config){var expoMajor=config.sdkVersion?parseInt(config.sdkVersion.split('.')[0],10):-1;var isExpoPre55=expoMajor<55;return{expoMajor:expoMajor,isExpoPre55:isExpoPre55};}
|
|
1
|
+
Object.defineProperty(exports,"__esModule",{value:true});exports.getExpoInfo=getExpoInfo;exports.hasExpoUpdatesInstalled=hasExpoUpdatesInstalled;function getExpoInfo(config){var expoMajor=config.sdkVersion?parseInt(config.sdkVersion.split('.')[0],10):-1;var isExpoPre55=expoMajor<55;return{expoMajor:expoMajor,isExpoPre55:isExpoPre55};}function hasExpoUpdatesInstalled(projectRoot){if(!projectRoot)return false;try{require.resolve('expo-updates/package.json',{paths:[projectRoot]});return true;}catch(_unused){return false;}}
|
|
2
2
|
//# sourceMappingURL=expoUtils.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["getExpoInfo","config","expoMajor","sdkVersion","parseInt","split","isExpoPre55"],"sourceRoot":"../../../src","sources":["expo-config-plugin/expoUtils.ts"],"mappings":"
|
|
1
|
+
{"version":3,"names":["getExpoInfo","config","expoMajor","sdkVersion","parseInt","split","isExpoPre55","hasExpoUpdatesInstalled","projectRoot","require","resolve","paths","_unused"],"sourceRoot":"../../../src","sources":["expo-config-plugin/expoUtils.ts"],"mappings":"iJAEO,QAAS,CAAAA,WAAWA,CAACC,MAAkB,CAAE,CAC9C,GAAM,CAAAC,SAAS,CAAGD,MAAM,CAACE,UAAU,CAC/BC,QAAQ,CAACH,MAAM,CAACE,UAAU,CAACE,KAAK,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,CAAE,EAAE,CAAC,CAC7C,CAAC,CAAC,CACN,GAAM,CAAAC,WAAW,CAAGJ,SAAS,CAAG,EAAE,CAClC,MAAO,CACLA,SAAS,CAATA,SAAS,CACTI,WAAW,CAAXA,WACF,CAAC,CACH,CAEO,QAAS,CAAAC,uBAAuBA,CACrCC,WAA+B,CACtB,CACT,GAAI,CAACA,WAAW,CAAE,MAAO,MAAK,CAC9B,GAAI,CACFC,OAAO,CAACC,OAAO,CAAC,2BAA2B,CAAE,CAC3CC,KAAK,CAAE,CAACH,WAAW,CACrB,CAAC,CAAC,CACF,MAAO,KAAI,CACb,CAAE,MAAAI,OAAA,CAAM,CACN,MAAO,MAAK,CACd,CACF","ignoreList":[]}
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
var _interopRequireDefault=require("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(exports,"__esModule",{value:true});exports.ensureFrameworkHasExpoPlistResource=ensureFrameworkHasExpoPlistResource;exports.selectExpoPlistFileReference=selectExpoPlistFileReference;var _slicedToArray2=_interopRequireDefault(require("@babel/runtime/helpers/slicedToArray"));var _logging=require("../../logging");var _SourceModificationError=require("../../errors/SourceModificationError");var _xcodeHelpers=require("../xcodeHelpers");var EXPO_PLIST_FILE_NAME='Expo.plist';var EXPO_PLIST_PRIMARY_RELATIVE_PATH='Supporting/Expo.plist';var RESOURCES_BUILD_PHASE_COMMENT='Resources';var EXPO_PLIST_RESOURCE_COMMENT='Expo.plist in Resources';function normalizePbxString(value){return String(value!=null?value:'').replace(/^"(.*)"$/,'$1');}function normalizePbxPathLike(value){return normalizePbxString(value).replace(/^\.\//,'');}function isSupportingGroup(group){var groupName=normalizePbxString(group.name);var groupPath=normalizePbxString(group.path);return groupName==='Supporting'||groupPath==='Supporting'||groupPath.endsWith('/Supporting');}function groupContainsFileReference(group,fileRefUuid){var children=Array.isArray(group.children)?group.children:[];return children.some(function(child){if(typeof child==='string'){return child===fileRefUuid;}return(child==null?void 0:child.value)===fileRefUuid;});}function isPrimaryExpoPlistMatch(fileRefUuid,fileRef,groups){var normalizedPath=normalizePbxPathLike(fileRef.path);var fileName=normalizePbxString(fileRef.name);if(normalizedPath===EXPO_PLIST_PRIMARY_RELATIVE_PATH||normalizedPath.endsWith(`/${EXPO_PLIST_PRIMARY_RELATIVE_PATH}`)){return true;}if(normalizedPath!==EXPO_PLIST_FILE_NAME&&fileName!==EXPO_PLIST_FILE_NAME){return false;}return Object.entries(groups!=null?groups:{}).some(function(_ref){var _ref2=(0,_slicedToArray2.default)(_ref,2),groupUuid=_ref2[0],group=_ref2[1];if(groupUuid.endsWith('_comment')||typeof group==='string'){return false;}return isSupportingGroup(group)&&groupContainsFileReference(group,fileRefUuid);});}function selectExpoPlistFileReference(fileReferences,groups){for(var _ref3 of Object.entries(fileReferences)){var _ref4=(0,_slicedToArray2.default)(_ref3,2);var fileRefUuid=_ref4[0];var fileRef=_ref4[1];if(fileRefUuid.endsWith('_comment')||typeof fileRef==='string'){continue;}if(isPrimaryExpoPlistMatch(fileRefUuid,fileRef,groups)){return fileRefUuid;}}return null;}function getExpoPlistFileRefOrThrow(project){var _hash;var fileReferences=project.pbxFileReferenceSection();var groups=(_hash=project.hash)==null||(_hash=_hash.project)==null||(_hash=_hash.objects)==null?void 0:_hash.PBXGroup;var existingExpoPlistFileRefUuid=selectExpoPlistFileReference(fileReferences,groups);if(existingExpoPlistFileRefUuid){return existingExpoPlistFileRefUuid;}throw new _SourceModificationError.SourceModificationError(`Could not find the "${EXPO_PLIST_PRIMARY_RELATIVE_PATH}" PBXFileReference needed for Expo.plist resource wiring`);}function ensureFrameworkHasExpoPlistResource(project,frameworkTargetUUID){var expoPlistFileRefUuid=getExpoPlistFileRefOrThrow(project);var didAddExpoPlistResource=(0,_xcodeHelpers.ensureTargetHasFileReferenceInResourcesBuildPhase)(project,frameworkTargetUUID,expoPlistFileRefUuid,{resourcesBuildPhaseComment:RESOURCES_BUILD_PHASE_COMMENT,buildFileComment:EXPO_PLIST_RESOURCE_COMMENT});if(!didAddExpoPlistResource){_logging.Logger.logDebug('Framework resources already include Supporting/Expo.plist');return;}_logging.Logger.logDebug('Added Supporting/Expo.plist to framework PBXResourcesBuildPhase');}
|
|
2
|
+
//# sourceMappingURL=expo-updates.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["_logging","require","_SourceModificationError","_xcodeHelpers","EXPO_PLIST_FILE_NAME","EXPO_PLIST_PRIMARY_RELATIVE_PATH","RESOURCES_BUILD_PHASE_COMMENT","EXPO_PLIST_RESOURCE_COMMENT","normalizePbxString","value","String","replace","normalizePbxPathLike","isSupportingGroup","group","groupName","name","groupPath","path","endsWith","groupContainsFileReference","fileRefUuid","children","Array","isArray","some","child","isPrimaryExpoPlistMatch","fileRef","groups","normalizedPath","fileName","Object","entries","_ref","_ref2","_slicedToArray2","default","groupUuid","selectExpoPlistFileReference","fileReferences","_ref3","_ref4","getExpoPlistFileRefOrThrow","project","_hash","pbxFileReferenceSection","hash","objects","PBXGroup","existingExpoPlistFileRefUuid","SourceModificationError","ensureFrameworkHasExpoPlistResource","frameworkTargetUUID","expoPlistFileRefUuid","didAddExpoPlistResource","ensureTargetHasFileReferenceInResourcesBuildPhase","resourcesBuildPhaseComment","buildFileComment","Logger","logDebug"],"sourceRoot":"../../../../../src","sources":["expo-config-plugin/ios/utils/expo-updates.ts"],"mappings":"0XAEA,IAAAA,QAAA,CAAAC,OAAA,kBACA,IAAAC,wBAAA,CAAAD,OAAA,yCACA,IAAAE,aAAA,CAAAF,OAAA,oBAeA,GAAM,CAAAG,oBAAoB,CAAG,YAAY,CACzC,GAAM,CAAAC,gCAAgC,CAAG,uBAAuB,CAChE,GAAM,CAAAC,6BAA6B,CAAG,WAAW,CACjD,GAAM,CAAAC,2BAA2B,CAAG,yBAAyB,CAE7D,QAAS,CAAAC,kBAAkBA,CAACC,KAAc,CAAU,CAClD,MAAO,CAAAC,MAAM,CAACD,KAAK,OAALA,KAAK,CAAI,EAAE,CAAC,CAACE,OAAO,CAAC,UAAU,CAAE,IAAI,CAAC,CACtD,CAEA,QAAS,CAAAC,oBAAoBA,CAACH,KAAc,CAAU,CACpD,MAAO,CAAAD,kBAAkB,CAACC,KAAK,CAAC,CAACE,OAAO,CAAC,OAAO,CAAE,EAAE,CAAC,CACvD,CAEA,QAAS,CAAAE,iBAAiBA,CAACC,KAAmB,CAAW,CACvD,GAAM,CAAAC,SAAS,CAAGP,kBAAkB,CAACM,KAAK,CAACE,IAAI,CAAC,CAChD,GAAM,CAAAC,SAAS,CAAGT,kBAAkB,CAACM,KAAK,CAACI,IAAI,CAAC,CAEhD,MACE,CAAAH,SAAS,GAAK,YAAY,EAC1BE,SAAS,GAAK,YAAY,EAC1BA,SAAS,CAACE,QAAQ,CAAC,aAAa,CAAC,CAErC,CAEA,QAAS,CAAAC,0BAA0BA,CACjCN,KAAmB,CACnBO,WAAmB,CACV,CACT,GAAM,CAAAC,QAAQ,CAAGC,KAAK,CAACC,OAAO,CAACV,KAAK,CAACQ,QAAQ,CAAC,CAAGR,KAAK,CAACQ,QAAQ,CAAG,EAAE,CAEpE,MAAO,CAAAA,QAAQ,CAACG,IAAI,CAAC,SAACC,KAAK,CAAK,CAC9B,GAAI,MAAO,C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QAAQ,CACb,2DACF,CAAC,CACD,OACF,CAEAD,eAAM,CAACC,QAAQ,CACb,iEACF,CAAC,CACH","ignoreList":[]}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
Object.defineProperty(exports,"__esModule",{value:true});exports.withBrownfieldIos=void 0;var _configPlugins=require("@expo/config-plugins");var _xcodeHelpers=require("./xcodeHelpers");var _podfileHelpers=require("./podfileHelpers");var _withIosFrameworkFiles=require("./withIosFrameworkFiles");var _logging=require("../logging");var _expoUtils=require("../expoUtils");var withBrownfieldIos=exports.withBrownfieldIos=function withBrownfieldIos(config,props){var _getExpoInfo=(0,_expoUtils.getExpoInfo)(config),isExpoPre55=_getExpoInfo.isExpoPre55,expoMajor=_getExpoInfo.expoMajor;config=(0,_configPlugins.withXcodeProject)(config,function(xcodeConfig){var project=xcodeConfig.modResults,modRequest=xcodeConfig.modRequest;var _addFrameworkTarget=(0,_xcodeHelpers.addFrameworkTarget)(project,modRequest,props.ios),frameworkTargetUUID=_addFrameworkTarget.frameworkTargetUUID,targetAlreadyExists=_addFrameworkTarget.targetAlreadyExists;if(targetAlreadyExists){_logging.Logger.logDebug(`Skipping further Xcode modifications as framework target was already present`);return xcodeConfig;}(0,_xcodeHelpers.copyBundleReactNativePhase)(project,frameworkTargetUUID);if(isExpoPre55){_logging.Logger.logDebug(`Adding ExpoModulesProvider patch phase for Expo SDK ${config.sdkVersion}`);(0,_xcodeHelpers.addExpoPre55ShellPatchScriptPhase)(modRequest,project,{frameworkName:props.ios.frameworkName,frameworkTargetUUID:frameworkTargetUUID});}else{_logging.Logger.logDebug(`Skipping ExpoModulesProvider patch phase for Expo SDK ${config.sdkVersion}`);}(0,_xcodeHelpers.addSourceFilesBuildPhase)(project,frameworkTargetUUID,props.ios);return xcodeConfig;});config=(0,_configPlugins.withPodfile)(config,function(podfileConfig){var frameworkName=props.ios.frameworkName;podfileConfig.modResults.contents=(0,_podfileHelpers.modifyPodfile)(podfileConfig.modResults.contents,frameworkName,expoMajor);return podfileConfig;});config=(0,_withIosFrameworkFiles.withIosFrameworkFiles)(config,props);return config;};
|
|
1
|
+
Object.defineProperty(exports,"__esModule",{value:true});exports.withBrownfieldIos=void 0;var _configPlugins=require("@expo/config-plugins");var _xcodeHelpers=require("./xcodeHelpers");var _podfileHelpers=require("./podfileHelpers");var _expoUpdates=require("./utils/expo-updates");var _withIosFrameworkFiles=require("./withIosFrameworkFiles");var _logging=require("../logging");var _expoUtils=require("../expoUtils");var withBrownfieldIos=exports.withBrownfieldIos=function withBrownfieldIos(config,props){var _getExpoInfo=(0,_expoUtils.getExpoInfo)(config),isExpoPre55=_getExpoInfo.isExpoPre55,expoMajor=_getExpoInfo.expoMajor;config=(0,_configPlugins.withXcodeProject)(config,function(xcodeConfig){var project=xcodeConfig.modResults,modRequest=xcodeConfig.modRequest;var hasExpoUpdates=(0,_expoUtils.hasExpoUpdatesInstalled)(modRequest.projectRoot);var _addFrameworkTarget=(0,_xcodeHelpers.addFrameworkTarget)(project,modRequest,props.ios),frameworkTargetUUID=_addFrameworkTarget.frameworkTargetUUID,targetAlreadyExists=_addFrameworkTarget.targetAlreadyExists;if(hasExpoUpdates){(0,_expoUpdates.ensureFrameworkHasExpoPlistResource)(project,frameworkTargetUUID);}else{_logging.Logger.logDebug('Skipping Expo.plist framework resource wiring because expo-updates is not installed');}if(targetAlreadyExists){_logging.Logger.logDebug(`Skipping further Xcode modifications as framework target was already present`);return xcodeConfig;}(0,_xcodeHelpers.copyBundleReactNativePhase)(project,frameworkTargetUUID);if(isExpoPre55){_logging.Logger.logDebug(`Adding ExpoModulesProvider patch phase for Expo SDK ${config.sdkVersion}`);(0,_xcodeHelpers.addExpoPre55ShellPatchScriptPhase)(modRequest,project,{frameworkName:props.ios.frameworkName,frameworkTargetUUID:frameworkTargetUUID});}else{_logging.Logger.logDebug(`Skipping ExpoModulesProvider patch phase for Expo SDK ${config.sdkVersion}`);}(0,_xcodeHelpers.addSourceFilesBuildPhase)(project,frameworkTargetUUID,props.ios);return xcodeConfig;});config=(0,_configPlugins.withPodfile)(config,function(podfileConfig){var frameworkName=props.ios.frameworkName;podfileConfig.modResults.contents=(0,_podfileHelpers.modifyPodfile)(podfileConfig.modResults.contents,frameworkName,expoMajor);return podfileConfig;});config=(0,_withIosFrameworkFiles.withIosFrameworkFiles)(config,props);return config;};
|
|
2
2
|
//# sourceMappingURL=withBrownfieldIos.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["_configPlugins","require","_xcodeHelpers","_podfileHelpers","_withIosFrameworkFiles","_logging","_expoUtils","withBrownfieldIos","exports","config","props","_getExpoInfo","getExpoInfo","isExpoPre55","expoMajor","withXcodeProject","xcodeConfig","project","modResults","modRequest","_addFrameworkTarget","addFrameworkTarget","ios","frameworkTargetUUID","targetAlreadyExists","Logger","logDebug","copyBundleReactNativePhase","sdkVersion","addExpoPre55ShellPatchScriptPhase","frameworkName","addSourceFilesBuildPhase","withPodfile","podfileConfig","contents","modifyPodfile","withIosFrameworkFiles"],"sourceRoot":"../../../../src","sources":["expo-config-plugin/ios/withBrownfieldIos.ts"],"mappings":"0FAAA,IAAAA,cAAA,CAAAC,OAAA,yBAMA,IAAAC,aAAA,CAAAD,OAAA,mBAMA,IAAAE,eAAA,CAAAF,OAAA,qBACA,IAAAG,
|
|
1
|
+
{"version":3,"names":["_configPlugins","require","_xcodeHelpers","_podfileHelpers","_expoUpdates","_withIosFrameworkFiles","_logging","_expoUtils","withBrownfieldIos","exports","config","props","_getExpoInfo","getExpoInfo","isExpoPre55","expoMajor","withXcodeProject","xcodeConfig","project","modResults","modRequest","hasExpoUpdates","hasExpoUpdatesInstalled","projectRoot","_addFrameworkTarget","addFrameworkTarget","ios","frameworkTargetUUID","targetAlreadyExists","ensureFrameworkHasExpoPlistResource","Logger","logDebug","copyBundleReactNativePhase","sdkVersion","addExpoPre55ShellPatchScriptPhase","frameworkName","addSourceFilesBuildPhase","withPodfile","podfileConfig","contents","modifyPodfile","withIosFrameworkFiles"],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ACpB,CAGA,GAAAe,wCAA0B,EAACd,OAAO,CAAES,mBAAmB,CAAC,CAGxD,GAAIb,WAAW,CAAE,CACfgB,eAAM,CAACC,QAAQ,CACb,uDAAuDrB,MAAM,CAACuB,UAAU,EAC1E,CAAC,CAED,GAAAC,+CAAiC,EAACd,UAAU,CAAEF,OAAO,CAAE,CACrDiB,aAAa,CAAExB,KAAK,CAACe,GAAG,CAACS,aAAa,CACtCR,mBAAmB,CAAEA,mBACvB,CAAC,CAAC,CACJ,CAAC,IAAM,CACLG,eAAM,CAACC,QAAQ,CACb,yDAAyDrB,MAAM,CAACuB,UAAU,EAC5E,CAAC,CACH,CAEA,GAAAG,sCAAwB,EAAClB,OAAO,CAAES,mBAAmB,CAAEhB,KAAK,CAACe,GAAG,CAAC,CAEjE,MAAO,CAAAT,WAAW,CACpB,CAAC,CAAC,CAGFP,MAAM,CAAG,GAAA2B,0BAAW,EAAC3B,MAAM,CAAE,SAAC4B,aAAa,CAAK,CAC9C,GAAQ,CAAAH,aAAa,CAAKxB,KAAK,CAACe,GAAG,CAA3BS,aAAa,CAErBG,aAAa,CAACnB,UAAU,CAACoB,QAAQ,CAAG,GAAAC,6BAAa,EAC/CF,aAAa,CAACnB,UAAU,CAACoB,QAAQ,CACjCJ,aAAa,CACbpB,SACF,CAAC,CAED,MAAO,CAAAuB,aAAa,CACtB,CAAC,CAAC,CAGF5B,MAAM,CAAG,GAAA+B,4CAAqB,EAAC/B,MAAM,CAAEC,KAAK,CAAC,CAE7C,MAAO,CAAAD,MAAM,CACf,CAAC","ignoreList":[]}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
var _interopRequireDefault=require("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(exports,"__esModule",{value:true});exports.addExpoPre55ShellPatchScriptPhase=addExpoPre55ShellPatchScriptPhase;exports.addFrameworkTarget=addFrameworkTarget;exports.addSourceFilesBuildPhase=addSourceFilesBuildPhase;exports.copyBundleReactNativePhase=copyBundleReactNativePhase;exports.ensureExpoPre55ShellPatchScriptPhaseIsOrdered=ensureExpoPre55ShellPatchScriptPhaseIsOrdered;var _slicedToArray2=_interopRequireDefault(require("@babel/runtime/helpers/slicedToArray"));var _nodePath=_interopRequireDefault(require("node:path"));var _configPlugins=require("@expo/config-plugins");var _logging=require("../logging");var _SourceModificationError=require("../errors/SourceModificationError");var _withIosFrameworkFiles=require("./withIosFrameworkFiles");var _engine=require("../template/engine");function addFrameworkTarget(project,modRequest,options){var frameworkName=options.frameworkName,bundleIdentifier=options.bundleIdentifier;var existingTarget=project.pbxTargetByName(frameworkName);if(existingTarget){var _Object$entries$find;_logging.Logger.logDebug(`Framework target "${frameworkName}" already exists, skipping creation`);var frameworkTargetUUID=(_Object$entries$find=Object.entries(project.pbxNativeTargetSection()).find(function(_ref){var _ref2=(0,_slicedToArray2.default)(_ref,2),_key=_ref2[0],value=_ref2[1];return(value==null?void 0:value.productReference)===existingTarget.productReference;}))==null?void 0:_Object$entries$find[0];if(!frameworkTargetUUID){throw new _SourceModificationError.SourceModificationError(`Failed to find framework target UUID for ${frameworkName}, although it can be resolved by name`);}return{frameworkTargetUUID:frameworkTargetUUID,targetAlreadyExists:true};}_logging.Logger.logDebug(`Adding iOS framework target: ${frameworkName}`);var frameworkTarget=project.addTarget(frameworkName,'framework',frameworkName,bundleIdentifier);if(!frameworkTarget){throw new _SourceModificationError.SourceModificationError(`Failed to create framework target: ${frameworkName}`);}var frameworkBuildConfigurations=project.pbxXCConfigurationList()[frameworkTarget.pbxNativeTarget.buildConfigurationList];var debugFrameworkConfigKey=frameworkBuildConfigurations.buildConfigurations.find(function(_ref3){var comment=_ref3.comment;return comment==='Debug';}).value;var releaseFrameworkConfigKey=frameworkBuildConfigurations.buildConfigurations.find(function(_ref4){var comment=_ref4.comment;return comment==='Release';}).value;var debugSettings=getFrameworkBuildSettings({configuration:'Debug'},options);var releaseSettings=getFrameworkBuildSettings({configuration:'Release'},options);var configs=project.pbxXCBuildConfigurationSection();for(var configName in configs){var sourceBuildSettings=configName===releaseFrameworkConfigKey?releaseSettings:configName===debugFrameworkConfigKey?debugSettings:null;if(sourceBuildSettings){var destinationBuildSettings=configs[configName].buildSettings;for(var key in sourceBuildSettings){destinationBuildSettings[key]=sourceBuildSettings[key];}_logging.Logger.logDebug(`Updated build settings for ${configName} configuration of target ${frameworkName}`);}}Object.entries(debugSettings).forEach(function(_ref5){var _ref6=(0,_slicedToArray2.default)(_ref5,2),key=_ref6[0],value=_ref6[1];project.updateBuildProperty(key,value,'Debug',frameworkName);});Object.entries(releaseSettings).forEach(function(_ref7){var _ref8=(0,_slicedToArray2.default)(_ref7,2),key=_ref8[0],value=_ref8[1];project.updateBuildProperty(key,value,'Release',frameworkName);});var filePaths=(0,_withIosFrameworkFiles.getFrameworkSourceFiles)(options).map(function(file){return file.relativePath;});var groupPath=_nodePath.default.join(modRequest.platformProjectRoot,frameworkName);_logging.Logger.logDebug(`Creating PBX group '${frameworkName}' under path '${groupPath}' with files: ${filePaths.join(', ')}`);var frameworkGroup=project.addPbxGroup(filePaths,frameworkName,groupPath);var mainGroupKey=project.getFirstProject().firstProject.mainGroup;project.addToPbxGroup(frameworkGroup.uuid,mainGroupKey);_logging.Logger.logInfo(`Successfully added framework target: ${frameworkName}`);return{frameworkTargetUUID:frameworkTarget.uuid,targetAlreadyExists:false};}function addSourceFilesBuildPhase(project,frameworkTargetUUID,options){var filePaths=(0,_withIosFrameworkFiles.getFrameworkSourceFiles)(options).map(function(file){return file.relativePath;});var sourceFiles=filePaths.filter(function(filePath){return!filePath.endsWith('.plist');});project.addBuildPhase(sourceFiles,'PBXSourcesBuildPhase',options.frameworkName,frameworkTargetUUID,'framework','""');}function getFrameworkBuildSettings(_ref9,_ref0){var configuration=_ref9.configuration;var bundleIdentifier=_ref0.bundleIdentifier,deploymentTarget=_ref0.deploymentTarget,frameworkName=_ref0.frameworkName,frameworkVersion=_ref0.frameworkVersion,customBuildSettings=_ref0.buildSettings;var isDebug=configuration==='Debug';return Object.assign({BUILD_LIBRARY_FOR_DISTRIBUTION:'YES',USER_SCRIPT_SANDBOXING:'NO',SKIP_INSTALL:'NO',ENABLE_MODULE_VERIFIER:'NO',PRODUCT_BUNDLE_IDENTIFIER:`"${bundleIdentifier}"`,IPHONEOS_DEPLOYMENT_TARGET:deploymentTarget,SWIFT_VERSION:'5.0',TARGETED_DEVICE_FAMILY:`"1,2"`,INFOPLIST_FILE:`${frameworkName}/Info.plist`,CURRENT_PROJECT_VERSION:`"${frameworkVersion}"`,PRODUCT_NAME:'"$(TARGET_NAME)"',SWIFT_OPTIMIZATION_LEVEL:isDebug?'-Onone':'-O'},customBuildSettings);}function copyBundleReactNativePhase(project,targetUuid){var buildPhaseName='Bundle React Native code and images';var shellScriptPhases=project.hash.project.objects.PBXShellScriptBuildPhase;if(!shellScriptPhases){throw new _SourceModificationError.SourceModificationError(`No shell script build phases found, skipping ${buildPhaseName}`);}var existingPhaseUuid=null;for(var key of Object.keys(shellScriptPhases)){if(key.endsWith('_comment'))continue;var phase=shellScriptPhases[key];if(phase.name===`"${buildPhaseName}"`||phase.name===buildPhaseName){existingPhaseUuid=key;break;}}if(!existingPhaseUuid){throw new _SourceModificationError.SourceModificationError(`Could not find "${buildPhaseName}" build phase, skipping`);}var nativeTargets=project.hash.project.objects.PBXNativeTarget;if(nativeTargets&&nativeTargets[targetUuid]){var target=nativeTargets[targetUuid];if(target.buildPhases){if(!target.buildPhases.some(function(phase){return phase.value===existingPhaseUuid;})){target.buildPhases.push({value:existingPhaseUuid,comment:buildPhaseName});_logging.Logger.logDebug(`Added "${buildPhaseName}" build phase to framework target ${target.name}`);}}}}function resolveAppTargetName(project,modRequest){var appTargets=_configPlugins.IOSConfig.Target.getNativeTargets(project).map(function(_ref1){var _target$name;var _ref10=(0,_slicedToArray2.default)(_ref1,2),target=_ref10[1];if(!_configPlugins.IOSConfig.Target.isTargetOfType(target,_configPlugins.IOSConfig.Target.TargetType.APPLICATION)){return null;}var name=_configPlugins.IOSConfig.XcodeUtils.unquote((_target$name=target.name)!=null?_target$name:'').trim();return name!=null?name:null;}).filter(function(name){return!!name;});if(appTargets.length===1){return appTargets[0];}else{_logging.Logger.logWarning('Multiple application targets found in the Xcode project. Falling back to the CNG-derived name from mod compiler.');}var cngDerivedProjectName=modRequest.projectName;if(cngDerivedProjectName&&appTargets.includes(cngDerivedProjectName)){return cngDerivedProjectName;}else{_logging.Logger.logWarning('CNG-derived name from mod compiler is not set or is not an application target. Falling back to the unfiltered-type target name.');}try{var _firstAppTarget$name;var _IOSConfig$Target$fin=_configPlugins.IOSConfig.Target.findFirstNativeTarget(project),_IOSConfig$Target$fin2=(0,_slicedToArray2.default)(_IOSConfig$Target$fin,2),firstAppTarget=_IOSConfig$Target$fin2[1];var name=_configPlugins.IOSConfig.XcodeUtils.unquote((_firstAppTarget$name=firstAppTarget.name)!=null?_firstAppTarget$name:'').trim();return name||null;}catch(_unused){_logging.Logger.logWarning('No first native target of any type found in the Xcode project. This was the last resort fallback.');}_logging.Logger.logError(`Could not determine the iOS app target name from the Xcode project. Please adjust your Xcode project to have exactly one application target.`);return null;}function addExpoPre55ShellPatchScriptPhase(modRequest,project,_ref11){var frameworkName=_ref11.frameworkName,frameworkTargetUUID=_ref11.frameworkTargetUUID;var resolvedAppTargetName=resolveAppTargetName(project,modRequest);_logging.Logger.logInfo(`Resolved iOS app target name: ${resolvedAppTargetName}`);if(!resolvedAppTargetName){throw new _SourceModificationError.SourceModificationError(`Could not determine the iOS app target name from the Xcode project.`);}project.addBuildPhase([],'PBXShellScriptBuildPhase','Patch ExpoModulesProvider',frameworkTargetUUID,{shellPath:'/bin/sh',shellScript:(0,_engine.renderTemplate)('ios','patchExpoPre55.sh',{'{{APP_TARGET_NAME}}':resolvedAppTargetName,'{{FRAMEWORK_NAME}}':frameworkName})});}function ensureExpoPre55ShellPatchScriptPhaseIsOrdered(project,frameworkTargetUUID){var modified=false;var nativeTargetSection=project.pbxNativeTargetSection();var buildPhases=nativeTargetSection[frameworkTargetUUID].buildPhases;var expoConfigurePhaseIndex=buildPhases.findIndex(function(phase){var _comment;return(phase==null||(_comment=phase.comment)==null?void 0:_comment.toLowerCase())==='[Expo] Configure project'.toLowerCase();});var patchExpoModulesProviderPhaseIndex=buildPhases.findIndex(function(phase){var _comment2;return(phase==null||(_comment2=phase.comment)==null?void 0:_comment2.toLowerCase())==='Patch ExpoModulesProvider'.toLowerCase();});if(patchExpoModulesProviderPhaseIndex<expoConfigurePhaseIndex){var element=buildPhases.splice(patchExpoModulesProviderPhaseIndex,1)[0];buildPhases.splice(expoConfigurePhaseIndex,0,element);modified=true;}nativeTargetSection[frameworkTargetUUID].buildPhases=buildPhases;project.writeSync();return modified;}
|
|
1
|
+
var _interopRequireDefault=require("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(exports,"__esModule",{value:true});exports.addExpoPre55ShellPatchScriptPhase=addExpoPre55ShellPatchScriptPhase;exports.addFrameworkTarget=addFrameworkTarget;exports.addSourceFilesBuildPhase=addSourceFilesBuildPhase;exports.copyBundleReactNativePhase=copyBundleReactNativePhase;exports.createPbxCommentedReference=createPbxCommentedReference;exports.ensureExpoPre55ShellPatchScriptPhaseIsOrdered=ensureExpoPre55ShellPatchScriptPhaseIsOrdered;exports.ensureTargetHasFileReferenceInResourcesBuildPhase=ensureTargetHasFileReferenceInResourcesBuildPhase;var _slicedToArray2=_interopRequireDefault(require("@babel/runtime/helpers/slicedToArray"));var _nodePath=_interopRequireDefault(require("node:path"));var _configPlugins=require("@expo/config-plugins");var _logging=require("../logging");var _SourceModificationError=require("../errors/SourceModificationError");var _withIosFrameworkFiles=require("./withIosFrameworkFiles");var _engine=require("../template/engine");function addFrameworkTarget(project,modRequest,options){var frameworkName=options.frameworkName,bundleIdentifier=options.bundleIdentifier;var existingTarget=project.pbxTargetByName(frameworkName);if(existingTarget){var _Object$entries$find;_logging.Logger.logDebug(`Framework target "${frameworkName}" already exists, skipping creation`);var frameworkTargetUUID=(_Object$entries$find=Object.entries(project.pbxNativeTargetSection()).find(function(_ref){var _ref2=(0,_slicedToArray2.default)(_ref,2),_key=_ref2[0],value=_ref2[1];return(value==null?void 0:value.productReference)===existingTarget.productReference;}))==null?void 0:_Object$entries$find[0];if(!frameworkTargetUUID){throw new _SourceModificationError.SourceModificationError(`Failed to find framework target UUID for ${frameworkName}, although it can be resolved by name`);}return{frameworkTargetUUID:frameworkTargetUUID,targetAlreadyExists:true};}_logging.Logger.logDebug(`Adding iOS framework target: ${frameworkName}`);var frameworkTarget=project.addTarget(frameworkName,'framework',frameworkName,bundleIdentifier);if(!frameworkTarget){throw new _SourceModificationError.SourceModificationError(`Failed to create framework target: ${frameworkName}`);}var frameworkBuildConfigurations=project.pbxXCConfigurationList()[frameworkTarget.pbxNativeTarget.buildConfigurationList];var debugFrameworkConfigKey=frameworkBuildConfigurations.buildConfigurations.find(function(_ref3){var comment=_ref3.comment;return comment==='Debug';}).value;var releaseFrameworkConfigKey=frameworkBuildConfigurations.buildConfigurations.find(function(_ref4){var comment=_ref4.comment;return comment==='Release';}).value;var debugSettings=getFrameworkBuildSettings({configuration:'Debug'},options);var releaseSettings=getFrameworkBuildSettings({configuration:'Release'},options);var configs=project.pbxXCBuildConfigurationSection();for(var configName in configs){var sourceBuildSettings=configName===releaseFrameworkConfigKey?releaseSettings:configName===debugFrameworkConfigKey?debugSettings:null;if(sourceBuildSettings){var destinationBuildSettings=configs[configName].buildSettings;for(var key in sourceBuildSettings){destinationBuildSettings[key]=sourceBuildSettings[key];}_logging.Logger.logDebug(`Updated build settings for ${configName} configuration of target ${frameworkName}`);}}Object.entries(debugSettings).forEach(function(_ref5){var _ref6=(0,_slicedToArray2.default)(_ref5,2),key=_ref6[0],value=_ref6[1];project.updateBuildProperty(key,value,'Debug',frameworkName);});Object.entries(releaseSettings).forEach(function(_ref7){var _ref8=(0,_slicedToArray2.default)(_ref7,2),key=_ref8[0],value=_ref8[1];project.updateBuildProperty(key,value,'Release',frameworkName);});var filePaths=(0,_withIosFrameworkFiles.getFrameworkSourceFiles)(options).map(function(file){return file.relativePath;});var groupPath=_nodePath.default.join(modRequest.platformProjectRoot,frameworkName);_logging.Logger.logDebug(`Creating PBX group '${frameworkName}' under path '${groupPath}' with files: ${filePaths.join(', ')}`);var frameworkGroup=project.addPbxGroup(filePaths,frameworkName,groupPath);var mainGroupKey=project.getFirstProject().firstProject.mainGroup;project.addToPbxGroup(frameworkGroup.uuid,mainGroupKey);_logging.Logger.logInfo(`Successfully added framework target: ${frameworkName}`);return{frameworkTargetUUID:frameworkTarget.uuid,targetAlreadyExists:false};}function addSourceFilesBuildPhase(project,frameworkTargetUUID,options){var filePaths=(0,_withIosFrameworkFiles.getFrameworkSourceFiles)(options).map(function(file){return file.relativePath;});var sourceFiles=filePaths.filter(function(filePath){return!filePath.endsWith('.plist');});project.addBuildPhase(sourceFiles,'PBXSourcesBuildPhase',options.frameworkName,frameworkTargetUUID,'framework','""');}var PBX_BUILD_ACTION_MASK_ALL=2147483647;var PBX_RUN_ONLY_FOR_DEPLOYMENT_POSTPROCESSING_DISABLED=0;var PBX_RESOURCES_BUILD_PHASE_ISA='PBXResourcesBuildPhase';var PBX_BUILD_FILE_ISA='PBXBuildFile';function createPbxCommentedReference(value,comment){return{value:value,comment:comment};}function createResourcesBuildPhase(){return{isa:PBX_RESOURCES_BUILD_PHASE_ISA,buildActionMask:PBX_BUILD_ACTION_MASK_ALL,files:[],runOnlyForDeploymentPostprocessing:PBX_RUN_ONLY_FOR_DEPLOYMENT_POSTPROCESSING_DISABLED};}function createBuildFile(fileRef){return{isa:PBX_BUILD_FILE_ISA,fileRef:fileRef};}function getRawProjectObjects(project){var _hash$project$objects,_hash;return(_hash$project$objects=(_hash=project.hash)==null||(_hash=_hash.project)==null?void 0:_hash.objects)!=null?_hash$project$objects:{};}function getReferencedUuid(reference){var _reference$value;if(!reference){return null;}return typeof reference==='string'?reference:(_reference$value=reference.value)!=null?_reference$value:null;}function getFrameworkTargetOrThrow(project,frameworkTargetUUID){var nativeTargets=getRawProjectObjects(project).PBXNativeTarget;var frameworkTarget=nativeTargets==null?void 0:nativeTargets[frameworkTargetUUID];if(!frameworkTarget){throw new _SourceModificationError.SourceModificationError(`Framework target UUID "${frameworkTargetUUID}" not found while wiring a resources build phase`);}return frameworkTarget;}function getOrCreateResourcesBuildPhaseForTarget(project,frameworkTargetUUID,frameworkTarget,resourcesBuildPhaseComment){var _rawProjectObjects$PB,_frameworkTarget$buil;var rawProjectObjects=getRawProjectObjects(project);var resourceBuildPhases=(_rawProjectObjects$PB=rawProjectObjects.PBXResourcesBuildPhase)!=null?_rawProjectObjects$PB:rawProjectObjects.PBXResourcesBuildPhase={};var resourcesBuildPhaseUuid=((_frameworkTarget$buil=frameworkTarget.buildPhases)!=null?_frameworkTarget$buil:[]).map(function(phase){return getReferencedUuid(phase);}).find(function(phaseUuid){return!!phaseUuid&&!!resourceBuildPhases[phaseUuid];});if(resourcesBuildPhaseUuid){return resourceBuildPhases[resourcesBuildPhaseUuid];}var createdResourcesBuildPhaseUuid=project.generateUuid();resourceBuildPhases[createdResourcesBuildPhaseUuid]=createResourcesBuildPhase();resourceBuildPhases[`${createdResourcesBuildPhaseUuid}_comment`]=resourcesBuildPhaseComment;var targetBuildPhases=Array.isArray(frameworkTarget.buildPhases)?frameworkTarget.buildPhases:[];targetBuildPhases.push(createPbxCommentedReference(createdResourcesBuildPhaseUuid,resourcesBuildPhaseComment));frameworkTarget.buildPhases=targetBuildPhases;_logging.Logger.logDebug(`Created missing PBXResourcesBuildPhase for framework target "${frameworkTargetUUID}"`);return resourceBuildPhases[createdResourcesBuildPhaseUuid];}function hasBuildFileForFileRef(project,resourcesBuildPhase,fileRefUuid){var buildFileSection=project.pbxBuildFileSection();var files=Array.isArray(resourcesBuildPhase.files)?resourcesBuildPhase.files:[];return files.some(function(phaseFile){var _buildFileSection$bui;var buildFileUuid=getReferencedUuid(phaseFile);if(!buildFileUuid){return false;}return((_buildFileSection$bui=buildFileSection[buildFileUuid])==null?void 0:_buildFileSection$bui.fileRef)===fileRefUuid;});}function addBuildFileToResourcesPhase(project,resourcesBuildPhase,fileRefUuid,buildFileComment){var buildFileSection=project.pbxBuildFileSection();var buildFileUuid=project.generateUuid();buildFileSection[buildFileUuid]=createBuildFile(fileRefUuid);buildFileSection[`${buildFileUuid}_comment`]=buildFileComment;var files=Array.isArray(resourcesBuildPhase.files)?resourcesBuildPhase.files:[];files.push(createPbxCommentedReference(buildFileUuid,buildFileComment));resourcesBuildPhase.files=files;}function ensureTargetHasFileReferenceInResourcesBuildPhase(project,frameworkTargetUUID,fileRefUuid,_ref9){var resourcesBuildPhaseComment=_ref9.resourcesBuildPhaseComment,buildFileComment=_ref9.buildFileComment;var frameworkTarget=getFrameworkTargetOrThrow(project,frameworkTargetUUID);var resourcesBuildPhase=getOrCreateResourcesBuildPhaseForTarget(project,frameworkTargetUUID,frameworkTarget,resourcesBuildPhaseComment);if(hasBuildFileForFileRef(project,resourcesBuildPhase,fileRefUuid)){return false;}addBuildFileToResourcesPhase(project,resourcesBuildPhase,fileRefUuid,buildFileComment);return true;}function getFrameworkBuildSettings(_ref0,_ref1){var configuration=_ref0.configuration;var bundleIdentifier=_ref1.bundleIdentifier,deploymentTarget=_ref1.deploymentTarget,frameworkName=_ref1.frameworkName,frameworkVersion=_ref1.frameworkVersion,customBuildSettings=_ref1.buildSettings;var isDebug=configuration==='Debug';return Object.assign({BUILD_LIBRARY_FOR_DISTRIBUTION:'YES',USER_SCRIPT_SANDBOXING:'NO',SKIP_INSTALL:'NO',ENABLE_MODULE_VERIFIER:'NO',PRODUCT_BUNDLE_IDENTIFIER:`"${bundleIdentifier}"`,IPHONEOS_DEPLOYMENT_TARGET:deploymentTarget,SWIFT_VERSION:'5.0',TARGETED_DEVICE_FAMILY:`"1,2"`,INFOPLIST_FILE:`${frameworkName}/Info.plist`,CURRENT_PROJECT_VERSION:`"${frameworkVersion}"`,PRODUCT_NAME:'"$(TARGET_NAME)"',SWIFT_OPTIMIZATION_LEVEL:isDebug?'-Onone':'-O'},customBuildSettings);}function copyBundleReactNativePhase(project,targetUuid){var buildPhaseName='Bundle React Native code and images';var shellScriptPhases=project.hash.project.objects.PBXShellScriptBuildPhase;if(!shellScriptPhases){throw new _SourceModificationError.SourceModificationError(`No shell script build phases found, skipping ${buildPhaseName}`);}var existingPhaseUuid=null;for(var key of Object.keys(shellScriptPhases)){if(key.endsWith('_comment'))continue;var phase=shellScriptPhases[key];if(phase.name===`"${buildPhaseName}"`||phase.name===buildPhaseName){existingPhaseUuid=key;break;}}if(!existingPhaseUuid){throw new _SourceModificationError.SourceModificationError(`Could not find "${buildPhaseName}" build phase, skipping`);}var nativeTargets=project.hash.project.objects.PBXNativeTarget;if(nativeTargets&&nativeTargets[targetUuid]){var target=nativeTargets[targetUuid];if(target.buildPhases){if(!target.buildPhases.some(function(phase){return phase.value===existingPhaseUuid;})){target.buildPhases.push(createPbxCommentedReference(existingPhaseUuid,buildPhaseName));_logging.Logger.logDebug(`Added "${buildPhaseName}" build phase to framework target ${target.name}`);}}}}function resolveAppTargetName(project,modRequest){var appTargets=_configPlugins.IOSConfig.Target.getNativeTargets(project).map(function(_ref10){var _target$name;var _ref11=(0,_slicedToArray2.default)(_ref10,2),target=_ref11[1];if(!_configPlugins.IOSConfig.Target.isTargetOfType(target,_configPlugins.IOSConfig.Target.TargetType.APPLICATION)){return null;}var name=_configPlugins.IOSConfig.XcodeUtils.unquote((_target$name=target.name)!=null?_target$name:'').trim();return name!=null?name:null;}).filter(function(name){return!!name;});if(appTargets.length===1){return appTargets[0];}else{_logging.Logger.logWarning('Multiple application targets found in the Xcode project. Falling back to the CNG-derived name from mod compiler.');}var cngDerivedProjectName=modRequest.projectName;if(cngDerivedProjectName&&appTargets.includes(cngDerivedProjectName)){return cngDerivedProjectName;}else{_logging.Logger.logWarning('CNG-derived name from mod compiler is not set or is not an application target. Falling back to the unfiltered-type target name.');}try{var _firstAppTarget$name;var _IOSConfig$Target$fin=_configPlugins.IOSConfig.Target.findFirstNativeTarget(project),_IOSConfig$Target$fin2=(0,_slicedToArray2.default)(_IOSConfig$Target$fin,2),firstAppTarget=_IOSConfig$Target$fin2[1];var name=_configPlugins.IOSConfig.XcodeUtils.unquote((_firstAppTarget$name=firstAppTarget.name)!=null?_firstAppTarget$name:'').trim();return name||null;}catch(_unused){_logging.Logger.logWarning('No first native target of any type found in the Xcode project. This was the last resort fallback.');}_logging.Logger.logError(`Could not determine the iOS app target name from the Xcode project. Please adjust your Xcode project to have exactly one application target.`);return null;}function addExpoPre55ShellPatchScriptPhase(modRequest,project,_ref12){var frameworkName=_ref12.frameworkName,frameworkTargetUUID=_ref12.frameworkTargetUUID;var resolvedAppTargetName=resolveAppTargetName(project,modRequest);_logging.Logger.logInfo(`Resolved iOS app target name: ${resolvedAppTargetName}`);if(!resolvedAppTargetName){throw new _SourceModificationError.SourceModificationError(`Could not determine the iOS app target name from the Xcode project.`);}project.addBuildPhase([],'PBXShellScriptBuildPhase','Patch ExpoModulesProvider',frameworkTargetUUID,{shellPath:'/bin/sh',shellScript:(0,_engine.renderTemplate)('ios','patchExpoPre55.sh',{'{{APP_TARGET_NAME}}':resolvedAppTargetName,'{{FRAMEWORK_NAME}}':frameworkName})});}function ensureExpoPre55ShellPatchScriptPhaseIsOrdered(project,frameworkTargetUUID){var modified=false;var nativeTargetSection=project.pbxNativeTargetSection();var buildPhases=nativeTargetSection[frameworkTargetUUID].buildPhases;var expoConfigurePhaseIndex=buildPhases.findIndex(function(phase){var _comment;return(phase==null||(_comment=phase.comment)==null?void 0:_comment.toLowerCase())==='[Expo] Configure project'.toLowerCase();});var patchExpoModulesProviderPhaseIndex=buildPhases.findIndex(function(phase){var _comment2;return(phase==null||(_comment2=phase.comment)==null?void 0:_comment2.toLowerCase())==='Patch ExpoModulesProvider'.toLowerCase();});if(patchExpoModulesProviderPhaseIndex<expoConfigurePhaseIndex){var element=buildPhases.splice(patchExpoModulesProviderPhaseIndex,1)[0];buildPhases.splice(expoConfigurePhaseIndex,0,element);modified=true;}nativeTargetSection[frameworkTargetUUID].buildPhases=buildPhases;project.writeSync();return modified;}
|
|
2
2
|
//# sourceMappingURL=xcodeHelpers.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["_nodePath","_interopRequireDefault","require","_configPlugins","_logging","_SourceModificationError","_withIosFrameworkFiles","_engine","addFrameworkTarget","project","modRequest","options","frameworkName","bundleIdentifier","existingTarget","pbxTargetByName","_Object$entries$find","Logger","logDebug","frameworkTargetUUID","Object","entries","pbxNativeTargetSection","find","_ref","_ref2","_slicedToArray2","default","_key","value","productReference","SourceModificationError","targetAlreadyExists","frameworkTarget","addTarget","frameworkBuildConfigurations","pbxXCConfigurationList","pbxNativeTarget","buildConfigurationList","debugFrameworkConfigKey","buildConfigurations","_ref3","comment","releaseFrameworkConfigKey","_ref4","debugSettings","getFrameworkBuildSettings","configuration","releaseSettings","configs","pbxXCBuildConfigurationSection","configName","sourceBuildSettings","destinationBuildSettings","buildSettings","key","forEach","_ref5","_ref6","updateBuildProperty","_ref7","_ref8","filePaths","getFrameworkSourceFiles","map","file","relativePath","groupPath","path","join","platformProjectRoot","frameworkGroup","addPbxGroup","mainGroupKey","getFirstProject","firstProject","mainGroup","addToPbxGroup","uuid","logInfo","addSourceFilesBuildPhase","sourceFiles","filter","filePath","endsWith","addBuildPhase","_ref9","_ref0","deploymentTarget","frameworkVersion","customBuildSettings","isDebug","assign","BUILD_LIBRARY_FOR_DISTRIBUTION","USER_SCRIPT_SANDBOXING","SKIP_INSTALL","ENABLE_MODULE_VERIFIER","PRODUCT_BUNDLE_IDENTIFIER","IPHONEOS_DEPLOYMENT_TARGET","SWIFT_VERSION","TARGETED_DEVICE_FAMILY","INFOPLIST_FILE","CURRENT_PROJECT_VERSION","PRODUCT_NAME","SWIFT_OPTIMIZATION_LEVEL","copyBundleReactNativePhase","targetUuid","buildPhaseName","shellScriptPhases","hash","objects","PBXShellScriptBuildPhase","existingPhaseUuid","keys","phase","name","nativeTargets","PBXNativeTarget","target","buildPhases","some","push","resolveAppTargetName","appTargets","IOSConfig","Target","getNativeTargets","_ref1","_target$name","_ref10","isTargetOfType","TargetType","APPLICATION","XcodeUtils","unquote","trim","length","logWarning","cngDerivedProjectName","projectName","includes","_firstAppTarget$name","_IOSConfig$Target$fin","findFirstNativeTarget","_IOSConfig$Target$fin2","firstAppTarget","_unused","logError","addExpoPre55ShellPatchScriptPhase","_ref11","resolvedAppTargetName","shellPath","shellScript","renderTemplate","ensureExpoPre55ShellPatchScriptPhaseIsOrdered","modified","nativeTargetSection","expoConfigurePhaseIndex","findIndex","_comment","toLowerCase","patchExpoModulesProviderPhaseIndex","_comment2","element","splice","writeSync"],"sourceRoot":"../../../../src","sources":["expo-config-plugin/ios/xcodeHelpers.ts"],"mappings":"8jBAAA,IAAAA,SAAA,CAAAC,sBAAA,CAAAC,OAAA,eAEA,IAAAC,cAAA,CAAAD,OAAA,yBAMA,IAAAE,QAAA,CAAAF,OAAA,eAEA,IAAAG,wBAAA,CAAAH,OAAA,sCACA,IAAAI,sBAAA,CAAAJ,OAAA,4BACA,IAAAK,OAAA,CAAAL,OAAA,uBAQO,QAAS,CAAAM,kBAAkBA,CAChCC,OAAqB,CACrBC,UAAkC,CAClCC,OAA0C,CAI1C,CACA,GAAQ,CAAAC,aAAa,CAAuBD,OAAO,CAA3CC,aAAa,CAAEC,gBAAgB,CAAKF,OAAO,CAA5BE,gBAAgB,CAGvC,GAAM,CAAAC,cAAc,CAAGL,OAAO,CAACM,eAAe,CAACH,aAAa,CAAC,CAC7D,GAAIE,cAAc,CAAE,KAAAE,oBAAA,CAClBC,eAAM,CAACC,QAAQ,CACb,qBAAqBN,aAAa,qCACpC,CAAC,CAED,GAAM,CAAAO,mBAAmB,EAAAH,oBAAA,CAAGI,MAAM,CAACC,OAAO,CACxCZ,OAAO,CAACa,sBAAsB,CAAC,CACjC,CAAC,CAACC,IAAI,CACJ,SAAAC,IAAA,MAAAC,KAAA,IAAAC,eAAA,CAAAC,OAAA,EAAAH,I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C,CAE5D,GAAM,CAAAiG,WAAkD,CACtDqC,mBAAmB,CAACzI,mBAAmB,CAAC,CAACoG,WAAW,CAEtD,GAAM,CAAAsC,uBAAuB,CAAGtC,WAAW,CAACuC,SAAS,CACnD,SAAC5C,KAAK,MAAA6C,QAAA,OACJ,CAAC7C,KAAK,SAAA6C,QAAA,CAAL7C,KAAK,CAAUxE,OAAO,eAAvBqH,QAAA,CAAyBC,WAAW,CAAC,CAAC,IACtC,0BAA0B,CAACA,WAAW,CAAC,CAAC,EAC5C,CAAC,CAED,GAAM,CAAAC,kCAAkC,CAAG1C,WAAW,CAACuC,SAAS,CAC9D,SAAC5C,KAAK,MAAAgD,SAAA,OACJ,CAAChD,KAAK,SAAAgD,SAAA,CAALhD,KAAK,CAAUxE,OAAO,eAAvBwH,SAAA,CAAyBF,WAAW,CAAC,CAAC,IACtC,2BAA2B,CAACA,WAAW,CAAC,CAAC,EAC7C,CAAC,CAGD,GAAIC,kCAAkC,CAAGJ,uBAAuB,CAAE,CAChE,GAAM,CAAAM,OAAO,CAAG5C,WAAW,CAAC6C,MAAM,CAChCH,kCAAkC,CAClC,CACF,CAAC,CAAC,CAAC,CAAC,CACJ1C,WAAW,CAAC6C,MAAM,CAACP,uBAAuB,CAAE,CAAC,CAAEM,OAAO,CAAC,CACvDR,QAAQ,CAAG,IAAI,CACjB,CAEAC,mBAAmB,CAACzI,mBAAmB,CAAC,CAACoG,WAAW,CAAGA,WAAW,CAElE9G,OAAO,CAAC4J,SAAS,CAAC,CAAC,CAEnB,MAAO,CAAAV,QAAQ,CACjB","ignoreList":[]}
|
|
1
|
+
{"version":3,"names":["_nodePath","_interopRequireDefault","require","_configPlugins","_logging","_SourceModificationError","_withIosFrameworkFiles","_engine","addFrameworkTarget","project","modRequest","options","frameworkName","bundleIdentifier","existingTarget","pbxTargetByName","_Object$entries$find","Logger","logDebug","frameworkTargetUUID","Object","entries","pbxNativeTargetSection","find","_ref","_ref2","_slicedToArray2","default","_key","value","productReference","SourceModificationError","targetAlreadyExists","frameworkTarget","addTarget","frameworkBuildConfigurations","pbxXCConfigurationList","pbxNativeTarget","buildConfigurationList","debugFrameworkConfigKey","buildConfigurations","_ref3","comment","releaseFrameworkConfigKey","_ref4","debugSettings","getFrameworkBuildSettings","configuration","releaseSettings","configs","pbxXCBuildConfigurationSection","configName","sourceBuildSettings","destinationBuildSettings","buildSettings","key","forEach","_ref5","_ref6","updateBuildProperty","_ref7","_ref8","filePaths","getFrameworkSourceFiles","map","file","relativePath","groupPath","path","join","platformProjectRoot","frameworkGroup","addPbxGroup","mainGroupKey","getFirstProject","firstProject","mainGroup","addToPbxGroup","uuid","logInfo","addSourceFilesBuildPhase","sourceFiles","filter","filePath","endsWith","addBuildPhase","PBX_BUILD_ACTION_MASK_ALL","PBX_RUN_ONLY_FOR_DEPLOYMENT_POSTPROCESSING_DISABLED","PBX_RESOURCES_BUILD_PHASE_ISA","PBX_BUILD_FILE_ISA","createPbxCommentedReference","createResourcesBuildPhase","isa","buildActionMask","files","runOnlyForDeploymentPostprocessing","createBuildFile","fileRef","getRawProjectObjects","_hash$project$objects","_hash","hash","objects","getReferencedUuid","reference","_reference$value","getFrameworkTargetOrThrow","nativeTargets","PBXNativeTarget","getOrCreateResourcesBuildPhaseForTarget","resourcesBuildPhaseComment","_rawProjectObjects$PB","_frameworkTarget$buil","rawProjectObjects","resourceBuildPhases","PBXResourcesBuildPhase","resourcesBuildPhaseUuid","buildPhases","phase","phaseUuid","createdResourcesBuildPhaseUuid","generateUuid","targetBuildPhases","Array","isArray","push","hasBuildFileForFileRef","resourcesBuildPhase","fileRefUuid","buildFileSection","pbxBuildFileSection","some","phaseFile","_buildFileSection$bui","buildFileUuid","addBuildFileToResourcesPhase","buildFileComment","ensureTargetHasFileReferenceInResourcesBuildPhase","_ref9","_ref0","_ref1","deploymentTarget","frameworkVersion","customBuildSettings","isDebug","assign","BUILD_LIBRARY_FOR_DISTRIBUTION","USER_SCRIPT_SANDBOXING","SKIP_INSTALL","ENABLE_MODULE_VERIFIER","PRODUCT_BUNDLE_IDENTIFIER","IPHONEOS_DEPLOYMENT_TARGET","SWIFT_VERSION","TARGETED_DEVICE_FAMILY","INFOPLIST_FILE","CURRENT_PROJECT_VERSION","PRODUCT_NAME","SWIFT_OPTIMIZATION_LEVEL","copyBundleReactNativePhase","targetUuid","buildPhaseName","shellScriptPhases","PBXShellScriptBuildPhase","existingPhaseUuid","keys","name","target","resolveAppTargetName","appTargets","IOSConfig","Target","getNativeTargets","_ref10","_target$name","_ref11","isTargetOfType","TargetType","APPLICATION","XcodeUtils","unquote","trim","length","logWarning","cngDerivedProjectName","projectName","includes","_firstAppTarget$name","_IOSConfig$Target$fin","findFirstNativeTarget","_IOSConfig$Target$fin2","firstAppTarget","_unused","logError","addExpoPre55ShellPatchScriptPhase","_ref12","resolvedAppTargetName","shellPath","shellScript","renderTemplate","ensureExpoPre55ShellPatchScriptPhaseIsOrdered","modified","nativeTargetSection","expoConfigurePhaseIndex","findIndex","_comment","toLowerCase","patchExpoModulesProviderPhaseIndex","_comment2","element","splice","writeSync"],"sourceRoot":"../../../../src","sources":["expo-config-plugin/ios/xcodeHelpers.ts"],"mappings":"0uBAAA,IAAAA,SAAA,CAAAC,sBAAA,CAAAC,OAAA,eAEA,IAAAC,cAAA,CAAAD,OAAA,yBAMA,IAAAE,QAAA,CAAAF,OAAA,eAEA,IAAAG,wBAAA,CAAAH,OAAA,sCACA,IAAAI,sBAAA,CAAAJ,OAAA,4BACA,IAAAK,OAAA,CAAAL,OAAA,uBAQO,QAAS,CAAAM,kBAAkBA,CAChCC,OAAqB,CACrBC,UAAkC,CAClCC,OAA0C,CAI1C,CACA,GAAQ,CAAAC,aAAa,CAAuBD,OAAO,CAA3CC,aAAa,CAAEC,gBAAgB,CAAKF,OAAO,CAA5BE,gBAAgB,CAGvC,GAAM,CAAAC,cAAc,CAAGL,OAAO,CAACM,eAAe,CAACH,aAAa,CAAC,CAC7D,GAAIE,cAAc,CAAE,KAAAE,oBA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