Description: removing useless parts from build.gradle
Author: Pierre Gruet <pgt@debian.org>
Forwarded: not-needed
Last-Update: 2022-03-26

--- a/build.gradle
+++ b/build.gradle
@@ -1,30 +1,12 @@
-// Dependencies for the buildscript
-buildscript {
-    repositories {
-        mavenCentral()
-    }
-}
-
 // PLUGINS
 plugins {
     id 'java-library'
-    id 'maven-publish'
-    id 'signing'
-    id 'com.palantir.git-version' version "0.11.0"
-    id 'jacoco'
 }
 
 group = 'org.broadinstitute'
 
-final isRelease = Boolean.getBoolean("release")
-version = (isRelease ? gitVersion() : gitVersion() + "-SNAPSHOT")
 description = """HTTP/S FileSystem provider for Java NIO.2"""
 
-// library dependencies
-repositories {
-    mavenCentral()
-}
-
 def slf4jVersion = "1.7.25"
 
 dependencies {
@@ -43,45 +25,6 @@
     testImplementation "com.github.samtools:htsjdk:4.1.1"
 }
 
-// for managing the wrapper task
-wrapper {
-    gradleVersion = '8.4'
-}
-
-java {
-    withJavadocJar()
-    withSourcesJar()
-}
-
-tasks.withType(Javadoc) {
-    // the title includes the version of the API
-    title = "http-nio $version API"
-
-    // add Java8 optional tags
-    options.tags = ["apiNote:a:API Note:",
-                    "implSpec:a:Implementation Requirements:",
-                    "implNote:a:Implementation Note:"]
-
-    // capture the output for the javadoc task to check if there are warnings
-    // from https://stackoverflow.com/questions/29519085/how-to-fail-gradle-build-on-javadoc-warnings
-    def capturedOutput = []
-    def listener = { capturedOutput << it } as StandardOutputListener
-    doFirst {
-        logging.addStandardErrorListener(listener)
-        logging.addStandardOutputListener(listener)
-    }
-    doLast {
-        logging.removeStandardOutputListener(listener)
-        logging.removeStandardErrorListener(listener)
-        // if threre is any warning, fail with a gradle exception
-        capturedOutput.each { e ->
-            if(e.toString() =~ " warning: ") {
-                throw new GradleException("There are javadoc warnings: javadoc failed");
-            }
-        }
-    }
-}
-
 // test task
 tasks.withType(Test) {
 
@@ -129,64 +72,3 @@
                    'Implementation-Version': project.version
     }
 }
-
-publishing {
-    publications {
-        library(MavenPublication) {
-            from components.java
-
-            pom {
-                name = 'http-nio'
-                packaging = 'jar'
-                description = project.description
-                url = 'https://github.com/broadinstitute/http-nio'
-
-                developers {
-                    developer {
-                        id = 'MagicDGS'
-                        name = 'Daniel Gómez-Sánchez'
-                        url = 'https://github.com/magicDGS/'
-                    }
-                    developer {
-                        id = "gatkdev"
-                        name = "GATK Development Team"
-                        email = "gatk-dev-public@broadinstitute.org"
-                    }
-                }
-
-                scm {
-                    url = 'git@github.com:broadinstitute/http-nio.git'
-                    connection = 'scm:git:git@github.com:broadinstitute/htt-nio.git'
-                }
-
-                licenses {
-                    license {
-                        name = 'BSD 3-Clause'
-                        url = 'https://github.com/broadinstitute/http-nio/blob/master/LICENSE.txt'
-                        distribution = 'repo'
-                    }
-                }
-            }
-            repositories {
-                maven {
-                    credentials {
-                        username = isRelease ? project.findProperty("sonatypeUsername") : project.findProperty("artifactoryUsername")
-                        password = isRelease ? project.findProperty("sonatypePassword") : project.findProperty("artifactoryPassword")
-                    }
-                    def release = "https://oss.sonatype.org/service/local/staging/deploy/maven2/"
-                    def snapshot = "https://broadinstitute.jfrog.io/broadinstitute/libs-snapshot-local/"
-                    url = isRelease ? release : snapshot
-                }
-            }
-        }
-    }
-}
-//
-//tasks.withType(Sign) {
-//    onlyIf {  isRelease && gradle.taskGraph.hasTask("publishLibraryPublicationToMavenRepository")   }
-//}
-
-signing {
-    sign publishing.publications.library
-}
-
