yandexads-flutter

Форк
0
67 строк · 1.8 Кб
1
def localProperties = new Properties()
2
def localPropertiesFile = rootProject.file('local.properties')
3
if (localPropertiesFile.exists()) {
4
    localPropertiesFile.withReader('UTF-8') { reader ->
5
        localProperties.load(reader)
6
    }
7
}
8

9
def flutterRoot = localProperties.getProperty('flutter.sdk')
10
if (flutterRoot == null) {
11
    throw new GradleException("Flutter SDK not found. Define location with flutter.sdk in the local.properties file.")
12
}
13

14
def flutterVersionCode = localProperties.getProperty('flutter.versionCode')
15
if (flutterVersionCode == null) {
16
    flutterVersionCode = '1'
17
}
18

19
def flutterVersionName = localProperties.getProperty('flutter.versionName')
20
if (flutterVersionName == null) {
21
    flutterVersionName = '1.0'
22
}
23

24
apply plugin: 'com.android.application'
25
apply plugin: 'kotlin-android'
26
apply from: "$flutterRoot/packages/flutter_tools/gradle/flutter.gradle"
27

28
android {
29
    compileSdkVersion flutter.compileSdkVersion
30

31
    compileOptions {
32
        sourceCompatibility JavaVersion.VERSION_1_8
33
        targetCompatibility JavaVersion.VERSION_1_8
34
    }
35

36
    kotlinOptions {
37
        jvmTarget = '1.8'
38
    }
39

40
    sourceSets {
41
        main.java.srcDirs += 'src/main/kotlin'
42
    }
43

44
    defaultConfig {
45
        applicationId "ru.kovardin.flutter_yandex_ads_example"
46
        minSdkVersion 21
47
        targetSdkVersion flutter.targetSdkVersion
48
        versionCode flutterVersionCode.toInteger()
49
        versionName flutterVersionName
50
    }
51

52
    buildTypes {
53
        release {
54
            // TODO: Add your own signing config for the release build.
55
            // Signing with the debug keys for now, so `flutter run --release` works.
56
            signingConfig signingConfigs.debug
57
        }
58
    }
59
}
60

61
flutter {
62
    source '../..'
63
}
64

65
dependencies {
66
    implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk7:$kotlin_version"
67
}
68

Использование cookies

Мы используем файлы cookie в соответствии с Политикой конфиденциальности и Политикой использования cookies.

Нажимая кнопку «Принимаю», Вы даете АО «СберТех» согласие на обработку Ваших персональных данных в целях совершенствования нашего веб-сайта и Сервиса GitVerse, а также повышения удобства их использования.

Запретить использование cookies Вы можете самостоятельно в настройках Вашего браузера.