Permalink
Fetching contributors…
Cannot retrieve contributors at this time
62 lines (53 sloc) 2.55 KB
<?xml version="1.0" encoding="UTF-8"?>
<project name="external-login" default="build" basedir=".">
<property name="server" value="http://download.chdemko.com/joomla/extensions/external-login" />
<property name="version" value="3.1.0.0-rc4" />
<property name="shortversion" value="3.1" />
<property name="joomlaversion" value="3" />
<property name="dist" value="build" />
<target name="build" depends="phpcs, clean, src, readme, server "/>
<target name="readme">
<copy file="README.markdown.tpl" tofile="README.markdown" overwrite="true" />
<replace file="README.markdown" token="@VERSION@" value="${version}"/>
<replace file="README.markdown" token="@JOOMLAVERSION@" value="${joomlaversion}"/>
<replace file="README.markdown" token="@SERVER@" value="${server}"/>
</target>
<target name="server" description="Generate Server file">
<copy file="server.xml.tpl" tofile="server-${shortversion}.xml" overwrite="true" />
<replace file="server-${shortversion}.xml" token="@VERSION@" value="${version}"/>
<replace file="server-${shortversion}.xml" token="@SERVER@" value="${server}"/>
<replace file="server-${shortversion}.xml" token="@SHORTVERSION@" value="${shortversion}"/>
<copy file="server-${shortversion}.xml" tofile="${dist}/server-${shortversion}.xml" />
<delete file="server-${shortversion}.xml" />
</target>
<target name="update" description="Generate Update file">
<copy file="update.xml.tpl" tofile="update.xml" overwrite="true" />
<replace file="update.xml" token="@VERSION@" value="${version}"/>
<replace file="update.xml" token="@SERVER@" value="${server}"/>
<replace file="update.xml" token="@SHORTVERSION@" value="${shortversion}"/>
<replace file="update.xml" token="@JOOMLAVERSION@" value="${joomlaversion}"/>
<copy file="update.xml" tofile="${dist}/update-${project-name}-${shortversion}.xml" />
<delete file="update.xml" />
</target>
<target name="phpcs" description="Generate checkstyle.xml using PHP_CodeSniffer">
<exec executable="phpcs">
<arg value="--extensions=php" />
<arg value="-p" />
<arg value="--standard=Joomla" />
<arg value="--ignore=tmpl" />
<arg path="." />
</exec>
</target>
<target name="src">
<ant antfile="src/build.xml" useNativeBasedir="true" />
<copy todir="${dist}">
<fileset dir="src/${dist}" />
</copy>
</target>
<target name="zip" description="Generate Zip file">
<zip destfile="${dist}/${project-name}-${version}.zip" basedir="." excludes="**/*~,*.tpl,build.xml,update.xml" />
</target>
<target name="clean" description="Clean up">
<delete dir="${dist}" />
</target>
</project>