Search code examples
phpphing

Phing: Cutting out piece of code with Phing


I tried different phing filters regex aso. to cut out different pieces of code out of a build target.

For that i use something like

##CUTSTART
<?php // ...code to cut... ?>
##CUTEND

This won't work because of no multiline support i guess:

             <filterchain>
   <replaceregexp>
  <regexp pattern="##CUTSTART(.*)##CUTEND" replace="## gone" ignoreCase="true" />
   </replaceregexp>
 </filterchain> 

Got an idea?


Solution

  • Look here : http://phing.info/trac/ticket/472 It seems that multiline support has been added (4 weeks ago!)