Browse Source

Update Gradle to 8.1 and AGP to v8.0 (#329)

* Update AGP to 8.0.0.

* Set JAVA_HOME to JDK17

* Update lint version.

* Use right JDK for dependency analysis, replace deprecated env var.

* Upgrade to Gradle 8.1.

* Remove `@Supress(DSL_SCOPE_VIOLATION)` as it's no longer needed.

---------

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
test/jme/compound-poc
Jorge Martin Espinosa 1 year ago committed by GitHub
parent
commit
de010545fb
  1. 5
      .github/workflows/build.yml
  2. 9
      .github/workflows/maestro.yml
  3. 9
      .github/workflows/nightly.yml
  4. 9
      .github/workflows/nightly_manual.yml
  5. 20
      .github/workflows/quality.yml
  6. 8
      .github/workflows/tests.yml
  7. 3
      anvilannotations/build.gradle.kts
  8. 2
      anvilcodegen/build.gradle.kts
  9. 9
      app/build.gradle.kts
  10. 2
      appnav/build.gradle.kts
  11. 2
      build.gradle.kts
  12. 1
      features/createroom/api/build.gradle.kts
  13. 2
      features/createroom/impl/build.gradle.kts
  14. 1
      features/login/api/build.gradle.kts
  15. 2
      features/login/impl/build.gradle.kts
  16. 1
      features/logout/api/build.gradle.kts
  17. 2
      features/logout/impl/build.gradle.kts
  18. 2
      features/messages/api/build.gradle.kts
  19. 2
      features/messages/impl/build.gradle.kts
  20. 1
      features/onboarding/api/build.gradle.kts
  21. 2
      features/onboarding/impl/build.gradle.kts
  22. 1
      features/preferences/api/build.gradle.kts
  23. 2
      features/preferences/impl/build.gradle.kts
  24. 1
      features/rageshake/api/build.gradle.kts
  25. 2
      features/rageshake/impl/build.gradle.kts
  26. 1
      features/rageshake/test/build.gradle.kts
  27. 2
      features/roomdetails/api/build.gradle.kts
  28. 2
      features/roomdetails/impl/build.gradle.kts
  29. 1
      features/roomlist/api/build.gradle.kts
  30. 2
      features/roomlist/impl/build.gradle.kts
  31. 1
      features/userlist/api/build.gradle.kts
  32. 2
      features/userlist/impl/build.gradle.kts
  33. 1
      features/userlist/test/build.gradle.kts
  34. 2
      features/verifysession/api/build.gradle.kts
  35. 2
      features/verifysession/impl/build.gradle.kts
  36. 5
      gradle.properties
  37. 4
      gradle/libs.versions.toml
  38. 4
      gradle/wrapper/gradle-wrapper.properties
  39. 1
      libraries/androidutils/build.gradle.kts
  40. 3
      libraries/architecture/build.gradle.kts
  41. 7
      libraries/core/build.gradle.kts
  42. 6
      libraries/coroutines/build.gradle.kts
  43. 2
      libraries/dateformatter/api/build.gradle.kts
  44. 2
      libraries/dateformatter/impl/build.gradle.kts
  45. 2
      libraries/dateformatter/test/build.gradle.kts
  46. 3
      libraries/deeplink/build.gradle.kts
  47. 6
      libraries/designsystem/build.gradle.kts
  48. 2
      libraries/di/build.gradle.kts
  49. 1
      libraries/elementresources/build.gradle.kts
  50. 1
      libraries/encrypted-db/build.gradle.kts
  51. 6
      libraries/matrix/api/build.gradle.kts
  52. 2
      libraries/matrix/impl/build.gradle.kts
  53. 2
      libraries/matrix/test/build.gradle.kts
  54. 2
      libraries/matrixui/build.gradle.kts
  55. 1
      libraries/network/build.gradle.kts
  56. 1
      libraries/permissions/api/build.gradle.kts
  57. 2
      libraries/permissions/impl/build.gradle.kts
  58. 2
      libraries/permissions/noop/build.gradle.kts
  59. 1
      libraries/push/api/build.gradle.kts
  60. 1
      libraries/push/impl/build.gradle.kts
  61. 1
      libraries/pushproviders/api/build.gradle.kts
  62. 1
      libraries/pushproviders/firebase/build.gradle.kts
  63. 1
      libraries/pushproviders/unifiedpush/build.gradle.kts
  64. 1
      libraries/pushstore/api/build.gradle.kts
  65. 1
      libraries/pushstore/impl/build.gradle.kts
  66. 1
      libraries/session-storage/api/build.gradle.kts
  67. 1
      libraries/session-storage/impl-memory/build.gradle.kts
  68. 1
      libraries/session-storage/impl/build.gradle.kts
  69. 6
      libraries/statemachine/build.gradle.kts
  70. 1
      libraries/testtags/build.gradle.kts
  71. 2
      libraries/textcomposer/build.gradle.kts
  72. 9
      libraries/ui-strings/build.gradle.kts
  73. 1
      plugins/build.gradle.kts
  74. 2
      plugins/src/main/kotlin/Versions.kt
  75. 6
      plugins/src/main/kotlin/extension/CommonExtension.kt
  76. 9
      plugins/src/main/kotlin/extension/DependencyHandleScope.kt
  77. 1
      plugins/src/main/kotlin/io.element.android-compose-application.gradle.kts
  78. 1
      plugins/src/main/kotlin/io.element.android-compose-library.gradle.kts
  79. 1
      plugins/src/main/kotlin/io.element.android-library.gradle.kts
  80. 1
      samples/minimal/build.gradle.kts
  81. 1
      services/analytics/api/build.gradle.kts
  82. 1
      services/analytics/noop/build.gradle.kts
  83. 2
      services/appnavstate/api/build.gradle.kts
  84. 2
      services/appnavstate/impl/build.gradle.kts
  85. 2
      services/appnavstate/test/build.gradle.kts
  86. 1
      services/toolbox/api/build.gradle.kts
  87. 1
      services/toolbox/impl/build.gradle.kts
  88. 7
      tests/testutils/build.gradle.kts
  89. 2
      tests/uitests/build.gradle.kts

5
.github/workflows/build.yml

@ -28,6 +28,11 @@ jobs: @@ -28,6 +28,11 @@ jobs:
# Ensure we are building the branch and not the branch after being merged on develop
# https://github.com/actions/checkout/issues/881
ref: ${{ github.event_name == 'pull_request' && github.event.pull_request.head.sha || github.ref }}
- name: Use JDK 17
uses: actions/setup-java@v3
with:
distribution: 'temurin' # See 'Supported distributions' for available options
java-version: '17'
- name: Configure gradle
uses: gradle/gradle-build-action@v2
with:

9
.github/workflows/maestro.yml

@ -24,6 +24,15 @@ jobs: @@ -24,6 +24,15 @@ jobs:
cancel-in-progress: true
steps:
- uses: actions/checkout@v3
with:
# Ensure we are building the branch and not the branch after being merged on develop
# https://github.com/actions/checkout/issues/881
ref: ${{ github.event_name == 'pull_request' && github.event.pull_request.head.sha || github.ref }}
- uses: actions/setup-java@v3
name: Use JDK 17
with:
distribution: 'temurin' # See 'Supported distributions' for available options
java-version: '17'
- name: Assemble debug APK
run: ./gradlew assembleDebug $CI_GRADLE_ARG_PROPERTIES
- uses: mobile-dev-inc/action-maestro-cloud@v1.3.1

9
.github/workflows/nightly.yml

@ -16,6 +16,15 @@ jobs: @@ -16,6 +16,15 @@ jobs:
if: ${{ github.repository == 'vector-im/element-x-android' }}
steps:
- uses: actions/checkout@v3
with:
# Ensure we are building the branch and not the branch after being merged on develop
# https://github.com/actions/checkout/issues/881
ref: ${{ github.event_name == 'pull_request' && github.event.pull_request.head.sha || github.ref }}
- name: Use JDK 17
uses: actions/setup-java@v3
with:
distribution: 'temurin' # See 'Supported distributions' for available options
java-version: '17'
- name: Install towncrier
run: |
python3 -m pip install towncrier

9
.github/workflows/nightly_manual.yml

@ -13,6 +13,15 @@ jobs: @@ -13,6 +13,15 @@ jobs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
with:
# Ensure we are building the branch and not the branch after being merged on develop
# https://github.com/actions/checkout/issues/881
ref: ${{ github.event_name == 'pull_request' && github.event.pull_request.head.sha || github.ref }}
- name: Use JDK 17
uses: actions/setup-java@v3
with:
distribution: 'temurin' # See 'Supported distributions' for available options
java-version: '17'
- name: Install towncrier
run: |
python3 -m pip install towncrier

20
.github/workflows/quality.yml

@ -8,7 +8,7 @@ on: @@ -8,7 +8,7 @@ on:
# Enrich gradle.properties for CI/CD
env:
GRADLE_OPTS: -Dorg.gradle.jvmargs="-Xmx3072m -Dfile.encoding=UTF-8 -XX:+HeapDumpOnOutOfMemoryError" -XX:MaxPermSize=512m -Dkotlin.daemon.jvm.options="-Xmx2g" -Dkotlin.incremental=false
GRADLE_OPTS: -Dorg.gradle.jvmargs="-Xmx3072m -Dfile.encoding=UTF-8 -XX:+HeapDumpOnOutOfMemoryError" -XX:MaxMetaspaceSize=512m -Dkotlin.daemon.jvm.options="-Xmx2g" -Dkotlin.incremental=false
CI_GRADLE_ARG_PROPERTIES: --stacktrace -PpreDexEnable=false --max-workers 2 --no-daemon
jobs:
@ -21,6 +21,15 @@ jobs: @@ -21,6 +21,15 @@ jobs:
cancel-in-progress: true
steps:
- uses: actions/checkout@v3
with:
# Ensure we are building the branch and not the branch after being merged on develop
# https://github.com/actions/checkout/issues/881
ref: ${{ github.event_name == 'pull_request' && github.event.pull_request.head.sha || github.ref }}
- name: Use JDK 17
uses: actions/setup-java@v3
with:
distribution: 'temurin' # See 'Supported distributions' for available options
java-version: '17'
- name: Configure gradle
uses: gradle/gradle-build-action@v2
with:
@ -60,6 +69,15 @@ jobs: @@ -60,6 +69,15 @@ jobs:
cancel-in-progress: true
steps:
- uses: actions/checkout@v3
with:
# Ensure we are building the branch and not the branch after being merged on develop
# https://github.com/actions/checkout/issues/881
ref: ${{ github.event_name == 'pull_request' && github.event.pull_request.head.sha || github.ref }}
- name: Use JDK 17
uses: actions/setup-java@v3
with:
distribution: 'temurin' # See 'Supported distributions' for available options
java-version: '17'
- name: Configure gradle
uses: gradle/gradle-build-action@v2
with:

8
.github/workflows/tests.yml

@ -24,7 +24,15 @@ jobs: @@ -24,7 +24,15 @@ jobs:
- name: ⏬ Checkout with LFS
uses: actions/checkout@v3
with:
# Ensure we are building the branch and not the branch after being merged on develop
# https://github.com/actions/checkout/issues/881
ref: ${{ github.event_name == 'pull_request' && github.event.pull_request.head.sha || github.ref }}
lfs: 'true'
- name: Use JDK 17
uses: actions/setup-java@v3
with:
distribution: 'temurin' # See 'Supported distributions' for available options
java-version: '17'
- name: Configure gradle
uses: gradle/gradle-build-action@v2
with:

3
anvilannotations/build.gradle.kts

@ -13,9 +13,6 @@ @@ -13,9 +13,6 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
// TODO: Remove once https://youtrack.jetbrains.com/issue/KTIJ-19369 is fixed
@Suppress("DSL_SCOPE_VIOLATION")
plugins {
alias(libs.plugins.kotlin.jvm)
id("com.android.lint")

2
anvilcodegen/build.gradle.kts

@ -14,8 +14,6 @@ @@ -14,8 +14,6 @@
* limitations under the License.
*/
// TODO: Remove once https://youtrack.jetbrains.com/issue/KTIJ-19369 is fixed
@Suppress("DSL_SCOPE_VIOLATION")
plugins {
alias(libs.plugins.kotlin.jvm)
alias(libs.plugins.kapt)

9
app/build.gradle.kts

@ -21,11 +21,8 @@ import extension.allFeaturesImpl @@ -21,11 +21,8 @@ import extension.allFeaturesImpl
import extension.allLibrariesImpl
import extension.allServicesImpl
// TODO: Remove once https://youtrack.jetbrains.com/issue/KTIJ-19369 is fixed
@Suppress("DSL_SCOPE_VIOLATION")
plugins {
id("io.element.android-compose-application")
alias(libs.plugins.stem)
alias(libs.plugins.kotlin.android)
alias(libs.plugins.anvil)
alias(libs.plugins.ksp)
@ -142,7 +139,7 @@ android { @@ -142,7 +139,7 @@ android {
}
}
kotlinOptions {
jvmTarget = "1.8"
jvmTarget = "17"
}
// Waiting for https://github.com/google/ksp/issues/37
@ -153,6 +150,10 @@ android { @@ -153,6 +150,10 @@ android {
}
}
}
buildFeatures {
buildConfig = true
}
}
androidComponents {

2
appnav/build.gradle.kts

@ -18,8 +18,6 @@ @@ -18,8 +18,6 @@
import extension.allFeaturesApi
// TODO: Remove once https://youtrack.jetbrains.com/issue/KTIJ-19369 is fixed
@Suppress("DSL_SCOPE_VIOLATION")
plugins {
id("io.element.android-compose-library")
alias(libs.plugins.anvil)

2
build.gradle.kts

@ -25,8 +25,6 @@ buildscript { @@ -25,8 +25,6 @@ buildscript {
*/
// Top-level build file where you can add configuration options common to all sub-projects/modules.
// TODO: Remove once https://youtrack.jetbrains.com/issue/KTIJ-19369 is fixed
@Suppress("DSL_SCOPE_VIOLATION")
plugins {
alias(libs.plugins.android.application) apply false
alias(libs.plugins.android.library) apply false

1
features/createroom/api/build.gradle.kts

@ -13,7 +13,6 @@ @@ -13,7 +13,6 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
plugins {
id("io.element.android-library")
}

2
features/createroom/impl/build.gradle.kts

@ -14,8 +14,6 @@ @@ -14,8 +14,6 @@
* limitations under the License.
*/
// TODO: Remove once https://youtrack.jetbrains.com/issue/KTIJ-19369 is fixed
@Suppress("DSL_SCOPE_VIOLATION")
plugins {
id("io.element.android-compose-library")
alias(libs.plugins.anvil)

1
features/login/api/build.gradle.kts

@ -13,7 +13,6 @@ @@ -13,7 +13,6 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
plugins {
id("io.element.android-library")
}

2
features/login/impl/build.gradle.kts

@ -14,8 +14,6 @@ @@ -14,8 +14,6 @@
* limitations under the License.
*/
// TODO: Remove once https://youtrack.jetbrains.com/issue/KTIJ-19369 is fixed
@Suppress("DSL_SCOPE_VIOLATION")
plugins {
id("io.element.android-compose-library")
alias(libs.plugins.anvil)

1
features/logout/api/build.gradle.kts

@ -13,7 +13,6 @@ @@ -13,7 +13,6 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
plugins {
id("io.element.android-compose-library")
}

2
features/logout/impl/build.gradle.kts

@ -14,8 +14,6 @@ @@ -14,8 +14,6 @@
* limitations under the License.
*/
// TODO: Remove once https://youtrack.jetbrains.com/issue/KTIJ-19369 is fixed
@Suppress("DSL_SCOPE_VIOLATION")
plugins {
id("io.element.android-compose-library")
alias(libs.plugins.anvil)

2
features/messages/api/build.gradle.kts

@ -14,8 +14,6 @@ @@ -14,8 +14,6 @@
* limitations under the License.
*/
// TODO: Remove once https://youtrack.jetbrains.com/issue/KTIJ-19369 is fixed
@Suppress("DSL_SCOPE_VIOLATION")
plugins {
id("io.element.android-library")
}

2
features/messages/impl/build.gradle.kts

@ -14,8 +14,6 @@ @@ -14,8 +14,6 @@
* limitations under the License.
*/
// TODO: Remove once https://youtrack.jetbrains.com/issue/KTIJ-19369 is fixed
@Suppress("DSL_SCOPE_VIOLATION")
plugins {
id("io.element.android-compose-library")
alias(libs.plugins.anvil)

1
features/onboarding/api/build.gradle.kts

@ -13,7 +13,6 @@ @@ -13,7 +13,6 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
plugins {
id("io.element.android-library")
}

2
features/onboarding/impl/build.gradle.kts

@ -14,8 +14,6 @@ @@ -14,8 +14,6 @@
* limitations under the License.
*/
// TODO: Remove once https://youtrack.jetbrains.com/issue/KTIJ-19369 is fixed
@Suppress("DSL_SCOPE_VIOLATION")
plugins {
id("io.element.android-compose-library")
alias(libs.plugins.anvil)

1
features/preferences/api/build.gradle.kts

@ -13,7 +13,6 @@ @@ -13,7 +13,6 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
plugins {
id("io.element.android-library")
}

2
features/preferences/impl/build.gradle.kts

@ -14,8 +14,6 @@ @@ -14,8 +14,6 @@
* limitations under the License.
*/
// TODO: Remove once https://youtrack.jetbrains.com/issue/KTIJ-19369 is fixed
@Suppress("DSL_SCOPE_VIOLATION")
plugins {
id("io.element.android-compose-library")
alias(libs.plugins.anvil)

1
features/rageshake/api/build.gradle.kts

@ -13,7 +13,6 @@ @@ -13,7 +13,6 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
plugins {
id("io.element.android-compose-library")
}

2
features/rageshake/impl/build.gradle.kts

@ -14,8 +14,6 @@ @@ -14,8 +14,6 @@
* limitations under the License.
*/
// TODO: Remove once https://youtrack.jetbrains.com/issue/KTIJ-19369 is fixed
@Suppress("DSL_SCOPE_VIOLATION")
plugins {
id("io.element.android-compose-library")
alias(libs.plugins.anvil)

1
features/rageshake/test/build.gradle.kts

@ -13,7 +13,6 @@ @@ -13,7 +13,6 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
plugins {
id("io.element.android-library")
}

2
features/roomdetails/api/build.gradle.kts

@ -14,8 +14,6 @@ @@ -14,8 +14,6 @@
* limitations under the License.
*/
// TODO: Remove once https://youtrack.jetbrains.com/issue/KTIJ-19369 is fixed
@Suppress("DSL_SCOPE_VIOLATION")
plugins {
id("io.element.android-library")
}

2
features/roomdetails/impl/build.gradle.kts

@ -14,8 +14,6 @@ @@ -14,8 +14,6 @@
* limitations under the License.
*/
// TODO: Remove once https://youtrack.jetbrains.com/issue/KTIJ-19369 is fixed
@Suppress("DSL_SCOPE_VIOLATION")
plugins {
id("io.element.android-compose-library")
alias(libs.plugins.anvil)

1
features/roomlist/api/build.gradle.kts

@ -13,7 +13,6 @@ @@ -13,7 +13,6 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
plugins {
id("io.element.android-library")
}

2
features/roomlist/impl/build.gradle.kts

@ -14,8 +14,6 @@ @@ -14,8 +14,6 @@
* limitations under the License.
*/
// TODO: Remove once https://youtrack.jetbrains.com/issue/KTIJ-19369 is fixed
@Suppress("DSL_SCOPE_VIOLATION")
plugins {
id("io.element.android-compose-library")
alias(libs.plugins.anvil)

1
features/userlist/api/build.gradle.kts

@ -13,7 +13,6 @@ @@ -13,7 +13,6 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
plugins {
id("io.element.android-compose-library")
}

2
features/userlist/impl/build.gradle.kts

@ -14,8 +14,6 @@ @@ -14,8 +14,6 @@
* limitations under the License.
*/
// TODO: Remove once https://youtrack.jetbrains.com/issue/KTIJ-19369 is fixed
@Suppress("DSL_SCOPE_VIOLATION")
plugins {
id("io.element.android-compose-library")
alias(libs.plugins.anvil)

1
features/userlist/test/build.gradle.kts

@ -13,7 +13,6 @@ @@ -13,7 +13,6 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
plugins {
id("io.element.android-compose-library")
}

2
features/verifysession/api/build.gradle.kts

@ -14,8 +14,6 @@ @@ -14,8 +14,6 @@
* limitations under the License.
*/
// TODO: Remove once https://youtrack.jetbrains.com/issue/KTIJ-19369 is fixed
@Suppress("DSL_SCOPE_VIOLATION")
plugins {
id("io.element.android-library")
}

2
features/verifysession/impl/build.gradle.kts

@ -14,8 +14,6 @@ @@ -14,8 +14,6 @@
* limitations under the License.
*/
// TODO: Remove once https://youtrack.jetbrains.com/issue/KTIJ-19369 is fixed
@Suppress("DSL_SCOPE_VIOLATION")
plugins {
id("io.element.android-compose-library")
alias(libs.plugins.ksp)

5
gradle.properties

@ -46,7 +46,10 @@ signing.element.nightly.keyPassword=Secret @@ -46,7 +46,10 @@ signing.element.nightly.keyPassword=Secret
# Customise the Lint version to use a more recent version than the one bundled with AGP
# https://googlesamples.github.io/android-custom-lint-rules/usage/newer-lint.md.html
android.experimental.lint.version=8.0.0-alpha10
android.experimental.lint.version=8.0.0
# Enable test fixture for all modules by default
android.experimental.enableTestFixtures=true
# Create BuildConfig files as bytecode to avoid Java compilation phase
android.enableBuildConfigAsBytecode=true

4
gradle/libs.versions.toml

@ -3,7 +3,7 @@ @@ -3,7 +3,7 @@
[versions]
# Project
android_gradle_plugin = "7.4.2"
android_gradle_plugin = "8.0.0"
kotlin = "1.8.10"
ksp = "1.8.10-1.0.9"
molecule = "0.9.0"
@ -162,8 +162,6 @@ detekt = { id = "io.gitlab.arturbosch.detekt", version.ref = "detekt" } @@ -162,8 +162,6 @@ detekt = { id = "io.gitlab.arturbosch.detekt", version.ref = "detekt" }
ktlint = { id = "org.jlleitschuh.gradle.ktlint", version.ref = "ktlint" }
dependencygraph = { id = "com.savvasdalkitsis.module-dependency-graph", version.ref = "dependencygraph" }
dependencycheck = { id = "org.owasp.dependencycheck", version.ref = "dependencycheck" }
stem = { id = "com.likethesalad.stem", version.ref = "stem" }
stemlibrary = { id = "com.likethesalad.stem-library", version.ref = "stem" }
paparazzi = "app.cash.paparazzi:1.2.0"
sonarqube = "org.sonarqube:4.0.0.2929"
kover = "org.jetbrains.kotlinx.kover:0.6.1"

4
gradle/wrapper/gradle-wrapper.properties vendored

@ -16,8 +16,8 @@ @@ -16,8 +16,8 @@
#Fri Oct 07 15:02:00 CEST 2022
distributionBase=GRADLE_USER_HOME
distributionSha256Sum=518a863631feb7452b8f1b3dc2aaee5f388355cc3421bbd0275fbeadd77e84b2
distributionUrl=https\://services.gradle.org/distributions/gradle-7.6.1-all.zip
distributionSha256Sum=2cbafcd2c47a101cb2165f636b4677fac0b954949c9429c1c988da399defe6a9
distributionUrl=https\://services.gradle.org/distributions/gradle-8.1-all.zip
distributionPath=wrapper/dists
zipStorePath=wrapper/dists
zipStoreBase=GRADLE_USER_HOME

1
libraries/androidutils/build.gradle.kts

@ -14,7 +14,6 @@ @@ -14,7 +14,6 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
plugins {
id("io.element.android-library")
}

3
libraries/architecture/build.gradle.kts

@ -13,9 +13,6 @@ @@ -13,9 +13,6 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
// TODO: Remove once https://youtrack.jetbrains.com/issue/KTIJ-19369 is fixed
@Suppress("DSL_SCOPE_VIOLATION")
plugins {
id("io.element.android-compose-library")
}

7
libraries/core/build.gradle.kts

@ -13,9 +13,6 @@ @@ -13,9 +13,6 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
// TODO: Remove once https://youtrack.jetbrains.com/issue/KTIJ-19369 is fixed
@Suppress("DSL_SCOPE_VIOLATION")
plugins {
id("java-library")
id("com.android.lint")
@ -23,8 +20,8 @@ plugins { @@ -23,8 +20,8 @@ plugins {
}
java {
sourceCompatibility = JavaVersion.VERSION_1_8
targetCompatibility = JavaVersion.VERSION_1_8
sourceCompatibility = JavaVersion.VERSION_17
targetCompatibility = JavaVersion.VERSION_17
}
dependencies {

6
libraries/coroutines/build.gradle.kts

@ -13,16 +13,14 @@ @@ -13,16 +13,14 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
// TODO: Remove once https://youtrack.jetbrains.com/issue/KTIJ-19369 is fixed
@Suppress("DSL_SCOPE_VIOLATION")
plugins {
id("java-library")
alias(libs.plugins.kotlin.jvm)
}
java {
sourceCompatibility = JavaVersion.VERSION_1_8
targetCompatibility = JavaVersion.VERSION_1_8
sourceCompatibility = JavaVersion.VERSION_17
targetCompatibility = JavaVersion.VERSION_17
}
dependencies {

2
libraries/dateformatter/api/build.gradle.kts

@ -14,8 +14,6 @@ @@ -14,8 +14,6 @@
* limitations under the License.
*/
// TODO: Remove once https://youtrack.jetbrains.com/issue/KTIJ-19369 is fixed
@Suppress("DSL_SCOPE_VIOLATION")
plugins {
id("io.element.android-library")
}

2
libraries/dateformatter/impl/build.gradle.kts

@ -14,8 +14,6 @@ @@ -14,8 +14,6 @@
* limitations under the License.
*/
// TODO: Remove once https://youtrack.jetbrains.com/issue/KTIJ-19369 is fixed
@Suppress("DSL_SCOPE_VIOLATION")
plugins {
id("io.element.android-library")
alias(libs.plugins.ksp)

2
libraries/dateformatter/test/build.gradle.kts

@ -14,8 +14,6 @@ @@ -14,8 +14,6 @@
* limitations under the License.
*/
// TODO: Remove once https://youtrack.jetbrains.com/issue/KTIJ-19369 is fixed
@Suppress("DSL_SCOPE_VIOLATION")
plugins {
id("io.element.android-library")
}

3
libraries/deeplink/build.gradle.kts

@ -13,9 +13,6 @@ @@ -13,9 +13,6 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
// TODO: Remove once https://youtrack.jetbrains.com/issue/KTIJ-19369 is fixed
@Suppress("DSL_SCOPE_VIOLATION")
plugins {
id("io.element.android-library")
alias(libs.plugins.anvil)

6
libraries/designsystem/build.gradle.kts

@ -14,8 +14,6 @@ @@ -14,8 +14,6 @@
* limitations under the License.
*/
// TODO: Remove once https://youtrack.jetbrains.com/issue/KTIJ-19369 is fixed
@Suppress("DSL_SCOPE_VIOLATION")
plugins {
id("io.element.android-compose-library")
alias(libs.plugins.ksp)
@ -25,6 +23,10 @@ plugins { @@ -25,6 +23,10 @@ plugins {
android {
namespace = "io.element.android.libraries.designsystem"
buildFeatures {
buildConfig = true
}
dependencies {
// Should not be there, but this is a POC
implementation(libs.coil.compose)

2
libraries/di/build.gradle.kts

@ -14,8 +14,6 @@ @@ -14,8 +14,6 @@
* limitations under the License.
*/
// TODO: Remove once https://youtrack.jetbrains.com/issue/KTIJ-19369 is fixed
@Suppress("DSL_SCOPE_VIOLATION")
plugins {
alias(libs.plugins.kotlin.jvm)
id("com.android.lint")

1
libraries/elementresources/build.gradle.kts

@ -13,7 +13,6 @@ @@ -13,7 +13,6 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
plugins {
id("io.element.android-library")
}

1
libraries/encrypted-db/build.gradle.kts

@ -13,7 +13,6 @@ @@ -13,7 +13,6 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
plugins {
id("io.element.android-library")
}

6
libraries/matrix/api/build.gradle.kts

@ -14,8 +14,6 @@ @@ -14,8 +14,6 @@
* limitations under the License.
*/
// TODO: Remove once https://youtrack.jetbrains.com/issue/KTIJ-19369 is fixed
@Suppress("DSL_SCOPE_VIOLATION")
plugins {
id("io.element.android-library")
id("kotlin-parcelize")
@ -25,6 +23,10 @@ plugins { @@ -25,6 +23,10 @@ plugins {
android {
namespace = "io.element.android.libraries.matrix.api"
buildFeatures {
buildConfig = true
}
}
anvil {

2
libraries/matrix/impl/build.gradle.kts

@ -14,8 +14,6 @@ @@ -14,8 +14,6 @@
* limitations under the License.
*/
// TODO: Remove once https://youtrack.jetbrains.com/issue/KTIJ-19369 is fixed
@Suppress("DSL_SCOPE_VIOLATION")
plugins {
id("io.element.android-library")
alias(libs.plugins.anvil)

2
libraries/matrix/test/build.gradle.kts

@ -14,8 +14,6 @@ @@ -14,8 +14,6 @@
* limitations under the License.
*/
// TODO: Remove once https://youtrack.jetbrains.com/issue/KTIJ-19369 is fixed
@Suppress("DSL_SCOPE_VIOLATION")
plugins {
id("io.element.android-library")
}

2
libraries/matrixui/build.gradle.kts

@ -14,8 +14,6 @@ @@ -14,8 +14,6 @@
* limitations under the License.
*/
// TODO: Remove once https://youtrack.jetbrains.com/issue/KTIJ-19369 is fixed
@Suppress("DSL_SCOPE_VIOLATION")
plugins {
id("io.element.android-compose-library")
alias(libs.plugins.anvil)

1
libraries/network/build.gradle.kts

@ -13,7 +13,6 @@ @@ -13,7 +13,6 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
plugins {
id("io.element.android-library")
alias(libs.plugins.anvil)

1
libraries/permissions/api/build.gradle.kts

@ -13,7 +13,6 @@ @@ -13,7 +13,6 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
plugins {
id("io.element.android-compose-library")
alias(libs.plugins.ksp)

2
libraries/permissions/impl/build.gradle.kts

@ -14,8 +14,6 @@ @@ -14,8 +14,6 @@
* limitations under the License.
*/
// TODO: Remove once https://youtrack.jetbrains.com/issue/KTIJ-19369 is fixed
@Suppress("DSL_SCOPE_VIOLATION")
plugins {
id("io.element.android-compose-library")
alias(libs.plugins.anvil)

2
libraries/permissions/noop/build.gradle.kts

@ -14,8 +14,6 @@ @@ -14,8 +14,6 @@
* limitations under the License.
*/
// TODO: Remove once https://youtrack.jetbrains.com/issue/KTIJ-19369 is fixed
@Suppress("DSL_SCOPE_VIOLATION")
plugins {
id("io.element.android-compose-library")
}

1
libraries/push/api/build.gradle.kts

@ -13,7 +13,6 @@ @@ -13,7 +13,6 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
plugins {
id("io.element.android-library")
}

1
libraries/push/impl/build.gradle.kts

@ -13,7 +13,6 @@ @@ -13,7 +13,6 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
plugins {
id("io.element.android-library")
alias(libs.plugins.anvil)

1
libraries/pushproviders/api/build.gradle.kts

@ -13,7 +13,6 @@ @@ -13,7 +13,6 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
plugins {
id("io.element.android-library")
}

1
libraries/pushproviders/firebase/build.gradle.kts

@ -13,7 +13,6 @@ @@ -13,7 +13,6 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
plugins {
id("io.element.android-library")
alias(libs.plugins.anvil)

1
libraries/pushproviders/unifiedpush/build.gradle.kts

@ -13,7 +13,6 @@ @@ -13,7 +13,6 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
plugins {
id("io.element.android-library")
alias(libs.plugins.anvil)

1
libraries/pushstore/api/build.gradle.kts

@ -13,7 +13,6 @@ @@ -13,7 +13,6 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
plugins {
id("io.element.android-library")
}

1
libraries/pushstore/impl/build.gradle.kts

@ -13,7 +13,6 @@ @@ -13,7 +13,6 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
plugins {
id("io.element.android-library")
alias(libs.plugins.anvil)

1
libraries/session-storage/api/build.gradle.kts

@ -13,7 +13,6 @@ @@ -13,7 +13,6 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
plugins {
id("io.element.android-library")
}

1
libraries/session-storage/impl-memory/build.gradle.kts

@ -13,7 +13,6 @@ @@ -13,7 +13,6 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
plugins {
id("io.element.android-library")
}

1
libraries/session-storage/impl/build.gradle.kts

@ -13,7 +13,6 @@ @@ -13,7 +13,6 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
plugins {
id("io.element.android-library")
alias(libs.plugins.anvil)

6
libraries/statemachine/build.gradle.kts

@ -14,8 +14,6 @@ @@ -14,8 +14,6 @@
* limitations under the License.
*/
// TODO: Remove once https://youtrack.jetbrains.com/issue/KTIJ-19369 is fixed
@Suppress("DSL_SCOPE_VIOLATION")
plugins {
id("java-library")
id("com.android.lint")
@ -23,8 +21,8 @@ plugins { @@ -23,8 +21,8 @@ plugins {
}
java {
sourceCompatibility = JavaVersion.VERSION_1_8
targetCompatibility = JavaVersion.VERSION_1_8
sourceCompatibility = JavaVersion.VERSION_17
targetCompatibility = JavaVersion.VERSION_17
}
dependencies {

1
libraries/testtags/build.gradle.kts

@ -13,7 +13,6 @@ @@ -13,7 +13,6 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
plugins {
id("io.element.android-compose-library")
}

2
libraries/textcomposer/build.gradle.kts

@ -14,8 +14,6 @@ @@ -14,8 +14,6 @@
* limitations under the License.
*/
// TODO: Remove once https://youtrack.jetbrains.com/issue/KTIJ-19369 is fixed
@Suppress("DSL_SCOPE_VIOLATION")
plugins {
id("io.element.android-compose-library")
alias(libs.plugins.ksp)

9
libraries/ui-strings/build.gradle.kts

@ -14,19 +14,10 @@ @@ -14,19 +14,10 @@
* limitations under the License.
*/
// TODO: Remove once https://youtrack.jetbrains.com/issue/KTIJ-19369 is fixed
@Suppress("DSL_SCOPE_VIOLATION")
plugins {
id("io.element.android-library")
alias(libs.plugins.stemlibrary)
}
android {
namespace = "io.element.android.libraries.ui.strings"
}
// forcing the stem string template generator to be cacheable, without this the templates
// are regenerated causing the app module to recompile its sources
tasks.withType(com.likethesalad.android.templates.common.tasks.BaseTask::class.java) {
outputs.cacheIf { true }
}

1
plugins/build.gradle.kts

@ -13,7 +13,6 @@ @@ -13,7 +13,6 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
plugins {
`kotlin-dsl`
`kotlin-dsl-precompiled-script-plugins`

2
plugins/src/main/kotlin/Versions.kt

@ -24,6 +24,6 @@ object Versions { @@ -24,6 +24,6 @@ object Versions {
const val compileSdk = 33
const val targetSdk = 33
const val minSdk = 23
val javaCompileVersion = JavaVersion.VERSION_11
val javaCompileVersion = JavaVersion.VERSION_17
val javaLanguageVersion: JavaLanguageVersion = JavaLanguageVersion.of(11)
}

6
plugins/src/main/kotlin/extension/CommonExtension.kt

@ -32,8 +32,8 @@ fun CommonExtension<*, *, *, *>.androidConfig(project: Project) { @@ -32,8 +32,8 @@ fun CommonExtension<*, *, *, *>.androidConfig(project: Project) {
compileOptions {
isCoreLibraryDesugaringEnabled = true
sourceCompatibility = JavaVersion.VERSION_1_8
targetCompatibility = JavaVersion.VERSION_1_8
sourceCompatibility = JavaVersion.VERSION_17
targetCompatibility = JavaVersion.VERSION_17
}
testOptions {
@ -58,7 +58,7 @@ fun CommonExtension<*, *, *, *>.composeConfig(libs: LibrariesForLibs) { @@ -58,7 +58,7 @@ fun CommonExtension<*, *, *, *>.composeConfig(libs: LibrariesForLibs) {
kotlinCompilerExtensionVersion = libs.versions.composecompiler.get()
}
packagingOptions {
packaging {
resources.excludes.apply {
add("META-INF/AL2.0")
add("META-INF/LGPL2.1")

9
plugins/src/main/kotlin/extension/DependencyHandleScope.kt

@ -16,14 +16,17 @@ @@ -16,14 +16,17 @@
package extension
import gradle.kotlin.dsl.accessors._71f190358cebd46a469f2989484fd643.androidTestImplementation
import gradle.kotlin.dsl.accessors._71f190358cebd46a469f2989484fd643.debugImplementation
import gradle.kotlin.dsl.accessors._71f190358cebd46a469f2989484fd643.implementation
import org.gradle.accessors.dm.LibrariesForLibs
import org.gradle.kotlin.dsl.DependencyHandlerScope
import org.gradle.kotlin.dsl.project
import java.io.File
private fun DependencyHandlerScope.implementation(dependency: Any) = dependencies.add("implementation", dependency)
private fun DependencyHandlerScope.androidTestImplementation(dependency: Any) = dependencies.add("androidTestImplementation", dependency)
private fun DependencyHandlerScope.debugImplementation(dependency: Any) = dependencies.add("debugImplementation", dependency)
/**
* Dependencies used by all the modules
*/

1
plugins/src/main/kotlin/io.element.android-compose-application.gradle.kts

@ -24,7 +24,6 @@ import extension.composeDependencies @@ -24,7 +24,6 @@ import extension.composeDependencies
import org.gradle.accessors.dm.LibrariesForLibs
val libs = the<LibrariesForLibs>()
plugins {
id("com.android.application")
id("kotlin-android")

1
plugins/src/main/kotlin/io.element.android-compose-library.gradle.kts

@ -24,7 +24,6 @@ import extension.composeDependencies @@ -24,7 +24,6 @@ import extension.composeDependencies
import org.gradle.accessors.dm.LibrariesForLibs
val libs = the<LibrariesForLibs>()
plugins {
id("com.android.library")
id("kotlin-android")

1
plugins/src/main/kotlin/io.element.android-library.gradle.kts

@ -22,7 +22,6 @@ import extension.commonDependencies @@ -22,7 +22,6 @@ import extension.commonDependencies
import org.gradle.accessors.dm.LibrariesForLibs
val libs = the<LibrariesForLibs>()
plugins {
id("com.android.library")
id("kotlin-android")

1
samples/minimal/build.gradle.kts

@ -14,7 +14,6 @@ @@ -14,7 +14,6 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
plugins {
id("io.element.android-compose-application")
alias(libs.plugins.kotlin.android)

1
services/analytics/api/build.gradle.kts

@ -13,7 +13,6 @@ @@ -13,7 +13,6 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
plugins {
id("io.element.android-library")
}

1
services/analytics/noop/build.gradle.kts

@ -13,7 +13,6 @@ @@ -13,7 +13,6 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
plugins {
id("io.element.android-library")
alias(libs.plugins.anvil)

2
services/appnavstate/api/build.gradle.kts

@ -14,8 +14,6 @@ @@ -14,8 +14,6 @@
* limitations under the License.
*/
// TODO: Remove once https://youtrack.jetbrains.com/issue/KTIJ-19369 is fixed
@Suppress("DSL_SCOPE_VIOLATION")
plugins {
id("io.element.android-library")
}

2
services/appnavstate/impl/build.gradle.kts

@ -14,8 +14,6 @@ @@ -14,8 +14,6 @@
* limitations under the License.
*/
// TODO: Remove once https://youtrack.jetbrains.com/issue/KTIJ-19369 is fixed
@Suppress("DSL_SCOPE_VIOLATION")
plugins {
id("io.element.android-library")
alias(libs.plugins.ksp)

2
services/appnavstate/test/build.gradle.kts

@ -14,8 +14,6 @@ @@ -14,8 +14,6 @@
* limitations under the License.
*/
// TODO: Remove once https://youtrack.jetbrains.com/issue/KTIJ-19369 is fixed
@Suppress("DSL_SCOPE_VIOLATION")
plugins {
id("io.element.android-library")
}

1
services/toolbox/api/build.gradle.kts

@ -13,7 +13,6 @@ @@ -13,7 +13,6 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
plugins {
id("io.element.android-library")
}

1
services/toolbox/impl/build.gradle.kts

@ -13,7 +13,6 @@ @@ -13,7 +13,6 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
plugins {
id("io.element.android-library")
alias(libs.plugins.anvil)

7
tests/testutils/build.gradle.kts

@ -13,9 +13,6 @@ @@ -13,9 +13,6 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
// TODO: Remove once https://youtrack.jetbrains.com/issue/KTIJ-19369 is fixed
@Suppress("DSL_SCOPE_VIOLATION")
plugins {
id("io.element.android-library")
alias(libs.plugins.ksp)
@ -23,6 +20,10 @@ plugins { @@ -23,6 +20,10 @@ plugins {
android {
namespace = "io.element.android.tests.testutils"
buildFeatures {
buildConfig = true
}
}
dependencies {

2
tests/uitests/build.gradle.kts

@ -17,8 +17,6 @@ @@ -17,8 +17,6 @@
import extension.allFeaturesImpl
import extension.allLibrariesImpl
// TODO: Remove once https://youtrack.jetbrains.com/issue/KTIJ-19369 is fixed
@Suppress("DSL_SCOPE_VIOLATION")
plugins {
id("io.element.android-compose-library")
alias(libs.plugins.ksp)

Loading…
Cancel
Save