gradle/gradle — pull request #119 by barrypitman (2013-01-16 10:12:49+00:00)
Title: Improve robustness of MavenProjectXmlWriter

Using the [bootstrap plugin](http://gradle.org/docs/current/userguide/bootstrap_plugin.html), I kept getting this error:

`[Fatal Error] :346:6: The processing instruction target matching "[xX][mM][lL]" is not allowed.
:maven2Gradle FAILED`

Turns out the reason was that my pom.xml had this at the top:
``

instead of what the plugin was expecting.
``

This changes makes the search and replace more robust using a regex expression to
identify to the XML declaration.