I should also mention that variables #set in the velocity template are
then visible in the JellyContext thereafter ...

On Mon, Dec 16, 2002 at 01:01:00AM -0000, [EMAIL PROTECTED] wrote:
> kaz         2002/12/15 17:01:00
> 
>   Modified:    .        project.xml
>   Added:       src/java/org/apache/maven/jelly/tags/velocity
>                         JellyContextAdapter.java MergeTag.java
>                         VelocityTagLibrary.java VelocityTagSupport.java
>   Log:
>   Adding a Velocity taglib for use in our Jelly scripts.  The taglib is
>   very basic.   It contains only one tag at the moment with only a few
>   options.  This was just a first pass at getting something working.
>   Basically, the tag takes a Velocity template, merges it with the current
>   JellyContext, and dumps the output to a file or stuffs it into a
>   variable in the JellyContext (similar to the <j:file> tag).
>   
>   For example (taken from uberjar plugin):
>   
>       <velocity:merge
>         name="${dest}/classworlds.conf"
>         template="${plugin.dir}/src/conf/classworlds.conf"/>
>   
>   This uses the template specified by the 'template' attribute, and merges
>   it with the current JellyContext (containing all of the maven goodies),
>   and dumps the output to classworlds.conf.  Alternatively, the output
>   could have been dumped to a variable.  In addition, 'inputEncoding' and
>   'outputEncoding' attributes can be specified to set the encoding for the
>   template and output file respectively.
>   
>   Thanks to James for the idea and slacking off on his day off so I could
>   write it before he got to it :-)

--
To unsubscribe, e-mail:   <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>

Reply via email to