Hi,

 

I am using velocity to output a groovy script.

 

My velocity template is something like this.

 

 

#foreach $c in $a

 

def ${c}function()

{

 ....

}

 

#end

 

 

The output that gets generated puts everything into one line and groovy
fails to evaluate it since it expects each function definition to start
with a new line.

 

Essentially this is how the output gets generated at present.

 

def afunction() { ... }  def bfunction {...}

 

 

Is there any way I can have velocity preserve my formatting when the
output is generated ?

 

 

Thanks,

 

 

 

Roshan

Reply via email to