Skip to content

Commit

Permalink
Readme and deployment
Browse files Browse the repository at this point in the history
- Add bintray deployment options for jcenter
- Include repo location for bintray in readme
  • Loading branch information
bret-fears committed Mar 28, 2017
1 parent a4da1f7 commit 93f6a9a
Show file tree
Hide file tree
Showing 3 changed files with 102 additions and 3 deletions.
8 changes: 7 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
# Spruce Android Animation Library
[![CircleCI Build Status](https://circleci.com/gh/willowtreeapps/spruce-android.svg?style=shield)](https://circleci.com/gh/willowtreeapps/spruce-android)
[![License MIT](https://img.shields.io/badge/License-MIT-blue.svg?style=flat)]()
[![Public Yes](https://img.shields.io/badge/Public-no-red.svg?style=flat)]()
[![Public Yes](https://img.shields.io/badge/Public-yes-green.svg?style=flat)]()

## What is it?
Spruce is a lightweight animation library that helps choreograph the animations on the screen. With so many different animation libraries out there, developers need to make sure that each view is animating at the appropriate time. Spruce can help designers request complex multi-view animations and not have the developers cringe at the prototype.
Expand All @@ -16,6 +16,12 @@ Spruce is a lightweight animation library that helps choreograph the animations
Add the following to your project's build.gradle file

```
repositories {
maven {
url "http://willowtreeapps.bintray.com/maven2"
}
}
dependencies {
compile 'com.willowtreeapps.spruce:spruce-android:1.0.0'
}
Expand Down
2 changes: 2 additions & 0 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,8 @@ buildscript {
}
dependencies {
classpath 'com.android.tools.build:gradle:2.2.3'
classpath 'com.github.dcendents:android-maven-gradle-plugin:1.5'
classpath 'com.jfrog.bintray.gradle:gradle-bintray-plugin:1.7.3'

// NOTE: Do not place your application dependencies here; they belong
// in the individual module build.gradle files
Expand Down
95 changes: 93 additions & 2 deletions lib/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,8 @@
*/

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

android {
compileSdkVersion 25
Expand All @@ -29,8 +31,8 @@ android {
minSdkVersion 16
targetSdkVersion 25
versionCode 1
versionName "1.0"
setProperty("archivesBaseName", "spruce-lib-$versionName")
versionName "1.0.0"
setProperty("archivesBaseName", "spruce-android")
}
buildTypes {
release {
Expand All @@ -42,6 +44,7 @@ android {
testOptions {
unitTests.returnDefaultValues = true
}

}

task javadocs(type: Javadoc) {
Expand All @@ -60,3 +63,91 @@ dependencies {
testCompile 'org.mockito:mockito-core:2.7.17'
testCompile 'org.robolectric:robolectric:3.3.1'
}

def siteUrl = 'https://github.com/willowtreeapps/spruce-android'
def gitUrl = 'https://github.com/willowtreeapps/spruce-android.git'
group = "com.willowtreeapps.spruce"
version = "1.0.0"

install {
repositories.mavenInstaller {
// This generates POM.xml with proper parameters
pom {
project {
packaging 'aar'

name 'spruce-android'
description = 'lightweight animation library'
url siteUrl

licenses {
license {
name 'MIT License'
url 'https://opensource.org/licenses/MIT'
}
}
developers {
developer {
id 'willowtreeapps'
name 'WillowTree Inc'
email 'developer@willowtreeapps.com'
}
}
scm {
connection gitUrl
developerConnection gitUrl
url siteUrl
}
}
}
}
}

task sourcesJar(type: Jar) {
from android.sourceSets.main.java.srcDirs
classifier = 'sources'
}

task javadoc(type: Javadoc) {
source = android.sourceSets.main.java.srcDirs
classpath += project.files(android.getBootClasspath().join(File.pathSeparator))
}

task javadocJar(type: Jar, dependsOn: javadoc) {
classifier = 'javadoc'
from javadoc.destinationDir
}

artifacts {
archives javadocJar
archives sourcesJar
}

Properties properties = new Properties()
properties.load(project.rootProject.file('local.properties').newDataInputStream())


bintray {
user = properties.getProperty("bintray.user")
key = properties.getProperty("bintray.apikey")

configurations = ['archives']
pkg {
repo = "maven2"
name = "com.willowtreeapps.spruce"
websiteUrl = siteUrl
vcsUrl = gitUrl
licenses = ["MIT"]
userOrg = 'willowtreeapps'
vcsUrl = 'https://github.com/willowtreeapps/spruce-android.git'
publish = true
version {
name = '1.0.0'
vcsTag = '1.0.0'
gpg {
sign = true
passphrase = properties.getProperty("bintray.gpg.password")
}
}
}
}

0 comments on commit 93f6a9a

Please sign in to comment.