diff --git a/android/build.gradle b/android/build.gradle index 76a290f..1a04977 100644 --- a/android/build.gradle +++ b/android/build.gradle @@ -20,7 +20,7 @@ def safeExtGet(prop, fallback) { } apply plugin: 'com.android.library' -apply plugin: 'maven' +apply plugin: 'maven-publish' buildscript { // The Android Gradle plugin is only required when opening the android folder stand-alone. @@ -39,7 +39,7 @@ buildscript { } apply plugin: 'com.android.library' -apply plugin: 'maven' +apply plugin: 'maven-publish' android { compileSdkVersion safeExtGet('compileSdkVersion', DEFAULT_COMPILE_SDK_VERSION) @@ -106,19 +106,18 @@ def configureReactNativePom(def pom) { } afterEvaluate { project -> - // some Gradle build hooks ref: - // https://www.oreilly.com/library/view/gradle-beyond-the/9781449373801/ch03.html - task androidJavadoc(type: Javadoc) { - source = android.sourceSets.main.java.srcDirs - classpath += files(android.bootClasspath) - classpath += files(project.getConfigurations().getByName('compile').asList()) - include '**/*.java' - } - - task androidJavadocJar(type: Jar, dependsOn: androidJavadoc) { - classifier = 'javadoc' - from androidJavadoc.destinationDir - } + // https://github.com/iamolegga/react-native-launch-arguments/issues/38#issuecomment-1186194177 + // task androidJavadoc(type: Javadoc) { + // project.configurations.getByName("implementation").setCanBeResolved(true) + // source = android.sourceSets.main.java.srcDirs + // classpath += files(android.bootClasspath) + // classpath += files(project.getConfigurations().getByName('implementation').asList()) + // include '**/*.java' + // } + // task androidJavadocJar(type: Jar, dependsOn: androidJavadoc) { + // classifier = 'javadoc' + // from androidJavadoc.destinationDir + // } task androidSourcesJar(type: Jar) { classifier = 'sources' @@ -137,15 +136,15 @@ afterEvaluate { project -> artifacts { archives androidSourcesJar - archives androidJavadocJar + // archives androidJavadocJar } - task installArchives(type: Upload) { - configuration = configurations.archives - repositories.mavenDeployer { - // Deploy to react-native-event-bridge/maven, ready to publish to npm - repository url: "file://${projectDir}/../android/maven" - configureReactNativePom pom - } - } + // task installArchives(type: Upload) { + // configuration = configurations.archives + // repositories.mavenDeployer { + // // Deploy to react-native-event-bridge/maven, ready to publish to npm + // repository url: "file://${projectDir}/../android/maven" + // configureReactNativePom pom + // } + // } }