Fix pom file (#517)

pull/519/head
Mattia Iavarone 5 years ago committed by GitHub
parent f2350512f0
commit 535eebc865
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 4
      build.gradle
  2. 72
      cameraview/build.gradle

@ -5,8 +5,8 @@ buildscript {
} }
dependencies { dependencies {
classpath 'com.android.tools.build:gradle:3.4.1' classpath 'com.android.tools.build:gradle:3.4.2'
classpath 'com.github.dcendents:android-maven-gradle-plugin:1.5' classpath 'com.github.dcendents:android-maven-gradle-plugin:2.1'
classpath 'com.jfrog.bintray.gradle:gradle-bintray-plugin:1.8.4' classpath 'com.jfrog.bintray.gradle:gradle-bintray-plugin:1.8.4'
} }
} }

@ -56,35 +56,51 @@ dependencies {
//region bintray //region bintray
// install is a task defined by the Gradle Maven plugin, which is used to
// publish a maven repo to a local repository. (we actually use the android version of the plugin,
// com.github.dcendents.android-maven, to support AARs)
// https://docs.gradle.org/current/userguide/maven_plugin.html#sec:maven_tasks
install { install {
repositories.mavenInstaller { // The repositories property is common to all tasks of type Upload and returns the repositories
pom.project { // into which we will upload data. https://docs.gradle.org/current/dsl/org.gradle.api.tasks.Upload.html#org.gradle.api.tasks.Upload:repositories
name 'CameraView' // It returns a RepositoryHandler: https://docs.gradle.org/current/dsl/org.gradle.api.artifacts.dsl.RepositoryHandler.html
description 'A well documented, high-level Android interface that makes capturing pictures ' + repositories {
'and videos easy, addressing most of the common issues and needs.' // The maven plugin adds a mavenInstaller property to the RepositoryHandler which can be used to
url 'https://github.com/natario1/CameraView' // add and configure a local maven repository cache.
// https://docs.gradle.org/current/dsl/org.gradle.api.artifacts.dsl.RepositoryHandler.html#N11785
packaging 'aar' mavenInstaller {
groupId project.group // The object here extends PomFilterContainer so we can configure the pom file here.
artifactId 'cameraview' // https://docs.gradle.org/current/javadoc/org/gradle/api/artifacts/maven/PomFilterContainer.html#pom-groovy.lang.Closure-
version project.version pom {
// Now we are inside a MavenPom object that can be configured. We get the project and configure.
licenses { // https://docs.gradle.org/current/javadoc/org/gradle/api/artifacts/maven/MavenPom.html
license { project {
name 'The Apache Software License, Version 2.0' name 'CameraView'
url 'http://www.apache.org/licenses/LICENSE-2.0.txt' description 'A well documented, high-level Android interface that makes capturing pictures ' +
} 'and videos easy, addressing most of the common issues and needs.'
} url 'https://github.com/natario1/CameraView'
scm { packaging 'aar'
connection 'https://github.com/natario1/CameraView.git' groupId project.group
developerConnection 'https://github.com/natario1/CameraView.git' artifactId 'cameraview'
url 'https://github.com/natario1/CameraView' version project.version
licenses {
} license {
developers { name 'The Apache Software License, Version 2.0'
developer { url 'http://www.apache.org/licenses/LICENSE-2.0.txt'
id = 'natario' }
name 'Natario' }
scm {
connection 'https://github.com/natario1/CameraView.git'
developerConnection 'https://github.com/natario1/CameraView.git'
url 'https://github.com/natario1/CameraView'
}
developers {
developer {
id = 'natario'
name 'Mattia Iavarone'
}
}
} }
} }
} }

Loading…
Cancel
Save