apply plugin: 'com.android.library'
apply plugin: 'com.github.dcendents.android-maven'
apply plugin: "com.jfrog.bintray"

ext {
    PUBLISH_GROUP_ID = 'com.emredavarci'
    PUBLISH_ARTIFACT_ID = 'noty'
    PUBLISH_VERSION = '1.0.3'
}


android {
    compileSdkVersion 25
    buildToolsVersion "25.0.1"

    defaultConfig {
        minSdkVersion 16
        targetSdkVersion 25
        versionCode 4
        versionName "1.0.3"

        testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner"

    }
    buildTypes {
        release {
            minifyEnabled false
            proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
        }
    }
}

dependencies {
    compile fileTree(dir: 'libs', include: ['*.jar'])
    androidTestCompile('com.android.support.test.espresso:espresso-core:2.2.2', {
        exclude group: 'com.android.support', module: 'support-annotations'
    })
    compile 'com.android.support:appcompat-v7:25.0.1'
    testCompile 'junit:junit:4.12'
}

apply from: 'https://raw.githubusercontent.com/blundell/release-android-library/master/android-release-aar.gradle'

def siteUrl = 'https://github.com/emre1512/Noty'      // Homepage URL of the library
def gitUrl = 'https://github.com/emre1512/Noty.git'   // Git repository URL
group = "com.emredavarci"

install {
    repositories.mavenInstaller {
        pom {
            project {
                packaging 'aar'

                name 'com.emredavarci:noty' // TODO
                description = 'Noty' // TODO
                url siteUrl

                // Set your license
                licenses {
                    license {
                        name 'The Apache Software License, Version 2.0'
                        url 'http://www.apache.org/licenses/LICENSE-2.0.txt'
                    }
                }
                developers {
                    developer {
                        id 'emre1512' // TODO
                        name 'M. Emre Davarci' // TODO
                        email 'emre151291@gmail.com' // TODO
                    }
                }
                scm {
                    connection gitUrl
                    developerConnection gitUrl
                    url siteUrl
                }
            }
        }
    }
}
