diff --git a/iOS/AppHub.framework/AppHub b/iOS/AppHub.framework/AppHub deleted file mode 120000 index caa9f15..0000000 --- a/iOS/AppHub.framework/AppHub +++ /dev/null @@ -1 +0,0 @@ -Versions/Current/AppHub \ No newline at end of file diff --git a/iOS/AppHub.framework/Headers b/iOS/AppHub.framework/Headers deleted file mode 120000 index a177d2a..0000000 --- a/iOS/AppHub.framework/Headers +++ /dev/null @@ -1 +0,0 @@ -Versions/Current/Headers \ No newline at end of file diff --git a/iOS/AppHub.framework/Versions/A/AppHub b/iOS/AppHub.framework/Versions/A/AppHub deleted file mode 100644 index bbddcb3..0000000 Binary files a/iOS/AppHub.framework/Versions/A/AppHub and /dev/null differ diff --git a/iOS/AppHub.framework/Versions/A/Headers/AHBuild.h b/iOS/AppHub.framework/Versions/A/Headers/AHBuild.h deleted file mode 100644 index e030009..0000000 --- a/iOS/AppHub.framework/Versions/A/Headers/AHBuild.h +++ /dev/null @@ -1,57 +0,0 @@ -// -// AHBuild.h -// AppHub -// -// Copyright (c) 2015 AppHub. All rights reserved. -// - -#import - -/** -An object that represents an AppHub build. This object -holds a reference to an `NSBundle` which contains `.jsbundle` files -and images for a build. An AHBuild also contains build metadata, such -as an identifier and description. - -Example usage: - - AHBuild *build = [AppHub buildManager].currentBuild; - NSURL *jsCodeLocation = [build.bundle URLForResource:@"main" withExtension:@"jsbundle]; - - */ - -@interface AHBuild : NSObject - -///--------------------- -/// @name Properties -///--------------------- - -/** - * The bundle of JavaScript and images for a build of your application. Use - * `-[NSBundle URLForResource:withExtension:]` and other `NSBundle` methods to - * access files within the bundle. - */ -@property (nonatomic, readonly) NSBundle *bundle; - -/// The identifier, or `LOCAL` if the build originates from the App Store. -/// This identifier is guaranteed to be unique for each build of your app. -@property (nonatomic, readonly) NSString *identifier; - -/** - * The name of the build as defined form the AppHub dashboard. - */ -@property (nonatomic, readonly) NSString *name; - -/** - * The user-defined description of the build. Build descriptions can be - * configured from the AppHub dashboard. - */ -@property (nonatomic, readonly) NSString *buildDescription; - -/// The date at which the build was created. -@property (nonatomic, readonly) NSDate *creationDate; - -/// An array of iOS app version strings with which the build is compatible. -@property (nonatomic, readonly) NSArray *compatibleIOSVersions; - -@end diff --git a/iOS/AppHub.framework/Versions/A/Headers/AHBuildManager.h b/iOS/AppHub.framework/Versions/A/Headers/AHBuildManager.h deleted file mode 100644 index 5eabe3b..0000000 --- a/iOS/AppHub.framework/Versions/A/Headers/AHBuildManager.h +++ /dev/null @@ -1,98 +0,0 @@ -// -// AHBuildManager.h -// AppHub -// -// Copyright (c) 2015 AppHub. All rights reserved. -// - -#import - -#import "AHDefines.h" - -@class AHBuild; - -/** - * Posted whenever a new build becomes available for this application. Use this - * opportunity to notify the user of a new build, or force refresh the - * application. - */ -extern NSString *const AHBuildManagerDidMakeBuildAvailableNotification; - -/** - * Notification user info key for the newly available build. - */ -extern NSString *const AHBuildManagerBuildKey; - -/** - * The AHBuildManager contains methods for retrieving the current build and fetching new builds. - * - * Access the AHBuildManager singleton by calling `[AppHub buildManager]`. - * - * @see [AppHub buildManager] - */ -@interface AHBuildManager : NSObject - -- (instancetype)init NS_UNAVAILABLE; - -///--------------------- -/// @name Retrieving Builds -///--------------------- - -/** - * The currently loaded build of your application, either the remote build if it - * has been loaded or the instance for the App Store build. - */ -@property (nonatomic, readonly) AHBuild *currentBuild; - -///--------------------- -/// @name Configuration -///--------------------- - -/** - * Use `debugBuildsEnabled` to enable debug builds for this device. Setting this property to - * `true` will cause your app to load builds that are designated as "debug-only" in the AppHub dashboard. - * - * Defaults to `false`. - */ -@property (nonatomic, assign, getter=areDebugBuildsEnabled) BOOL debugBuildsEnabled; - -/** - * The AppHub SDK will poll the server for new builds of your App. By default, - * the SDK will only poll for new builds when the device is connected to WiFi. You can - * configure this behavior via the `cellularDownloadsEnabled` property. - * - * To manually control the frequency and timing of the polling, you can disable automatic polling by - * setting this property to 'false'. - * - * See the docs for a full explanation of AppHub polling. - * - * Defaults to `true`. - */ -@property (nonatomic, assign, getter=isAutomaticPollingEnabled) BOOL automaticPollingEnabled; - -/** - * By default, the AppHub SDK will only poll for new builds when the device is connected to WiFi. - * - * Set this property to `true` to enable downloads on any internet connection. Caution: enabling this boolean - * will increase your app's data usage. - * - * Defaults to `false`. - */ -@property (nonatomic, assign, getter=areCellularDownloadsEnabled) BOOL cellularDownloadsEnabled; - -///--------------------- -/// @name Fetching Builds Manually (Advanced) -///--------------------- - -/** - * Fetch a build from AppHub with a completion block. Call this method to force - * the SDK to check for newly available builds, or use it to guarantee that you - * load the most up-to-date JavaScript on each client. - * - * @param completionHandler A block of type AHBuildResultBlock that will be invoked upon - * completion of the fetch. If not nil, the resulting `AHBuild` in the block is guaranteed to - * be the most up-to-date build of your application. - */ -- (void)fetchBuildWithCompletionHandler:(AHBuildResultBlock)completionHandler; - -@end diff --git a/iOS/AppHub.framework/Versions/A/Headers/AHDefines.h b/iOS/AppHub.framework/Versions/A/Headers/AHDefines.h deleted file mode 100644 index db94d35..0000000 --- a/iOS/AppHub.framework/Versions/A/Headers/AHDefines.h +++ /dev/null @@ -1,35 +0,0 @@ -// -// AHDefines.h -// AppHub -// -// Copyright (c) 2015 AppHub. All rights reserved. -// - -#import - -@class AHBuild; - -/// A block that is a called from the result of an asynchronous AHBuild request. -typedef void (^AHBuildResultBlock)(AHBuild *result, NSError *error); - -/// The identifier for an AHBuild that originates from the App Store. -extern NSString *const AHDefaultBuildID; - -/** - * Specifies different logging levels for limiting log message display. - * - * @see [AppHub setLogLevel:] - */ -typedef NS_ENUM(NSUInteger, AHLogLevel) { - /// Disables all logging. - AHLogLevelNone, - - /// Displays only AHLogLevelError logs. - AHLogLevelError, - - /// Displays AHLogLevelError and AHLogLevelWarning logs. - AHLogLevelWarning, - - /// Displays AHLogLevelError, AHLogLevelWarning, and AHLogLevelDebug logs. - AHLogLevelDebug, -}; diff --git a/iOS/AppHub.framework/Versions/A/Headers/AppHub.h b/iOS/AppHub.framework/Versions/A/Headers/AppHub.h deleted file mode 100644 index bc17f23..0000000 --- a/iOS/AppHub.framework/Versions/A/Headers/AppHub.h +++ /dev/null @@ -1,78 +0,0 @@ -// -// AppHub.h -// AppHub -// -// Copyright (c) 2015 AppHub. All rights reserved. -// - -#import -#import - -#import "AHDefines.h" -#import "AHBuild.h" -#import "AHBuildManager.h" - -/** - * The AppHub class contains static functions that handle global - * configuration for the AppHub framework. - */ - -@interface AppHub : NSObject - -///--------------------- -/// @name Retrieving Builds -///--------------------- - -/// @return A shared instance of `AHBuildManager` that can be used to access the current build. -+ (AHBuildManager *)buildManager; - -///--------------------- -/// @name Configuration -///--------------------- - -/// The applicationID used to configure the AppHub framework. -/// @param applicationID The applicationID as specified from the AppHub dashboard. -+ (void)setApplicationID:(NSString *)applicationID; - -/// @return The applicationID used to configure the AppHub framework. -+ (NSString *)applicationID; - -/// The level of logging that will be displayed to the Xcode console. -/// @param logLevel The level of logging that will be displayed to the Xcode console. -+ (void)setLogLevel:(AHLogLevel)logLevel; - -/// @return The level of logging that will be displayed to the Xcode console. -+ (AHLogLevel)logLevel; - -/// The version of the installed SDK. -+ (NSString *)SDKVersion; - -///--------------------- -/// @name Testing Builds -///--------------------- - -/** -Present a view that allows you to select between all available builds of your application. - -The resulting block will be invoked on the main thread, so you can present a view from the completion block. - - -Example: - - [[AppHub buildManager] presentSelectorWithBuildHandler:^(AHBuild *build, NSError *error) { - if (error || ! build) { - // An error occurred. - } else { - NSURL *jsCodeLocation = [build.bundle URLForResource:@"main" withExtension:@"jsbundle"]; - // ... do something with the jsbundle, like presenting an RCTRootView - } - }]; - -@param viewController The view controller on which a build selector table will be presented. -@param block An AHBuildResultBlock that will be invoked upon selection of a build. - - */ -+ (void)presentSelectorOnViewController:(UIViewController *)viewController - withBuildHandler:(AHBuildResultBlock)block; - -@end \ No newline at end of file diff --git a/iOS/AppHub.framework/Versions/Current b/iOS/AppHub.framework/Versions/Current deleted file mode 120000 index 8c7e5a6..0000000 --- a/iOS/AppHub.framework/Versions/Current +++ /dev/null @@ -1 +0,0 @@ -A \ No newline at end of file diff --git a/iOS/AppHubStarterProject.app.dSYM.zip b/iOS/AppHubStarterProject.app.dSYM.zip deleted file mode 100644 index fd3d547..0000000 Binary files a/iOS/AppHubStarterProject.app.dSYM.zip and /dev/null differ diff --git a/iOS/AppHubStarterProject.xcodeproj/project.pbxproj b/iOS/AppHubStarterProject.xcodeproj/project.pbxproj index cc5fdda..a815cd0 100644 --- a/iOS/AppHubStarterProject.xcodeproj/project.pbxproj +++ b/iOS/AppHubStarterProject.xcodeproj/project.pbxproj @@ -21,8 +21,8 @@ 400C2F581BA4B5AA0003A96D /* LaunchScreen.xib in Resources */ = {isa = PBXBuildFile; fileRef = 400C2F501BA4B5AA0003A96D /* LaunchScreen.xib */; }; 400C2F591BA4B5AA0003A96D /* Images.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 400C2F521BA4B5AA0003A96D /* Images.xcassets */; }; 400C2F5C1BA4B5AA0003A96D /* main.m in Sources */ = {isa = PBXBuildFile; fileRef = 400C2F551BA4B5AA0003A96D /* main.m */; }; - 40AC29CF1BE2AB4300CD45C7 /* AppHub.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 40AC29CE1BE2AB4300CD45C7 /* AppHub.framework */; }; 40AC29D11BE2AE9000CD45C7 /* main.jsbundle in Resources */ = {isa = PBXBuildFile; fileRef = 40AC29D01BE2AE9000CD45C7 /* main.jsbundle */; }; + 40AC29E51BE2D4AC00CD45C7 /* AppHub.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 40AC29E41BE2D4AC00CD45C7 /* AppHub.framework */; }; 40EA7FBA1BAB768000CD144C /* libz.tbd in Frameworks */ = {isa = PBXBuildFile; fileRef = 405E2BF01BAB694F00A6915B /* libz.tbd */; }; 832341BD1AAA6AB300B99B32 /* libRCTText.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 832341B51AAA6A8300B99B32 /* libRCTText.a */; }; /* End PBXBuildFile section */ @@ -118,8 +118,8 @@ 400C2F531BA4B5AA0003A96D /* Info.plist */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.xml; name = Info.plist; path = AppHubStarterProject/Info.plist; sourceTree = SOURCE_ROOT; }; 400C2F551BA4B5AA0003A96D /* main.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = main.m; path = AppHubStarterProject/main.m; sourceTree = SOURCE_ROOT; }; 405E2BF01BAB694F00A6915B /* libz.tbd */ = {isa = PBXFileReference; lastKnownFileType = "sourcecode.text-based-dylib-definition"; name = libz.tbd; path = usr/lib/libz.tbd; sourceTree = SDKROOT; }; - 40AC29CE1BE2AB4300CD45C7 /* AppHub.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; path = AppHub.framework; sourceTree = ""; }; 40AC29D01BE2AE9000CD45C7 /* main.jsbundle */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text; path = main.jsbundle; sourceTree = SOURCE_ROOT; }; + 40AC29E41BE2D4AC00CD45C7 /* AppHub.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; path = AppHub.framework; sourceTree = ""; }; 78C398B01ACF4ADC00677621 /* RCTLinking.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.pb-project"; name = RCTLinking.xcodeproj; path = "../node_modules/react-native/Libraries/LinkingIOS/RCTLinking.xcodeproj"; sourceTree = ""; }; 832341B01AAA6A8300B99B32 /* RCTText.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.pb-project"; name = RCTText.xcodeproj; path = "../node_modules/react-native/Libraries/Text/RCTText.xcodeproj"; sourceTree = ""; }; /* End PBXFileReference section */ @@ -136,7 +136,7 @@ 00C302E71ABCBA2D00DB3ED1 /* libRCTGeolocation.a in Frameworks */, 00C302E81ABCBA2D00DB3ED1 /* libRCTImage.a in Frameworks */, 133E29F31AD74F7200F7D852 /* libRCTLinking.a in Frameworks */, - 40AC29CF1BE2AB4300CD45C7 /* AppHub.framework in Frameworks */, + 40AC29E51BE2D4AC00CD45C7 /* AppHub.framework in Frameworks */, 00C302E91ABCBA2D00DB3ED1 /* libRCTNetwork.a in Frameworks */, 139105C61AF99C1200B5F7CC /* libRCTSettings.a in Frameworks */, 832341BD1AAA6AB300B99B32 /* libRCTText.a in Frameworks */, @@ -247,8 +247,8 @@ 832341AE1AAA6A7D00B99B32 /* Libraries */ = { isa = PBXGroup; children = ( + 40AC29E41BE2D4AC00CD45C7 /* AppHub.framework */, 405E2BF01BAB694F00A6915B /* libz.tbd */, - 40AC29CE1BE2AB4300CD45C7 /* AppHub.framework */, 400C2F3C1BA4AAD40003A96D /* SystemConfiguration.framework */, 146833FF1AC3E56700842450 /* React.xcodeproj */, 00C302A71ABCB8CE00DB3ED1 /* RCTActionSheet.xcodeproj */, diff --git a/package.json b/package.json index 590c611..d225e33 100644 --- a/package.json +++ b/package.json @@ -6,6 +6,7 @@ "start": "node_modules/react-native/packager/packager.sh" }, "dependencies": { + "apphub": "0.0.2", "react-native": "^0.13.2" } }