diff --git a/.gradle/7.2/executionHistory/executionHistory.bin b/.gradle/7.2/executionHistory/executionHistory.bin index 39a9510..ab7f218 100644 Binary files a/.gradle/7.2/executionHistory/executionHistory.bin and b/.gradle/7.2/executionHistory/executionHistory.bin differ diff --git a/.gradle/7.2/executionHistory/executionHistory.lock b/.gradle/7.2/executionHistory/executionHistory.lock index c626328..30cb15a 100644 Binary files a/.gradle/7.2/executionHistory/executionHistory.lock and b/.gradle/7.2/executionHistory/executionHistory.lock differ diff --git a/.gradle/7.2/fileHashes/fileHashes.bin b/.gradle/7.2/fileHashes/fileHashes.bin index 8fe011b..4c28935 100644 Binary files a/.gradle/7.2/fileHashes/fileHashes.bin and b/.gradle/7.2/fileHashes/fileHashes.bin differ diff --git a/.gradle/7.2/fileHashes/fileHashes.lock b/.gradle/7.2/fileHashes/fileHashes.lock index 57ac74f..5b25d99 100644 Binary files a/.gradle/7.2/fileHashes/fileHashes.lock and b/.gradle/7.2/fileHashes/fileHashes.lock differ diff --git a/.gradle/7.2/fileHashes/resourceHashesCache.bin b/.gradle/7.2/fileHashes/resourceHashesCache.bin index 96bdbf6..528bfd9 100644 Binary files a/.gradle/7.2/fileHashes/resourceHashesCache.bin and b/.gradle/7.2/fileHashes/resourceHashesCache.bin differ diff --git a/.gradle/buildOutputCleanup/buildOutputCleanup.lock b/.gradle/buildOutputCleanup/buildOutputCleanup.lock index dbc21b9..0808c92 100644 Binary files a/.gradle/buildOutputCleanup/buildOutputCleanup.lock and b/.gradle/buildOutputCleanup/buildOutputCleanup.lock differ diff --git a/.gradle/buildOutputCleanup/outputFiles.bin b/.gradle/buildOutputCleanup/outputFiles.bin index ab532df..adef464 100644 Binary files a/.gradle/buildOutputCleanup/outputFiles.bin and b/.gradle/buildOutputCleanup/outputFiles.bin differ diff --git a/README.en.md b/README.en.md deleted file mode 100644 index 48d74f3..0000000 --- a/README.en.md +++ /dev/null @@ -1,36 +0,0 @@ -# 铁锈助手 - -#### Description -铁锈助手私有存储库 - -#### Software Architecture -Software architecture description - -#### Installation - -1. xxxx -2. xxxx -3. xxxx - -#### Instructions - -1. xxxx -2. xxxx -3. xxxx - -#### Contribution - -1. Fork the repository -2. Create Feat_xxx branch -3. Commit your code -4. Create Pull Request - - -#### Gitee Feature - -1. You can use Readme\_XXX.md to support different languages, such as Readme\_en.md, Readme\_zh.md -2. Gitee blog [blog.gitee.com](https://blog.gitee.com) -3. Explore open source project [https://gitee.com/explore](https://gitee.com/explore) -4. The most valuable open source project [GVP](https://gitee.com/gvp) -5. The manual of Gitee [https://gitee.com/help](https://gitee.com/help) -6. The most popular members [https://gitee.com/gitee-stars/](https://gitee.com/gitee-stars/) diff --git a/app/build.gradle b/app/build.gradle index 72d1bfa..ae2fe15 100644 --- a/app/build.gradle +++ b/app/build.gradle @@ -30,8 +30,8 @@ android { applicationId "com.coldmint.rust.pro" minSdkVersion 21 targetSdkVersion 32 - versionCode 13 - versionName "2.0 Release 7(2022-4-5)" + versionCode 14 + versionName "2.0 Release 7(2022-4-6)" testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner" } diff --git a/app/src/main/java/com/coldmint/rust/pro/MainActivity.kt b/app/src/main/java/com/coldmint/rust/pro/MainActivity.kt index f564afb..b6f0e01 100644 --- a/app/src/main/java/com/coldmint/rust/pro/MainActivity.kt +++ b/app/src/main/java/com/coldmint/rust/pro/MainActivity.kt @@ -15,6 +15,7 @@ import com.google.android.material.snackbar.Snackbar import android.widget.Toast import android.net.Uri import android.os.* +import android.util.Log import android.view.* import android.widget.PopupMenu import android.widget.SearchView @@ -150,6 +151,7 @@ class MainActivity : BaseActivity() { val executorService = Executors.newSingleThreadExecutor() executorService.submit { //检查更新 + val key = "应用更新" val packageInfo: PackageInfo = packageManager.getPackageInfo(packageName, 0) val checkBetaUpdate = appSettings.getValue(AppSettings.Setting.CheckBetaUpdate, false) @@ -160,16 +162,25 @@ class MainActivity : BaseActivity() { //版本名不一致,是Beta模式 if (packageInfo.versionName != data.versionName) { needShowDialog = true + Log.d(key, "是测试模式,版本名称不一致") + } else { + Log.d(key, "是测试模式,并且是Beta版本") } } else if (checkBetaUpdate) { //版本名不一致 if (packageInfo.versionName != data.versionName) { needShowDialog = true + Log.d(key, "开启了检查Beta版本,版本名称不一致") + } else { + Log.d(key, "开启了检查Beta版本,无需更新") } } else { //版本号不一致 if (packageInfo.versionCode != data.versionNumber) { needShowDialog = true + Log.d(key, "正式打包模式,版本号不一致") + } else { + Log.d(key, "正式打包模式,版本号一致无需更新") } } @@ -246,7 +257,10 @@ class MainActivity : BaseActivity() { recreate() return } - startViewModel.verifyingUserInfo() + val error = startViewModel.signatureErrorLiveData.value ?: true + if (!error) { + startViewModel.verifyingUserInfo() + } } } diff --git a/app/src/main/java/com/coldmint/rust/pro/viewmodel/StartViewModel.kt b/app/src/main/java/com/coldmint/rust/pro/viewmodel/StartViewModel.kt index a126c3e..190626b 100644 --- a/app/src/main/java/com/coldmint/rust/pro/viewmodel/StartViewModel.kt +++ b/app/src/main/java/com/coldmint/rust/pro/viewmodel/StartViewModel.kt @@ -299,18 +299,27 @@ class StartViewModel(application: Application) : BaseAndroidViewModel(applicatio * 检查签名是否有错误 */ private fun checkSignature(): Boolean { + val key = "签名检查" val sign = AppOperator.getSignature(context) if (BuildConfig.DEBUG) { + //是测试模式 if (GlobalMethod.DEBUG_SIGN != sign) { + Log.e(key, "测试打包,签名检查错误" + sign + "不是合法的签名。") signatureErrorLiveData.value = true + } else { + Log.d(key, "测试打包,签名合法。") + signatureErrorLiveData.value = false } } else { if (GlobalMethod.RELEASE_SIGN != sign) { signatureErrorLiveData.value = true + Log.e(key, "正式打包,签名检查错误" + sign + "不是合法的签名。") + } else { + Log.d(key, "正式打包,签名合法。") + signatureErrorLiveData.value = false } } - signatureErrorLiveData.value = false - return signatureErrorLiveData.value ?: false + return signatureErrorLiveData.value ?: true } /** diff --git a/app/src/main/res/values/strings.xml b/app/src/main/res/values/strings.xml index a30ef2f..2266281 100644 --- a/app/src/main/res/values/strings.xml +++ b/app/src/main/res/values/strings.xml @@ -812,6 +812,7 @@ 在相册选择图像 炮塔设计 用户体验计划 - 匿名发送软件奔溃信息。 + 匿名发送软件奔溃信息(暂不可用)。 版本更新与用户体验计划 + experiencePlan \ No newline at end of file diff --git a/app/src/main/res/xml/root_preferences.xml b/app/src/main/res/xml/root_preferences.xml index b086c30..b92e3ba 100644 --- a/app/src/main/res/xml/root_preferences.xml +++ b/app/src/main/res/xml/root_preferences.xml @@ -206,8 +206,9 @@ app:title="@string/check_beta_update" />