diff --git a/app/build.gradle.kts b/app/build.gradle.kts index 5265e27..f435c68 100644 --- a/app/build.gradle.kts +++ b/app/build.gradle.kts @@ -10,7 +10,7 @@ android { compileSdk = 36 defaultConfig { - applicationId = "com.witClean.watch" + applicationId = "com.xiaoqu.watch" minSdk = 27 targetSdk = 27 versionCode = 183 @@ -19,6 +19,21 @@ android { testInstrumentationRunner = "androidx.test.runner.AndroidJUnitRunner" } + // 发布时用 productFlavors 切换包名: + // dev: com.xiaoqu.watch(调试用,和旧版不冲突) + // prod: com.witClean.watch(正式发布,旧版 OTA 升级) + flavorDimensions += "env" + productFlavors { + create("dev") { + dimension = "env" + applicationId = "com.xiaoqu.watch" + } + create("prod") { + dimension = "env" + applicationId = "com.witClean.watch" + } + } + buildTypes { debug { buildConfigField("String", "SERVICE_URL", "\"https://app.updatexiaoqu.com:9443/\"")