Created
January 24, 2013 04:02
-
-
Save jurberg/4617534 to your computer and use it in GitHub Desktop.
Adding a context-param to the beginning a Grails app web.xml
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
eventWebXmlEnd = { String tmpfile -> | |
def contextParam = '''<context-param> | |
<description>Spring Expression Language Support</description> | |
<param-name>springJspExpressionSupport</param-name> | |
<param-value>false</param-value> | |
</context-param>''' | |
def root = new XmlParser().parse(webXmlFile) | |
root.children().add(0, new XmlParser().parseText(contextParam)) | |
new XmlNodePrinter(new PrintWriter(new FileWriter(webXmlFile))).print(root) | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment