diff --git a/README.md b/README.md index c8e782b..fda1c97 100644 --- a/README.md +++ b/README.md @@ -1,4 +1,5 @@ # IconButton for Android +[ ![Download](https://api.bintray.com/packages/pnc/maven/iconbutton/images/download.svg) ](https://bintray.com/pnc/maven/iconbutton/_latestVersion) IconButton is an Android button widget that allows you to center both the button's text and an icon. @@ -19,7 +20,7 @@ Make sure you declare the JCenter repository in your project's `build.gradle`: Then add a compile-time dependency on this library, adding the `dependencies` section to `build.gradle` if it doesn't already exist: dependencies { - compile 'com.githang:com-phillipcalvin-iconbutton:1.0.1@aar' + compile 'com.githang:com-phillipcalvin-iconbutton:1.1.0@aar' } ### For Old Version diff --git a/library/bintray.gradle b/library/bintray.gradle index 08b6347..42b2ed3 100644 --- a/library/bintray.gradle +++ b/library/bintray.gradle @@ -1,31 +1,35 @@ group = PROJ_GROUP version = PROJ_VERSION - +project.archivesBaseName = PROJ_ARTIFACTID apply plugin: 'com.jfrog.bintray' apply plugin: 'maven-publish' - -task androidJavadocs(type: Javadoc) { - source = android.sourceSets.main.java +task sourcesJar(type: Jar) { + from android.sourceSets.main.java.srcDirs + classifier = 'sources' } - -task androidJavadocsJar(type: Jar) { - classifier = 'javadoc' - from androidJavadocs.destinationDir +task javadoc(type: Javadoc) { + source = android.sourceSets.main.java.srcDirs + classpath += configurations.compile + classpath += project.files(android.getBootClasspath().join(File.pathSeparator)) } - -task androidLibJar(type: Jar) { - from fileTree(dir: './build/intermediates/classes/release') +task javadocJar(type: Jar, dependsOn: javadoc) { + classifier = 'javadoc' + from javadoc.destinationDir } - -task androidSourcesJar(type: Jar) { - classifier = 'sources' - from android.sourceSets.main.java.srcDirs +javadoc { + options{ + encoding "UTF-8" + charSet 'UTF-8' + author true + version true + links "http://docs.oracle.com/javase/7/docs/api" + title PROJ_ARTIFACTID + } } - artifacts { - archives androidSourcesJar + archives javadocJar + archives sourcesJar } - def pomConfig = { licenses { license { @@ -35,10 +39,6 @@ def pomConfig = { } } developers { - developer { - id 'pnc' - name 'Phillip Calvin' - } developer { id DEVELOPER_ID name DEVELOPER_NAME @@ -46,16 +46,13 @@ def pomConfig = { } } } - publishing { publications { mavenJava(MavenPublication) { artifactId PROJ_ARTIFACTID - - artifact androidSourcesJar - artifact androidJavadocsJar - artifact bundleRelease - + pom{ + packaging 'aar' + } pom.withXml { def root = asNode() root.appendNode('description', PROJ_DESCRIPTION) @@ -64,38 +61,21 @@ publishing { } } } - bintray { - //Do not share your username and key. - // Config it in ~/.gradle/gradle.properties or local.properties - user = bintrayUser - key = bintrayKey - - publications = ['mavenJava'] //When uploading Maven-based publication files - // - AND/OR - - filesSpec { //When uploading any arbitrary files ('filesSpec' is a standard Gradle CopySpec) - from 'arbitrary-files' - into 'standalone_files/level1' - rename '(.+)\\.(.+)', '$1-suffix.$2' - } + user = hasProperty("bintrayUser")?getProperty("bintrayUser"):getProperty("BINTRAY_USER") + key = hasProperty("bintrayKey")?getProperty("bintrayKey"):getProperty("BINTRAY_KEY") + configurations = ['archives'] + publications = ['mavenJava'] dryRun = false //Whether to run this as dry-run, without deploying - publish = true //If version should be auto published after an upload + publish = true pkg { repo = 'maven' - // userOrg = 'myorg' //An optional organization name when the repo belongs to one of the user's orgs name = PROJ_NAME desc = PROJ_DESCRIPTION websiteUrl = PROJ_WEBSITEURL issueTrackerUrl = PROJ_ISSUETRACKERURL vcsUrl = PROJ_VCSURL licenses = ['Apache-2.0'] - // labels = ['gear', 'gore', 'gorilla'] publicDownloadNumbers = true - //attributes= ['a': ['ay1', 'ay2'], 'b': ['bee'], c: 'cee'] //Optional package-level attributes - //Optional version descriptor - version { - name = PROJ_VERSION //Bintray logical version name - vcsTag = PROJ_VERSION - } } -} +} \ No newline at end of file