dweiss commented on code in PR #14764:
URL: https://github.com/apache/lucene/pull/14764#discussion_r2142130077


##########
build-tools/build-infra/src/main/groovy/lucene.datasets.external-datasets.gradle:
##########
@@ -162,29 +167,31 @@ configure(project(":lucene:benchmark")) {
 
       logger.lifecycle("Extracting ${ext.name} into ${ext.dst}...")
       ext.dst.deleteDir()
-      buildinfra.extractReuters(untarPath.toString(), ext.dst.toString())
+      ExtractReuters.main(untarPath.toString(), ext.dst.toString())
     }
-  }
-
-  task downloadDatasets() {
-    group "Data set download"
-    description "Download all data sets."
-  }
-
-  [
-      getEnWiki,
-      getGeoNames,
-      getTop100kWikiWordFiles,
-      getReuters,
-      getEnWikiRandomLines
-  ].each { task ->
-    task.group "Data set download"
-    task.description "Download the ${task.ext.name} data set."
-
-    downloadDatasets.dependsOn(task)
-
-    task.doFirst {
-      logger.lifecycle("Downloading data set ${task.ext.name} from 
${task.ext.src} to ${task.ext.dst}...")
+  })
+
+  def downloadTasks = [
+    getEnWikiTask,
+    getGeoNamesTask,
+    getTop100kWikiWordFilesTask,
+    getReutersTask,
+    getEnWikiRandomLinesTask
+  ]
+
+  tasks.register("downloadDatasets", {
+    group = "Data set download"
+    description = "Download all data sets."
+
+    dependsOn downloadTasks
+  })
+
+  downloadTasks.each {
+    it.configure {
+      group = "Data set download"
+      doFirst {

Review Comment:
   I agree with you but again - leaving for smaller improvements later. I also 
find the new gradle conventions extremely counterintuitive. To me, the groovy 
code reads. Once you get into properties, providers and lazy evaluation, things 
become so much more complicated, at least to me. 



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscr...@lucene.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscr...@lucene.apache.org
For additional commands, e-mail: issues-h...@lucene.apache.org

Reply via email to