This is an automated email from the ASF dual-hosted git repository.

paulk pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/groovy.git


The following commit(s) were added to refs/heads/master by this push:
     new efaa3bf  minor refactoring
efaa3bf is described below

commit efaa3bf52c078c520f2047a5edc548dfe551961c
Author: Paul King <[email protected]>
AuthorDate: Tue Feb 4 11:55:31 2020 +1000

    minor refactoring
---
 gradle/assemble.gradle | 53 +++++++++++++++++++++++++-------------------------
 1 file changed, 27 insertions(+), 26 deletions(-)

diff --git a/gradle/assemble.gradle b/gradle/assemble.gradle
index 92f1d23..b028fb5 100644
--- a/gradle/assemble.gradle
+++ b/gradle/assemble.gradle
@@ -20,7 +20,7 @@
 import org.apache.tools.ant.filters.ReplaceTokens
 import org.codehaus.groovy.gradle.JarJarTask
 
-group = 'org.codehaus.groovy'
+group = 'org.apache.groovy'
 archivesBaseName = 'groovy'
 
 ext.srcSpec = copySpec {
@@ -97,10 +97,10 @@ def excludedFromManifest = [
 ext.allManifest = manifest {
     attributes(
             'Extension-Name': 'groovy',
-            'Specification-Title': 'Groovy: a powerful, dynamic language for 
the JVM',
+            'Specification-Title': 'Groovy: a powerful, multi-faceted language 
for the JVM',
             'Specification-Version': groovyBundleVersion,
             'Specification-Vendor': 'The Apache Software Foundation',
-            'Implementation-Title': 'Groovy: a powerful, dynamic language for 
the JVM',
+            'Implementation-Title': 'Groovy: a powerful, multi-faceted 
language for the JVM',
             'Implementation-Version': groovyBundleVersion,
             'Implementation-Vendor': 'The Apache Software Foundation',
             'Bundle-ManifestVersion': '2',
@@ -161,7 +161,7 @@ allprojects {
 
     def producedJars = [jar]
     jar {
-        appendix = 'raw'
+        archiveAppendix = 'raw'
         manifest {
             from(allManifest) {
                 eachEntry { details ->
@@ -175,8 +175,8 @@ allprojects {
     if (rootProject.indyCapable()) {
         task jarWithIndy(type: Jar) {
             dependsOn compileGroovyWithIndy
-            classifier = 'indy'
-            appendix = 'raw'
+            archiveClassifier = 'indy'
+            archiveAppendix = 'raw'
             from sourceSets.main.java.outputDir
             from sourceSets.main.groovy.outputDir
             from compileGroovyWithIndy.destinationDir
@@ -201,7 +201,7 @@ allprojects {
 
         task "jar${arch.name}"(type: JarJarTask) {
             dependsOn arch
-            from = file(arch.archivePath)
+            from = file(arch.archiveFile)
             if (project == rootProject) {
                 repackagedLibraries = 
files(configurations.runtime.incoming.artifactView {
                     componentFilter { component ->
@@ -239,7 +239,7 @@ allprojects {
             outputFile = 
file("$buildDir/libs/${arch.baseName}-${arch.version}${arch.classifier ? '-' + 
arch.classifier : ''}.jar")
 
             withManifest {
-                def moduleName = "org.codehaus.${project.name.replace('-', 
'.')}"
+                def moduleName = "org.apache.${project.name.replace('-', '.')}"
                 attributes('Automatic-Module-Name': moduleName)
                 from(allManifest) {
                     eachEntry { details ->
@@ -323,31 +323,31 @@ task sourceAllJar(type: Jar, dependsOn: { 
modules()*.sourceJar + rootProject.sou
     modules()*.sourceJar.each {
         with it.rootSpec
     }
-    baseName = 'groovy-all'
-    classifier = 'sources'
+    archiveBaseName = 'groovy-all'
+    archiveClassifier = 'sources'
 }
 
 allprojects {
     task javadocJar(type: Jar, dependsOn: javadoc) {
         from javadoc.destinationDir
-        classifier = 'javadoc'
+        archiveClassifier = 'javadoc'
     }
     task groovydocJar(type: Jar, dependsOn: groovydoc) {
         from groovydoc.destinationDir
-        classifier = 'groovydoc'
+        archiveClassifier = 'groovydoc'
     }
 }
 
 task javadocAllJar(type: Jar, dependsOn: javadocAll) {
-    baseName = 'groovy-all'
+    archiveBaseName = 'groovy-all'
     from javadocAll.destinationDir
-    classifier = 'javadoc'
+    archiveClassifier = 'javadoc'
 }
 
 task groovydocAllJar(type: Jar, dependsOn: groovydocAll) {
-    baseName = 'groovy-all'
+    archiveBaseName = 'groovy-all'
     from groovydocAll.destinationDir
-    classifier = 'groovydoc'
+    archiveClassifier = 'groovydoc'
 }
 
 evaluationDependsOn('groovy-jaxb')
@@ -434,8 +434,8 @@ ext.distSpec = copySpec {
 }
 
 task distBin(type: Zip) {
-    baseName = 'apache-groovy'
-    appendix = 'binary'
+    archiveBaseName = 'apache-groovy'
+    archiveAppendix = 'binary'
     into("groovy-$version") {
         with distSpec
     }
@@ -447,8 +447,8 @@ task distBin(type: Zip) {
 }
 
 task distDoc(type: Zip, dependsOn: doc) {
-    baseName = 'apache-groovy'
-    appendix = 'docs'
+    archiveBaseName = 'apache-groovy'
+    archiveAppendix = 'docs'
     into("groovy-$version") {
         with docSpec
     }
@@ -469,8 +469,8 @@ task syncDoc(type: Copy, dependsOn: doc) {
 }
 
 task distSrc(type: Zip) {
-    baseName = 'apache-groovy'
-    appendix = 'src'
+    archiveBaseName = 'apache-groovy'
+    archiveAppendix = 'src'
     into("groovy-$version")
     with srcSpec
 }
@@ -507,7 +507,7 @@ distBin.dependsOn checkNoSnapshotVersions
 
 task dist(type: Zip, dependsOn: [checkCompatibility, distBin, distSrc, 
distDoc, syncDoc]) {
     description = 'Generates the binary, sources, documentation and full 
distributions'
-    baseName = 'apache-groovy'
+    archiveBaseName = 'apache-groovy'
     duplicatesStrategy = DuplicatesStrategy.EXCLUDE
     appendix 'sdk'
     into "groovy-$version"
@@ -522,9 +522,10 @@ task dist(type: Zip, dependsOn: [checkCompatibility, 
distBin, distSrc, distDoc,
         with srcSpec
     }
 
-    if ((version.endsWith('SNAPSHOT') && 
!groovyBundleVersion.endsWith('SNAPSHOT'))
-            || (!version.endsWith('SNAPSHOT') && 
groovyBundleVersion.endsWith('SNAPSHOT'))) {
-        throw new GradleException("Incoherent versions. Found 
groovyVersion=$version and groovyBundleVersion=$groovyBundleVersion")
+    def av = version
+    if ((av.endsWith('SNAPSHOT') && !groovyBundleVersion.endsWith('SNAPSHOT'))
+            || (!av.endsWith('SNAPSHOT') && 
groovyBundleVersion.endsWith('SNAPSHOT'))) {
+        throw new GradleException("Incoherent versions. Found 
groovyVersion=$av and groovyBundleVersion=$groovyBundleVersion")
     }
 }
 

Reply via email to