[ 
https://issues.apache.org/jira/browse/MANTTASKS-141?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Herve Boutemy updated MANTTASKS-141:
------------------------------------
    Description: 
Since 2.0.9 Maven supports the usage of expressions in the 'mirrorOf' element
(See http://maven.apache.org/guides/mini/guide-mirror-settings.html)

These expression are not wel interpreted by the dependencies task.

The snippet
{code:xml}
    <dependencies pathId="xy1.path" settingsFile="${basedir}/settings.xml">
      <dependency groupId="x" artifactId="y" version="1" type="pom"/>
    </dependencies>
works when settings.xml is:
<settings>
  ...
  <mirrors>
    <mirror>
      <mirrorOf>project-releases-repository</mirrorOf>
      <url>http://the.maven.proxy/project...</url>
    </mirror>
    <mirror>
      <mirrorOf>*</mirrorOf>
      <url>http://the.maven.proxy/public...</url>
    </mirror>
  </mirrors>
 ...
</settings>
{code}

It stops working (= not able to download dependency) when settings.xml is:
{code:xml}
<settings>
  ...
  <mirrors>
    <mirror>
      <mirrorOf>*,!project-releases-repository</mirrorOf>
      <url>http://the.maven.proxy/public...</url>
    </mirror>
  </mirrors>
 ...
</settings>
{code}


  was:
Since 2.0.9 Maven supports the usage of expressions in the 'mirrorOf' element
(See http://maven.apache.org/guides/mini/guide-mirror-settings.html)

These expression are not wel interpreted by the dependencies task.

The snippet
    <dependencies pathId="xy1.path" settingsFile="${basedir}/settings.xml">
      <dependency groupId="x" artifactId="y" version="1" type="pom"/>
    </dependencies>
works when settings.xml is:
<settings>
  ...
  <mirrors>
    <mirror>
      <mirrorOf>project-releases-repository</mirrorOf>
      <url>http://the.maven.proxy/project...</url>
    </mirror>
    <mirror>
      <mirrorOf>*</mirrorOf>
      <url>http://the.maven.proxy/public...</url>
    </mirror>
  </mirrors>
 ...
</settings>

It stops working (= not able to download dependency) when settings.xml is:
<settings>
  ...
  <mirrors>
    <mirror>
      <mirrorOf>*,!project-releases-repository</mirrorOf>
      <url>http://the.maven.proxy/public...</url>
    </mirror>
  </mirrors>
 ...
</settings>



> Using expressions in a mirrorOf element breaks the downloading of dependencies
> ------------------------------------------------------------------------------
>
>                 Key: MANTTASKS-141
>                 URL: https://issues.apache.org/jira/browse/MANTTASKS-141
>             Project: Maven Ant Tasks (RETIRED)
>          Issue Type: Bug
>          Components: dependencies task
>    Affects Versions: 2.0.9
>            Reporter: Koen Roevens
>            Assignee: Jason van Zyl
>            Priority: Major
>
> Since 2.0.9 Maven supports the usage of expressions in the 'mirrorOf' element
> (See http://maven.apache.org/guides/mini/guide-mirror-settings.html)
> These expression are not wel interpreted by the dependencies task.
> The snippet
> {code:xml}
>     <dependencies pathId="xy1.path" settingsFile="${basedir}/settings.xml">
>       <dependency groupId="x" artifactId="y" version="1" type="pom"/>
>     </dependencies>
> works when settings.xml is:
> <settings>
>   ...
>   <mirrors>
>     <mirror>
>       <mirrorOf>project-releases-repository</mirrorOf>
>       <url>http://the.maven.proxy/project...</url>
>     </mirror>
>     <mirror>
>       <mirrorOf>*</mirrorOf>
>       <url>http://the.maven.proxy/public...</url>
>     </mirror>
>   </mirrors>
>  ...
> </settings>
> {code}
> It stops working (= not able to download dependency) when settings.xml is:
> {code:xml}
> <settings>
>   ...
>   <mirrors>
>     <mirror>
>       <mirrorOf>*,!project-releases-repository</mirrorOf>
>       <url>http://the.maven.proxy/public...</url>
>     </mirror>
>   </mirrors>
>  ...
> </settings>
> {code}



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

Reply via email to