开发者

Using multiple ivy:retrieve patterns in my build.xml to associate with multiple artifact patterns

开发者 https://www.devze.com 2023-01-31 03:11 出处:网络
I have files in two different directories that I would like to publish.One set of files has a .jar extension the other set doesn\'t have any extension at all.

I have files in two different directories that I would like to publish. One set of files has a .jar extension the other set doesn't have any extension at all.

In my build.xml file under publish I have the following code:

<ivy:publish resolver="public-publis开发者_运维知识库her" conf="default"
   deliverivypattern="${build}/${delivery.pattern}">
  <artifacts pattern="${build}/[artifact].[ext]"/>
  <artifacts pattern="${misc}/bin/[artifact]"/>
</ivy:publish>

then when I do my retrieve I tried to do something like:

<ivy:retrieve pattern="ivyLib/[artifact].[ext]" conf="default" />
<ivy:retrieve pattern="ivyLib/[artifact]" conf="default"/>

but that didn't work. It puts a . after my files that don't have any extensions on them. Now I'm all out of ideas and any help would be greatly appreciated.

Thanks in advance,

Josh


try this instead

<ivy:retrieve pattern="ivyLib/[artifact](.[ext])" conf="default" />

the () makes the contents of the () optional so it should match ivyLib/Foo and ivyLib/Foo.jar

0

精彩评论

暂无评论...
验证码 换一张
取 消