ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Jeff Turner <j...@socialchange.net.au>
Subject Re: Nested patternsets
Date Mon, 23 Apr 2001 07:53:42 GMT
A more general way of asking this is "if patternsets are indeed sets, can one
create unions and differences of patternsets?".

Here's some examples/use cases:

Union (construct a patternset of binary files):

<patternset id="image.files">
  <include name="**/*.gif">
  <include name="**/*.png">
  <include name="**/*.jpg">
<patternset>

<patternset id="binary.files">
  <include name="**/*.class"/>
  <include idref="image.files"/>
</patternset>


Difference (get non-binary files):

<patternset id="binary.files">
  <include name="**/*.class"/>
</patternset>

<patternset id="non.binary.files">
  <include name="**/*"/>
  <exclude idref="binary.files"/>
</patternset>


One could then say:

<copy filtering="on">
  <patternset idref="non.binary.files"/>
</copy>

<copy filtering="off">
  <patternset idref="binary.files"/>
</copy>


thanks,

--Jeff

On Mon, Apr 23, 2001 at 05:26:28PM +1000, Jeff Turner wrote:
> Hello again,
> 
> I'm pretty sure this isn't currently possible, so I'd like to flag it as
> "feature request".
> 
> I'd like patternsets to be nestable, eg:
> 
> <patternset id="image.files">
>   <include name="**/*.gif"/>
>   <include name="**/*.png"/>
>   <include name="**/*.jpg"/>
> </patternset>
> 
> <patternset id="binary.files" >
>   <include name="**/*.class"/>
>   <include name="**/*.jar"/>
>   <patternset idref="image.files"/>
> </patternset>
> 
> 
> Is that achievable currently?
> 
> thanks,
> 
> --Jeff

Mime
View raw message