mirror of
git://code.qt.io/qt/qt5.git
synced 2026-07-06 06:37:03 +08:00
Provisioning: add feature delivery to the Gradle cache project
Add feature-delivery plugin to the provisioning Gradle cache to avoid potential fetching on each build in qtbase tests. Pick-to: 6.12 6.11 6.8 Change-Id: Ie9126114287aff77abcd2f68bfff4d8dc25fa6a9 Reviewed-by: Toni Saario <toni.saario@qt.io>
This commit is contained in:
@@ -7,6 +7,7 @@ which use `--offline`.
|
||||
Caches dependencies for:
|
||||
- `com.android.application`: used by Qt test/example APK builds
|
||||
- `com.android.library`: used by Qt JAR builds
|
||||
- `android.dynamic.feature`: used by Feature Delivery tests
|
||||
- `org.jetbrains.kotlin.android`: used by some Qt modules
|
||||
- AndroidX: used by app builds
|
||||
|
||||
|
||||
@@ -10,11 +10,14 @@ android {
|
||||
applicationId 'org.qtproject.qt.gradlecache.app'
|
||||
minSdk = 28
|
||||
}
|
||||
|
||||
dynamicFeatures = [':feature']
|
||||
}
|
||||
|
||||
dependencies {
|
||||
implementation libs.core
|
||||
implementation libs.appcompat
|
||||
implementation libs.material
|
||||
implementation libs.play.feature.delivery
|
||||
testImplementation libs.junit
|
||||
}
|
||||
|
||||
@@ -0,0 +1,4 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<resources>
|
||||
<string name="feature_title">Feature</string>
|
||||
</resources>
|
||||
@@ -1,4 +1,5 @@
|
||||
plugins {
|
||||
alias(libs.plugins.android.application) apply false
|
||||
alias(libs.plugins.android.library) apply false
|
||||
alias(libs.plugins.android.dynamic.feature) apply false
|
||||
}
|
||||
|
||||
@@ -0,0 +1,17 @@
|
||||
plugins {
|
||||
alias(libs.plugins.android.dynamic.feature)
|
||||
}
|
||||
|
||||
android {
|
||||
namespace = 'org.qtproject.qt.gradlecache.feature'
|
||||
compileSdk = 36
|
||||
|
||||
defaultConfig {
|
||||
minSdk = 28
|
||||
}
|
||||
}
|
||||
|
||||
dependencies {
|
||||
implementation project(':app')
|
||||
implementation libs.play.feature.delivery
|
||||
}
|
||||
@@ -0,0 +1,12 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:dist="http://schemas.android.com/apk/distribution">
|
||||
<dist:module
|
||||
dist:instant="false"
|
||||
dist:title="@string/feature_title">
|
||||
<dist:delivery>
|
||||
<dist:on-demand />
|
||||
</dist:delivery>
|
||||
<dist:fusing dist:include="true" />
|
||||
</dist:module>
|
||||
</manifest>
|
||||
@@ -0,0 +1,5 @@
|
||||
package org.qtproject.qt.gradlecache.feature
|
||||
|
||||
object Feature {
|
||||
fun hello(): String = "hello"
|
||||
}
|
||||
@@ -4,13 +4,16 @@ core = "1.17.0"
|
||||
appcompat = "1.7.1"
|
||||
material = "1.13.0"
|
||||
junit = "4.13.2"
|
||||
play-feature-delivery = "2.1.0"
|
||||
|
||||
[libraries]
|
||||
core = { group = "androidx.core", name = "core", version.ref = "core" }
|
||||
appcompat = { group = "androidx.appcompat", name = "appcompat", version.ref = "appcompat" }
|
||||
material = { group = "com.google.android.material", name = "material", version.ref = "material" }
|
||||
junit = { group = "junit", name = "junit", version.ref = "junit" }
|
||||
play-feature-delivery = { module = "com.google.android.play:feature-delivery", version.ref = "play-feature-delivery" }
|
||||
|
||||
[plugins]
|
||||
android-application = { id = "com.android.application", version.ref = "agp" }
|
||||
android-library = { id = "com.android.library", version.ref = "agp" }
|
||||
android-dynamic-feature = { id = "com.android.dynamic-feature", version.ref = "agp" }
|
||||
|
||||
@@ -14,4 +14,4 @@ dependencyResolutionManagement {
|
||||
}
|
||||
|
||||
rootProject.name = 'gradlecache'
|
||||
include ':app', ':lib'
|
||||
include ':app', ':lib', ':feature'
|
||||
|
||||
Reference in New Issue
Block a user