1
0
Fork 0
mirror of https://github.com/ethauvin/kotlin-pluralizer.git synced 2025-04-25 08:47:12 -07:00

it's now a kotlin library and not an android library

This commit is contained in:
Cesar Ferreira 2016-09-04 23:31:25 +01:00
parent d0f22d0f40
commit 075acc0c94
9 changed files with 92 additions and 98 deletions

View file

@ -1,43 +1,18 @@
buildscript {
repositories {
mavenCentral()
}
dependencies {
classpath 'com.github.dcendents:android-maven-gradle-plugin:1.5'
jcenter()
mavenLocal()
}
}
apply plugin: 'com.android.library'
apply plugin: 'kotlin-android'
android {
compileSdkVersion 24
buildToolsVersion "24.0.2"
defaultConfig {
minSdkVersion 16
targetSdkVersion 24
versionCode 1
versionName "1.0"
}
lintOptions {
abortOnError false
}
buildTypes {
release {
minifyEnabled false
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
}
}
sourceSets {
main.java.srcDirs += 'src/main/kotlin'
}
plugins {
id 'com.jfrog.bintray' version '1.6'
}
apply plugin: 'java'
apply plugin: 'kotlin'
apply plugin: 'maven-publish'
dependencies {
compile "org.jetbrains.kotlin:kotlin-stdlib:$kotlin_version"
}

View file

@ -1,52 +1,59 @@
// build a jar with source files
group "$ext_groupId"
version "$ext_version"
publishing {
publications {
MyPublication(MavenPublication) {
from components.java
artifact sourcesJar
groupId "$ext_groupId"
artifactId "$ext_artifactId"
version "$ext_version"
}
}
}
task sourcesJar(type: Jar) {
from android.sourceSets.main.java.srcDirs
from sourceSets.main.java.srcDirs
classifier = 'sources'
}
task javadoc(type: Javadoc) {
failOnError false
source = android.sourceSets.main.java.sourceFiles
classpath += project.files(android.getBootClasspath().join(File.pathSeparator))
classpath += configurations.compile
}
// build a jar with javadoc
task javadocJar(type: Jar, dependsOn: javadoc) {
classifier = 'javadoc'
from javadoc.destinationDir
}
artifacts {
archives sourcesJar
archives javadocJar
archives sourcesJar
}
//
//bintray {
// user = System.getenv('BINTRAY_USER')
// key = System.getenv('BINTRAY_API_KEY')
//
// dryRun = false
// publish = true
//
// publications = ['MyPublication']
// pkg {
// repo = 'maven'
// name = "$ext_artifactId"
// licenses = ['Apache-2.0']
// labels = ['android', 'gradle-plugin']
//
// publicDownloadNumbers = true
// vcsUrl = "$ext_vcsUrl"
//
// version {
// name = "$ext_version"
// desc = "$ext_description"
// released = new Date()
// gpg {
// sign = true // Determines whether to GPG sign the files.
// }
// }
// }
//}
bintray {
user = System.getenv('BINTRAY_USER')
key = System.getenv('BINTRAY_API_KEY')
dryRun = false
publish = true
publications = ['MyPublication']
pkg {
repo = 'maven'
name = "$ext_artifactId"
licenses = ['Apache-2.0']
labels = ['android', 'gradle-plugin']
publicDownloadNumbers = true
vcsUrl = "$ext_vcsUrl"
version {
name = "$ext_version"
desc = "$ext_description"
released = new Date()
gpg {
sign = true // Determines whether to GPG sign the files.
}
}
}
}