iOS Question How to add HockeyApp for iOS?

CanguroCode

Active Member
Licensed User
Longtime User
XkYiXht.jpg


I need upload my alpha version iOS app to HockeyApp for sharing to my testers / clients, since I don't want they send me theirs UDID´s or they do something extra steps. I just want to share a link and they can download my app. But I don't have idea how to achive some steps in HockeyApp documentation:

https://support.hockeyapp.net/kb/client-integration-ios-mac-os-x-tvos/hockeyapp-for-ios

How can I accomplish the 2.3, 2.4 and 2.5 instructions?

-2.3 Copy the SDK into your projects directory in Finder

From our experience, 3rd-party libraries usually reside inside a subdirectory (let's call our subdirectory Vendor), so if you don't have your project organized with a subdirectory for libraries, now would be a great start for it. To continue our example, create a folder called Vendor inside your project directory and move the unzipped HockeySDK-iOS-folder into it.

The SDK comes in four flavors:

  • Default SDK without Feedback: HockeySDK.embeddedframework
  • Full featured SDK with Feedback: HockeySDK.embeddedframework in the subfolder HockeySDKAllFeatures.
  • Crash reporting only: HockeySDK.framework in the subfolder HockeySDKCrashOnly.
  • Crash reporting only for extensions: HockeySDK.framework in the subfolder HockeySDKCrashOnlyExtension(which is required to be used for extensions).
Our examples will use the default SDK (HockeySDK.embeddedframework).

-2.4 Add the SDK to the project in Xcode
We recommend using Xcode's group-feature to create a group for 3rd-party-libraries similar to the structure of our files on disk. For example, similar to the file structure in 2.3 above, our projects have a group called Vendor.




    • Make sure the Project Navigator is visible (⌘+1).
    • Drag & drop HockeySDK.embeddedframework from your Finder to the Vendor group in Xcode using the Project Navigator on the left side.
    • An overlay will appear. Select Create groups and set the checkmark for your target. Then click Finish.

-2.5 Modify Code:
Objective-C
Open your AppDelegate.m file.
Add the following line at the top of the file below your own import statements:
B4X:
@import HockeySDK;
Search for the method
B4X:
application:didFinishLaunchingWithOptions:
Add the following lines to setup and start the HockeyApp SDK:
B4X:
[[BITHockeyManager sharedHockeyManager] configureWithIdentifier:mad:"APP_IDENTIFIER"];
// Do some additional configuration if needed here
[[BITHockeyManager sharedHockeyManager] startManager];
[[BITHockeyManager sharedHockeyManager].authenticator authenticateInstallation]; // This line is obsolete in the crash only builds

Swift


Open your AppDelegate.swift file.
Add the following line at the top of the file below your own import statements:
B4X:
import HockeySDK

Search for the method
B4X:
func application(_ application: UIApplication, didFinishLaunchingWithOptions launchOptions: [UIApplicationLaunchOptionsKey: Any]?) -> Bool

Add the following lines to setup and start the HockeyApp SDK:
B4X:
BITHockeyManager.shared().configure(withIdentifier: "APP_IDENTIFIER")
BITHockeyManager.shared().start()
BITHockeyManager.shared().authenticator.authenticateInstallation() // This line is obsolete in t
he crash only builds

Since I don't know where to upload the files (I hosted mac user) and where put that code.

Thanks in advance
 
Last edited:
Top