Skip to content

Commit

Permalink
Merge pull request #120 from adjust/app_short_version
Browse files Browse the repository at this point in the history
App short version
  • Loading branch information
nonelse committed Aug 21, 2015
2 parents c2a9fed + a91082d commit 1ee63ff
Show file tree
Hide file tree
Showing 11 changed files with 42 additions and 20 deletions.
4 changes: 2 additions & 2 deletions Adjust.podspec
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
Pod::Spec.new do |s|
s.name = "Adjust"
s.version = "4.2.7"
s.version = "4.2.8"
s.summary = "This is the iOS SDK of adjust. You can read more about it at http://adjust.com."
s.homepage = "http://adjust.com"
s.license = { :type => 'MIT', :file => 'MIT-LICENSE' }
s.author = { "Christian Wellenbrock" => "welle@adjust.com" }
s.source = { :git => "https://github.com/adjust/ios_sdk.git", :tag => "v4.2.7" }
s.source = { :git => "https://github.com/adjust/ios_sdk.git", :tag => "v4.2.8" }
s.platform = :ios, '4.3'
s.framework = 'SystemConfiguration'
s.weak_framework = 'AdSupport', 'iAd'
Expand Down
12 changes: 5 additions & 7 deletions Adjust/ADJActivityHandler.m
Original file line number Diff line number Diff line change
Expand Up @@ -114,15 +114,13 @@ - (void)launchDeepLink:(NSDictionary *)jsonDict{

NSURL* deepLinkUrl = [NSURL URLWithString:deepLink];

if (![[UIApplication sharedApplication]
canOpenURL:deepLinkUrl]) {
[self.logger error:@"Unable to open deep link (%@)", deepLink];
return;
}

[self.logger info:@"Open deep link (%@)", deepLink];

[[UIApplication sharedApplication] openURL:deepLinkUrl];
BOOL success = [[UIApplication sharedApplication] openURL:deepLinkUrl];

if (!success) {
[self.logger error:@"Unable to open deep link (%@)", deepLink];
}
}

- (void)setEnabled:(BOOL)enabled {
Expand Down
1 change: 1 addition & 0 deletions Adjust/ADJDeviceInfo.h
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@
@property (nonatomic, copy) NSString *clientSdk;
@property (nonatomic, copy) NSString *bundeIdentifier;
@property (nonatomic, copy) NSString *bundleVersion;
@property (nonatomic, copy) NSString *bundleShortVersion;
@property (nonatomic, copy) NSString *deviceType;
@property (nonatomic, copy) NSString *deviceName;
@property (nonatomic, copy) NSString *osName;
Expand Down
2 changes: 2 additions & 0 deletions Adjust/ADJDeviceInfo.m
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,7 @@ - (id) initWithSdkPrefix:(NSString *)sdkPrefix {
self.vendorId = UIDevice.currentDevice.adjVendorId;
self.bundeIdentifier = [infoDictionary objectForKey:(NSString *)kCFBundleIdentifierKey];
self.bundleVersion = [infoDictionary objectForKey:(NSString *)kCFBundleVersionKey];
self.bundleShortVersion = [bundle objectForInfoDictionaryKey:@"CFBundleShortVersionString"];
self.languageCode = [locale objectForKey:NSLocaleLanguageCode];
self.countryCode = [locale objectForKey:NSLocaleCountryCode];
self.osName = @"ios";
Expand Down Expand Up @@ -69,6 +70,7 @@ -(id)copyWithZone:(NSZone *)zone
copy.clientSdk = [self.clientSdk copyWithZone:zone];
copy.bundeIdentifier = [self.bundeIdentifier copyWithZone:zone];
copy.bundleVersion = [self.bundleVersion copyWithZone:zone];
copy.bundleShortVersion = [self.bundleShortVersion copyWithZone:zone];
copy.deviceType = [self.deviceType copyWithZone:zone];
copy.deviceName = [self.deviceName copyWithZone:zone];
copy.osName = [self.osName copyWithZone:zone];
Expand Down
9 changes: 5 additions & 4 deletions Adjust/ADJPackageBuilder.m
Original file line number Diff line number Diff line change
Expand Up @@ -95,10 +95,10 @@ - (ADJActivityPackage *)buildClickPackage:(NSString *)clickSource
[self parameters:parameters setDate:self.purchaseTime forKey:@"purchase_time"];

if (self.attribution != nil) {
[self parameters:parameters setString:self.attribution.trackerName forKey:@"tracker"];
[self parameters:parameters setString:self.attribution.campaign forKey:@"campaign"];
[self parameters:parameters setString:self.attribution.adgroup forKey:@"adgroup"];
[self parameters:parameters setString:self.attribution.creative forKey:@"creative"];
[self parameters:parameters setString:self.attribution.trackerName forKey:@"tracker"];
[self parameters:parameters setString:self.attribution.campaign forKey:@"campaign"];
[self parameters:parameters setString:self.attribution.adgroup forKey:@"adgroup"];
[self parameters:parameters setString:self.attribution.creative forKey:@"creative"];
}

ADJActivityPackage *clickPackage = [self defaultActivityPackage];
Expand Down Expand Up @@ -179,6 +179,7 @@ - (void) injectDeviceInfo:(ADJDeviceInfo *)deviceInfo
[self parameters:parameters setString:deviceInfo.pushToken forKey:@"push_token"];
[self parameters:parameters setString:deviceInfo.bundeIdentifier forKey:@"bundle_id"];
[self parameters:parameters setString:deviceInfo.bundleVersion forKey:@"app_version"];
[self parameters:parameters setString:deviceInfo.bundleShortVersion forKey:@"app_version_short"];
[self parameters:parameters setString:deviceInfo.deviceType forKey:@"device_type"];
[self parameters:parameters setString:deviceInfo.deviceName forKey:@"device_name"];
[self parameters:parameters setString:deviceInfo.osName forKey:@"os_name"];
Expand Down
2 changes: 1 addition & 1 deletion Adjust/ADJTimerOnce.m
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ - (NSTimeInterval)fireIn {

- (void)startIn:(NSTimeInterval)startIn
{
self.fireDate = [[NSDate date] initWithTimeIntervalSinceNow:startIn];
self.fireDate = [[NSDate alloc] initWithTimeIntervalSinceNow:startIn];

if (self.source != nil) {
dispatch_cancel(self.source);
Expand Down
2 changes: 1 addition & 1 deletion Adjust/ADJUtil.m
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
#include <sys/xattr.h>

static NSString * const kBaseUrl = @"https://app.adjust.com";
static NSString * const kClientSdk = @"ios4.2.7";
static NSString * const kClientSdk = @"ios4.2.8";

static NSString * const kDateFormat = @"yyyy-MM-dd'T'HH:mm:ss.SSS'Z'Z";
static NSDateFormatter *dateFormat;
Expand Down
2 changes: 1 addition & 1 deletion AdjustTests/ADJPackageFields.m
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ - (id) init {

// default values
self.appToken = @"123456789012";
self.clientSdk = @"ios4.2.7";
self.clientSdk = @"ios4.2.8";
self.suffix = @"";
self.environment = @"sandbox";

Expand Down
24 changes: 22 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ If you're using [CocoaPods][cocoapods], you can add the following line to your
`Podfile` and continue with [step 3](#step3):

```ruby
pod 'Adjust', :git => 'git://github.com/adjust/ios_sdk.git', :tag => 'v4.2.7'
pod 'Adjust', :git => 'git://github.com/adjust/ios_sdk.git', :tag => 'v4.2.8'
```

### 1. Get the SDK
Expand Down Expand Up @@ -343,7 +343,27 @@ You can check if the adjust SDK is currently enabled by calling the function
`isEnabled`. It is always possible to activate the adjust SDK by invoking
`setEnabled` with the enabled parameter as `YES`.

### 11. Partner parameters
### 11. Offline mode

You can put the adjust SDK in offline mode to suspend transmission to our servers,
while retaining tracked data to be sent later. While in offline mode, all information is saved
in a file, so be careful not to trigger too many events while in offline mode.

You can activate offline mode by calling `setOfflineMode` with the parameter `YES`.

```objc
[Adjust setOfflineMode:YES];
```
Conversely, you can deactivate offline mode by calling `setOfflineMode` with `NO`.
When the adjust SDK is put back in online mode, all saved information is send to our servers
with the correct time information.
Unlike disabling tracking, this setting is *not remembered*
bettween sessions. This means that the SDK is in online mode whenever it is started,
even if the app was terminated in offline mode.
### 12. Partner parameters
You can also add parameters to be transmitted to network partners, for the
integrations that have been activated in your adjust dashboard.
Expand Down
2 changes: 1 addition & 1 deletion VERSION
Original file line number Diff line number Diff line change
@@ -1 +1 @@
4.2.7
4.2.8
2 changes: 1 addition & 1 deletion doc/migrate.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
## Migrate your adjust SDK for iOS to v4.2.7 from v3.4.0
## Migrate your adjust SDK for iOS to v4.2.8 from v3.4.0

### Initial setup

Expand Down

0 comments on commit 1ee63ff

Please sign in to comment.