Project

General

Profile

« Previous | Next » 

Revision 8021

retrieve MetacatUI project from github (requires client has git installed!) and build into the "metacatui" skin during the war process. https://projects.ecoinformatics.org/ecoinfo/issues/6020

View differences:

build.xml
47 47
			<include name="*.jar" />
48 48
		</fileset>
49 49
	</path>
50
	
51
	<!-- Allow integration with Git projects -->
52
	<macrodef name = "git">
53
	    <attribute name = "command" />
54
	    <attribute name = "dir" default = "" />
55
	    <element name = "args" optional = "true" />
56
	    <sequential>
57
	        <echo message = "git @{command}" />
58
	        <exec executable = "git" dir = "@{dir}">
59
	            <arg value = "@{command}" />
60
	            <args/>
61
	        </exec>
62
	    </sequential>
63
	</macrodef>
64
	<macrodef name = "git-clone-pull">
65
	    <attribute name = "repository" />
66
	    <attribute name = "dest" />
67
	    <sequential>
68
	        <git command = "clone">
69
	            <args>
70
	                <arg value = "@{repository}" />
71
	                <arg value = "@{dest}" />
72
	            </args>
73
	        </git>
74
	        <git command = "pull" dir = "@{dest}" />
75
	    </sequential>
76
	</macrodef>
50 77
    	
51 78
	<taskdef resource="axis-tasks.properties"
52 79
		classpathref="axis.ant.classpath" />
......
352 379
			value="https://code.ecoinformatics.org/code/eml/tags/${eml2_1_1-schema-tag}" />
353 380
		<property name="svn.eml2StyleUrl"
354 381
			value="https://code.ecoinformatics.org/code/eml/tags/${eml2-style-tag}" />
355

  
382
		
383
		<!-- the git repo -->
384
		<property name="metacatui.git.repository.url"
385
					value="https://github.com/NCEAS/metacatui.git" />
386
		<property name="metacatui.build.dir"
387
					value="${build.dir}/metacatui" />
388
		<property name="metacatui.resources.dir"
389
					value="${metacatui.build.dir}/metacatui/src/main/webapp" />
390
		
356 391
		<!-- load the svn task -->
357 392
		<path id="svn.classpath">
358 393
			<pathelement location="${svnjavahl.jar}" />
......
498 533

  
499 534
		<!--  ant dir="${utilitiesdir}" inheritAll="false"  target="dist" / -->
500 535
	</target>
536
	
537
	<!-- get metacatUI project -->
538
	<target name="getMetacatUI" depends="init">
539
		<git-clone-pull repository="${metacatui.git.repository.url}" dest="${metacatui.build.dir}" />
540
	</target>
541
	
542
	<target name="copyMetacatUI" depends="getMetacatUI">
543
		<copy todir="${lib.dir}${style-skins-relpath}/metacatui">
544
			<fileset dir="${metacatui.resources.dir}" includes="**/*">
545
			</fileset>
546
		</copy>
547
	</target>
501 548

  
502 549
	<target name="getutilities" depends="prepare"
503 550
		description="Checks utility out of svn and copies it to your metacat sandbox">
......
893 940
	</target>
894 941

  
895 942
	<target name="warPrepare"
896
		depends="cgiPrepare,jar,clientjar,harvesterjar,testPrepare,documentation"
943
		depends="cgiPrepare,jar,clientjar,harvesterjar,testPrepare,documentation,copyMetacatUI"
897 944
		description="Prepare files for creating a web archive (WAR)">
898 945

  
899 946
		<property name="war.lib" value="${build.war}/lib" />

Also available in: Unified diff