<?xml version="1.0" encoding="UTF-8"?> | |
<!-- | |
*************************************************************************************************************************** | |
* Licensed to the Apache Software Foundation (ASF) under one or more contributor license agreements. See the NOTICE file * | |
* distributed with this work for additional information regarding copyright ownership. The ASF licenses this file * | |
* to you under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance * | |
* with the License. You may obtain a copy of the License at * | |
* * | |
* http://www.apache.org/licenses/LICENSE-2.0 * | |
* * | |
* Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an * | |
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the * | |
* specific language governing permissions and limitations under the License. * | |
*************************************************************************************************************************** | |
--> | |
<!-- | |
Provides a VERY basic ANT script for creating a microservice zip file. | |
--> | |
<project name='Microservice' default='Microservice.Build'> | |
<target name='Microservice.Build'> | |
<tstamp/> | |
<loadproperties srcFile='build.properties'/> | |
<path id='classpath'> | |
<fileset dir='lib' includes='*.jar'/> | |
</path> | |
<delete dir='build' quiet='true'/> | |
<copy todir='build/bin'> | |
<fileset dir='src' excludes='**/*.java'/> | |
</copy> | |
<copy todir='build/microservice'> | |
<fileset dir='.' includes='*.cfg,lib/**'/> | |
</copy> | |
<javac srcdir='src' destdir='build/bin' fork='true' source='1.6' target='1.6' debug='true' includeantruntime='false'> | |
<classpath refid='classpath'/> | |
</javac> | |
<jar jarfile='build/microservice/${jar}' basedir='build/bin' duplicate='fail' level='9' manifest='META-INF/MANIFEST.MF'> | |
<manifest> | |
<attribute name='Built-By' value='${user.name}'/> | |
<attribute name='Build-Date' value='${TODAY}'/> | |
<attribute name='Bundle-Version' value='${version}'/> | |
</manifest> | |
</jar> | |
<zip basedir='build/microservice' destfile='build/${zip}'/> | |
<delete dir='build/bin' quiet='true'/> | |
</target> | |
</project> |