<commit_before><project name="grails" default="help">

	<property name="server.port" value="8080"/>

    <property name="servlet.version" value="2.3"/>
	<property name="path" value="" />

    <taskdef name="groovyc" classname="org.codehaus.groovy.ant.Groovyc" />
    <taskdef name="groovy"  classname="org.codehaus.groovy.ant.Groovy" />

    <target name="help">
		<echo>Usage: grails [target]

Targets:
"create-app"          - Create a new grails app
"create-controller"   - Create a new controller
"create-service"      - Create a new service
"create-domain-class" - Create a new domain class
"create-taglib"		  - Create a new tag library class
"create-test-suite"   - Create a new test suite
"create-job"         - Create a quartz scheduled job
"generate-controller" - Generates a controller from a domain class
"generate-views"      - Generates the views from a domain class
"generate-all"        - Generates the all artifacts from a domain class
"install-dojo"        - Installs the Dojo toolkit into the current project
"test-app"            - Run current app's unit tests
"run-app"             - Run the application locally and wait
"create-webtest"      - Create the functional test layout
"run-webtest"         - Run the functional tests for a running app
"war"        		  - Creates a deployable Web Application Archive (WAR)
"shell"               - Opens the Grails interactive command line shell
"console"             - Opens the Grails interactive swing console
        </echo>
	</target>


    <target name="init-props">
        <property environment="env"/>
        <fail unless="env.GRAILS_HOME" message="GRAILS_HOME is not set."/>
        <property name="grails.home" location="${env.GRAILS_HOME}"/>
        <groovy >
            // reusable code blocks, stored as Closure references
            project.addReference('lower'){ it[0].toLowerCase() + it[1..-1] }
            project.addReference('caps') { it[0].toUpperCase() + it[1..-1] }
            project.addReference('normCaps') {x, y ->
                x = x.replaceAll(' ','')
                x = x[0].toUpperCase() + x[1..-1]
                if (x.endsWith(y)) x = x[0..(x.size() - y.size()-1)]
                return x
            }
        </groovy>
    </target>

    <target name="init" depends="init-props" description="Initialise the current app">
        <mkdir dir="${path}src"/>
        <mkdir dir="${path}src/java"/>
        <mkdir dir="${path}src/groovy"/>
        <mkdir dir="${path}grails-app"/>
        <mkdir dir="${path}grails-app/controllers"/>
        <mkdir dir="${path}grails-app/services"/>
        <mkdir dir="${path}grails-app/domain"/>
        <mkdir dir="${path}grails-app/taglib"/>
        <mkdir dir="${path}grails-app/views"/>
        <mkdir dir="${path}grails-app/views/layouts"/>
        <mkdir dir="${path}grails-app/i18n"/>
        <mkdir dir="${path}grails-app/conf"/>
        <mkdir dir="${path}grails-tests"/>
        <mkdir dir="${path}web-app"/>
        <mkdir dir="${path}web-app"/>
        <mkdir dir="${path}web-app"/>
        <mkdir dir="${path}web-app/js"/>
        <mkdir dir="${path}web-app/css"/>
        <mkdir dir="${path}web-app/images"/>
        <mkdir dir="${path}web-app/WEB-INF/classes"/>
        <!--<mkdir dir="${path}<commit_msg>added META-INF to created folders. fixes GRAILS-226<commit_after><project name="grails" default="help">

	<property name="server.port" value="8080"/>

    <property name="servlet.version" value="2.3"/>
	<property name="path" value="" />

    <taskdef name="groovyc" classname="org.codehaus.groovy.ant.Groovyc" />
    <taskdef name="groovy"  classname="org.codehaus.groovy.ant.Groovy" />

    <target name="help">
		<echo>Usage: grails [target]

Targets:
"create-app"          - Create a new grails app
"create-controller"   - Create a new controller
"create-service"      - Create a new service
"create-domain-class" - Create a new domain class
"create-taglib"		  - Create a new tag library class
"create-test-suite"   - Create a new test suite
"create-job"         - Create a quartz scheduled job
"generate-controller" - Generates a controller from a domain class
"generate-views"      - Generates the views from a domain class
"generate-all"        - Generates the all artifacts from a domain class
"install-dojo"        - Installs the Dojo toolkit into the current project
"test-app"            - Run current app's unit tests
"run-app"             - Run the application locally and wait
"create-webtest"      - Create the functional test layout
"run-webtest"         - Run the functional tests for a running app
"war"        		  - Creates a deployable Web Application Archive (WAR)
"shell"               - Opens the Grails interactive command line shell
"console"             - Opens the Grails interactive swing console
        </echo>
	</target>


    <target name="init-props">
        <property environment="env"/>
        <fail unless="env.GRAILS_HOME" message="GRAILS_HOME is not set."/>
        <property name="grails.home" location="${env.GRAILS_HOME}"/>
        <groovy >
            // reusable code blocks, stored as Closure references
            project.addReference('lower'){ it[0].toLowerCase() + it[1..-1] }
            project.addReference('caps') { it[0].toUpperCase() + it[1..-1] }
            project.addReference('normCaps') {x, y ->
                x = x.replaceAll(' ','')
                x = x[0].toUpperCase() + x[1..-1]
                if (x.endsWith(y)) x = x[0..(x.size() - y.size()-1)]
                return x
            }
        </groovy>
    </target>

    <target name="init" depends="init-props" description="Initialise the current app">
        <mkdir dir="${path}src"/>
        <mkdir dir="${path}src/java"/>
        <mkdir dir="${path}src/groovy"/>
        <mkdir dir="${path}grails-app"/>
        <mkdir dir="${path}grails-app/controllers"/>
        <mkdir dir="${path}grails-app/services"/>
        <mkdir dir="${path}grails-app/domain"/>
        <mkdir dir="${path}grails-app/taglib"/>
        <mkdir dir="${path}grails-app/views"/>
        <mkdir dir="${path}grails-app/views/layouts"/>
        <mkdir dir="${path}grails-app/i18n"/>
        <mkdir dir="${path}grails-app/conf"/>
        <mkdir dir="${path}grails-tests"/>
        <mkdir dir="${path}web-app"/>
        <mkdir dir="${path}web-app"/>
        <mkdir dir="${path}web-app"/>
        <mkdir dir="${path}web-app/js"/>
        <mkdir dir="${path}web-app/css"/>
        <mkdir dir="${path}web-app/images"/>
        <mkdir dir="${path}web-app/WEB-INF/classes"/>
        <mkdir dir="${path}web-app/META-INF"/>  
        <!--<mkdir dir="${path}
{'fraction_non_alphanumeric': 0.16255112861687623, 'fraction_numerical': 0.006211180124223602, 'mean_word_length': 2.5042462845010616, 'pattern_counts': {'":': 0, '<': 84, '<?xml version=': 0, '>': 82, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '3058801', 'n_tokens_mistral': 2098, 'n_tokens_neox': 1984, 'n_words': 497}