Permalink
Browse files

Update build.xml with deployment tasks.

  • Loading branch information...
1 parent 687548c commit ca682b384050e23f4e8175c2ff91ed0bd52b2104 @beberlei beberlei committed Dec 4, 2010
Showing with 28 additions and 2 deletions.
  1. +2 −1 build.properties.dev
  2. +26 −1 build.xml
View
@@ -6,7 +6,8 @@ build.dir=build
dist.dir=dist
report.dir=reports
log.archive.dir=logs
-svn.path=/usr/bin/svn
+project.pirum_dir=
+project.download_dir=
test.phpunit_configuration_file=
test.phpunit_generate_coverage=0
test.pmd_reports=0
View
@@ -141,7 +141,7 @@
<!--
Builds distributable PEAR packages.
-->
- <target name="build-packages" depends="build">
+ <target name="build-packages" depends="build-orm">
<d51pearpkg2 baseinstalldir="/" dir="${build.dir}/doctrine-orm">
<name>DoctrineORM</name>
<summary>Doctrine Object Relational Mapper</summary>
@@ -180,4 +180,29 @@
</fileset>
</tar>
</target>
+
+ <target name="git-tag">
+ <exec command="git tag -a ${version}" passthru="true" />
+ <exec command="git push origin ${version}" passthru="true" />
+ </target>
+
+ <target name="pirum-release">
+ <exec command="sudo pirum add ${project.pirum_dir} ${project.basedir}/dist/DoctrineDBAL-${version}.tgz" dir="." passthru="true" />
+ <exec command="sudo pirum build ${project.pirum_dir}" passthru="true" />
+ </target>
+
+ <target name="distribute-download">
+ <copy file="dist/DoctrineORM-${version}-full.tar.gz" todir="${project.download_dir}" />
+ </target>
+
+ <target name="update-dev-version">
+ <propertyprompt propertyName="next_version" defaultValue="${version}" promptText="Enter next version string (without -DEV)" />
+ <exec command="sed 's/${version}-DEV/${next_version}-DEV/' ${project.basedir}/lib/Doctrine/ORM/Version.php > ${project.basedir}/lib/Doctrine/ORM/Version2.php" passthru="true" />
+ <exec command="mv ${project.basedir}/lib/Doctrine/ORM/Version2.php ${project.basedir}/lib/Doctrine/ORM/Version.php" passthru="true" />
+ <exec command="git add ${project.basedir}/lib/Doctrine/ORM/Version.php" passthru="true" />
+ <exec command="git commit -m 'Bump Dev Version to ${next_version}-DEV'" passthru="true" />
+ <exec command="git push origin master" passthru="true" />
+ </target>
+
+ <target name="release" depends="git-tag,build-packages,distribute-download,pirum-release,update-dev-version" />
</project>

0 comments on commit ca682b3

Please sign in to comment.