From cae1eba3cb64daab903a51fe905b76c624a3cd1f Mon Sep 17 00:00:00 2001 From: Hiddify1 Date: Mon, 1 May 2023 19:59:29 +0200 Subject: [PATCH] new: add crash handler --- V2rayNG/app/build.gradle | 5 +-- V2rayNG/app/release/output-metadata.json | 36 +++++++++---------- .../kotlin/com/v2ray/ang/AngApplication.kt | 2 ++ V2rayNG/build.gradle | 1 + 4 files changed, 24 insertions(+), 20 deletions(-) diff --git a/V2rayNG/app/build.gradle b/V2rayNG/app/build.gradle index 23ea07980..b6d037e6c 100644 --- a/V2rayNG/app/build.gradle +++ b/V2rayNG/app/build.gradle @@ -19,8 +19,8 @@ android { minSdkVersion 21 targetSdkVersion Integer.parseInt("$targetSdkVer") multiDexEnabled true - versionCode 5100201 //hiddify - versionName "1.2.1" //hiddify + versionCode 5100202 //hiddify + versionName "1.2.2" //hiddify } buildTypes { @@ -132,3 +132,4 @@ dependencies { } +apply plugin: 'com.google.gms.google-services' diff --git a/V2rayNG/app/release/output-metadata.json b/V2rayNG/app/release/output-metadata.json index 1e369931a..f64659bf7 100644 --- a/V2rayNG/app/release/output-metadata.json +++ b/V2rayNG/app/release/output-metadata.json @@ -11,8 +11,8 @@ "type": "UNIVERSAL", "filters": [], "attributes": [], - "versionCode": 5100200, - "versionName": "1.2.0", + "versionCode": 5100201, + "versionName": "1.2.1", "outputFile": "HiddifyNG_null.apk" }, { @@ -20,52 +20,52 @@ "filters": [ { "filterType": "ABI", - "value": "armeabi-v7a" + "value": "x86" } ], "attributes": [], - "versionCode": 6100200, - "versionName": "1.2.0", - "outputFile": "HiddifyNG_armeabi-v7a.apk" + "versionCode": 8100201, + "versionName": "1.2.1", + "outputFile": "HiddifyNG_x86.apk" }, { "type": "ONE_OF_MANY", "filters": [ { "filterType": "ABI", - "value": "x86" + "value": "x86_64" } ], "attributes": [], - "versionCode": 8100200, - "versionName": "1.2.0", - "outputFile": "HiddifyNG_x86.apk" + "versionCode": 9100201, + "versionName": "1.2.1", + "outputFile": "HiddifyNG_x86_64.apk" }, { "type": "ONE_OF_MANY", "filters": [ { "filterType": "ABI", - "value": "arm64-v8a" + "value": "armeabi-v7a" } ], "attributes": [], - "versionCode": 7100200, - "versionName": "1.2.0", - "outputFile": "HiddifyNG_arm64-v8a.apk" + "versionCode": 6100201, + "versionName": "1.2.1", + "outputFile": "HiddifyNG_armeabi-v7a.apk" }, { "type": "ONE_OF_MANY", "filters": [ { "filterType": "ABI", - "value": "x86_64" + "value": "arm64-v8a" } ], "attributes": [], - "versionCode": 9100200, - "versionName": "1.2.0", - "outputFile": "HiddifyNG_x86_64.apk" + "versionCode": 7100201, + "versionName": "1.2.1", + "outputFile": "HiddifyNG_arm64-v8a.apk" } ], "elementType": "File" diff --git a/V2rayNG/app/src/main/kotlin/com/v2ray/ang/AngApplication.kt b/V2rayNG/app/src/main/kotlin/com/v2ray/ang/AngApplication.kt index ecb17feb9..edb9e8bfe 100644 --- a/V2rayNG/app/src/main/kotlin/com/v2ray/ang/AngApplication.kt +++ b/V2rayNG/app/src/main/kotlin/com/v2ray/ang/AngApplication.kt @@ -2,6 +2,7 @@ package com.v2ray.ang import androidx.multidex.MultiDexApplication import androidx.preference.PreferenceManager +import com.google.firebase.FirebaseApp import com.google.firebase.crashlytics.FirebaseCrashlytics import com.tencent.mmkv.MMKV @@ -17,6 +18,7 @@ class AngApplication : MultiDexApplication() { super.onCreate() // LeakCanary.install(this) + FirebaseApp.initializeApp(this); FirebaseCrashlytics.getInstance().setCrashlyticsCollectionEnabled(true) Thread.setDefaultUncaughtExceptionHandler(ExceptionHandler(this)) diff --git a/V2rayNG/build.gradle b/V2rayNG/build.gradle index 2b8baa1b8..cd3da8eae 100644 --- a/V2rayNG/build.gradle +++ b/V2rayNG/build.gradle @@ -15,6 +15,7 @@ buildscript { // Make sure that you have the Google services Gradle plugin dependency classpath 'com.google.gms:google-services:4.3.15' + // Add the dependency for the Crashlytics Gradle plugin classpath 'com.google.firebase:firebase-crashlytics-gradle:2.9.5' }