diff --git a/.travis.yml b/.travis.yml index 0f12e0a..05a549d 100644 --- a/.travis.yml +++ b/.travis.yml @@ -9,7 +9,7 @@ matrix: os: osx env: - WebPack="iOS" - osx_image: xcode10.2 + osx_image: xcode12.2 language: node_js node_js: "10" jdk: oraclejdk8 @@ -23,15 +23,15 @@ matrix: jdk: oraclejdk8 before_install: nvm install 10 script: - - cd src && npm i && npm run preparedemo && cd ../demo && tns build android + - cd src && npm i && npm run preparedemo && cd ../demo-ng && tns build android - os: osx - osx_image: xcode10.2 + osx_image: xcode12.2 language: node_js node_js: "10" jdk: oraclejdk8 before_script: pod repo update script: - - cd src && npm i && npm run preparedemo && cd ../demo && tns build ios + - cd src && npm i && npm run preparedemo && cd ../demo-ng && tns build ios android: components: diff --git a/demo-ng/package.json b/demo-ng/package.json index e8a711f..bec97d4 100644 --- a/demo-ng/package.json +++ b/demo-ng/package.json @@ -5,7 +5,7 @@ "version": "6.2.0" }, "tns-ios": { - "version": "6.2.0" + "version": "6.5.4" } }, "description": "NativeScript Application", @@ -43,17 +43,19 @@ "@angular/platform-browser-dynamic": "~8.2.3", "@angular/router": "~8.2.3", "nativescript-angular": "~8.2.0", - "nativescript-app-sync": "file:../publish/package/nativescript-app-sync-2.0.0.tgz", + "nativescript-app-sync": "file:../publish/package/nativescript-app-sync-3.0.0.tgz", "nativescript-theme-core": "~1.0.6", "reflect-metadata": "~0.1.13", "rxjs": "~6.5.2", - "tns-core-modules": "~6.2.0", + "tns-core-modules": "~6.5.24", "zone.js": "~0.10.0" }, "devDependencies": { "@angular/compiler-cli": "~8.2.3", "@ngtools/webpack": "~8.2.2", "nativescript-dev-webpack": "~1.3.0", + "tns-android": "6.2.0", + "tns-ios": "6.5.4", "typescript": "~3.5.3" } } diff --git a/demo/package.json b/demo/package.json index b5697e0..9f56495 100644 --- a/demo/package.json +++ b/demo/package.json @@ -5,7 +5,7 @@ "version": "6.2.0" }, "tns-android": { - "version": "6.2.0" + "version": "6.5.4" } }, "scripts": { @@ -31,10 +31,10 @@ "ci.tslint": "npm i && tslint --config '../tslint.json' 'demoapp/**/*.ts' --exclude '**/node_modules/**' --exclude '**/typings/**'" }, "dependencies": { - "nativescript-app-sync": "file:../publish/package/nativescript-app-sync-2.0.0.tgz", + "nativescript-app-sync": "file:../publish/package/nativescript-app-sync-3.0.0.tgz", "nativescript-theme-core": "~1.0.4", "nativescript-unit-test-runner": "0.7.0", - "tns-core-modules": "~6.2.0" + "tns-core-modules": "~6.5.24" }, "devDependencies": { "babel-traverse": "6.26.0", @@ -45,11 +45,12 @@ "karma": "4.1.0", "karma-jasmine": "2.0.1", "karma-nativescript-launcher": "^0.4.0", + "karma-webpack": "3.0.5", "lazy": "1.0.11", "nativescript-dev-webpack": "1.3.0", + "tns-ios": "6.5.4", "tns-platform-declarations": "~6.2.0", "tslint": "~5.20.0", - "typescript": "~3.5.3", - "karma-webpack": "3.0.5" + "typescript": "~3.5.3" } } diff --git a/src/app-sync.ts b/src/app-sync.ts index 3982e80..c914ac8 100644 --- a/src/app-sync.ts +++ b/src/app-sync.ts @@ -101,7 +101,8 @@ export class AppSync { } // skip AppSync when HMR is detected, unless it's explicitly allowed - if (typeof (global).hmrRefresh === "function" && !options.enabledWhenUsingHmr) { + // @ts-ignore + if (Boolean(module.hot) && !options.enabledWhenUsingHmr) { syncCallback && syncCallback(SyncStatus.SKIPPING_BECAUSE_HMR_ENABLED); return; } @@ -299,17 +300,16 @@ export class AppSync { private static killApp(restartOnAndroid: boolean): void { if (Application.android) { if (restartOnAndroid) { + const packageManager = Application.android.context.getPackageManager(); + const intent = packageManager.getLaunchIntentForPackage(Application.android.context.getPackageName()); + const componentName = intent.getComponent(); + //noinspection JSUnresolvedFunction,JSUnresolvedVariable - const mStartActivity = new android.content.Intent(Application.android.context, Application.android.startActivity.getClass()); - const mPendingIntentId = parseInt("" + (Math.random() * 100000), 10); - //noinspection JSUnresolvedFunction,JSUnresolvedVariable - const mPendingIntent = android.app.PendingIntent.getActivity(Application.android.context, mPendingIntentId, mStartActivity, android.app.PendingIntent.FLAG_CANCEL_CURRENT); - //noinspection JSUnresolvedFunction,JSUnresolvedVariable - const mgr = Application.android.context.getSystemService(android.content.Context.ALARM_SERVICE); - //noinspection JSUnresolvedFunction,JSUnresolvedVariable - mgr.set(android.app.AlarmManager.RTC, java.lang.System.currentTimeMillis() + 100, mPendingIntent); + const mainIntent = new android.content.Intent.makeRestartActivityTask(componentName); + Application.android.context.startActivity(mainIntent); //noinspection JSUnresolvedFunction,JSUnresolvedVariable } + //noinspection JSUnresolvedFunction,JSUnresolvedVariable android.os.Process.killProcess(android.os.Process.myPid()); } else if (Application.ios) { exit(0); diff --git a/src/package.json b/src/package.json index f9705a2..4cf4a58 100644 --- a/src/package.json +++ b/src/package.json @@ -1,6 +1,6 @@ { "name": "nativescript-app-sync", - "version": "2.0.0", + "version": "3.0.0", "description": "Use AppSync to hot deploy updates to your app.", "main": "app-sync", "typings": "index.d.ts", @@ -11,7 +11,7 @@ }, "hooks": [ { - "type": "before-prepare", + "type": "after-prepare", "script": "scripts/ios/appsync-ios.js", "inject": true }, @@ -70,7 +70,7 @@ "dependencies": { "nativescript-app-sync-sdk": "~1.0.1", "nativescript-appversion": "~1.4.4", - "nativescript-hook": "~0.2.5", + "nativescript-hook": "git://github.com/NativeScript/nativescript-hook.git#feat/ns7", "nativescript-zip": "~4.0.2" }, "devDependencies": { diff --git a/src/platforms/ios/AppSync.framework/AppSync b/src/platforms/ios/AppSync.framework/AppSync deleted file mode 100755 index 5d3daa8..0000000 Binary files a/src/platforms/ios/AppSync.framework/AppSync and /dev/null differ diff --git a/src/platforms/ios/AppSync.xcframework/Info.plist b/src/platforms/ios/AppSync.xcframework/Info.plist new file mode 100644 index 0000000..9d4e994 --- /dev/null +++ b/src/platforms/ios/AppSync.xcframework/Info.plist @@ -0,0 +1,44 @@ + + + + + AvailableLibraries + + + DebugSymbolsPath + dSYMs + LibraryIdentifier + ios-arm64_x86_64-simulator + LibraryPath + AppSync.framework + SupportedArchitectures + + arm64 + x86_64 + + SupportedPlatform + ios + SupportedPlatformVariant + simulator + + + DebugSymbolsPath + dSYMs + LibraryIdentifier + ios-arm64 + LibraryPath + AppSync.framework + SupportedArchitectures + + arm64 + + SupportedPlatform + ios + + + CFBundlePackageType + XFWK + XCFrameworkFormatVersion + 1.0 + + diff --git a/src/platforms/ios/AppSync.xcframework/ios-arm64/AppSync.framework/AppSync b/src/platforms/ios/AppSync.xcframework/ios-arm64/AppSync.framework/AppSync new file mode 100755 index 0000000..acda8f4 Binary files /dev/null and b/src/platforms/ios/AppSync.xcframework/ios-arm64/AppSync.framework/AppSync differ diff --git a/src/platforms/ios/AppSync.framework/Headers/AppSync.h b/src/platforms/ios/AppSync.xcframework/ios-arm64/AppSync.framework/Headers/AppSync.h similarity index 100% rename from src/platforms/ios/AppSync.framework/Headers/AppSync.h rename to src/platforms/ios/AppSync.xcframework/ios-arm64/AppSync.framework/Headers/AppSync.h diff --git a/src/platforms/ios/AppSync.framework/Headers/TNSAppSync.h b/src/platforms/ios/AppSync.xcframework/ios-arm64/AppSync.framework/Headers/TNSAppSync.h similarity index 100% rename from src/platforms/ios/AppSync.framework/Headers/TNSAppSync.h rename to src/platforms/ios/AppSync.xcframework/ios-arm64/AppSync.framework/Headers/TNSAppSync.h diff --git a/src/platforms/ios/AppSync.xcframework/ios-arm64/AppSync.framework/Info.plist b/src/platforms/ios/AppSync.xcframework/ios-arm64/AppSync.framework/Info.plist new file mode 100644 index 0000000..6e0c507 Binary files /dev/null and b/src/platforms/ios/AppSync.xcframework/ios-arm64/AppSync.framework/Info.plist differ diff --git a/src/platforms/ios/AppSync.framework/Modules/module.modulemap b/src/platforms/ios/AppSync.xcframework/ios-arm64/AppSync.framework/Modules/module.modulemap similarity index 100% rename from src/platforms/ios/AppSync.framework/Modules/module.modulemap rename to src/platforms/ios/AppSync.xcframework/ios-arm64/AppSync.framework/Modules/module.modulemap diff --git a/src/platforms/ios/AppSync.xcframework/ios-arm64/dSYMs/AppSync.framework.dSYM/Contents/Info.plist b/src/platforms/ios/AppSync.xcframework/ios-arm64/dSYMs/AppSync.framework.dSYM/Contents/Info.plist new file mode 100644 index 0000000..c75ab0f --- /dev/null +++ b/src/platforms/ios/AppSync.xcframework/ios-arm64/dSYMs/AppSync.framework.dSYM/Contents/Info.plist @@ -0,0 +1,20 @@ + + + + + CFBundleDevelopmentRegion + English + CFBundleIdentifier + com.apple.xcode.dsym.org.nativescript.plugin.AppSync + CFBundleInfoDictionaryVersion + 6.0 + CFBundlePackageType + dSYM + CFBundleSignature + ???? + CFBundleShortVersionString + 1.0 + CFBundleVersion + 1 + + diff --git a/src/platforms/ios/AppSync.xcframework/ios-arm64/dSYMs/AppSync.framework.dSYM/Contents/Resources/DWARF/AppSync b/src/platforms/ios/AppSync.xcframework/ios-arm64/dSYMs/AppSync.framework.dSYM/Contents/Resources/DWARF/AppSync new file mode 100644 index 0000000..e138e03 Binary files /dev/null and b/src/platforms/ios/AppSync.xcframework/ios-arm64/dSYMs/AppSync.framework.dSYM/Contents/Resources/DWARF/AppSync differ diff --git a/src/platforms/ios/AppSync.xcframework/ios-arm64_x86_64-simulator/AppSync.framework/AppSync b/src/platforms/ios/AppSync.xcframework/ios-arm64_x86_64-simulator/AppSync.framework/AppSync new file mode 100755 index 0000000..a4bb0a0 Binary files /dev/null and b/src/platforms/ios/AppSync.xcframework/ios-arm64_x86_64-simulator/AppSync.framework/AppSync differ diff --git a/src/platforms/ios/AppSync.xcframework/ios-arm64_x86_64-simulator/AppSync.framework/Headers/AppSync.h b/src/platforms/ios/AppSync.xcframework/ios-arm64_x86_64-simulator/AppSync.framework/Headers/AppSync.h new file mode 100644 index 0000000..6739cbb --- /dev/null +++ b/src/platforms/ios/AppSync.xcframework/ios-arm64_x86_64-simulator/AppSync.framework/Headers/AppSync.h @@ -0,0 +1,8 @@ +// In this header, you should import all the public headers of your framework +#import "TNSAppSync.h" + +//! Project version number for AppSync. +FOUNDATION_EXPORT double AppSyncVersionNumber; + +//! Project version string for AppSync. +FOUNDATION_EXPORT const unsigned char AppSyncVersionString[]; diff --git a/src/platforms/ios/AppSync.xcframework/ios-arm64_x86_64-simulator/AppSync.framework/Headers/TNSAppSync.h b/src/platforms/ios/AppSync.xcframework/ios-arm64_x86_64-simulator/AppSync.framework/Headers/TNSAppSync.h new file mode 100644 index 0000000..15a94d6 --- /dev/null +++ b/src/platforms/ios/AppSync.xcframework/ios-arm64_x86_64-simulator/AppSync.framework/Headers/TNSAppSync.h @@ -0,0 +1,14 @@ +#import +#import + +@interface TNSAppSync : NSObject + ++ (NSString *_Nonnull)applicationPathWithDefault:(NSString *_Nonnull) defaultPath; + ++ (void)unzipFileAtPath:(NSString *_Nonnull)path toDestination:(NSString *_Nullable)destination onProgress:(void (^_Nullable)(long entryNumber, long totalNumber))progressHandler onComplete:(void(^_Nullable)(NSString * _Nonnull path, BOOL succeeded, NSError * _Nullable error))completionHandler; + ++ (BOOL)copyEntriesInFolder:(NSString *_Nonnull)sourceFolder + destFolder:(NSString *_Nonnull)destFolder + error:(NSError *_Nullable*_Nullable)error; + +@end diff --git a/src/platforms/ios/AppSync.framework/Info.plist b/src/platforms/ios/AppSync.xcframework/ios-arm64_x86_64-simulator/AppSync.framework/Info.plist similarity index 54% rename from src/platforms/ios/AppSync.framework/Info.plist rename to src/platforms/ios/AppSync.xcframework/ios-arm64_x86_64-simulator/AppSync.framework/Info.plist index b2c6e97..41dcc90 100644 Binary files a/src/platforms/ios/AppSync.framework/Info.plist and b/src/platforms/ios/AppSync.xcframework/ios-arm64_x86_64-simulator/AppSync.framework/Info.plist differ diff --git a/src/platforms/ios/AppSync.xcframework/ios-arm64_x86_64-simulator/AppSync.framework/Modules/module.modulemap b/src/platforms/ios/AppSync.xcframework/ios-arm64_x86_64-simulator/AppSync.framework/Modules/module.modulemap new file mode 100644 index 0000000..8b27de1 --- /dev/null +++ b/src/platforms/ios/AppSync.xcframework/ios-arm64_x86_64-simulator/AppSync.framework/Modules/module.modulemap @@ -0,0 +1,6 @@ +framework module AppSync { + umbrella header "AppSync.h" + + export * + module * { export * } +} diff --git a/src/platforms/ios/AppSync.xcframework/ios-arm64_x86_64-simulator/AppSync.framework/_CodeSignature/CodeResources b/src/platforms/ios/AppSync.xcframework/ios-arm64_x86_64-simulator/AppSync.framework/_CodeSignature/CodeResources new file mode 100644 index 0000000..4bc9180 --- /dev/null +++ b/src/platforms/ios/AppSync.xcframework/ios-arm64_x86_64-simulator/AppSync.framework/_CodeSignature/CodeResources @@ -0,0 +1,147 @@ + + + + + files + + Headers/AppSync.h + + QnoL5htRCYf3vNSUV1RCbrU6DuE= + + Headers/TNSAppSync.h + + 57QeYZjbTCvP88jM45WFAeNPwdA= + + Info.plist + + lV9mLkovgQVcdhwUCtjkyXguJcE= + + Modules/module.modulemap + + XHe/o89O4o9x3hFxuYnt/j7qJBE= + + + files2 + + Headers/AppSync.h + + hash + + QnoL5htRCYf3vNSUV1RCbrU6DuE= + + hash2 + + /3YLK9fFP5nnNI+nwcR26nVPJD0P0jdX/JBY04N6oXA= + + + Headers/TNSAppSync.h + + hash + + 57QeYZjbTCvP88jM45WFAeNPwdA= + + hash2 + + Wddo6LqspI5KYmiiPXf6kXs5RygeRsEFG54yP5zzuIg= + + + Modules/module.modulemap + + hash + + XHe/o89O4o9x3hFxuYnt/j7qJBE= + + hash2 + + Gmwa12m+ZCHssiRhHUukWqgeWK+Pg/8LKXvzCRzyoow= + + + + rules + + ^.* + + ^.*\.lproj/ + + optional + + weight + 1000 + + ^.*\.lproj/locversion.plist$ + + omit + + weight + 1100 + + ^Base\.lproj/ + + weight + 1010 + + ^version.plist$ + + + rules2 + + .*\.dSYM($|/) + + weight + 11 + + ^(.*/)?\.DS_Store$ + + omit + + weight + 2000 + + ^.* + + ^.*\.lproj/ + + optional + + weight + 1000 + + ^.*\.lproj/locversion.plist$ + + omit + + weight + 1100 + + ^Base\.lproj/ + + weight + 1010 + + ^Info\.plist$ + + omit + + weight + 20 + + ^PkgInfo$ + + omit + + weight + 20 + + ^embedded\.provisionprofile$ + + weight + 20 + + ^version\.plist$ + + weight + 20 + + + + diff --git a/src/platforms/ios/AppSync.xcframework/ios-arm64_x86_64-simulator/dSYMs/AppSync.framework.dSYM/Contents/Info.plist b/src/platforms/ios/AppSync.xcframework/ios-arm64_x86_64-simulator/dSYMs/AppSync.framework.dSYM/Contents/Info.plist new file mode 100644 index 0000000..c75ab0f --- /dev/null +++ b/src/platforms/ios/AppSync.xcframework/ios-arm64_x86_64-simulator/dSYMs/AppSync.framework.dSYM/Contents/Info.plist @@ -0,0 +1,20 @@ + + + + + CFBundleDevelopmentRegion + English + CFBundleIdentifier + com.apple.xcode.dsym.org.nativescript.plugin.AppSync + CFBundleInfoDictionaryVersion + 6.0 + CFBundlePackageType + dSYM + CFBundleSignature + ???? + CFBundleShortVersionString + 1.0 + CFBundleVersion + 1 + + diff --git a/src/platforms/ios/AppSync.xcframework/ios-arm64_x86_64-simulator/dSYMs/AppSync.framework.dSYM/Contents/Resources/DWARF/AppSync b/src/platforms/ios/AppSync.xcframework/ios-arm64_x86_64-simulator/dSYMs/AppSync.framework.dSYM/Contents/Resources/DWARF/AppSync new file mode 100644 index 0000000..e52c291 Binary files /dev/null and b/src/platforms/ios/AppSync.xcframework/ios-arm64_x86_64-simulator/dSYMs/AppSync.framework.dSYM/Contents/Resources/DWARF/AppSync differ diff --git a/src/platforms/ios_lib/AppSync/AppSync/TNSAppSync.m b/src/platforms/ios_lib/AppSync/AppSync/TNSAppSync.m index 69253dc..29dcaaf 100644 --- a/src/platforms/ios_lib/AppSync/AppSync/TNSAppSync.m +++ b/src/platforms/ios_lib/AppSync/AppSync/TNSAppSync.m @@ -23,7 +23,7 @@ + (NSString *_Nonnull)applicationPathWithDefault:(NSString *_Nonnull) defaultPat NSString* appStoreAppBuildTime = timestamp.stringValue; BOOL appSyncPackageIsNewerThanAppStoreVersion = - [appSyncAppBuildTime isEqualToString: appStoreAppBuildTime] && [appSyncAppVersion isEqualToString: appStoreAppVersion]; + [appSyncAppBuildTime isEqualToString: appStoreAppBuildTime] && ([appSyncAppVersion isEqualToString: appStoreAppVersion] || [appSyncAppVersion compare:appStoreAppVersion options:NSNumericSearch] == NSOrderedDescending); if (appSyncPackageIsNewerThanAppStoreVersion) { NSString* docPath = [NSSearchPathForDirectoriesInDomains(NSDocumentDirectory, NSUserDomainMask, YES) firstObject]; diff --git a/src/platforms/ios_lib/AppSync/build.sh b/src/platforms/ios_lib/AppSync/build.sh new file mode 100755 index 0000000..757d663 --- /dev/null +++ b/src/platforms/ios_lib/AppSync/build.sh @@ -0,0 +1,39 @@ +echo "Set exit on simple errors" +set -e + +rm -rf $(PWD)/build + +echo "Build for iphonesimulator" +xcodebuild \ + -project AppSync.xcodeproj \ + -scheme AppSync \ + -sdk iphonesimulator \ + -destination "generic/platform=iOS Simulator" \ + -configuration Release \ + clean build \ + BUILD_DIR=$(PWD)/build \ + SKIP_INSTALL=NO \ + -quiet + +echo "Build for iphoneos" +xcodebuild \ + -project AppSync.xcodeproj \ + -scheme AppSync \ + -sdk iphoneos \ + -destination "generic/platform=iOS" \ + -configuration Release \ + clean build \ + BUILD_DIR=$(PWD)/build \ + CODE_SIGN_IDENTITY="" \ + CODE_SIGNING_REQUIRED=NO \ + SKIP_INSTALL=NO \ + -quiet + +echo "Creating XCFramework" +xcodebuild \ + -create-xcframework \ + -framework $(PWD)/build/Release-iphoneos/AppSync.framework \ + -debug-symbols $(PWD)/build/Release-iphoneos/AppSync.framework.dSYM \ + -framework $(PWD)/build/Release-iphonesimulator/AppSync.framework \ + -debug-symbols $(PWD)/build/Release-iphonesimulator/AppSync.framework.dSYM \ + -output $(PWD)/build/AppSync.xcframework diff --git a/src/platforms/ios_lib/AppSync/build/AppSync.xcframework/Info.plist b/src/platforms/ios_lib/AppSync/build/AppSync.xcframework/Info.plist new file mode 100644 index 0000000..9d4e994 --- /dev/null +++ b/src/platforms/ios_lib/AppSync/build/AppSync.xcframework/Info.plist @@ -0,0 +1,44 @@ + + + + + AvailableLibraries + + + DebugSymbolsPath + dSYMs + LibraryIdentifier + ios-arm64_x86_64-simulator + LibraryPath + AppSync.framework + SupportedArchitectures + + arm64 + x86_64 + + SupportedPlatform + ios + SupportedPlatformVariant + simulator + + + DebugSymbolsPath + dSYMs + LibraryIdentifier + ios-arm64 + LibraryPath + AppSync.framework + SupportedArchitectures + + arm64 + + SupportedPlatform + ios + + + CFBundlePackageType + XFWK + XCFrameworkFormatVersion + 1.0 + + diff --git a/src/platforms/ios_lib/AppSync/build/AppSync.xcframework/ios-arm64/AppSync.framework/AppSync b/src/platforms/ios_lib/AppSync/build/AppSync.xcframework/ios-arm64/AppSync.framework/AppSync new file mode 100755 index 0000000..acda8f4 Binary files /dev/null and b/src/platforms/ios_lib/AppSync/build/AppSync.xcframework/ios-arm64/AppSync.framework/AppSync differ diff --git a/src/platforms/ios_lib/AppSync/build/AppSync.xcframework/ios-arm64/AppSync.framework/Headers/AppSync.h b/src/platforms/ios_lib/AppSync/build/AppSync.xcframework/ios-arm64/AppSync.framework/Headers/AppSync.h new file mode 100644 index 0000000..6739cbb --- /dev/null +++ b/src/platforms/ios_lib/AppSync/build/AppSync.xcframework/ios-arm64/AppSync.framework/Headers/AppSync.h @@ -0,0 +1,8 @@ +// In this header, you should import all the public headers of your framework +#import "TNSAppSync.h" + +//! Project version number for AppSync. +FOUNDATION_EXPORT double AppSyncVersionNumber; + +//! Project version string for AppSync. +FOUNDATION_EXPORT const unsigned char AppSyncVersionString[]; diff --git a/src/platforms/ios_lib/AppSync/build/AppSync.xcframework/ios-arm64/AppSync.framework/Headers/TNSAppSync.h b/src/platforms/ios_lib/AppSync/build/AppSync.xcframework/ios-arm64/AppSync.framework/Headers/TNSAppSync.h new file mode 100644 index 0000000..15a94d6 --- /dev/null +++ b/src/platforms/ios_lib/AppSync/build/AppSync.xcframework/ios-arm64/AppSync.framework/Headers/TNSAppSync.h @@ -0,0 +1,14 @@ +#import +#import + +@interface TNSAppSync : NSObject + ++ (NSString *_Nonnull)applicationPathWithDefault:(NSString *_Nonnull) defaultPath; + ++ (void)unzipFileAtPath:(NSString *_Nonnull)path toDestination:(NSString *_Nullable)destination onProgress:(void (^_Nullable)(long entryNumber, long totalNumber))progressHandler onComplete:(void(^_Nullable)(NSString * _Nonnull path, BOOL succeeded, NSError * _Nullable error))completionHandler; + ++ (BOOL)copyEntriesInFolder:(NSString *_Nonnull)sourceFolder + destFolder:(NSString *_Nonnull)destFolder + error:(NSError *_Nullable*_Nullable)error; + +@end diff --git a/src/platforms/ios_lib/AppSync/build/AppSync.xcframework/ios-arm64/AppSync.framework/Info.plist b/src/platforms/ios_lib/AppSync/build/AppSync.xcframework/ios-arm64/AppSync.framework/Info.plist new file mode 100644 index 0000000..6e0c507 Binary files /dev/null and b/src/platforms/ios_lib/AppSync/build/AppSync.xcframework/ios-arm64/AppSync.framework/Info.plist differ diff --git a/src/platforms/ios_lib/AppSync/build/AppSync.xcframework/ios-arm64/AppSync.framework/Modules/module.modulemap b/src/platforms/ios_lib/AppSync/build/AppSync.xcframework/ios-arm64/AppSync.framework/Modules/module.modulemap new file mode 100644 index 0000000..8b27de1 --- /dev/null +++ b/src/platforms/ios_lib/AppSync/build/AppSync.xcframework/ios-arm64/AppSync.framework/Modules/module.modulemap @@ -0,0 +1,6 @@ +framework module AppSync { + umbrella header "AppSync.h" + + export * + module * { export * } +} diff --git a/src/platforms/ios_lib/AppSync/build/AppSync.xcframework/ios-arm64/dSYMs/AppSync.framework.dSYM/Contents/Info.plist b/src/platforms/ios_lib/AppSync/build/AppSync.xcframework/ios-arm64/dSYMs/AppSync.framework.dSYM/Contents/Info.plist new file mode 100644 index 0000000..c75ab0f --- /dev/null +++ b/src/platforms/ios_lib/AppSync/build/AppSync.xcframework/ios-arm64/dSYMs/AppSync.framework.dSYM/Contents/Info.plist @@ -0,0 +1,20 @@ + + + + + CFBundleDevelopmentRegion + English + CFBundleIdentifier + com.apple.xcode.dsym.org.nativescript.plugin.AppSync + CFBundleInfoDictionaryVersion + 6.0 + CFBundlePackageType + dSYM + CFBundleSignature + ???? + CFBundleShortVersionString + 1.0 + CFBundleVersion + 1 + + diff --git a/src/platforms/ios_lib/AppSync/build/AppSync.xcframework/ios-arm64/dSYMs/AppSync.framework.dSYM/Contents/Resources/DWARF/AppSync b/src/platforms/ios_lib/AppSync/build/AppSync.xcframework/ios-arm64/dSYMs/AppSync.framework.dSYM/Contents/Resources/DWARF/AppSync new file mode 100644 index 0000000..e138e03 Binary files /dev/null and b/src/platforms/ios_lib/AppSync/build/AppSync.xcframework/ios-arm64/dSYMs/AppSync.framework.dSYM/Contents/Resources/DWARF/AppSync differ diff --git a/src/platforms/ios_lib/AppSync/build/AppSync.xcframework/ios-arm64_x86_64-simulator/AppSync.framework/AppSync b/src/platforms/ios_lib/AppSync/build/AppSync.xcframework/ios-arm64_x86_64-simulator/AppSync.framework/AppSync new file mode 100755 index 0000000..a4bb0a0 Binary files /dev/null and b/src/platforms/ios_lib/AppSync/build/AppSync.xcframework/ios-arm64_x86_64-simulator/AppSync.framework/AppSync differ diff --git a/src/platforms/ios_lib/AppSync/build/AppSync.xcframework/ios-arm64_x86_64-simulator/AppSync.framework/Headers/AppSync.h b/src/platforms/ios_lib/AppSync/build/AppSync.xcframework/ios-arm64_x86_64-simulator/AppSync.framework/Headers/AppSync.h new file mode 100644 index 0000000..6739cbb --- /dev/null +++ b/src/platforms/ios_lib/AppSync/build/AppSync.xcframework/ios-arm64_x86_64-simulator/AppSync.framework/Headers/AppSync.h @@ -0,0 +1,8 @@ +// In this header, you should import all the public headers of your framework +#import "TNSAppSync.h" + +//! Project version number for AppSync. +FOUNDATION_EXPORT double AppSyncVersionNumber; + +//! Project version string for AppSync. +FOUNDATION_EXPORT const unsigned char AppSyncVersionString[]; diff --git a/src/platforms/ios_lib/AppSync/build/AppSync.xcframework/ios-arm64_x86_64-simulator/AppSync.framework/Headers/TNSAppSync.h b/src/platforms/ios_lib/AppSync/build/AppSync.xcframework/ios-arm64_x86_64-simulator/AppSync.framework/Headers/TNSAppSync.h new file mode 100644 index 0000000..15a94d6 --- /dev/null +++ b/src/platforms/ios_lib/AppSync/build/AppSync.xcframework/ios-arm64_x86_64-simulator/AppSync.framework/Headers/TNSAppSync.h @@ -0,0 +1,14 @@ +#import +#import + +@interface TNSAppSync : NSObject + ++ (NSString *_Nonnull)applicationPathWithDefault:(NSString *_Nonnull) defaultPath; + ++ (void)unzipFileAtPath:(NSString *_Nonnull)path toDestination:(NSString *_Nullable)destination onProgress:(void (^_Nullable)(long entryNumber, long totalNumber))progressHandler onComplete:(void(^_Nullable)(NSString * _Nonnull path, BOOL succeeded, NSError * _Nullable error))completionHandler; + ++ (BOOL)copyEntriesInFolder:(NSString *_Nonnull)sourceFolder + destFolder:(NSString *_Nonnull)destFolder + error:(NSError *_Nullable*_Nullable)error; + +@end diff --git a/src/platforms/ios_lib/AppSync/build/AppSync.xcframework/ios-arm64_x86_64-simulator/AppSync.framework/Info.plist b/src/platforms/ios_lib/AppSync/build/AppSync.xcframework/ios-arm64_x86_64-simulator/AppSync.framework/Info.plist new file mode 100644 index 0000000..41dcc90 Binary files /dev/null and b/src/platforms/ios_lib/AppSync/build/AppSync.xcframework/ios-arm64_x86_64-simulator/AppSync.framework/Info.plist differ diff --git a/src/platforms/ios_lib/AppSync/build/AppSync.xcframework/ios-arm64_x86_64-simulator/AppSync.framework/Modules/module.modulemap b/src/platforms/ios_lib/AppSync/build/AppSync.xcframework/ios-arm64_x86_64-simulator/AppSync.framework/Modules/module.modulemap new file mode 100644 index 0000000..8b27de1 --- /dev/null +++ b/src/platforms/ios_lib/AppSync/build/AppSync.xcframework/ios-arm64_x86_64-simulator/AppSync.framework/Modules/module.modulemap @@ -0,0 +1,6 @@ +framework module AppSync { + umbrella header "AppSync.h" + + export * + module * { export * } +} diff --git a/src/platforms/ios_lib/AppSync/build/AppSync.xcframework/ios-arm64_x86_64-simulator/AppSync.framework/_CodeSignature/CodeResources b/src/platforms/ios_lib/AppSync/build/AppSync.xcframework/ios-arm64_x86_64-simulator/AppSync.framework/_CodeSignature/CodeResources new file mode 100644 index 0000000..4bc9180 --- /dev/null +++ b/src/platforms/ios_lib/AppSync/build/AppSync.xcframework/ios-arm64_x86_64-simulator/AppSync.framework/_CodeSignature/CodeResources @@ -0,0 +1,147 @@ + + + + + files + + Headers/AppSync.h + + QnoL5htRCYf3vNSUV1RCbrU6DuE= + + Headers/TNSAppSync.h + + 57QeYZjbTCvP88jM45WFAeNPwdA= + + Info.plist + + lV9mLkovgQVcdhwUCtjkyXguJcE= + + Modules/module.modulemap + + XHe/o89O4o9x3hFxuYnt/j7qJBE= + + + files2 + + Headers/AppSync.h + + hash + + QnoL5htRCYf3vNSUV1RCbrU6DuE= + + hash2 + + /3YLK9fFP5nnNI+nwcR26nVPJD0P0jdX/JBY04N6oXA= + + + Headers/TNSAppSync.h + + hash + + 57QeYZjbTCvP88jM45WFAeNPwdA= + + hash2 + + Wddo6LqspI5KYmiiPXf6kXs5RygeRsEFG54yP5zzuIg= + + + Modules/module.modulemap + + hash + + XHe/o89O4o9x3hFxuYnt/j7qJBE= + + hash2 + + Gmwa12m+ZCHssiRhHUukWqgeWK+Pg/8LKXvzCRzyoow= + + + + rules + + ^.* + + ^.*\.lproj/ + + optional + + weight + 1000 + + ^.*\.lproj/locversion.plist$ + + omit + + weight + 1100 + + ^Base\.lproj/ + + weight + 1010 + + ^version.plist$ + + + rules2 + + .*\.dSYM($|/) + + weight + 11 + + ^(.*/)?\.DS_Store$ + + omit + + weight + 2000 + + ^.* + + ^.*\.lproj/ + + optional + + weight + 1000 + + ^.*\.lproj/locversion.plist$ + + omit + + weight + 1100 + + ^Base\.lproj/ + + weight + 1010 + + ^Info\.plist$ + + omit + + weight + 20 + + ^PkgInfo$ + + omit + + weight + 20 + + ^embedded\.provisionprofile$ + + weight + 20 + + ^version\.plist$ + + weight + 20 + + + + diff --git a/src/platforms/ios_lib/AppSync/build/AppSync.xcframework/ios-arm64_x86_64-simulator/dSYMs/AppSync.framework.dSYM/Contents/Info.plist b/src/platforms/ios_lib/AppSync/build/AppSync.xcframework/ios-arm64_x86_64-simulator/dSYMs/AppSync.framework.dSYM/Contents/Info.plist new file mode 100644 index 0000000..c75ab0f --- /dev/null +++ b/src/platforms/ios_lib/AppSync/build/AppSync.xcframework/ios-arm64_x86_64-simulator/dSYMs/AppSync.framework.dSYM/Contents/Info.plist @@ -0,0 +1,20 @@ + + + + + CFBundleDevelopmentRegion + English + CFBundleIdentifier + com.apple.xcode.dsym.org.nativescript.plugin.AppSync + CFBundleInfoDictionaryVersion + 6.0 + CFBundlePackageType + dSYM + CFBundleSignature + ???? + CFBundleShortVersionString + 1.0 + CFBundleVersion + 1 + + diff --git a/src/platforms/ios_lib/AppSync/build/AppSync.xcframework/ios-arm64_x86_64-simulator/dSYMs/AppSync.framework.dSYM/Contents/Resources/DWARF/AppSync b/src/platforms/ios_lib/AppSync/build/AppSync.xcframework/ios-arm64_x86_64-simulator/dSYMs/AppSync.framework.dSYM/Contents/Resources/DWARF/AppSync new file mode 100644 index 0000000..e52c291 Binary files /dev/null and b/src/platforms/ios_lib/AppSync/build/AppSync.xcframework/ios-arm64_x86_64-simulator/dSYMs/AppSync.framework.dSYM/Contents/Resources/DWARF/AppSync differ diff --git a/src/platforms/ios_lib/AppSync/build/Release-iphoneos/AppSync.framework.dSYM/Contents/Info.plist b/src/platforms/ios_lib/AppSync/build/Release-iphoneos/AppSync.framework.dSYM/Contents/Info.plist new file mode 100644 index 0000000..c75ab0f --- /dev/null +++ b/src/platforms/ios_lib/AppSync/build/Release-iphoneos/AppSync.framework.dSYM/Contents/Info.plist @@ -0,0 +1,20 @@ + + + + + CFBundleDevelopmentRegion + English + CFBundleIdentifier + com.apple.xcode.dsym.org.nativescript.plugin.AppSync + CFBundleInfoDictionaryVersion + 6.0 + CFBundlePackageType + dSYM + CFBundleSignature + ???? + CFBundleShortVersionString + 1.0 + CFBundleVersion + 1 + + diff --git a/src/platforms/ios_lib/AppSync/build/Release-iphoneos/AppSync.framework.dSYM/Contents/Resources/DWARF/AppSync b/src/platforms/ios_lib/AppSync/build/Release-iphoneos/AppSync.framework.dSYM/Contents/Resources/DWARF/AppSync new file mode 100644 index 0000000..e138e03 Binary files /dev/null and b/src/platforms/ios_lib/AppSync/build/Release-iphoneos/AppSync.framework.dSYM/Contents/Resources/DWARF/AppSync differ diff --git a/src/platforms/ios_lib/AppSync/build/Release-iphoneos/AppSync.framework/AppSync b/src/platforms/ios_lib/AppSync/build/Release-iphoneos/AppSync.framework/AppSync new file mode 100755 index 0000000..acda8f4 Binary files /dev/null and b/src/platforms/ios_lib/AppSync/build/Release-iphoneos/AppSync.framework/AppSync differ diff --git a/src/platforms/ios_lib/AppSync/build/Release-iphoneos/AppSync.framework/Headers/AppSync.h b/src/platforms/ios_lib/AppSync/build/Release-iphoneos/AppSync.framework/Headers/AppSync.h new file mode 100644 index 0000000..6739cbb --- /dev/null +++ b/src/platforms/ios_lib/AppSync/build/Release-iphoneos/AppSync.framework/Headers/AppSync.h @@ -0,0 +1,8 @@ +// In this header, you should import all the public headers of your framework +#import "TNSAppSync.h" + +//! Project version number for AppSync. +FOUNDATION_EXPORT double AppSyncVersionNumber; + +//! Project version string for AppSync. +FOUNDATION_EXPORT const unsigned char AppSyncVersionString[]; diff --git a/src/platforms/ios_lib/AppSync/build/Release-iphoneos/AppSync.framework/Headers/TNSAppSync.h b/src/platforms/ios_lib/AppSync/build/Release-iphoneos/AppSync.framework/Headers/TNSAppSync.h new file mode 100644 index 0000000..15a94d6 --- /dev/null +++ b/src/platforms/ios_lib/AppSync/build/Release-iphoneos/AppSync.framework/Headers/TNSAppSync.h @@ -0,0 +1,14 @@ +#import +#import + +@interface TNSAppSync : NSObject + ++ (NSString *_Nonnull)applicationPathWithDefault:(NSString *_Nonnull) defaultPath; + ++ (void)unzipFileAtPath:(NSString *_Nonnull)path toDestination:(NSString *_Nullable)destination onProgress:(void (^_Nullable)(long entryNumber, long totalNumber))progressHandler onComplete:(void(^_Nullable)(NSString * _Nonnull path, BOOL succeeded, NSError * _Nullable error))completionHandler; + ++ (BOOL)copyEntriesInFolder:(NSString *_Nonnull)sourceFolder + destFolder:(NSString *_Nonnull)destFolder + error:(NSError *_Nullable*_Nullable)error; + +@end diff --git a/src/platforms/ios_lib/AppSync/build/Release-iphoneos/AppSync.framework/Info.plist b/src/platforms/ios_lib/AppSync/build/Release-iphoneos/AppSync.framework/Info.plist new file mode 100644 index 0000000..6e0c507 Binary files /dev/null and b/src/platforms/ios_lib/AppSync/build/Release-iphoneos/AppSync.framework/Info.plist differ diff --git a/src/platforms/ios_lib/AppSync/build/Release-iphoneos/AppSync.framework/Modules/module.modulemap b/src/platforms/ios_lib/AppSync/build/Release-iphoneos/AppSync.framework/Modules/module.modulemap new file mode 100644 index 0000000..8b27de1 --- /dev/null +++ b/src/platforms/ios_lib/AppSync/build/Release-iphoneos/AppSync.framework/Modules/module.modulemap @@ -0,0 +1,6 @@ +framework module AppSync { + umbrella header "AppSync.h" + + export * + module * { export * } +} diff --git a/src/platforms/ios_lib/AppSync/build/Release-iphonesimulator/AppSync.framework.dSYM/Contents/Info.plist b/src/platforms/ios_lib/AppSync/build/Release-iphonesimulator/AppSync.framework.dSYM/Contents/Info.plist new file mode 100644 index 0000000..c75ab0f --- /dev/null +++ b/src/platforms/ios_lib/AppSync/build/Release-iphonesimulator/AppSync.framework.dSYM/Contents/Info.plist @@ -0,0 +1,20 @@ + + + + + CFBundleDevelopmentRegion + English + CFBundleIdentifier + com.apple.xcode.dsym.org.nativescript.plugin.AppSync + CFBundleInfoDictionaryVersion + 6.0 + CFBundlePackageType + dSYM + CFBundleSignature + ???? + CFBundleShortVersionString + 1.0 + CFBundleVersion + 1 + + diff --git a/src/platforms/ios_lib/AppSync/build/Release-iphonesimulator/AppSync.framework.dSYM/Contents/Resources/DWARF/AppSync b/src/platforms/ios_lib/AppSync/build/Release-iphonesimulator/AppSync.framework.dSYM/Contents/Resources/DWARF/AppSync new file mode 100644 index 0000000..e52c291 Binary files /dev/null and b/src/platforms/ios_lib/AppSync/build/Release-iphonesimulator/AppSync.framework.dSYM/Contents/Resources/DWARF/AppSync differ diff --git a/src/platforms/ios_lib/AppSync/build/Release-iphonesimulator/AppSync.framework/AppSync b/src/platforms/ios_lib/AppSync/build/Release-iphonesimulator/AppSync.framework/AppSync new file mode 100755 index 0000000..a4bb0a0 Binary files /dev/null and b/src/platforms/ios_lib/AppSync/build/Release-iphonesimulator/AppSync.framework/AppSync differ diff --git a/src/platforms/ios_lib/AppSync/build/Release-iphonesimulator/AppSync.framework/Headers/AppSync.h b/src/platforms/ios_lib/AppSync/build/Release-iphonesimulator/AppSync.framework/Headers/AppSync.h new file mode 100644 index 0000000..6739cbb --- /dev/null +++ b/src/platforms/ios_lib/AppSync/build/Release-iphonesimulator/AppSync.framework/Headers/AppSync.h @@ -0,0 +1,8 @@ +// In this header, you should import all the public headers of your framework +#import "TNSAppSync.h" + +//! Project version number for AppSync. +FOUNDATION_EXPORT double AppSyncVersionNumber; + +//! Project version string for AppSync. +FOUNDATION_EXPORT const unsigned char AppSyncVersionString[]; diff --git a/src/platforms/ios_lib/AppSync/build/Release-iphonesimulator/AppSync.framework/Headers/TNSAppSync.h b/src/platforms/ios_lib/AppSync/build/Release-iphonesimulator/AppSync.framework/Headers/TNSAppSync.h new file mode 100644 index 0000000..15a94d6 --- /dev/null +++ b/src/platforms/ios_lib/AppSync/build/Release-iphonesimulator/AppSync.framework/Headers/TNSAppSync.h @@ -0,0 +1,14 @@ +#import +#import + +@interface TNSAppSync : NSObject + ++ (NSString *_Nonnull)applicationPathWithDefault:(NSString *_Nonnull) defaultPath; + ++ (void)unzipFileAtPath:(NSString *_Nonnull)path toDestination:(NSString *_Nullable)destination onProgress:(void (^_Nullable)(long entryNumber, long totalNumber))progressHandler onComplete:(void(^_Nullable)(NSString * _Nonnull path, BOOL succeeded, NSError * _Nullable error))completionHandler; + ++ (BOOL)copyEntriesInFolder:(NSString *_Nonnull)sourceFolder + destFolder:(NSString *_Nonnull)destFolder + error:(NSError *_Nullable*_Nullable)error; + +@end diff --git a/src/platforms/ios_lib/AppSync/build/Release-iphonesimulator/AppSync.framework/Info.plist b/src/platforms/ios_lib/AppSync/build/Release-iphonesimulator/AppSync.framework/Info.plist new file mode 100644 index 0000000..41dcc90 Binary files /dev/null and b/src/platforms/ios_lib/AppSync/build/Release-iphonesimulator/AppSync.framework/Info.plist differ diff --git a/src/platforms/ios_lib/AppSync/build/Release-iphonesimulator/AppSync.framework/Modules/module.modulemap b/src/platforms/ios_lib/AppSync/build/Release-iphonesimulator/AppSync.framework/Modules/module.modulemap new file mode 100644 index 0000000..8b27de1 --- /dev/null +++ b/src/platforms/ios_lib/AppSync/build/Release-iphonesimulator/AppSync.framework/Modules/module.modulemap @@ -0,0 +1,6 @@ +framework module AppSync { + umbrella header "AppSync.h" + + export * + module * { export * } +} diff --git a/src/platforms/ios_lib/AppSync/build/Release-iphonesimulator/AppSync.framework/_CodeSignature/CodeResources b/src/platforms/ios_lib/AppSync/build/Release-iphonesimulator/AppSync.framework/_CodeSignature/CodeResources new file mode 100644 index 0000000..4bc9180 --- /dev/null +++ b/src/platforms/ios_lib/AppSync/build/Release-iphonesimulator/AppSync.framework/_CodeSignature/CodeResources @@ -0,0 +1,147 @@ + + + + + files + + Headers/AppSync.h + + QnoL5htRCYf3vNSUV1RCbrU6DuE= + + Headers/TNSAppSync.h + + 57QeYZjbTCvP88jM45WFAeNPwdA= + + Info.plist + + lV9mLkovgQVcdhwUCtjkyXguJcE= + + Modules/module.modulemap + + XHe/o89O4o9x3hFxuYnt/j7qJBE= + + + files2 + + Headers/AppSync.h + + hash + + QnoL5htRCYf3vNSUV1RCbrU6DuE= + + hash2 + + /3YLK9fFP5nnNI+nwcR26nVPJD0P0jdX/JBY04N6oXA= + + + Headers/TNSAppSync.h + + hash + + 57QeYZjbTCvP88jM45WFAeNPwdA= + + hash2 + + Wddo6LqspI5KYmiiPXf6kXs5RygeRsEFG54yP5zzuIg= + + + Modules/module.modulemap + + hash + + XHe/o89O4o9x3hFxuYnt/j7qJBE= + + hash2 + + Gmwa12m+ZCHssiRhHUukWqgeWK+Pg/8LKXvzCRzyoow= + + + + rules + + ^.* + + ^.*\.lproj/ + + optional + + weight + 1000 + + ^.*\.lproj/locversion.plist$ + + omit + + weight + 1100 + + ^Base\.lproj/ + + weight + 1010 + + ^version.plist$ + + + rules2 + + .*\.dSYM($|/) + + weight + 11 + + ^(.*/)?\.DS_Store$ + + omit + + weight + 2000 + + ^.* + + ^.*\.lproj/ + + optional + + weight + 1000 + + ^.*\.lproj/locversion.plist$ + + omit + + weight + 1100 + + ^Base\.lproj/ + + weight + 1010 + + ^Info\.plist$ + + omit + + weight + 20 + + ^PkgInfo$ + + omit + + weight + 20 + + ^embedded\.provisionprofile$ + + weight + 20 + + ^version\.plist$ + + weight + 20 + + + + diff --git a/src/platforms/ios_lib/build.sh b/src/platforms/ios_lib/build.sh new file mode 100755 index 0000000..8a940dc --- /dev/null +++ b/src/platforms/ios_lib/build.sh @@ -0,0 +1,21 @@ +#!/bin/sh + +echo "Set exit on simple errors" +set -e + +echo "Use dumb terminal" +export TERM=dumb + +rm -rf ../ios || true +mkdir -p ../ios + +echo "Build iOS" + +cd AppSync +./build.sh +cd .. +echo "Copy AppSync/build/*.xcframework ../ios" + +cp -R AppSync/build/AppSync.xcframework ../ios + +# cp AppSync/build/*.framework.dSYM.zip dist/package/platforms/ios diff --git a/src/scripts/ios/appsync-ios.js b/src/scripts/ios/appsync-ios.js index b4d0351..3859908 100644 --- a/src/scripts/ios/appsync-ios.js +++ b/src/scripts/ios/appsync-ios.js @@ -19,15 +19,15 @@ function patchUIApplicationMain(iosProjectFolder) { // let's first inject a header we need replaceInFile( appSyncFileDest, - '#include ', - '#include \n#include ' + '#import ', + '#import \n#include ' ); // now inject the function call that determines the correct application path (either default or appsync'ed) replaceInFile( appSyncFileDest, - 'applicationPath = [NSBundle mainBundle].bundlePath;', - 'applicationPath = [TNSAppSync applicationPathWithDefault:[NSBundle mainBundle].bundlePath];' + 'baseDir = [[NSBundle mainBundle] resourcePath];', + 'baseDir = [TNSAppSync applicationPathWithDefault:[NSBundle mainBundle].bundlePath];' ); } @@ -49,4 +49,4 @@ module.exports = function ($injector, hookArgs) { const iosProjectFolder = prepareHooksHelper.getNativeProjectDir($injector, platform, hookArgs); patchUIApplicationMain(iosProjectFolder); } -}; \ No newline at end of file +};