Skip to content

Commit ce09eff

Browse files
committed
Bump AGP 8.7.3 to 8.8.0 and migrate resourceConfigurations to androidResources.localeFilters
1 parent 0b4939d commit ce09eff

File tree

4 files changed

+119
-117
lines changed

4 files changed

+119
-117
lines changed

app-k9mail/build.gradle.kts

Lines changed: 55 additions & 55 deletions
Original file line numberDiff line numberDiff line change
@@ -24,63 +24,63 @@ android {
2424
versionName = "10.0"
2525
versionNameSuffix = "a1"
2626

27+
buildConfigField("String", "CLIENT_INFO_APP_NAME", "\"K-9 Mail\"")
28+
}
29+
30+
androidResources {
2731
// Keep in sync with the resource string array "supported_languages"
28-
resourceConfigurations.addAll(
29-
listOf(
30-
"ar",
31-
"be",
32-
"bg",
33-
"ca",
34-
"co",
35-
"cs",
36-
"cy",
37-
"da",
38-
"de",
39-
"el",
40-
"en",
41-
"en_GB",
42-
"eo",
43-
"es",
44-
"et",
45-
"eu",
46-
"fa",
47-
"fi",
48-
"fr",
49-
"fy",
50-
"ga",
51-
"gl",
52-
"hr",
53-
"hu",
54-
"in",
55-
"is",
56-
"it",
57-
"iw",
58-
"ja",
59-
"ko",
60-
"lt",
61-
"lv",
62-
"nb",
63-
"nl",
64-
"nn",
65-
"pl",
66-
"pt_BR",
67-
"pt_PT",
68-
"ro",
69-
"ru",
70-
"sk",
71-
"sl",
72-
"sq",
73-
"sr",
74-
"sv",
75-
"tr",
76-
"uk",
77-
"vi",
78-
"zh_CN",
79-
"zh_TW",
80-
),
32+
localeFilters += listOf(
33+
"ar",
34+
"be",
35+
"bg",
36+
"ca",
37+
"co",
38+
"cs",
39+
"cy",
40+
"da",
41+
"de",
42+
"el",
43+
"en",
44+
"en_GB",
45+
"eo",
46+
"es",
47+
"et",
48+
"eu",
49+
"fa",
50+
"fi",
51+
"fr",
52+
"fy",
53+
"ga",
54+
"gl",
55+
"hr",
56+
"hu",
57+
"in",
58+
"is",
59+
"it",
60+
"iw",
61+
"ja",
62+
"ko",
63+
"lt",
64+
"lv",
65+
"nb",
66+
"nl",
67+
"nn",
68+
"pl",
69+
"pt_BR",
70+
"pt_PT",
71+
"ro",
72+
"ru",
73+
"sk",
74+
"sl",
75+
"sq",
76+
"sr",
77+
"sv",
78+
"tr",
79+
"uk",
80+
"vi",
81+
"zh_CN",
82+
"zh_TW",
8183
)
82-
83-
buildConfigField("String", "CLIENT_INFO_APP_NAME", "\"K-9 Mail\"")
8484
}
8585

8686
signingConfigs {

app-thunderbird/build.gradle.kts

Lines changed: 55 additions & 55 deletions
Original file line numberDiff line numberDiff line change
@@ -23,63 +23,63 @@ android {
2323
versionCode = 4
2424
versionName = "10.0"
2525

26+
buildConfigField("String", "CLIENT_INFO_APP_NAME", "\"Thunderbird for Android\"")
27+
}
28+
29+
androidResources {
2630
// Keep in sync with the resource string array "supported_languages"
27-
resourceConfigurations.addAll(
28-
listOf(
29-
"ar",
30-
"be",
31-
"bg",
32-
"ca",
33-
"co",
34-
"cs",
35-
"cy",
36-
"da",
37-
"de",
38-
"el",
39-
"en",
40-
"en_GB",
41-
"eo",
42-
"es",
43-
"et",
44-
"eu",
45-
"fa",
46-
"fi",
47-
"fr",
48-
"fy",
49-
"ga",
50-
"gl",
51-
"hr",
52-
"hu",
53-
"in",
54-
"is",
55-
"it",
56-
"iw",
57-
"ja",
58-
"ko",
59-
"lt",
60-
"lv",
61-
"nb",
62-
"nl",
63-
"nn",
64-
"pl",
65-
"pt_BR",
66-
"pt_PT",
67-
"ro",
68-
"ru",
69-
"sl",
70-
"sk",
71-
"sq",
72-
"sr",
73-
"sv",
74-
"tr",
75-
"uk",
76-
"vi",
77-
"zh_CN",
78-
"zh_TW",
79-
),
31+
localeFilters += listOf(
32+
"ar",
33+
"be",
34+
"bg",
35+
"ca",
36+
"co",
37+
"cs",
38+
"cy",
39+
"da",
40+
"de",
41+
"el",
42+
"en",
43+
"en_GB",
44+
"eo",
45+
"es",
46+
"et",
47+
"eu",
48+
"fa",
49+
"fi",
50+
"fr",
51+
"fy",
52+
"ga",
53+
"gl",
54+
"hr",
55+
"hu",
56+
"in",
57+
"is",
58+
"it",
59+
"iw",
60+
"ja",
61+
"ko",
62+
"lt",
63+
"lv",
64+
"nb",
65+
"nl",
66+
"nn",
67+
"pl",
68+
"pt_BR",
69+
"pt_PT",
70+
"ro",
71+
"ru",
72+
"sl",
73+
"sk",
74+
"sq",
75+
"sr",
76+
"sv",
77+
"tr",
78+
"uk",
79+
"vi",
80+
"zh_CN",
81+
"zh_TW",
8082
)
81-
82-
buildConfigField("String", "CLIENT_INFO_APP_NAME", "\"Thunderbird for Android\"")
8383
}
8484

8585
signingConfigs {

docs/translations.md

Lines changed: 7 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -50,21 +50,23 @@ all languages, this should be discussed with the core team who will use this pro
5050

5151
# Managing translations
5252

53-
Right now we're using the `resourceConfigurations` mechanism provided by the Android Gradle Plugin to limit which
54-
languages are included in builds of the app.
55-
See e.g. https://github.com/thunderbird/thunderbird-android/blob/176a520e86bfe6875ad409a7565d122406dc7550/app-k9mail/build.gradle.kts#L40-L48
53+
Right now we're using the `androidResources.localeFilters` mechanism provided by the Android Gradle Plugin to limit
54+
which languages are included in builds of the app,
55+
See [localFilters](<https://developer.android.com/reference/tools/gradle-api/8.8/com/android/build/api/dsl/ApplicationAndroidResources#localeFilters()>).
5656

5757
This list needs to be kept in sync with the string array `supported_languages`, so the in-app language picker offers
5858
exactly the languages that are included in the app.
5959

6060
## Removing a language
6161

62-
1. Remove the language code from the `resourceConfigurations` list in `app-k9mail/build.gradle.kts`.
62+
1. Remove the language code from the `androidResources.localeFilters` list in `app-thunderbird/build.gradle.kts` and
63+
`app-k9mail/build.gradle.kts`.
6364
2. Remove the entry from `supported_languages` in `app/core/src/main/res/values/arrays_general_settings_values.xml`.
6465

6566
## Adding a language
6667

67-
1. Add the language code to the `resourceConfigurations` list in `app-k9mail/build.gradle.kts`.
68+
1. Add the language code to the `androidResources.localeFilters` list in `app-thunderbird/build.gradle.kts` and
69+
`app-k9mail/build.gradle.kts`.
6870
2. Add an entry to `supported_languages` in `app/core/src/main/res/values/arrays_general_settings_values.xml`.
6971
3. Make sure that `language_values` in `app/core/src/main/res/values/arrays_general_settings_values.xml` contains an
7072
entry for the language code you just added. If not:

gradle/libs.versions.toml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,8 +15,8 @@ androidBilling = "7.1.1"
1515
androidDesugar = "2.1.3"
1616
androidMaterial = "1.12.0"
1717
# AGP and tools should be updated together
18-
androidGradlePlugin = "8.7.3"
19-
androidTools = "31.7.3"
18+
androidGradlePlugin = "8.8.0"
19+
androidTools = "31.8.0"
2020
androidxActivity = "1.9.3"
2121
androidxAnnotation = "1.9.1"
2222
androidxAppCompat = "1.7.0"

0 commit comments

Comments
 (0)