Merge branch 'develop' into feature/telemetry

# Conflicts:
#	Classes/BITHockeyManager.m
#	HockeySDK-Source.podspec
#	README.md
#	Support/buildnumber.xcconfig
#	Support/release.xcconfig
#	docs/Changelog-template.md
#	docs/Guide-Installation-Setup-template.md
This commit is contained in:
Lukas Spieß 2015-12-09 13:24:04 +01:00
commit 6304f49d69
20 changed files with 100 additions and 65 deletions

View File

@ -348,7 +348,7 @@ static const char *findSEL (const char *imageName, NSString *imageUUID, uint64_t
processPath = report.processInfo.processPath;
/* Remove username from the path */
#if TARGET_IPHONE_SIMULATOR
#if TARGET_OS_SIMULATOR
if ([processPath length] > 0)
processPath = [processPath stringByAbbreviatingWithTildeInPath];
if ([processPath length] > 0 && [[processPath substringToIndex:1] isEqualToString:@"~"])
@ -438,7 +438,7 @@ static const char *findSEL (const char *imageName, NSString *imageUUID, uint64_t
NSString *foundSelector = nil;
// search the registers value for the current arch
#if TARGET_IPHONE_SIMULATOR
#if TARGET_OS_SIMULATOR
if (lp64) {
foundSelector = [[self class] selectorForRegisterWithName:@"rsi" ofThread:crashed_thread report:report];
if (foundSelector == NULL)
@ -577,13 +577,13 @@ static const char *findSEL (const char *imageName, NSString *imageUUID, uint64_t
/* Remove username from the image path */
NSString *imageName = @"";
if (imageInfo.imageName && [imageInfo.imageName length] > 0) {
#if TARGET_IPHONE_SIMULATOR
#if TARGET_OS_SIMULATOR
imageName = [imageInfo.imageName stringByAbbreviatingWithTildeInPath];
#else
imageName = imageInfo.imageName;
#endif
}
#if TARGET_IPHONE_SIMULATOR
#if TARGET_OS_SIMULATOR
if ([imageName length] > 0 && [[imageName substringToIndex:1] isEqualToString:@"~"])
imageName = [NSString stringWithFormat:@"/Users/USER%@", [imageName substringFromIndex:1]];
#endif

View File

@ -27,9 +27,9 @@
*/
#import <Foundation/Foundation.h>
#import "BITFeedbackComposeViewControllerDelegate.h"
@class BITFeedbackManager;
@protocol BITFeedbackComposeViewControllerDelegate;
/**
* Delegate protocol which is notified about changes in the feedbackManager

View File

@ -28,6 +28,7 @@
#import <Foundation/Foundation.h>
#import <UIKit/UIKit.h>
#import "HockeySDKEnums.h"
/* NSString helpers */
NSString *bit_URLEncodedString(NSString *inputString);
@ -50,8 +51,7 @@ BOOL bit_isPreiOS7Environment(void);
BOOL bit_isPreiOS8Environment(void);
BOOL bit_isAppStoreReceiptSandbox(void);
BOOL bit_hasEmbeddedMobileProvision(void);
BOOL bit_isRunningInTestFlightEnvironment(void);
BOOL bit_isRunningInAppStoreEnvironment(void);
BITEnvironment bit_currentAppEnvironment(void);
BOOL bit_isRunningInAppExtension(void);
#if !defined (HOCKEYSDK_CONFIGURATION_ReleaseCrashOnly) && !defined (HOCKEYSDK_CONFIGURATION_ReleaseCrashOnlyExtensions)

View File

@ -309,9 +309,12 @@ BOOL bit_isPreiOS8Environment(void) {
}
BOOL bit_isAppStoreReceiptSandbox(void) {
#if TARGET_IPHONE_SIMULATOR
#if TARGET_OS_SIMULATOR
return NO;
#else
if (![NSBundle.mainBundle respondsToSelector:@selector(appStoreReceiptURL)]) {
return NO;
}
NSURL *appStoreReceiptURL = NSBundle.mainBundle.appStoreReceiptURL;
NSString *appStoreReceiptLastComponent = appStoreReceiptURL.lastPathComponent;
@ -325,25 +328,26 @@ BOOL bit_hasEmbeddedMobileProvision(void) {
return hasEmbeddedMobileProvision;
}
BOOL bit_isRunningInTestFlightEnvironment(void) {
#if TARGET_IPHONE_SIMULATOR
return NO;
BITEnvironment bit_currentAppEnvironment(void) {
#if TARGET_OS_SIMULATOR
return BITEnvironmentOther;
#else
if (bit_isAppStoreReceiptSandbox() && !bit_hasEmbeddedMobileProvision()) {
return YES;
// MobilePovision profiles are a clear indicator for Ad-Hoc distribution
if (bit_hasEmbeddedMobileProvision()) {
return BITEnvironmentOther;
}
return NO;
#endif
}
BOOL bit_isRunningInAppStoreEnvironment(void) {
#if TARGET_IPHONE_SIMULATOR
return NO;
#else
if (bit_isAppStoreReceiptSandbox() || bit_hasEmbeddedMobileProvision()) {
return NO;
// TestFlight is only supported from iOS 8 onwards, so at this point we have to be in the AppStore
if (floor(NSFoundationVersionNumber) <= NSFoundationVersionNumber_iOS_6_1) {
return BITEnvironmentAppStore;
}
return YES;
if (bit_isAppStoreReceiptSandbox()) {
return BITEnvironmentTestFlight;
}
return BITEnvironmentAppStore;
#endif
}

View File

@ -416,7 +416,7 @@
TestFlight and Other. Other summarizes several different distribution methods
and we might define additional specifc values for other environments in the future.
@see `BITEnvironment`
@see BITEnvironment
*/
@property (nonatomic, readonly) BITEnvironment appEnvironment;

View File

@ -172,18 +172,13 @@ bitstadium_info_t bitstadium_library_info __attribute__((section("__TEXT,__bit_h
_installString = bit_appAnonID(NO);
_disableInstallTracking = NO;
#if !TARGET_IPHONE_SIMULATOR
_appStoreEnvironment = NO;
// check if we are really in an app store environment
if (bit_isRunningInAppStoreEnvironment()) {
_appEnvironment = BITEnvironmentAppStore;
_appEnvironment = bit_currentAppEnvironment();
if (_appEnvironment == BITEnvironmentAppStore) {
_appStoreEnvironment = YES;
} else if (bit_isRunningInTestFlightEnvironment()) {
_appEnvironment = BITEnvironmentTestFlight;
} else {
_appEnvironment = BITEnvironmentOther;
}
#endif
[self performSelector:@selector(validateStartManagerIsInvoked) withObject:nil afterDelay:0.0f];
}
return self;

View File

@ -924,7 +924,7 @@ typedef NS_ENUM(NSInteger, BITUpdateAlertViewTag) {
return NO;
}
#if TARGET_IPHONE_SIMULATOR
#if TARGET_OS_SIMULATOR
/* We won't use this for now until we have a more robust solution for displaying UIAlertController
// requires iOS 8
id uialertcontrollerClass = NSClassFromString(@"UIAlertController");
@ -980,7 +980,7 @@ typedef NS_ENUM(NSInteger, BITUpdateAlertViewTag) {
return success;
#endif /* TARGET_IPHONE_SIMULATOR */
#endif /* TARGET_OS_SIMULATOR */
}

View File

@ -393,9 +393,8 @@
}
}
}
BITWebTableViewCell *cell = [[BITWebTableViewCell alloc] initWithStyle:UITableViewCellStyleDefault reuseIdentifier:kWebCellIdentifier];
[self configureWebCell:cell forAppVersion:appVersion];
BITWebTableViewCell *cell = [self webCellWithAppVersion:appVersion];
[_cells addObject:cell];
if (breakAfterThisAppVersion) break;
@ -405,6 +404,12 @@
[self showHidePreviousVersionsButton];
}
- (BITWebTableViewCell *)webCellWithAppVersion:(BITAppVersionMetaInfo *)appVersion {
BITWebTableViewCell *cell = [[BITWebTableViewCell alloc] initWithStyle:UITableViewCellStyleDefault reuseIdentifier:kWebCellIdentifier];
[self configureWebCell:cell forAppVersion:appVersion];
return cell;
}
- (void)showPreviousVersionAction {
_showAllVersions = YES;
BOOL showAllPending = NO;
@ -420,10 +425,8 @@
continue; // skip already shown
}
}
BITWebTableViewCell *cell = [[BITWebTableViewCell alloc] initWithStyle:UITableViewCellStyleDefault reuseIdentifier:kWebCellIdentifier];
[self configureWebCell:cell forAppVersion:appVersion];
[_cells addObject:cell];
[_cells addObject:[self webCellWithAppVersion:appVersion]];
}
[self.tableView reloadData];
[self showHidePreviousVersionsButton];

View File

@ -155,16 +155,26 @@ body { font: 13px 'Helvetica Neue', Helvetica; color:#626262; word-wrap:break-wo
}
#pragma mark - UIWebView
#pragma mark - UIWebViewDelegate
- (BOOL)webView:(UIWebView *)webView shouldStartLoadWithRequest:(NSURLRequest *)request navigationType:(UIWebViewNavigationType)navigationType {
if(navigationType == UIWebViewNavigationTypeOther)
return YES;
return NO;
switch (navigationType) {
case UIWebViewNavigationTypeLinkClicked:
[self openURL:request.URL];
return NO;
break;
case UIWebViewNavigationTypeOther:
return YES;
break;
case UIWebViewNavigationTypeBackForward:
case UIWebViewNavigationTypeFormResubmitted:
case UIWebViewNavigationTypeFormSubmitted:
case UIWebViewNavigationTypeReload:
return NO;
break;
}
}
- (void)webViewDidFinishLoad:(UIWebView *)webView {
if(_webViewContent)
[self showWebView];
@ -181,6 +191,12 @@ body { font: 13px 'Helvetica Neue', Helvetica; color:#626262; word-wrap:break-wo
self.webViewSize = CGSizeMake(fittingSize.width, [output integerValue]);
}
#pragma mark - Helper
- (void)openURL:(NSURL *)URL {
[[UIApplication sharedApplication] openURL:URL];
}
@end
#endif /* HOCKEYSDK_FEATURE_UPDATES */

View File

@ -79,6 +79,19 @@ NSString *BITHockeyMD5(NSString *str);
#define __IPHONE_8_0 80000
#endif
#ifndef TARGET_OS_SIMULATOR
#ifdef TARGET_IPHONE_SIMULATOR
#define TARGET_OS_SIMULATOR TARGET_IPHONE_SIMULATOR
#else
#define TARGET_OS_SIMULATOR 0
#endif /* TARGET_IPHONE_SIMULATOR */
#endif /* TARGET_OS_SIMULATOR */
#if __IPHONE_OS_VERSION_MIN_REQUIRED > __IPHONE_6_1

View File

@ -1,6 +1,6 @@
Pod::Spec.new do |s|
s.name = 'HockeySDK-Source'
s.version = '3.8.4'
s.version = '3.8.5'
s.summary = 'Collect live crash reports, get feedback from your users, distribute your betas, and analyze your test coverage with HockeyApp.'
s.description = <<-DESC
@ -15,7 +15,7 @@ Pod::Spec.new do |s|
s.documentation_url = "http://hockeyapp.net/help/sdk/ios/#{s.version}/"
s.license = 'MIT'
s.author = { 'Andreas Linde' => 'mail@andreaslinde.de', 'Thomas Dohmke' => "thomas@dohmke.de" }
s.author = { 'Microsoft' => 'support@hockeyapp.net' }
s.source = { :git => 'https://github.com/bitstadium/HockeySDK-iOS.git', :tag => s.version.to_s }
s.platform = :ios, '7.0'

View File

@ -1,6 +1,6 @@
Pod::Spec.new do |s|
s.name = 'HockeySDK'
s.version = '3.8.4'
s.version = '3.8.5'
s.summary = 'Collect live crash reports, get feedback from your users, distribute your betas, and analyze your test coverage with HockeyApp.'
s.description = <<-DESC
@ -15,7 +15,7 @@ Pod::Spec.new do |s|
s.documentation_url = "http://hockeyapp.net/help/sdk/ios/#{s.version}/"
s.license = { :type => 'MIT', :file => 'HockeySDK-iOS/LICENSE' }
s.author = { 'Andreas Linde' => 'mail@andreaslinde.de', 'Thomas Dohmke' => "thomas@dohmke.de" }
s.author = { 'Microsoft' => 'support@hockeyapp.net' }
s.platform = :ios, '7.0'
s.ios.deployment_target = '6.0'

View File

@ -3,7 +3,7 @@
The Hockey SDK is provided under the following license:
The MIT License
Copyright (c) 2012-2015 HockeyApp, Bit Stadium GmbH.
Copyright (c) Microsoft Corporation.
All rights reserved.
Permission is hereby granted, free of charge, to any person

View File

@ -1,3 +1,4 @@
OTHER_LDFLAGS=$(inherited) -framework CrashReporter -framework AssetsLibrary -framework CoreTelephony -framework CoreText -framework CoreGraphics -framework Foundation -framework MobileCoreServices -framework Photos -framework QuartzCore -framework QuickLook -framework Security -framework SystemConfiguration -framework UIKit -lc++ -lz
HOCKEYSDK_DOCSET_NAME=HockeySDK-iOS
HOCKEYSDK_GCC_PREPROCESSOR_DEFINITIONS=$(inherited) $(XCODEBUILD_GCC_PREPROCESSOR_DEFINITIONS)
HOCKEYSDK_WARNING_FLAGS = -Wshorten-64-to-32 -Wall

View File

@ -1699,7 +1699,7 @@
);
runOnlyForDeploymentPostprocessing = 0;
shellPath = /bin/sh;
shellScript = "/usr/local/bin/appledoc \\\n --output \"${SOURCE_ROOT}/../documentation\" \\\n --ignore Vendor \\\n --ignore Products \\\n --ignore Support \\\n --ignore .m \\\n --ignore *Private.h \\\n --ignore BITAttributedLabel.h \\\n --ignore BITStoreButton.h \\\n --ignore BITFeedbackListViewCell.h \\\n --ignore BITAppStoreHeader.h \\\n --ignore BITFeedbackMessage.h \\\n --ignore BITFeedbackMessageAttachment.h \\\n --ignore BITAuthenticationViewController.h \\\n --ignore BITHockeyAppClient.h \\\n --create-html \\\n --create-docset \\\n --install-docset \\\n --keep-intermediate-files \\\n --project-name \"${HOCKEYSDK_DOCSET_NAME} ${VERSION_STRING}\" \\\n --project-version \"${VERSION_STRING}\" \\\n --project-company \"Bit Stadium GmbH\" \\\n --company-id \"de.bitstadium\" \\\n --docset-bundle-name \"${HOCKEYSDK_DOCSET_NAME} ${VERSION_STRING}\" \\\n --docset-feed-name \"${HOCKEYSDK_DOCSET_NAME}\" \\\n --docset-desc \"\" \\\n --docset-platform-family \"iphoneos\" \\\n --index-desc \"${SOURCE_ROOT}/../docs/index.md\" \\\n --include \"${SOURCE_ROOT}/../docs/index.html\" \\\n --include \"${SOURCE_ROOT}/../docs/\" \\\n --merge-categories \\\n --no-repeat-first-par \\\n --warn-undocumented-object \\\n --warn-undocumented-member \\\n --warn-empty-description \\\n --warn-unknown-directive \\\n --warn-invalid-crossref \\\n --warn-missing-arg \\\n --logformat xcode \\\n --exit-threshold 2 \\\n \"${SOURCE_ROOT}/../\"\n";
shellScript = "${SRCROOT}/appledoc \\\n --output \"${SOURCE_ROOT}/../documentation\" \\\n --ignore Vendor \\\n --ignore Products \\\n --ignore Support \\\n --ignore .m \\\n --ignore *Private.h \\\n --ignore BITAttributedLabel.h \\\n --ignore BITStoreButton.h \\\n --ignore BITFeedbackListViewCell.h \\\n --ignore BITAppStoreHeader.h \\\n --ignore BITFeedbackMessage.h \\\n --ignore BITFeedbackMessageAttachment.h \\\n --ignore BITAuthenticationViewController.h \\\n --ignore BITHockeyAppClient.h \\\n --create-html \\\n --create-docset \\\n --install-docset \\\n --keep-intermediate-files \\\n --project-name \"${HOCKEYSDK_DOCSET_NAME} ${VERSION_STRING}\" \\\n --project-version \"${VERSION_STRING}\" \\\n --project-company \"Bit Stadium GmbH\" \\\n --company-id \"de.bitstadium\" \\\n --docset-bundle-name \"${HOCKEYSDK_DOCSET_NAME} ${VERSION_STRING}\" \\\n --docset-feed-name \"${HOCKEYSDK_DOCSET_NAME}\" \\\n --docset-desc \"\" \\\n --docset-platform-family \"iphoneos\" \\\n --index-desc \"${SOURCE_ROOT}/../docs/index.md\" \\\n --include \"${SOURCE_ROOT}/../docs/index.html\" \\\n --include \"${SOURCE_ROOT}/../docs/\" \\\n --merge-categories \\\n --no-repeat-first-par \\\n --warn-undocumented-object \\\n --warn-undocumented-member \\\n --warn-empty-description \\\n --warn-unknown-directive \\\n --warn-invalid-crossref \\\n --warn-missing-arg \\\n --logformat xcode \\\n --exit-threshold 2 \\\n \"${SOURCE_ROOT}/../\"\n";
};
/* End PBXShellScriptBuildPhase section */
@ -2120,7 +2120,6 @@
DYLIB_COMPATIBILITY_VERSION = 1;
DYLIB_CURRENT_VERSION = 1;
DYLIB_INSTALL_NAME_BASE = "@rpath";
ENABLE_BITCODE = NO;
ENABLE_NS_ASSERTIONS = NO;
ENABLE_STRICT_OBJC_MSGSEND = YES;
FRAMEWORK_SEARCH_PATHS = (
@ -2633,7 +2632,6 @@
DYLIB_COMPATIBILITY_VERSION = 1;
DYLIB_CURRENT_VERSION = 1;
DYLIB_INSTALL_NAME_BASE = "@rpath";
ENABLE_BITCODE = NO;
ENABLE_STRICT_OBJC_MSGSEND = YES;
FRAMEWORK_SEARCH_PATHS = (
"$(inherited)",
@ -2686,7 +2684,6 @@
DYLIB_COMPATIBILITY_VERSION = 1;
DYLIB_CURRENT_VERSION = 1;
DYLIB_INSTALL_NAME_BASE = "@rpath";
ENABLE_BITCODE = NO;
ENABLE_NS_ASSERTIONS = NO;
ENABLE_STRICT_OBJC_MSGSEND = YES;
FRAMEWORK_SEARCH_PATHS = (
@ -2737,7 +2734,6 @@
DYLIB_COMPATIBILITY_VERSION = 1;
DYLIB_CURRENT_VERSION = 1;
DYLIB_INSTALL_NAME_BASE = "@rpath";
ENABLE_BITCODE = NO;
ENABLE_NS_ASSERTIONS = NO;
ENABLE_STRICT_OBJC_MSGSEND = YES;
FRAMEWORK_SEARCH_PATHS = (

BIN
Support/appledoc Executable file

Binary file not shown.

View File

@ -7,4 +7,4 @@ BIT_ARM_ARCHS = armv7 armv7s arm64
BIT_SIM_ARCHS = x86_64 i386
ARCHS = $(BIT_ARM_ARCHS)
VALID_ARCHS = $(BIT_ARM_ARCHS)
OTHER_CFLAGS = -Wall -Wextra -Wshorten-64-to-32 -Wno-unused-parameter
OTHER_CFLAGS = $(HOCKEYSDK_WARNING_FLAGS)

View File

@ -1,4 +1,4 @@
#include "buildnumber.xcconfig"
OTHER_CFLAGS[sdk=iphoneos9.*] = -Wall -Wextra -Wshorten-64-to-32 -Wno-unused-parameter -fembed-bitcode
OTHER_CFLAGS[sdk=iphonesimulator9.*] = -Wall -Wextra -Wshorten-64-to-32 -Wno-unused-parameter
OTHER_CFLAGS[sdk=iphoneos9.*] = $(HOCKEYSDK_WARNING_FLAGS) -fembed-bitcode
OTHER_CFLAGS[sdk=iphonesimulator9.*] = $(HOCKEYSDK_WARNING_FLAGS)

View File

@ -2,6 +2,12 @@
- [NEW] Added `BITTelemetryManager` to track users and sessions
## Version 3.8.5
- [UPDATE] Some minor improvements to our documentation
- [BUGFIX] Fix a crash where `appStoreReceiptURL` was accidentally accessed on iOS 6
- [BUGFIX] Fix a warning when implementing `BITHockeyManagerDelegate`
## Version 3.8.4
- [BUGFIX] Fix a missing header in the `HockeySDK.h` umbrella

View File

@ -5,10 +5,11 @@ Mac and iOS crash reports show the stack traces for all running threads of your
To get these memory addresses translated you need to upload a dSYM package to the server, which contains all information required to make this happen. The symbolication process will then check the binary images section of the crash report and grab the UUID of the binary that caused the crash. Next it will get the UUID of the dSYM package to make sure they are identical and process the data if so.
**WARNING:** Every time you are doing a build, the app binary and the dSYM will get a new unique UUID, no matter if you changed the code or not. So make sure to archive all your binaries and dSYMs that you are using for beta or app store builds!
This will also apply when using Bitcode. Then, Apple will use your uploaded build and re-compile it on their end. Whenever this happens, this also changes the UUID and requires you to download the newly generated dSYM from Apple and upload it to HockeyApp.
## HowTo
Once you have your app ready for beta testing or even to submit it to the App Store, you need to upload the `.dSYM` bundle to HockeyApp to enable symbolication. If you have built your app with Xcode4, menu `Product` > `Archive`, you can find the `.dSYM` as follows:
Once you have your app ready for beta testing or even to submit it to the App Store, you need to upload the `.dSYM` bundle to HockeyApp to enable symbolication. If you have built your app with Xcode, menu `Product` > `Archive`, you can find the `.dSYM` as follows:
1. Chose `Window` > `Organizer` in Xcode.
2. Select the tab Archives.
@ -19,6 +20,6 @@ Once you have your app ready for beta testing or even to submit it to the App St
## Mac Desktop Uploader
As an alternative, you can use our [HockeyMac](Guide-Installation-Mac-App) app to upload the complete archive in one step. You can even integrate HockeyMac into Xcode to automatically show the upload interface after archiving your app, which would make all steps 1 to 6 not necessary any more!
As an alternative, you can use our [HockeyApp for Mac](http://hockeyapp.net/releases/mac/) app to upload the complete archive in one step.
Check out the [Mac Desktop Uploader Guide](Guide-Installation-Mac-App).
Also check out the guide on [how to upload to HockeyApp from Mac OS X](http://support.hockeyapp.net/kb/client-integration-ios-mac-os-x/how-to-upload-to-hockeyapp-from-mac-os-x).