mirror of
https://github.com/fankes/ColorOSNotifyIcon.git
synced 2025-09-04 01:35:22 +08:00
Modify merge contents of build.gradle into constant definitions
This commit is contained in:
6
.secret/key_store_secret.json
Normal file
6
.secret/key_store_secret.json
Normal file
@@ -0,0 +1,6 @@
|
|||||||
|
{
|
||||||
|
"keyAlias": "public",
|
||||||
|
"keyPassword": "123456",
|
||||||
|
"storeFileName": "universal.p12",
|
||||||
|
"storePassword": "123456"
|
||||||
|
}
|
@@ -1,39 +1,51 @@
|
|||||||
|
import groovy.json.JsonSlurper
|
||||||
|
|
||||||
plugins {
|
plugins {
|
||||||
id 'com.android.application'
|
id 'com.android.application'
|
||||||
id 'org.jetbrains.kotlin.android'
|
id 'org.jetbrains.kotlin.android'
|
||||||
id 'com.google.devtools.ksp' version '1.8.20-1.0.10'
|
id 'com.google.devtools.ksp'
|
||||||
}
|
}
|
||||||
|
|
||||||
android {
|
android {
|
||||||
compileSdk 33
|
|
||||||
|
|
||||||
signingConfigs {
|
signingConfigs {
|
||||||
debug {
|
universal {
|
||||||
storeFile file('../keystore/public')
|
def dirPath = rootProject.ext.app.signingConfigs.secretConfigsDirPath
|
||||||
storePassword '123456'
|
def fileName = rootProject.ext.app.signingConfigs.secretConfigsFileName
|
||||||
keyAlias 'public'
|
def configs = new JsonSlurper().parse(file("${dirPath}/${fileName}"))
|
||||||
keyPassword '123456'
|
keyAlias configs.keyAlias
|
||||||
|
keyPassword configs.keyPassword
|
||||||
|
storeFile file("${dirPath}/${configs.storeFileName}")
|
||||||
|
storePassword configs.storePassword
|
||||||
v1SigningEnabled true
|
v1SigningEnabled true
|
||||||
v2SigningEnabled true
|
v2SigningEnabled true
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
defaultConfig {
|
namespace 'com.fankes.coloros.notify'
|
||||||
applicationId "com.fankes.coloros.notify"
|
compileSdk rootProject.ext.android.compileSdk
|
||||||
minSdk 29
|
|
||||||
targetSdk 33
|
|
||||||
versionCode rootProject.ext.appVersionCode
|
|
||||||
versionName rootProject.ext.appVersionName
|
|
||||||
|
|
||||||
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
|
defaultConfig {
|
||||||
|
applicationId 'com.fankes.coloros.notify'
|
||||||
|
|
||||||
|
minSdk rootProject.ext.android.minSdk
|
||||||
|
targetSdk rootProject.ext.android.targetSdk
|
||||||
|
|
||||||
|
versionCode rootProject.ext.app.versionCode
|
||||||
|
versionName rootProject.ext.app.versionName
|
||||||
|
|
||||||
|
testInstrumentationRunner 'androidx.test.runner.AndroidJUnitRunner'
|
||||||
}
|
}
|
||||||
|
|
||||||
buildTypes {
|
buildTypes {
|
||||||
|
debug {
|
||||||
|
minifyEnabled false
|
||||||
|
signingConfig signingConfigs.universal
|
||||||
|
}
|
||||||
release {
|
release {
|
||||||
minifyEnabled rootProject.ext.enableR8
|
minifyEnabled true
|
||||||
shrinkResources rootProject.ext.enableR8
|
shrinkResources true
|
||||||
zipAlignEnabled rootProject.ext.enableR8
|
zipAlignEnabled true
|
||||||
signingConfig signingConfigs.debug
|
signingConfig signingConfigs.universal
|
||||||
proguardFiles getDefaultProguardFile('proguard-android-optimize.txt'), 'proguard-rules.pro'
|
proguardFiles getDefaultProguardFile('proguard-android-optimize.txt'), 'proguard-rules.pro'
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
17
build.gradle
17
build.gradle
@@ -2,12 +2,23 @@ plugins {
|
|||||||
id 'com.android.application' version '7.4.1' apply false
|
id 'com.android.application' version '7.4.1' apply false
|
||||||
id 'com.android.library' version '7.4.1' apply false
|
id 'com.android.library' version '7.4.1' apply false
|
||||||
id 'org.jetbrains.kotlin.android' version '1.8.20' apply false
|
id 'org.jetbrains.kotlin.android' version '1.8.20' apply false
|
||||||
|
id 'com.google.devtools.ksp' version '1.8.20-1.0.10' apply false
|
||||||
}
|
}
|
||||||
|
|
||||||
ext {
|
ext {
|
||||||
appVersionName = "1.95"
|
android = [
|
||||||
appVersionCode = 19
|
compileSdk: 33,
|
||||||
enableR8 = true
|
minSdk : 29,
|
||||||
|
targetSdk : 33
|
||||||
|
]
|
||||||
|
app = [
|
||||||
|
versionName : '1.95',
|
||||||
|
versionCode : 19,
|
||||||
|
signingConfigs: [
|
||||||
|
secretConfigsDirPath : "${projectDir.getAbsolutePath()}/.secret",
|
||||||
|
secretConfigsFileName: "key_store_secret.json"
|
||||||
|
]
|
||||||
|
]
|
||||||
}
|
}
|
||||||
|
|
||||||
task clean(type: Delete) {
|
task clean(type: Delete) {
|
||||||
|
Reference in New Issue
Block a user