[
https://issues.apache.org/jira/browse/IVY-324?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12483098
]
Xavier Hanin commented on IVY-324:
----------------------------------
see also IVY-439, which could be a nice syntax for conditional patterns too
(more similar to your suggestion, John).
> Conditional patterns
> --------------------
>
> Key: IVY-324
> URL: https://issues.apache.org/jira/browse/IVY-324
> Project: Ivy
> Issue Type: Improvement
> Affects Versions: 1.4
> Reporter: Xavier Hanin
> Assigned To: Xavier Hanin
>
> For the moment Ivy supports optional parts in patterns, but sometimes pattern
> need to be truly conditional.
> Two solutions can be considered:
> - add a condition attribute on patterns occuring in a list, like for all
> resource based dependency resolvers. For instance:
> <artifact
> pattern="path/to/[organisation]/[module]/[revision]/[artifact].[ext]"
> if="type=jar"/>
> <artifact
> pattern="path/to/[organisation]/[module]/[revision]/[artifact]-src.[ext]"
> if="type=source"/>
> - add a special syntax to allow conditional patterns everywhere. The drawback
> of this solution is that it may be difficult to read. The advantage is that
> it could be used wherever patterns are used (without requiring an additional
> attribute). Example:
> <artifact
> pattern="path/to/[organisation]/[module]/[revision]/[artifact]-src.[ext](if
> type=source)|path/to/[organisation]/[module]/[revision]/[artifact].[ext](if
> type=jar)"/>
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.