2009-10-01 16:44:24 -04:00
|
|
|
<?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.
|
|
|
|
-->
|
2009-07-24 15:03:58 -04:00
|
|
|
<project name="upload" default="upload" basedir=".">
|
2009-07-24 09:52:15 -04:00
|
|
|
<description>
|
2013-01-07 18:52:40 -05:00
|
|
|
Ant build file used to upload binaries to openjpa.apache.org/builds/latest.
|
2009-07-24 09:52:15 -04:00
|
|
|
</description>
|
|
|
|
<target name="upload">
|
2009-07-24 15:03:58 -04:00
|
|
|
|
2013-01-10 11:15:53 -05:00
|
|
|
<property name="build.dir" value="/www/www.apache.org/dist/openjpa/nightly.builds"/>
|
2009-07-24 15:03:58 -04:00
|
|
|
<property name="host" value="people.apache.org"/>
|
|
|
|
|
2009-07-24 09:52:15 -04:00
|
|
|
<mkdir dir="target/site/tempDocs" />
|
|
|
|
<unzip dest="target/site/tempDocs">
|
|
|
|
<fileset dir="target/site/downloads">
|
|
|
|
<include name="*binary*.zip" />
|
|
|
|
</fileset>
|
|
|
|
<patternset>
|
|
|
|
<include name="**/javadoc/**" />
|
2012-01-05 12:53:40 -05:00
|
|
|
<include name="**/docbook/**" />
|
2013-01-07 18:52:40 -05:00
|
|
|
<include name="**/schema/**"/>
|
2009-07-24 09:52:15 -04:00
|
|
|
</patternset>
|
|
|
|
</unzip>
|
2013-01-07 18:52:40 -05:00
|
|
|
|
2009-07-24 15:03:58 -04:00
|
|
|
<zip destfile="target/site/tempDocs/docs.zip">
|
|
|
|
<fileset dir="target/site/tempDocs">
|
|
|
|
<include name="**/javadoc/**"/>
|
2012-01-05 12:53:40 -05:00
|
|
|
<include name="**/docbook/**"/>
|
2013-01-07 18:52:40 -05:00
|
|
|
<include name="**/schema/**"/>
|
2009-07-24 15:03:58 -04:00
|
|
|
<exclude name="docs/**"/>
|
|
|
|
</fileset>
|
|
|
|
</zip>
|
2013-01-07 18:52:40 -05:00
|
|
|
<checksum>
|
2009-07-24 09:52:15 -04:00
|
|
|
<fileset dir="target/site/downloads/">
|
|
|
|
<include name="*.zip" />
|
|
|
|
</fileset>
|
|
|
|
</checksum>
|
2010-10-15 14:28:57 -04:00
|
|
|
|
|
|
|
<!-- update ${build.dir}/apache-openjpa-${project.version}/docs -->
|
2010-10-15 11:55:08 -04:00
|
|
|
<scp todir="${nightly.user.name}@${host}:${build.dir}" keyfile="${nightly.keyfile}" passphrase="${nightly.passphrase}" trust="true" sftp="true">
|
2013-01-07 18:52:40 -05:00
|
|
|
<fileset dir="target/site/tempDocs">
|
2009-07-24 15:03:58 -04:00
|
|
|
<include name="docs.zip"/>
|
|
|
|
</fileset>
|
2009-07-24 09:52:15 -04:00
|
|
|
</scp>
|
2012-03-09 14:33:00 -05:00
|
|
|
<sshexec host="${host}" username="${nightly.user.name}" keyfile="${nightly.keyfile}" passphrase="${nightly.passphrase}" command="rm -Rf ${build.dir}/apache-openjpa-${project.version}/docs ${build.dir}/apache-openjpa-${project.version}/examples" trust="true" />
|
2010-10-15 11:55:08 -04:00
|
|
|
<sshexec host="${host}" username="${nightly.user.name}" keyfile="${nightly.keyfile}" passphrase="${nightly.passphrase}" command="unzip -qq -d ${build.dir}/ ${build.dir}/docs.zip" trust="true" />
|
|
|
|
<sshexec host="${host}" username="${nightly.user.name}" keyfile="${nightly.keyfile}" passphrase="${nightly.passphrase}" command="rm ${build.dir}/docs.zip" trust="true" />
|
2010-10-15 14:28:57 -04:00
|
|
|
|
|
|
|
<!-- update ${build.dir}/apache-openjpa-${project.version}/downloads -->
|
|
|
|
<sshexec host="${host}" username="${nightly.user.name}" keyfile="${nightly.keyfile}" passphrase="${nightly.passphrase}" command="rm -Rf ${build.dir}/apache-openjpa-${project.version}/downloads" trust="true" />
|
2010-10-15 11:55:08 -04:00
|
|
|
<sshexec host="${host}" username="${nightly.user.name}" keyfile="${nightly.keyfile}" passphrase="${nightly.passphrase}" command="mkdir ${build.dir}/apache-openjpa-${project.version}/downloads " trust="true" />
|
|
|
|
<scp todir="${nightly.user.name}@${host}:${build.dir}/apache-openjpa-${project.version}/downloads" keyfile="${nightly.keyfile}" passphrase="${nightly.passphrase}" trust="true">
|
2009-07-24 15:03:58 -04:00
|
|
|
<fileset dir="target/site/downloads" />
|
2009-07-24 09:52:15 -04:00
|
|
|
</scp>
|
2013-01-07 18:52:40 -05:00
|
|
|
|
2010-10-15 14:28:57 -04:00
|
|
|
<!-- update ACLs in ${build.dir}/apache-openjpa-${project.version} -->
|
|
|
|
<sshexec host="${host}" username="${nightly.user.name}" keyfile="${nightly.keyfile}" passphrase="${nightly.passphrase}" command="find ${build.dir}/apache-openjpa-${project.version} -user ${nightly.user.name} -type d | xargs chmod 775" trust="true" />
|
|
|
|
<sshexec host="${host}" username="${nightly.user.name}" keyfile="${nightly.keyfile}" passphrase="${nightly.passphrase}" command="find ${build.dir}/apache-openjpa-${project.version} -user ${nightly.user.name} -type f | xargs chmod 664" trust="true" />
|
2013-01-07 18:52:40 -05:00
|
|
|
|
2009-07-24 09:52:15 -04:00
|
|
|
<delete>
|
|
|
|
<fileset dir="target/site/tempDocs" />
|
|
|
|
</delete>
|
|
|
|
</target>
|
|
|
|
</project>
|
|
|
|
|