Migration to build tools 1.3.0. Project shared on jcenter
This commit is contained in:
parent
c1eee56003
commit
a5a000281e
|
@ -5,7 +5,11 @@ buildscript {
|
||||||
jcenter()
|
jcenter()
|
||||||
}
|
}
|
||||||
dependencies {
|
dependencies {
|
||||||
classpath 'com.android.tools.build:gradle:1.2.3'
|
classpath 'com.android.tools.build:gradle:1.3.0'
|
||||||
|
classpath "com.jfrog.bintray.gradle:gradle-bintray-plugin:1.2"
|
||||||
|
// The following dependency has been replaced with newer version according to https://github.com/dcendents/android-maven-plugin
|
||||||
|
// classpath 'com.github.dcendents:android-maven-plugin:1.2'
|
||||||
|
classpath 'com.github.dcendents:android-maven-gradle-plugin:1.3'
|
||||||
|
|
||||||
// NOTE: Do not place your application dependencies here; they belong
|
// NOTE: Do not place your application dependencies here; they belong
|
||||||
// in the individual module build.gradle files
|
// in the individual module build.gradle files
|
||||||
|
|
|
@ -1,10 +1,43 @@
|
||||||
apply plugin: 'com.android.library'
|
apply plugin: 'com.android.library'
|
||||||
|
|
||||||
//ext {
|
/*
|
||||||
// PUBLISH_GROUP_ID = 'no.nordicsemi.android'
|
* I followed this:
|
||||||
// PUBLISH_ARTIFACT_ID = 'dfu-library'
|
* http://inthecheesefactory.com/blog/how-to-upload-library-to-jcenter-maven-central-as-dependency/en
|
||||||
// PUBLISH_VERSION = '0.6.0'
|
* tutorial to publish the library on jcenter and Maven Central repositories.
|
||||||
//}
|
* Some changes needed to be done. See below for details.
|
||||||
|
*
|
||||||
|
* A newer then described version of maven plugin dependency is required (see project's gradle.build).
|
||||||
|
*/
|
||||||
|
|
||||||
|
apply plugin: 'com.github.dcendents.android-maven'
|
||||||
|
apply plugin: 'com.jfrog.bintray'
|
||||||
|
|
||||||
|
ext {
|
||||||
|
PUBLISH_GROUP_ID = 'no.nordicsemi.android'
|
||||||
|
PUBLISH_ARTIFACT_ID = 'dfu'
|
||||||
|
PUBLISH_VERSION = '0.6'
|
||||||
|
|
||||||
|
bintrayRepo = 'android'
|
||||||
|
bintrayName = 'dfu-library'
|
||||||
|
|
||||||
|
publishedGroupId = PUBLISH_GROUP_ID
|
||||||
|
artifact = PUBLISH_ARTIFACT_ID
|
||||||
|
libraryVersion = PUBLISH_VERSION
|
||||||
|
libraryName = 'DFU Library'
|
||||||
|
libraryDescription = 'Device Firmware Update library'
|
||||||
|
|
||||||
|
issuesUrl = 'https://github.com/NordicSemiconductor/Android-DFU-Library/issues'
|
||||||
|
siteUrl = 'https://github.com/NordicSemiconductor/Android-DFU-Library'
|
||||||
|
gitUrl = 'https://github.com/NordicSemiconductor/Android-DFU-Library.git'
|
||||||
|
|
||||||
|
developerId = 'philips77'
|
||||||
|
developerName = 'Aleksander Nowakowski'
|
||||||
|
developerEmail = 'aleksander.nowakowski@nordicsemi.no'
|
||||||
|
|
||||||
|
licenseName = 'The BSD 3-Clause License'
|
||||||
|
licenseUrl = 'http://opensource.org/licenses/BSD-3-Clause'
|
||||||
|
allLicenses = ["BSD 3-Clause"]
|
||||||
|
}
|
||||||
|
|
||||||
android {
|
android {
|
||||||
compileSdkVersion 23
|
compileSdkVersion 23
|
||||||
|
@ -30,5 +63,45 @@ dependencies {
|
||||||
compile 'com.google.code.gson:gson:2.3.1'
|
compile 'com.google.code.gson:gson:2.3.1'
|
||||||
}
|
}
|
||||||
|
|
||||||
// Generate maven package: gradlew clean build generateRelease
|
// The following script creates a POM file required to publish on Maven Central
|
||||||
//apply from: 'https://raw.githubusercontent.com/blundell/release-android-library/master/android-release-aar.gradle'
|
apply from: 'https://raw.githubusercontent.com/nuuneoi/JCenter/master/installv1.gradle'
|
||||||
|
|
||||||
|
// This script creates sources and javadocs. Both are required to publish a library on jcenter and MC.
|
||||||
|
apply from: 'https://raw.githubusercontent.com/ArthurHub/release-android-library/master/android-release-aar.gradle'
|
||||||
|
|
||||||
|
// The following link publishes the library to jcenter. It does not handle the userOrg, so it has been copied and modified below.
|
||||||
|
//apply from: 'https://raw.githubusercontent.com/nuuneoi/JCenter/master/bintrayv1.gradle'
|
||||||
|
|
||||||
|
// Copied from https://raw.githubusercontent.com/nuuneoi/JCenter/master/bintrayv1.gradle
|
||||||
|
version = libraryVersion
|
||||||
|
|
||||||
|
// Bintray
|
||||||
|
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 = bintrayRepo
|
||||||
|
name = bintrayName
|
||||||
|
userOrg = properties.getProperty("bintray.userOrg")
|
||||||
|
desc = libraryDescription
|
||||||
|
websiteUrl = siteUrl
|
||||||
|
issueTrackerUrl = issuesUrl
|
||||||
|
vcsUrl = gitUrl
|
||||||
|
licenses = allLicenses
|
||||||
|
publish = true
|
||||||
|
publicDownloadNumbers = true
|
||||||
|
version {
|
||||||
|
desc = libraryDescription
|
||||||
|
gpg {
|
||||||
|
sign = true //Determines whether to GPG sign the files. The default is false
|
||||||
|
passphrase = properties.getProperty("bintray.gpg.password")
|
||||||
|
//Optional. The passphrase for GPG signing'
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
|
@ -1,5 +1,5 @@
|
||||||
<?xml version="1.0" encoding="UTF-8"?>
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
<module external.linked.project.id=":dfu" external.linked.project.path="$MODULE_DIR$" external.root.project.path="$MODULE_DIR$/.." external.system.id="GRADLE" external.system.module.group="DFULibrary" external.system.module.version="unspecified" type="JAVA_MODULE" version="4">
|
<module external.linked.project.id=":dfu" external.linked.project.path="$MODULE_DIR$" external.root.project.path="$MODULE_DIR$/.." external.system.id="GRADLE" external.system.module.group="no.nordicsemi.android" external.system.module.version="0.6" type="JAVA_MODULE" version="4">
|
||||||
<component name="FacetManager">
|
<component name="FacetManager">
|
||||||
<facet type="android-gradle" name="Android-Gradle">
|
<facet type="android-gradle" name="Android-Gradle">
|
||||||
<configuration>
|
<configuration>
|
||||||
|
@ -37,13 +37,13 @@
|
||||||
<sourceFolder url="file://$MODULE_DIR$/build/generated/source/buildConfig/debug" isTestSource="false" generated="true" />
|
<sourceFolder url="file://$MODULE_DIR$/build/generated/source/buildConfig/debug" isTestSource="false" generated="true" />
|
||||||
<sourceFolder url="file://$MODULE_DIR$/build/generated/source/rs/debug" isTestSource="false" generated="true" />
|
<sourceFolder url="file://$MODULE_DIR$/build/generated/source/rs/debug" isTestSource="false" generated="true" />
|
||||||
<sourceFolder url="file://$MODULE_DIR$/build/generated/res/rs/debug" type="java-resource" />
|
<sourceFolder url="file://$MODULE_DIR$/build/generated/res/rs/debug" type="java-resource" />
|
||||||
<sourceFolder url="file://$MODULE_DIR$/build/generated/res/generated/debug" type="java-resource" />
|
<sourceFolder url="file://$MODULE_DIR$/build/generated/res/resValues/debug" type="java-resource" />
|
||||||
<sourceFolder url="file://$MODULE_DIR$/build/generated/source/r/androidTest/debug" isTestSource="true" generated="true" />
|
<sourceFolder url="file://$MODULE_DIR$/build/generated/source/r/androidTest/debug" isTestSource="true" generated="true" />
|
||||||
<sourceFolder url="file://$MODULE_DIR$/build/generated/source/aidl/androidTest/debug" isTestSource="true" generated="true" />
|
<sourceFolder url="file://$MODULE_DIR$/build/generated/source/aidl/androidTest/debug" isTestSource="true" generated="true" />
|
||||||
<sourceFolder url="file://$MODULE_DIR$/build/generated/source/buildConfig/androidTest/debug" isTestSource="true" generated="true" />
|
<sourceFolder url="file://$MODULE_DIR$/build/generated/source/buildConfig/androidTest/debug" isTestSource="true" generated="true" />
|
||||||
<sourceFolder url="file://$MODULE_DIR$/build/generated/source/rs/androidTest/debug" isTestSource="true" generated="true" />
|
<sourceFolder url="file://$MODULE_DIR$/build/generated/source/rs/androidTest/debug" isTestSource="true" generated="true" />
|
||||||
<sourceFolder url="file://$MODULE_DIR$/build/generated/res/rs/androidTest/debug" type="java-test-resource" />
|
<sourceFolder url="file://$MODULE_DIR$/build/generated/res/rs/androidTest/debug" type="java-test-resource" />
|
||||||
<sourceFolder url="file://$MODULE_DIR$/build/generated/res/generated/androidTest/debug" type="java-test-resource" />
|
<sourceFolder url="file://$MODULE_DIR$/build/generated/res/resValues/androidTest/debug" type="java-test-resource" />
|
||||||
<sourceFolder url="file://$MODULE_DIR$/src/debug/res" type="java-resource" />
|
<sourceFolder url="file://$MODULE_DIR$/src/debug/res" type="java-resource" />
|
||||||
<sourceFolder url="file://$MODULE_DIR$/src/debug/resources" type="java-resource" />
|
<sourceFolder url="file://$MODULE_DIR$/src/debug/resources" type="java-resource" />
|
||||||
<sourceFolder url="file://$MODULE_DIR$/src/debug/assets" type="java-resource" />
|
<sourceFolder url="file://$MODULE_DIR$/src/debug/assets" type="java-resource" />
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
#Wed Apr 10 15:27:10 PDT 2013
|
#Fri Oct 16 09:46:17 CEST 2015
|
||||||
distributionBase=GRADLE_USER_HOME
|
distributionBase=GRADLE_USER_HOME
|
||||||
distributionPath=wrapper/dists
|
distributionPath=wrapper/dists
|
||||||
zipStoreBase=GRADLE_USER_HOME
|
zipStoreBase=GRADLE_USER_HOME
|
||||||
zipStorePath=wrapper/dists
|
zipStorePath=wrapper/dists
|
||||||
distributionUrl=https\://services.gradle.org/distributions/gradle-2.2.1-all.zip
|
distributionUrl=https\://services.gradle.org/distributions/gradle-2.4-all.zip
|
||||||
|
|
Loading…
Reference in New Issue