config.gradle

354 阅读1分钟
ext {
    android = [
            compileSdkVersion       :28,
            buildToolsVersion       :"28.0.3",
            minSdkVersion       :19,
            targetSdkVersion       :28,
            versionCode       :4,
            versionName       :'1.0.1',
            supportVersion : '28.0.0',

            Vbutterknife            : '10.1.0',
            Vretrofit2              : '2.6.1',
            Vokhttp                 : '3.14.2',
            Vrxjava                 : '2.2.8',
            Vrxandroid              : '2.1.1',
            Vrxlifecycle            : '2.2.1',
            Vgson                   : '2.8.5',
            VSupportSdk             : '28.0.0',
            vConstraint             : "1.1.3",
            Vtimber                 : '4.7.1'

    ]

    dependencies = [
            "appcompat-v7"               : "com.android.support:appcompat-v7:${android["VSupportSdk"]}",
            "support-v4"                    : "com.android.support:support-v4:${android["VSupportSdk"]}",
            "cardView"                      : "com.android.support:cardview-v7:${android["VSupportSdk"]}",
            "design"                     : "com.android.support:design:${android["VSupportSdk"]}",
            "annotations"                : "com.android.support:support-annotations:${android["VSupportSdk"]}",
            "recyclerview-v7"            : "com.android.support:recyclerview-v7:${android["VSupportSdk"]}",

            "support-constraint"         : "com.android.support.constraint:constraint-layout:${android["vConstraint"]}",

            "bottomSheetCore"                : 'com.flipboard:bottomsheet-core:1.5.3',
            "bottomSheetCommon"            : 'com.flipboard:bottomsheet-commons:1.5.3',
            "takephoto"                     : 'com.jph.takephoto:takephoto_library:4.0.3',

            'retrofit2'             : "com.squareup.retrofit2:retrofit:${android['Vretrofit2']}",
            'converter-gson'        : "com.squareup.retrofit2:converter-gson:${android['Vretrofit2']}",
            'adapter-rxjava2'       : "com.squareup.retrofit2:adapter-rxjava2:${android['Vretrofit2']}",

            'gson'                  : "com.google.code.gson:gson:${android['Vgson']}",
            'timber'                : "com.jakewharton.timber:timber:${android['Vtimber']}",

            'okhttp'                : "com.squareup.okhttp3:okhttp:${android['Vokhttp']}",
            'logging-interceptor'   : "com.squareup.okhttp3:logging-interceptor:${android['Vokhttp']}",

            'rxjava'                : "io.reactivex.rxjava2:rxjava:${android['Vrxjava']}",
            'rxandroid'             : "io.reactivex.rxjava2:rxandroid:${android['Vrxandroid']}",

            'rxlifecycle'            : "com.trello.rxlifecycle2:rxlifecycle:${android['Vrxlifecycle']}",
            'rxlifecycle-android'     : "com.trello.rxlifecycle2:rxlifecycle-android:${android['Vrxlifecycle']}",
            'rxlifecycle-components'  : "com.trello.rxlifecycle2:rxlifecycle-components:${android['Vrxlifecycle']}",

            'butterknife'           : "com.jakewharton:butterknife:${android['Vbutterknife']}",
            'butterknife-compiler'  : "com.jakewharton:butterknife-compiler:${android['Vbutterknife']}"
    ]
}