• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1apply plugin: 'com.android.library'
2apply plugin: 'com.github.dcendents.android-maven'
3
4group='com.github.philjay'
5
6android {
7    compileSdkVersion 28
8    buildToolsVersion '28.0.3'
9    defaultConfig {
10        minSdkVersion 14
11        targetSdkVersion 28
12        versionCode 3
13        versionName '3.1.0'
14    }
15    buildTypes {
16        release {
17            minifyEnabled false
18            proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
19        }
20    }
21    testOptions {
22        unitTests.returnDefaultValues = true // this prevents "not mocked" error
23    }
24}
25
26dependencies {
27    implementation 'androidx.annotation:annotation:1.0.0'
28    testImplementation 'junit:junit:4.12'
29}
30
31task sourcesJar(type: Jar) {
32    from android.sourceSets.main.java.srcDirs
33    classifier = 'sources'
34}
35
36task javadoc(type: Javadoc) {
37    options.charSet = 'UTF-8'
38    failOnError  false
39    source = android.sourceSets.main.java.sourceFiles
40    classpath += project.files(android.getBootClasspath().join(File.pathSeparator))
41}
42
43task javadocJar(type: Jar, dependsOn: javadoc) {
44    classifier = 'javadoc'
45    from javadoc.destinationDir
46}
47
48artifacts {
49    archives sourcesJar
50    archives javadocJar
51}
52