diff options
author | Artur Signell <artur@vaadin.com> | 2013-05-30 17:06:30 +0300 |
---|---|---|
committer | Vaadin Code Review <review@vaadin.com> | 2013-05-30 15:08:00 +0000 |
commit | 9a3dc4e99c7a417778342db83cd6e7c05558e5fb (patch) | |
tree | 4a77e0b93e48c9f2fec4839ffae76c3334ec337b /build | |
parent | d850db60f9f7e144307bcf525d96665d1be64fc8 (diff) | |
download | vaadin-framework-9a3dc4e99c7a417778342db83cd6e7c05558e5fb.tar.gz vaadin-framework-9a3dc4e99c7a417778342db83cd6e7c05558e5fb.zip |
Formatted XML files using defined rules (#11956)
Change-Id: Iecd621321fdde29d2d89d910ba46e9dadee58995
Diffstat (limited to 'build')
-rw-r--r-- | build/common.xml | 80 | ||||
-rwxr-xr-x | build/ide.xml | 311 |
2 files changed, 205 insertions, 186 deletions
diff --git a/build/common.xml b/build/common.xml index 1fc6349a46..ee60c1ff42 100644 --- a/build/common.xml +++ b/build/common.xml @@ -1,59 +1,65 @@ <?xml version="1.0"?> <project xmlns:antcontrib="antlib:net.sf.antcontrib" - xmlns:artifact="antlib:org.apache.maven.artifact.ant" - xmlns:ivy="antlib:org.apache.ivy.ant" - name="common" - basedir="../" - default="init-deps" > - - <property name="ivy.install.version" value="2.2.0"/> - <property name="ivy.jar.name" value="ivy-${ivy.install.version}.jar"/> + xmlns:artifact="antlib:org.apache.maven.artifact.ant" xmlns:ivy="antlib:org.apache.ivy.ant" + name="common" basedir="../" default="init-deps"> + + <property name="ivy.install.version" value="2.2.0" /> + <property name="ivy.jar.name" value="ivy-${ivy.install.version}.jar" /> <property name="ivy.jar.dir" value="${user.home}/.ant/lib" /> <property name="ivy.jar.file" value="${ivy.jar.dir}/${ivy.jar.name}" /> - - <target name="init-deps" description="Configure Ivy dependency management and load common task definitions" - depends="init-taskdefs" unless="deps.initialized"> + + <target name="init-deps" + description="Configure Ivy dependency management and load common task definitions" + depends="init-taskdefs" unless="deps.initialized"> <property name="deps.initialized" value="1" /> </target> - + <target name="check-ivy-installed"> - <available property="ivy.installed" file="${ivy.jar.file}"/> - <available property="ivy.installed" classname="org.apache.ivy.ant.IvyConfigure" /> - <antcall target="common.ivy-download" /> - </target> + <available property="ivy.installed" file="${ivy.jar.file}" /> + <available property="ivy.installed" classname="org.apache.ivy.ant.IvyConfigure" /> + <antcall target="common.ivy-download" /> + </target> <target name="ivy-download" unless="ivy.installed"> - <mkdir dir="${ivy.jar.dir}"/> - <get src="http://repo2.maven.org/maven2/org/apache/ivy/ivy/${ivy.install.version}/ivy-${ivy.install.version}.jar" dest="${ivy.jar.file}" usetimestamp="true"/> + <mkdir dir="${ivy.jar.dir}" /> + <get + src="http://repo2.maven.org/maven2/org/apache/ivy/ivy/${ivy.install.version}/ivy-${ivy.install.version}.jar" + dest="${ivy.jar.file}" usetimestamp="true" /> + </target> + + <target name="ivy-configure" depends="check-ivy-installed" + unless="deps.initialized"> + <!-- Ivy task definitions --> + <taskdef resource="org/apache/ivy/ant/antlib.xml" uri="antlib:org.apache.ivy.ant" + classpath="${ivy.jar.file}" /> + <!-- Ivy settings --> + <property name="ivy.settings.file" + value="${project.root}/build/ivy/ivysettings.xml" /> + <ivy:configure /> </target> - <target name="ivy-configure" depends="check-ivy-installed" unless="deps.initialized"> - <!-- Ivy task definitions --> - <taskdef resource="org/apache/ivy/ant/antlib.xml" uri="antlib:org.apache.ivy.ant" classpath="${ivy.jar.file}" /> - <!-- Ivy settings --> - <property name="ivy.settings.file" value="${project.root}/build/ivy/ivysettings.xml" /> - <ivy:configure/> - </target> - <target name="init-taskdefs" depends="ivy-configure" unless="deps.initialized"> <echo>Loading Ant tasks</echo> - <ivy:resolve file="${project.root}/build/ivy/ivy.xml" conf="taskdefs" /> + <ivy:resolve file="${project.root}/build/ivy/ivy.xml" + conf="taskdefs" /> <ivy:cachepath pathid="taskdefs.classpath" conf="taskdefs" /> - <taskdef resource="emma_ant.properties" classpathref="taskdefs.classpath" /> - - <!-- ant contrib required for flow control (for loop, if, property override) --> - <!-- Note that we have to use a namespace to avoid clash when running sub-ant. --> + <taskdef resource="emma_ant.properties" classpathref="taskdefs.classpath" /> + + <!-- ant contrib required for flow control (for loop, if, property + override) --> + <!-- Note that we have to use a namespace to avoid clash when running + sub-ant. --> <taskdef uri="antlib:net.sf.antcontrib" resource="net/sf/antcontrib/antlib.xml" classpathref="taskdefs.classpath" /> - - <!-- ant contrib for Maven integration --> + + <!-- ant contrib for Maven integration --> <taskdef resource="org/apache/maven/artifact/ant/antlib.xml" - uri="antlib:org.apache.maven.artifact.ant" classpathref="taskdefs.classpath" /> - - <!-- jarjar --> + uri="antlib:org.apache.maven.artifact.ant" classpathref="taskdefs.classpath" /> + + <!-- jarjar --> <taskdef name="jarjar" classname="com.tonicsystems.jarjar.JarJarTask" - classpathref="taskdefs.classpath"/> + classpathref="taskdefs.classpath" /> </target> diff --git a/build/ide.xml b/build/ide.xml index b1845020f3..5380536e2e 100755 --- a/build/ide.xml +++ b/build/ide.xml @@ -1,152 +1,165 @@ <?xml version="1.0"?> -<project xmlns:antcontrib="antlib:net.sf.antcontrib" xmlns:artifact="antlib:org.apache.maven.artifact.ant" xmlns:ivy="antlib:org.apache.ivy.ant" name="Build script for IDE users" basedir=".." default="theme-and-default-widgetset"> - <include file="${basedir}/gwt-files.xml" /> - - <property name="gwt.dev.classes" location="${gwt.eclipse.basedir}/dev/bin" /> - <property name="gwt.user.classes" location="${gwt.eclipse.basedir}/user/bin" /> - <property name="gwt.dev.src" location="${gwt.basedir}/dev/core/src" /> - <property name="gwt.dev.super.src" location="${gwt.basedir}/dev/core/super" /> - <property name="gwt.user.src" location="${gwt.basedir}/user/src" /> - <property name="gwt.user.super.src" location="${gwt.basedir}/user/super" /> - - <property name="work.dir" location="work" /> - <property name="theme-version" location="9.9.9.INTERNAL-DEBUG-BUILD" /> - <echo>Using gwt files from ${gwt.user.classes} and ${gwt.dev.classes}</echo> - - <ivy:resolve file="client-compiler/ivy.xml" conf="ide" /> - <ivy:cachepath pathid="client-compiler.deps" conf="ide" /> - <ivy:resolve file="server/ivy.xml" conf="ide" /> - <ivy:cachepath pathid="server.deps" conf="ide" /> - <ivy:resolve file="client/ivy.xml" conf="ide" /> - <ivy:cachepath pathid="client.deps" conf="ide" /> - <ivy:resolve file="shared/ivy.xml" conf="ide" /> - <ivy:cachepath pathid="shared.deps" conf="ide" /> - <ivy:resolve file="uitest/ivy.xml" conf="ide" /> - <ivy:cachepath pathid="uitest.deps" conf="ide" /> - <ivy:resolve file="theme-compiler/ivy.xml" conf="ide" /> - <ivy:cachepath pathid="theme-compiler.deps" conf="ide" /> - - <path id="classpath"> - <path location="bin" /> - <path location="build/classes" /> - <path location="${gwt.user.classes}" /> - <path location="${gwt.user.src}" /> - <path location="${gwt.user.super.src}" /> - <path location="${gwt.dev.classes}" /> - <path location="${gwt.dev.super.src}" /> - <path location="${gwt.dev.src}" /> - <path refid="client-compiler.deps" /> - <path refid="theme-compiler.deps" /> - <path refid="server.deps" /> - <path refid="shared.deps" /> - <path refid="uitest.deps" /> - <path refid="client.deps" /> - <path location="theme-compiler/src" /> - <path location="server/src" /> - <path location="shared/src" /> - <path location="uitest/src" /> - <path location="client/src" /> - </path> - - <target name="theme-and-default-widgetset" depends="default-widgetset, themes, vaadinPush.js"> - </target> - <target name="themes"> - <antcall target="compile-theme"> - <param name="theme" value="base" /> - </antcall> - <antcall target="compile-theme"> - <param name="theme" value="runo" /> - </antcall> - <antcall target="compile-theme"> - <param name="theme" value="reindeer" /> - </antcall> - <antcall target="compile-theme"> - <param name="theme" value="chameleon" /> - </antcall> - <antcall target="compile-theme"> - <param name="theme" value="liferay" /> - </antcall> - </target> - - <target name="compile-theme"> - <java classname="com.vaadin.buildhelpers.CompileTheme" failonerror="yes" fork="yes"> - <classpath refid="classpath" /> - <jvmarg value="-Djava.awt.headless=true" /> - <arg value="--theme" /> - <arg value="${theme}" /> - <arg value="--theme-version" /> - <arg value="${theme-version}" /> - <arg value="--theme-folder" /> - <arg value="WebContent/VAADIN/themes" /> - </java> - - </target> - - - <target name="default-widgetset"> - <antcall target="compile-widgetset"> - <param name="widgetset" value="com.vaadin.DefaultWidgetSet" /> - </antcall> - </target> - - <target name="testing-widgetset"> - <antcall target="compile-widgetset"> - <param name="widgetset" value="com.vaadin.tests.widgetset.TestingWidgetSet" /> - </antcall> - </target> - - <target name="compile-widgetset"> - <property name="module" value="${widgetset}" /> - <property name="module.output.dir" location="WebContent/VAADIN/widgetsets" /> - <property name="style" value="PRETTY" /> - <property name="localWorkers" value="2" /> - <property name="extraParams" value="" /> - - <mkdir dir="${module.output.dir}" /> - - <echo>Compiling ${module} to ${module.output.dir} with parameters -logLevel TRACE -style ${style} -localWorkers ${localWorkers} -strict ${extraParams}</echo> - - <!--<ivy:resolve inline="true" organisation="javax.validation" module="validation-api" revision="1.0.0.GA"/>--> - - <!-- compile the module --> - <java classname="com.google.gwt.dev.Compiler" classpathref="classpath" failonerror="yes" fork="yes" maxmemory="512m"> - <arg value="-workDir" /> - <arg value="${work.dir}" /> - <arg value="-logLevel" /> - <arg value="TRACE" /> - <arg value="-war" /> - <arg value="${module.output.dir}" /> - <arg value="-style" /> - <arg value="${style}" /> - - <arg value="-localWorkers" /> - <arg value="${localWorkers}" /> - <arg value="-strict" /> - <arg line="${extraParams}" /> - <arg value="${module}" /> - - <sysproperty key="vFailIfNotSerializable" value="true" /> - - <jvmarg value="-Xss8M" /> - <jvmarg value="-XX:MaxPermSize=256M" /> - <jvmarg value="-Djava.awt.headless=true" /> - <jvmarg value="-Dgwt.usearchives=false" /> - </java> - </target> - <target name="vaadinPush.js"> - <property name="vaadinPush.js.output" location="WebContent/VAADIN/vaadinPush.js" /> - - <loadfile srcfile="WebContent/VAADIN/jquery-1.7.2.js" property="jquery.js.contents" /> - <loadfile srcfile="WebContent/VAADIN/jquery.atmosphere.js" property="jquery.atmosphere.js.contents" /> - <loadfile srcfile="WebContent/VAADIN/vaadinPush.js.tpl" property="vaadinPush.js.contents"> - <filterchain> - <replacetokens begintoken="@" endtoken="@"> - <token key="jquery.js" value="${jquery.js.contents}" /> - <token key="jquery.atmosphere.js" value="${jquery.atmosphere.js.contents}" /> - </replacetokens> - </filterchain> - </loadfile> - <echo file="${vaadinPush.js.output}">${vaadinPush.js.contents}</echo> - </target> +<project xmlns:antcontrib="antlib:net.sf.antcontrib" + xmlns:artifact="antlib:org.apache.maven.artifact.ant" xmlns:ivy="antlib:org.apache.ivy.ant" + name="Build script for IDE users" basedir=".." + default="theme-and-default-widgetset"> + <include file="${basedir}/gwt-files.xml" /> + + <property name="gwt.dev.classes" location="${gwt.eclipse.basedir}/dev/bin" /> + <property name="gwt.user.classes" location="${gwt.eclipse.basedir}/user/bin" /> + <property name="gwt.dev.src" location="${gwt.basedir}/dev/core/src" /> + <property name="gwt.dev.super.src" location="${gwt.basedir}/dev/core/super" /> + <property name="gwt.user.src" location="${gwt.basedir}/user/src" /> + <property name="gwt.user.super.src" location="${gwt.basedir}/user/super" /> + + <property name="work.dir" location="work" /> + <property name="theme-version" location="9.9.9.INTERNAL-DEBUG-BUILD" /> + <echo>Using gwt files from ${gwt.user.classes} and + ${gwt.dev.classes}</echo> + + <ivy:resolve file="client-compiler/ivy.xml" conf="ide" /> + <ivy:cachepath pathid="client-compiler.deps" conf="ide" /> + <ivy:resolve file="server/ivy.xml" conf="ide" /> + <ivy:cachepath pathid="server.deps" conf="ide" /> + <ivy:resolve file="client/ivy.xml" conf="ide" /> + <ivy:cachepath pathid="client.deps" conf="ide" /> + <ivy:resolve file="shared/ivy.xml" conf="ide" /> + <ivy:cachepath pathid="shared.deps" conf="ide" /> + <ivy:resolve file="uitest/ivy.xml" conf="ide" /> + <ivy:cachepath pathid="uitest.deps" conf="ide" /> + <ivy:resolve file="theme-compiler/ivy.xml" conf="ide" /> + <ivy:cachepath pathid="theme-compiler.deps" conf="ide" /> + + <path id="classpath"> + <path location="bin" /> + <path location="build/classes" /> + <path location="${gwt.user.classes}" /> + <path location="${gwt.user.src}" /> + <path location="${gwt.user.super.src}" /> + <path location="${gwt.dev.classes}" /> + <path location="${gwt.dev.super.src}" /> + <path location="${gwt.dev.src}" /> + <path refid="client-compiler.deps" /> + <path refid="theme-compiler.deps" /> + <path refid="server.deps" /> + <path refid="shared.deps" /> + <path refid="uitest.deps" /> + <path refid="client.deps" /> + <path location="theme-compiler/src" /> + <path location="server/src" /> + <path location="shared/src" /> + <path location="uitest/src" /> + <path location="client/src" /> + </path> + + <target name="theme-and-default-widgetset" depends="default-widgetset, themes, vaadinPush.js"> + </target> + <target name="themes"> + <antcall target="compile-theme"> + <param name="theme" value="base" /> + </antcall> + <antcall target="compile-theme"> + <param name="theme" value="runo" /> + </antcall> + <antcall target="compile-theme"> + <param name="theme" value="reindeer" /> + </antcall> + <antcall target="compile-theme"> + <param name="theme" value="chameleon" /> + </antcall> + <antcall target="compile-theme"> + <param name="theme" value="liferay" /> + </antcall> + </target> + + <target name="compile-theme"> + <java classname="com.vaadin.buildhelpers.CompileTheme" + failonerror="yes" fork="yes"> + <classpath refid="classpath" /> + <jvmarg value="-Djava.awt.headless=true" /> + <arg value="--theme" /> + <arg value="${theme}" /> + <arg value="--theme-version" /> + <arg value="${theme-version}" /> + <arg value="--theme-folder" /> + <arg value="WebContent/VAADIN/themes" /> + </java> + + </target> + + + <target name="default-widgetset"> + <antcall target="compile-widgetset"> + <param name="widgetset" value="com.vaadin.DefaultWidgetSet" /> + </antcall> + </target> + + <target name="testing-widgetset"> + <antcall target="compile-widgetset"> + <param name="widgetset" + value="com.vaadin.tests.widgetset.TestingWidgetSet" /> + </antcall> + </target> + + <target name="compile-widgetset"> + <property name="module" value="${widgetset}" /> + <property name="module.output.dir" location="WebContent/VAADIN/widgetsets" /> + <property name="style" value="PRETTY" /> + <property name="localWorkers" value="2" /> + <property name="extraParams" value="" /> + + <mkdir dir="${module.output.dir}" /> + + <echo>Compiling ${module} to ${module.output.dir} with + parameters -logLevel TRACE -style ${style} -localWorkers + ${localWorkers} -strict ${extraParams}</echo> + + <!--<ivy:resolve inline="true" organisation="javax.validation" module="validation-api" + revision="1.0.0.GA"/> --> + + <!-- compile the module --> + <java classname="com.google.gwt.dev.Compiler" classpathref="classpath" + failonerror="yes" fork="yes" maxmemory="512m"> + <arg value="-workDir" /> + <arg value="${work.dir}" /> + <arg value="-logLevel" /> + <arg value="TRACE" /> + <arg value="-war" /> + <arg value="${module.output.dir}" /> + <arg value="-style" /> + <arg value="${style}" /> + + <arg value="-localWorkers" /> + <arg value="${localWorkers}" /> + <arg value="-strict" /> + <arg line="${extraParams}" /> + <arg value="${module}" /> + + <sysproperty key="vFailIfNotSerializable" value="true" /> + + <jvmarg value="-Xss8M" /> + <jvmarg value="-XX:MaxPermSize=256M" /> + <jvmarg value="-Djava.awt.headless=true" /> + <jvmarg value="-Dgwt.usearchives=false" /> + </java> + </target> + <target name="vaadinPush.js"> + <property name="vaadinPush.js.output" location="WebContent/VAADIN/vaadinPush.js" /> + + <loadfile srcfile="WebContent/VAADIN/jquery-1.7.2.js" + property="jquery.js.contents" /> + <loadfile srcfile="WebContent/VAADIN/jquery.atmosphere.js" + property="jquery.atmosphere.js.contents" /> + <loadfile srcfile="WebContent/VAADIN/vaadinPush.js.tpl" + property="vaadinPush.js.contents"> + <filterchain> + <replacetokens begintoken="@" endtoken="@"> + <token key="jquery.js" value="${jquery.js.contents}" /> + <token key="jquery.atmosphere.js" value="${jquery.atmosphere.js.contents}" /> + </replacetokens> + </filterchain> + </loadfile> + <echo file="${vaadinPush.js.output}">${vaadinPush.js.contents}</echo> + </target> </project>
\ No newline at end of file |