group 'dev.steenbakker.nordicdfu' version '1.0-SNAPSHOT' def localProperties = new Properties() def localPropertiesFile = rootProject.file('local.properties') if (localPropertiesFile.exists()) { localPropertiesFile.withReader('UTF-8') { reader -> localProperties.load(reader) } } def flutterRoot = localProperties.getProperty('flutter.sdk') if (flutterRoot == null) { throw new Exception("Flutter SDK not found. Define location with flutter.sdk in the local.properties file.") } def flutterVersionCode = localProperties.getProperty('flutter.versionCode') if (flutterVersionCode == null) { flutterVersionCode = '1' } def flutterVersionName = localProperties.getProperty('flutter.versionName') if (flutterVersionName == null) { flutterVersionName = '1.0' } buildscript { ext.kotlin_version = '1.6.21' repositories { google() mavenCentral() } dependencies { classpath 'com.android.tools.build:gradle:4.1.0' classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:1.7.0" } } rootProject.allprojects { repositories { google() mavenCentral() } } apply plugin: 'com.android.library' apply plugin: 'kotlin-android' android { compileSdkVersion 32 sourceSets { main.java.srcDirs += 'src/main/kotlin' } defaultConfig { minSdkVersion 18 } compileOptions { sourceCompatibility JavaVersion.VERSION_1_8 targetCompatibility JavaVersion.VERSION_1_8 } } dependencies { implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk7:$kotlin_version" compileOnly files("$flutterRoot/bin/cache/artifacts/engine/android-arm64/flutter.jar") // compileOnly 'androidx.annotation:annotation:1.3.0' implementation 'androidx.core:core:1.7.0' implementation 'androidx.localbroadcastmanager:localbroadcastmanager:1.1.0' implementation 'androidx.annotation:annotation:1.3.0' implementation 'com.google.code.gson:gson:2.8.9' } repositories { mavenCentral() }