diff --git a/build.gradle b/build.gradle index 6a26612..7f23c87 100644 --- a/build.gradle +++ b/build.gradle @@ -8,8 +8,7 @@ buildscript { } dependencies { classpath 'com.android.tools.build:gradle:3.0.0' - classpath 'com.github.dcendents:android-maven-gradle-plugin:2.0' - classpath 'com.jfrog.bintray.gradle:gradle-bintray-plugin:1.8.0' + classpath 'com.github.dcendents:android-maven-gradle-plugin:2.1' // NOTE: Do not place your application dependencies here; they belong // in the individual module build.gradle files diff --git a/sectionedrecyclerview/build.gradle b/sectionedrecyclerview/build.gradle index a3f4b68..f7c3155 100644 --- a/sectionedrecyclerview/build.gradle +++ b/sectionedrecyclerview/build.gradle @@ -1,4 +1,6 @@ apply plugin: 'com.android.library' +apply plugin: 'com.github.dcendents.android-maven' +group = 'com.github.crux-lab' android { compileSdkVersion 26 @@ -31,5 +33,3 @@ dependencies { androidTestImplementation 'com.android.support.test.espresso:espresso-core:3.0.1' implementation 'com.android.support:recyclerview-v7:26.1.0' } - -apply from: 'publish.gradle' \ No newline at end of file diff --git a/sectionedrecyclerview/publish.gradle b/sectionedrecyclerview/publish.gradle deleted file mode 100644 index 223c3b4..0000000 --- a/sectionedrecyclerview/publish.gradle +++ /dev/null @@ -1,83 +0,0 @@ -apply plugin: 'maven-publish' -apply plugin: 'com.jfrog.bintray' - -version '1.0.2' -group 'com.cruxlab' - -publishing { - publications { - Production(MavenPublication) { - artifact("$buildDir/outputs/aar/sectionedrecyclerview-release.aar") - groupId - artifactId 'sectionedrecyclerview' - version this.version - - pom.withXml { - def dependenciesNode = asNode().appendNode('dependencies') - - // Iterate over the implementation dependencies (we don't want the test ones), adding a node for each - configurations.implementation.allDependencies.each { - // Ensure dependencies such as fileTree are not included in the pom. - if (it.name != 'unspecified') { - def dependencyNode = dependenciesNode.appendNode('dependency') - dependencyNode.appendNode('groupId', it.group) - dependencyNode.appendNode('artifactId', it.name) - dependencyNode.appendNode('version', it.version) - } - } - } - } - } -} - -bintray { - Properties properties = new Properties() - properties.load(project.rootProject.file('local.properties').newDataInputStream()) - user = properties.getProperty('bintrayUser') - key = properties.getProperty('bintrayApiKey') - publications = ['Production'] - configurations = ['archives'] - override = true - pkg { - repo = 'SectionedRecyclerView' - name = 'SectionedRecyclerView' - userOrg = 'cruxlab' - description = "A library that allows using sections with pinnable headers in RecyclerView." - publish = true - publicDownloadNumbers = true - licenses = ['MIT'] - vcsUrl = 'https://github.com/crux-lab/sectioned-recycler-view.git' - dryRun = false - version { - name = this.version - desc = "${this.version}" - released = new Date() - vcsTag = this.version - } - } -} - -task sourcesJar(type: Jar) { - from android.sourceSets.main.java.srcDirs - classifier = 'sources' -} - -task javadoc(type: Javadoc) { - classpath += project.files(android.getBootClasspath().join(File.pathSeparator)) - android.libraryVariants.all { variant -> - if (variant.name == 'release') { - owner.classpath += variant.javaCompile.classpath - } - } - source = android.sourceSets.main.java.srcDirs -} - -task javadocJar(type: Jar, dependsOn: javadoc) { - classifier = 'javadoc' - from javadoc.destinationDir -} - -artifacts { - archives javadocJar - archives sourcesJar -} \ No newline at end of file