Commit f444c027 by sikang

load bugly for website

parent b4109455
...@@ -27,41 +27,35 @@ android { ...@@ -27,41 +27,35 @@ android {
} }
productFlavors { productFlavors {
website { website {
//是否集成bugly buildConfigField('String', 'BUGLY_APPID', "${bugly_appid}")
buildConfigField 'Boolean', 'LOAD_BUGLY', 'true'
dimension "channel" dimension "channel"
} }
googleplay { googleplay {
buildConfigField 'Boolean', 'LOAD_BUGLY', 'false' buildConfigField('String', 'BUGLY_APPID', "\"\"")
dimension "channel" dimension "channel"
} }
} }
} }
dependencies { dependencies {
exec{ exec {
workingDir = "../lib_base/script" workingDir = "../lib_base/script"
if ("${tongdun_parent_key}".size() > 5) { if ("${tongdun_parent_key}".size() > 5) {
implementation(name: 'android_spirit-20190220-2.0.0.1', ext: 'aar') implementation(name: 'android_spirit-20190220-2.0.0.1', ext: 'aar')
implementation 'com.alibaba:fastjson:1.1.58.android' implementation 'com.alibaba:fastjson:1.1.58.android'
executable 'sh' args "-c","./sdk_manager.py open TD" executable 'sh' args "-c", "./sdk_manager.py open TD"
}else{ } else {
executable 'sh' args "-c","./sdk_manager.py close TD" executable 'sh' args "-c", "./sdk_manager.py close TD"
} }
} }
// exec{ // def startParams = getGradle().getStartParameter().getTaskRequests()[0]
// workingDir = "../lib_base/script" // if(startParams!=null && startParams.getArgs().toString().contains("Website")){
// def startParams = getGradle().getStartParameter().getTaskRequests()[0]
// if(startParams!=null && startParams.getArgs().toString().contains("Website")){
// implementation 'com.tencent.bugly:crashreport:3.0.0'
// executable 'sh' args "-c","./sdk_manager.py open BUGLY"
// }else{
// executable 'sh' args "-c","./sdk_manager.py close BUGLY"
// }
// } // }
websiteImplementation 'com.tencent.bugly:crashreport:3.0.0'
implementation project(':cash_plugin_toolbox') implementation project(':cash_plugin_toolbox')
} }
......
...@@ -16,6 +16,7 @@ android { ...@@ -16,6 +16,7 @@ android {
//Api //Api
buildConfigField('String', 'FACEBOOK_APP_ID', "\"${facebook_app_id}\"") buildConfigField('String', 'FACEBOOK_APP_ID', "\"${facebook_app_id}\"")
buildConfigField('String', 'ACCOUNT_KIT_CLIENT_TOKEN', "\"${account_kit_client_token}\"") buildConfigField('String', 'ACCOUNT_KIT_CLIENT_TOKEN', "\"${account_kit_client_token}\"")
} }
buildTypes { buildTypes {
release { release {
...@@ -76,6 +77,9 @@ dependencies { ...@@ -76,6 +77,9 @@ dependencies {
//同盾 //同盾
compileOnly(name: 'android_spirit-20190220-2.0.0.1', ext: 'aar') compileOnly(name: 'android_spirit-20190220-2.0.0.1', ext: 'aar')
//bugly
compileOnly 'com.tencent.bugly:crashreport:3.0.0'
api(name: 'libfbref-release', ext: 'aar') api(name: 'libfbref-release', ext: 'aar')
......
...@@ -6,6 +6,7 @@ import android.content.res.Configuration; ...@@ -6,6 +6,7 @@ import android.content.res.Configuration;
import android.os.Bundle; import android.os.Bundle;
import android.support.multidex.MultiDex; import android.support.multidex.MultiDex;
import android.support.multidex.MultiDexApplication; import android.support.multidex.MultiDexApplication;
import android.text.TextUtils;
import android.util.Log; import android.util.Log;
import android.view.Gravity; import android.view.Gravity;
import android.view.View; import android.view.View;
...@@ -18,11 +19,13 @@ import com.jcminarro.philology.Philology; ...@@ -18,11 +19,13 @@ import com.jcminarro.philology.Philology;
import com.jcminarro.philology.PhilologyInterceptor; import com.jcminarro.philology.PhilologyInterceptor;
import com.jcminarro.philology.PhilologyRepository; import com.jcminarro.philology.PhilologyRepository;
import com.jcminarro.philology.PhilologyRepositoryFactory; import com.jcminarro.philology.PhilologyRepositoryFactory;
import com.tencent.bugly.crashreport.CrashReport;
import org.jetbrains.annotations.NotNull; import org.jetbrains.annotations.NotNull;
import org.jetbrains.annotations.Nullable; import org.jetbrains.annotations.Nullable;
import io.github.inflationx.viewpump.ViewPump; import io.github.inflationx.viewpump.ViewPump;
import tech.starwin.BuildConfig;
import tech.starwin.LibConfig; import tech.starwin.LibConfig;
import tech.starwin.network.Gateway; import tech.starwin.network.Gateway;
import tech.starwin.utils.InstallReferrerHelper; import tech.starwin.utils.InstallReferrerHelper;
...@@ -52,8 +55,6 @@ public abstract class BaseApplication extends MultiDexApplication { ...@@ -52,8 +55,6 @@ public abstract class BaseApplication extends MultiDexApplication {
@Override @Override
public void onCreate() { public void onCreate() {
super.onCreate(); super.onCreate();
// CrashReport.initCrashReport(getApplicationContext(), "注册时申请的APPID", false);
AppLanguageUtils.setLanguage(this, LibConfig.LANGUAGE); AppLanguageUtils.setLanguage(this, LibConfig.LANGUAGE);
PhilologyRepositoryFactory repositoryFactory = locale -> new DefaultPhilologyRepository(); PhilologyRepositoryFactory repositoryFactory = locale -> new DefaultPhilologyRepository();
......
...@@ -50,7 +50,6 @@ public class LibConfig { ...@@ -50,7 +50,6 @@ public class LibConfig {
public static String AGREEMENT_URL; public static String AGREEMENT_URL;
public static String REPAYMENT_H5; public static String REPAYMENT_H5;
public static String APP_URL; public static String APP_URL;
public static String BUGLY_APP_ID;
public static String PRIVACY_POLICY; public static String PRIVACY_POLICY;
public static String HOTLINE; public static String HOTLINE;
public static String LOAN_AGREEMENT; public static String LOAN_AGREEMENT;
...@@ -60,6 +59,7 @@ public class LibConfig { ...@@ -60,6 +59,7 @@ public class LibConfig {
public static String GATEWAY_HOST_G0; public static String GATEWAY_HOST_G0;
public static String GATEWAY_HOST_G1; public static String GATEWAY_HOST_G1;
public static String HARVESTER_IP; public static String HARVESTER_IP;
public static String BUGLY_APPID;
public static String ZENDESK_URL; public static String ZENDESK_URL;
public static String ZENDESK_APP_ID; public static String ZENDESK_APP_ID;
public static String ZENDESK_OAUTH_CLIENT_ID; public static String ZENDESK_OAUTH_CLIENT_ID;
...@@ -70,7 +70,6 @@ public class LibConfig { ...@@ -70,7 +70,6 @@ public class LibConfig {
public static String APPSFLYER_DEV_KEY; public static String APPSFLYER_DEV_KEY;
public static String XH_CHANNEL_NAME; public static String XH_CHANNEL_NAME;
public static boolean IS_COLLECT_MODE; public static boolean IS_COLLECT_MODE;
public static boolean LOAD_BUGLY = false;
public static String TEST_TOKEN; public static String TEST_TOKEN;
public static String LANGUAGE = "in"; public static String LANGUAGE = "in";
public static int HARVESTER_PORT;// public static int HARVESTER_PORT;//
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment