-
Notifications
You must be signed in to change notification settings - Fork 10
/
build.gradle
121 lines (102 loc) · 3.64 KB
/
build.gradle
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
plugins {
id 'com.android.application'
id 'kotlin-android'
id "com.diffplug.spotless"
id "se.ascp.gradle.gradle-versions-filter" version "0.1.16"
}
android {
compileSdk 33
defaultConfig {
applicationId "net.redwarp.gifwallpaper"
minSdkVersion 21
targetSdkVersion 33
versionCode 74
versionName "2.2.0"
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
resConfigs 'en', 'fr', 'ru', 'de', 'es', 'it', 'zh', 'eu', 'tr'
}
buildFeatures {
compose true
}
buildTypes {
release {
minifyEnabled true
shrinkResources true
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
}
}
compileOptions {
sourceCompatibility JavaVersion.VERSION_11
targetCompatibility JavaVersion.VERSION_11
}
kotlinOptions {
jvmTarget = "11"
freeCompilerArgs += "-opt-in=kotlin.RequiresOptIn"
}
sourceSets {
main {
resources {
srcDirs 'src/main/resources', "$rootDir/docs/"
}
}
}
testOptions {
unitTests {
includeAndroidResources = true
}
}
composeOptions {
kotlinCompilerExtensionVersion '1.4.0'
}
namespace 'net.redwarp.gifwallpaper'
}
spotless {
kotlin {
target '**/*.kt'
licenseHeaderFile(new File(rootDir, 'assets/license_header.kt'))
}
}
dependencies {
implementation fileTree(dir: 'libs', include: ['*.jar'])
implementation(project(':markdown'))
implementation 'androidx.appcompat:appcompat:1.6.0'
implementation 'androidx.core:core-ktx:1.9.0'
implementation "org.jetbrains.kotlinx:kotlinx-coroutines-core:1.6.4"
implementation 'org.jetbrains.kotlinx:kotlinx-coroutines-android:1.6.4'
implementation 'androidx.lifecycle:lifecycle-service:2.5.1'
implementation 'androidx.palette:palette-ktx:1.0.0'
implementation "com.atlassian.commonmark:commonmark:0.17.0"
implementation "app.redwarp.gif:decoder:1.4.4"
implementation "app.redwarp.gif:android-drawable:1.4.4"
implementation "androidx.datastore:datastore-preferences:1.0.0"
// Integration with activities
implementation 'androidx.activity:activity-compose:1.6.1'
// Compose Material Design
implementation "androidx.compose.material:material:1.3.1"
// Animations
implementation "androidx.compose.animation:animation:1.3.3"
// Tooling support (Previews, etc.)
implementation "androidx.compose.ui:ui-tooling:1.3.3"
implementation "androidx.compose.ui:ui-tooling-preview:1.3.3"
implementation "androidx.navigation:navigation-compose:2.5.3"
implementation "com.google.accompanist:accompanist-systemuicontroller:0.28.0"
testImplementation 'junit:junit:4.13.2'
testImplementation 'org.robolectric:robolectric:4.9.2'
androidTestImplementation 'androidx.test.ext:junit:1.1.5'
androidTestImplementation 'androidx.test.espresso:espresso-core:3.5.1'
// Test rules and transitive dependencies:
androidTestImplementation("androidx.compose.ui:ui-test-junit4:1.3.3")
// Needed for createComposeRule, but not createAndroidComposeRule:
debugImplementation("androidx.compose.ui:ui-test-manifest:1.3.3")
androidTestImplementation 'tools.fastlane:screengrab:2.1.1'
}
def isNonStable = { String version ->
def stableKeyword = ['RELEASE', 'FINAL', 'GA'].any { it -> version.toUpperCase().contains(it) }
def regex = /^[0-9,.v-]+(-r)?$/
return !stableKeyword && !(version ==~ regex)
}
dependencyUpdates {
rejectVersionIf {
isNonStable(it.candidate.version)
}
}