mirror of
https://github.com/msfjarvis/compose-lobsters
synced 2025-08-14 10:37:05 +05:30
gradle: sync property set with APS
This commit is contained in:
parent
f6e3b6c540
commit
91d97e0696
4 changed files with 74 additions and 8 deletions
6
.github/workflows/ci.yml
vendored
6
.github/workflows/ci.yml
vendored
|
@ -30,7 +30,7 @@ jobs:
|
||||||
- name: Run unit tests
|
- name: Run unit tests
|
||||||
uses: gradle/gradle-build-action@v2.1.3
|
uses: gradle/gradle-build-action@v2.1.3
|
||||||
with:
|
with:
|
||||||
arguments: check --stacktrace
|
arguments: check --stacktrace --no-configuration-cache
|
||||||
|
|
||||||
- name: (Fail-only) Upload test report
|
- name: (Fail-only) Upload test report
|
||||||
if: failure()
|
if: failure()
|
||||||
|
@ -58,7 +58,7 @@ jobs:
|
||||||
- name: Check codestyle with Spotless
|
- name: Check codestyle with Spotless
|
||||||
uses: gradle/gradle-build-action@v2.1.3
|
uses: gradle/gradle-build-action@v2.1.3
|
||||||
with:
|
with:
|
||||||
arguments: spotlessCheck
|
arguments: spotlessCheck --no-configuration-cache
|
||||||
|
|
||||||
deploy-release-snapshot:
|
deploy-release-snapshot:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
|
@ -86,7 +86,7 @@ jobs:
|
||||||
- name: Build release app
|
- name: Build release app
|
||||||
uses: gradle/gradle-build-action@v2.1.3
|
uses: gradle/gradle-build-action@v2.1.3
|
||||||
with:
|
with:
|
||||||
arguments: :android:assembleRelease
|
arguments: :android:assembleRelease --no-configuration-cache
|
||||||
|
|
||||||
- name: Clean secrets
|
- name: Clean secrets
|
||||||
run: scripts/signing-cleanup.sh
|
run: scripts/signing-cleanup.sh
|
||||||
|
|
|
@ -44,7 +44,7 @@ android {
|
||||||
}
|
}
|
||||||
val keystoreConfigFile = rootProject.layout.projectDirectory.file("keystore.properties")
|
val keystoreConfigFile = rootProject.layout.projectDirectory.file("keystore.properties")
|
||||||
if (keystoreConfigFile.asFile.exists()) {
|
if (keystoreConfigFile.asFile.exists()) {
|
||||||
val contents = providers.fileContents(keystoreConfigFile).asText.forUseAtConfigurationTime()
|
val contents = providers.fileContents(keystoreConfigFile).asText
|
||||||
val keystoreProperties = Properties()
|
val keystoreProperties = Properties()
|
||||||
keystoreProperties.load(contents.get().byteInputStream())
|
keystoreProperties.load(contents.get().byteInputStream())
|
||||||
signingConfigs {
|
signingConfigs {
|
||||||
|
@ -57,14 +57,19 @@ android {
|
||||||
}
|
}
|
||||||
buildTypes.all { signingConfig = signingConfigs.getByName("release") }
|
buildTypes.all { signingConfig = signingConfigs.getByName("release") }
|
||||||
}
|
}
|
||||||
|
buildFeatures { buildConfig = true }
|
||||||
buildTypes {
|
buildTypes {
|
||||||
getByName("release") {
|
named("release") {
|
||||||
isMinifyEnabled = true
|
isMinifyEnabled = false
|
||||||
proguardFiles("proguard-android-optimize.txt", "proguard-rules.pro")
|
setProguardFiles(listOf("proguard-android-optimize.txt", "proguard-rules.pro"))
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
compileOptions {
|
compileOptions {
|
||||||
sourceCompatibility = JavaVersion.VERSION_11
|
sourceCompatibility = JavaVersion.VERSION_11
|
||||||
targetCompatibility = JavaVersion.VERSION_11
|
targetCompatibility = JavaVersion.VERSION_11
|
||||||
}
|
}
|
||||||
|
dependenciesInfo {
|
||||||
|
includeInBundle = false
|
||||||
|
includeInApk = false
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -124,7 +124,7 @@ fun LobstersApp(
|
||||||
},
|
},
|
||||||
title = {
|
title = {
|
||||||
if (navItems.any { it.route == currentDestination }) {
|
if (navItems.any { it.route == currentDestination }) {
|
||||||
Text(text = stringResource(R.string.app_name), fontWeight = FontWeight.Bold)
|
Text(text = stringResource(commonR.string.app_name), fontWeight = FontWeight.Bold)
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
)
|
)
|
||||||
|
|
|
@ -1,8 +1,69 @@
|
||||||
|
org.gradle.parallel=true
|
||||||
|
org.gradle.configureondemand=false
|
||||||
|
org.gradle.caching=true
|
||||||
|
|
||||||
|
# Enable filesystem watching
|
||||||
|
org.gradle.vfs.watch=true
|
||||||
|
|
||||||
|
# Enable experimental configuration caching
|
||||||
|
org.gradle.unsafe.configuration-cache=true
|
||||||
|
|
||||||
|
# Enable Kotlin incremental compilation
|
||||||
|
kotlin.incremental=true
|
||||||
|
|
||||||
|
# Kotlin code style
|
||||||
kotlin.code.style=official
|
kotlin.code.style=official
|
||||||
|
|
||||||
|
# Enable incremental annotation processor for KAPT
|
||||||
|
kapt.incremental.apt=true
|
||||||
|
|
||||||
|
# Turn off AP discovery in compile path to enable compile avoidance
|
||||||
|
kapt.include.compile.classpath=false
|
||||||
|
|
||||||
|
# Use R8 instead of ProGuard for code shrinking.
|
||||||
|
android.enableR8.fullMode=true
|
||||||
|
|
||||||
|
# Enable AndroidX
|
||||||
android.useAndroidX=true
|
android.useAndroidX=true
|
||||||
|
|
||||||
|
# Kotlin Multiplatform
|
||||||
kotlin.mpp.enableGranularSourceSetsMetadata=true
|
kotlin.mpp.enableGranularSourceSetsMetadata=true
|
||||||
kotlin.native.enableDependencyPropagation=false
|
kotlin.native.enableDependencyPropagation=false
|
||||||
kotlin.mpp.stability.nowarn=true
|
kotlin.mpp.stability.nowarn=true
|
||||||
|
|
||||||
|
# Enable non-transitive R class namespacing where each library only contains
|
||||||
|
# references to the resources it declares instead of declarations plus all
|
||||||
|
# transitive dependency references.
|
||||||
|
android.nonTransitiveRClass=true
|
||||||
|
|
||||||
|
# Only keep the single relevant constructor for types mentioned in XML files
|
||||||
|
# instead of using a parameter wildcard which keeps them all.
|
||||||
|
android.useMinimalKeepRules=true
|
||||||
|
|
||||||
|
# Enable resource optimizations for release build
|
||||||
|
android.enableResourceOptimizations=true
|
||||||
|
|
||||||
|
# Opt into new publishing APIs
|
||||||
|
android.disableAutomaticComponentCreation=true
|
||||||
|
|
||||||
|
# Default Android build features
|
||||||
|
android.defaults.buildfeatures.buildconfig=false
|
||||||
|
android.defaults.buildfeatures.aidl=false
|
||||||
|
android.defaults.buildfeatures.renderscript=false
|
||||||
|
android.defaults.buildfeatures.resvalues=false
|
||||||
|
android.defaults.buildfeatures.shaders=false
|
||||||
|
|
||||||
|
# Disable warnings about unsupported features, we know what we're doing
|
||||||
|
android.suppressUnsupportedOptionWarnings=android.enableR8.fullMode,android.enableResourceOptimizations,android.nonTransitiveRClass,android.suppressUnsupportedOptionWarnings
|
||||||
|
|
||||||
|
# Maven publishing
|
||||||
|
GROUP=com.github.android-password-store
|
||||||
|
|
||||||
|
# OSSRH sometimes struggles with slow deployments, so this makes Gradle
|
||||||
|
# more tolerant to those delays.
|
||||||
|
systemProp.org.gradle.internal.http.connectionTimeout=500000
|
||||||
|
systemProp.org.gradle.internal.http.socketTimeout=500000
|
||||||
|
|
||||||
# Add opens for KAPT
|
# Add opens for KAPT
|
||||||
# https://youtrack.jetbrains.com/issue/KT-45545#focus=Comments-27-4862682.0-0
|
# https://youtrack.jetbrains.com/issue/KT-45545#focus=Comments-27-4862682.0-0
|
||||||
org.gradle.jvmargs=-Dfile.encoding=UTF-8 \
|
org.gradle.jvmargs=-Dfile.encoding=UTF-8 \
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue