You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@lucene.apache.org by ma...@apache.org on 2019/06/02 07:43:58 UTC

[lucene-solr] 02/03: SOLR-13452: Get commons-io version in forbiddenApis from versions.props.

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

markrmiller pushed a commit to branch jira/SOLR-13452_gradle_3
in repository https://gitbox.apache.org/repos/asf/lucene-solr.git

commit 91ac7f619942ae77480214c987ca769966c36ddf
Author: markrmiller <ma...@apache.org>
AuthorDate: Sun Jun 2 02:13:53 2019 -0500

    SOLR-13452: Get commons-io version in forbiddenApis from versions.props.
---
 .../org/apache/lucene/gradle/LuceneSolrForbiddenApisPlugin.groovy   | 6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)

diff --git a/buildSrc/src/main/groovy/org/apache/lucene/gradle/LuceneSolrForbiddenApisPlugin.groovy b/buildSrc/src/main/groovy/org/apache/lucene/gradle/LuceneSolrForbiddenApisPlugin.groovy
index 927a8de..80e36f5 100644
--- a/buildSrc/src/main/groovy/org/apache/lucene/gradle/LuceneSolrForbiddenApisPlugin.groovy
+++ b/buildSrc/src/main/groovy/org/apache/lucene/gradle/LuceneSolrForbiddenApisPlugin.groovy
@@ -48,10 +48,12 @@ class LuceneSolrForbiddenApisPlugin implements Plugin<Project> {
         task.signaturesURLs += getClass().getResource('/forbidden/lucene.txt')
       } else if (project.group ==~ /.*?\.solr(?:\.\w+)?/) {
         task.signaturesURLs += getClass().getResource((project.name == 'solrj') ? '/forbidden/solrj.txt' : '/forbidden/solr.txt')
-        task.bundledSignatures += [ 'commons-io-unsafe-' + COMMONS_IO_VERSION ]
         
-        // we delay adding the servlet-api checks until we figured out that we have a servlet-api.jar on forbidden's classpath:
+
         task.doFirst{
+          task.bundledSignatures += [ 'commons-io-unsafe-' + project.getVersion("commons-io:commons-io") ]
+          
+          // we delay adding the servlet-api checks until we figured out that we have a servlet-api.jar on forbidden's classpath:
           if (task.classpath.filter { it.name ==~ /.*?\bservlet-api\b.*?\.jar/ }.empty == false) {
             task.signaturesURLs += getClass().getResource('/forbidden/servlet-api.txt')
           }