Skip to content

Commit

Permalink
Added bintray dependencies to gradle
Browse files Browse the repository at this point in the history
  • Loading branch information
cortinico committed Jun 5, 2017
1 parent d312b53 commit 605a8ec
Show file tree
Hide file tree
Showing 2 changed files with 79 additions and 0 deletions.
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.3.2'
classpath 'com.github.dcendents:android-maven-gradle-plugin:1.4.1'
classpath 'com.jfrog.bintray.gradle:gradle-bintray-plugin:1.1'
}
}

Expand Down
77 changes: 77 additions & 0 deletions slidetoact/build.gradle
Original file line number Diff line number Diff line change
@@ -1,5 +1,9 @@
apply plugin: 'com.android.library'
apply plugin: 'kotlin-android'
apply plugin: 'com.github.dcendents.android-maven'
apply plugin: 'com.jfrog.bintray'

version = "0.1.0"

android {
compileSdkVersion 25
Expand Down Expand Up @@ -38,3 +42,76 @@ buildscript {
classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version"
}
}


def siteUrl = 'https://github.com/cortinico/slidetoact'
def gitUrl = 'https://github.com/cortinico/slidetoact.git'
group = "com.ncorti"

install {
repositories.mavenInstaller {
pom {
project {
packaging 'aar'
name 'com.ncorti:slidetoact'
description = 'A simple \'Slide to Unlock\' Material widget for Android, written in Kotlin'
url siteUrl
licenses {
license {
name 'MIT License'
url 'https://opensource.org/licenses/MIT'
}
}
developers {
developer {
id 'cortinico'
name 'Nicola Corti'
email 'corti.nico@gmail.com'
}
}
scm {
connection gitUrl
developerConnection gitUrl
url siteUrl
}
}
}
}
}

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

Properties properties = new Properties()
try {
properties.load(project.rootProject.file('local.properties').newDataInputStream())
} catch (ignored) {
logger.warn('File `local.properties`, not found!. If you\'re running on a CI you can ignore this warning.')
}

// https://github.com/bintray/gradle-bintray-plugin
bintray {
user = properties.getProperty("bintray.user")
key = properties.getProperty("bintray.apikey")

configurations = ['archives']
pkg {
repo = "maven"
name = "com.ncorti:slidetoact"
websiteUrl = siteUrl
vcsUrl = gitUrl
licenses = ["MIT"]
publish = true
version {
gpg {
sign = true
passphrase = properties.getProperty("bintray.gpg.password")
}
}
}
}

0 comments on commit 605a8ec

Please sign in to comment.