You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@maven.apache.org by Felipe Leme <ma...@felipeal.net> on 2004/07/20 16:52:55 UTC

Changes on announcement stylesheet content

 > Vincent @ MPANNOUNCEMENT-11
 > Could you show a sample announcement using your own stylesheet. Maybe 
we could integrate those changes in the default one if it's generic 
enough (and
 > useful)?

Right now our only customization (besides the language) is showing the 
SCM tag (and only if the <versions> element is available on project.xml 
- otherwise we assume the project is not under version control). So the 
change on announcement.jcl would be:

From:

Have fun!

To:

<j:if test="${size(pom.versions)!=0}">
Or you can download the source code using the following SCM tag:
      <j:forEach var="version" items="${pom.versions}">
        <j:if test="${version.id==versionVariable}">
      <j:whitespace trim="false">${version.tag}</j:whitespace> 
    </j:if> 
      </j:forEach>
</j:if>
Have fun!

Similarly, we changed announcement:check-version to fail if the tag is 
not there:

<!-- if project is under version control, check if the current release
     has a tag -->
    <j:if test="${size(pom.versions)!=0}">
      <j:set var="foundTag" value="false"/>
      <j:forEach var="version" items="${pom.versions}">
        <j:if test="${version.id==versionVariable}">
      <j:set var="found" value="true"/>
    </j:if> 
      </j:forEach>
      <j:if test="${!found}">
        <ant:fail>The release '${versionVariable}' does not have a SCM 
tag set at the POM.</ant:fail> 
      </j:if>
    </j:if>

I'm positng this on the list instead of Jira because it is a different 
issue than the original request. But if you liked it, I could create a 
new Jira entry and patch.

Regards,

Felipe



---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
For additional commands, e-mail: dev-help@maven.apache.org


RE: Changes on announcement stylesheet content

Posted by Vincent Massol <vm...@pivolis.com>.
Hi Felipe,

It sounds a little bit at the edge. But why not. I don't know. I guess we
would need to know what others think. If it's found useful then sure we can
commit it.

Thanks! Please continue exploring how to make the announcement plugin ever
better :-)
-Vincent

> -----Original Message-----
> From: Felipe Leme [mailto:maven@felipeal.net]
> Sent: mardi 20 juillet 2004 16:53
> To: dev@maven.apache.org
> Subject: Changes on announcement stylesheet content
> 
>  > Vincent @ MPANNOUNCEMENT-11
>  > Could you show a sample announcement using your own stylesheet. Maybe
> we could integrate those changes in the default one if it's generic
> enough (and
>  > useful)?
> 
> Right now our only customization (besides the language) is showing the
> SCM tag (and only if the <versions> element is available on project.xml
> - otherwise we assume the project is not under version control). So the
> change on announcement.jcl would be:
> 
> From:
> 
> Have fun!
> 
> To:
> 
> <j:if test="${size(pom.versions)!=0}">
> Or you can download the source code using the following SCM tag:
>       <j:forEach var="version" items="${pom.versions}">
>         <j:if test="${version.id==versionVariable}">
>       <j:whitespace trim="false">${version.tag}</j:whitespace>
>     </j:if>
>       </j:forEach>
> </j:if>
> Have fun!
> 
> Similarly, we changed announcement:check-version to fail if the tag is
> not there:
> 
> <!-- if project is under version control, check if the current release
>      has a tag -->
>     <j:if test="${size(pom.versions)!=0}">
>       <j:set var="foundTag" value="false"/>
>       <j:forEach var="version" items="${pom.versions}">
>         <j:if test="${version.id==versionVariable}">
>       <j:set var="found" value="true"/>
>     </j:if>
>       </j:forEach>
>       <j:if test="${!found}">
>         <ant:fail>The release '${versionVariable}' does not have a SCM
> tag set at the POM.</ant:fail>
>       </j:if>
>     </j:if>
> 
> I'm positng this on the list instead of Jira because it is a different
> issue than the original request. But if you liked it, I could create a
> new Jira entry and patch.
> 
> Regards,
> 
> Felipe
> 
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
> For additional commands, e-mail: dev-help@maven.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
For additional commands, e-mail: dev-help@maven.apache.org