Bug 1152871 - Include Adjust SDK private token in builds. r=mfinkle
authorNick Alexander <nalexander@mozilla.com>
Wed, 29 Apr 2015 09:56:02 -0700
changeset 241873 4767a0a19a62116c4d0575344033154a77b369be
parent 241872 94ca3cad5caa837d14b9ac77f8d8a4f4382b7679
child 241874 5b3682f97a33ff7d50ec75792e01416b8a6c2d3a
push id28671
push userryanvm@gmail.com
push dateFri, 01 May 2015 14:27:58 +0000
treeherdermozilla-central@60b269fed8cf [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersmfinkle
bugs1152871
milestone40.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 1152871 - Include Adjust SDK private token in builds. r=mfinkle
mobile/android/base/adjust/AdjustHelper.java
mobile/android/config/mozconfigs/common
--- a/mobile/android/base/adjust/AdjustHelper.java
+++ b/mobile/android/base/adjust/AdjustHelper.java
@@ -12,24 +12,27 @@ import com.adjust.sdk.Adjust;
 import com.adjust.sdk.AdjustConfig;
 import com.adjust.sdk.AdjustReferrerReceiver;
 import com.adjust.sdk.LogLevel;
 
 public class AdjustHelper implements AdjustHelperInterface {
     public void onCreate(final Context context, final String maybeAppToken) {
         final String environment;
         final String appToken;
+        final LogLevel logLevel;
         if (maybeAppToken != null) {
             environment = AdjustConfig.ENVIRONMENT_PRODUCTION;
             appToken = maybeAppToken;
+            logLevel = LogLevel.WARN;
         } else {
             environment = AdjustConfig.ENVIRONMENT_SANDBOX;
             appToken = "ABCDEFGHIJKL";
+            logLevel = LogLevel.VERBOSE;
         }
         AdjustConfig config = new AdjustConfig(context, appToken, environment);
-        config.setLogLevel(LogLevel.VERBOSE);
+        config.setLogLevel(logLevel);
         Adjust.onCreate(config);
     }
 
     public void onReceive(final Context context, final Intent intent) {
         new AdjustReferrerReceiver().onReceive(context, intent);
     }
 }
--- a/mobile/android/config/mozconfigs/common
+++ b/mobile/android/config/mozconfigs/common
@@ -32,16 +32,17 @@ ac_add_options --with-android-gnu-compil
 ac_add_options --with-android-version=9
 ac_add_options --with-system-zlib
 ac_add_options --enable-update-channel=${MOZ_UPDATE_CHANNEL}
 
 # Treat warnings as errors in directories with FAIL_ON_WARNINGS.
 ac_add_options --enable-warnings-as-errors
 
 ac_add_options --with-mozilla-api-keyfile=/builds/mozilla-fennec-geoloc-api.key
+ac_add_options --with-adjust-sdk-keyfile=/builds/adjust-sdk.token
 
 # Package js shell.
 export MOZ_PACKAGE_JSSHELL=1
 
 # Use ccache
 . "$topsrcdir/build/mozconfig.cache"
 
 HOST_CC="$topsrcdir/gcc/bin/gcc"