From e4f44b43af3234ed61946c4a09e0a108c5a4c4c9 Mon Sep 17 00:00:00 2001 From: greenart7c3 Date: Wed, 28 Jan 2026 17:10:13 -0300 Subject: [PATCH] Update build configuration to follow modern Gradle and Kotlin DSL syntax - Update `settings.gradle` and `app/build.gradle` to use assignment operators for properties like `url`, `namespace`, `useSupportLibrary`, and `buildFeatures`. - Migrate from `kotlinOptions` to `compilerOptions` in `build.gradle`. - Update Kotlin compiler argument handling to use `freeCompilerArgs.addAll` instead of list concatenation. --- app/build.gradle | 12 ++++++------ build.gradle | 8 ++++---- settings.gradle | 4 ++-- 3 files changed, 12 insertions(+), 12 deletions(-) diff --git a/app/build.gradle b/app/build.gradle index f184fc95..81676441 100644 --- a/app/build.gradle +++ b/app/build.gradle @@ -9,7 +9,7 @@ plugins { } android { - namespace 'com.greenart7c3.nostrsigner' + namespace = 'com.greenart7c3.nostrsigner' compileSdk = 36 defaultConfig { @@ -21,7 +21,7 @@ android { testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner" vectorDrawables { - useSupportLibrary true + useSupportLibrary = true } resourceConfigurations += [ 'bn-rBD', @@ -140,10 +140,10 @@ android { splits { abi { - enable true + enable = true reset() include "x86", "x86_64", "arm64-v8a", "armeabi-v7a" - universalApk true + universalApk = true } } @@ -153,8 +153,8 @@ android { } buildFeatures { - compose true - buildConfig true + compose = true + buildConfig = true } packagingOptions { diff --git a/build.gradle b/build.gradle index d24d34eb..b2c69dff 100644 --- a/build.gradle +++ b/build.gradle @@ -27,17 +27,17 @@ project(":app") { subprojects { tasks.withType(KotlinCompile).configureEach { - kotlinOptions { - var buildDirPath = project.layout.buildDirectory.get().asFile.absolutePath + compilerOptions { + def buildDirPath = project.layout.buildDirectory.get().asFile.absolutePath if (project.findProperty("composeCompilerReports") == "true") { - freeCompilerArgs += listOf( + freeCompilerArgs.addAll( "-P", "plugin:androidx.compose.compiler.plugins.kotlin:reportsDestination=" + buildDirPath + "/compose_compiler" ) } if (project.findProperty("composeCompilerMetrics") == "true") { - freeCompilerArgs += listOf( + freeCompilerArgs.addAll( "-P", "plugin:androidx.compose.compiler.plugins.kotlin:metricsDestination=" + buildDirPath + "/compose_compiler" diff --git a/settings.gradle b/settings.gradle index 6ecf5781..7696c7e7 100644 --- a/settings.gradle +++ b/settings.gradle @@ -3,7 +3,7 @@ pluginManagement { google() mavenCentral() gradlePluginPortal() - maven { url "https://jitpack.io" } + maven { url = "https://jitpack.io" } } } dependencyResolutionManagement { @@ -11,7 +11,7 @@ dependencyResolutionManagement { repositories { google() mavenCentral() - maven { url "https://jitpack.io" } + maven { url = "https://jitpack.io" } } } rootProject.name = "Nostr Signer"