Author: dwoods
Date: Fri Oct 15 19:04:07 2010
New Revision: 1023072

URL: http://svn.apache.org/viewvc?rev=1023072&view=rev
Log:
OPENJPA-1836 Only perform chmod on files/dirs that the nightly.user.name owns

Modified:
    openjpa/branches/2.0.x/openjpa-project/upload.xml

Modified: openjpa/branches/2.0.x/openjpa-project/upload.xml
URL: 
http://svn.apache.org/viewvc/openjpa/branches/2.0.x/openjpa-project/upload.xml?rev=1023072&r1=1023071&r2=1023072&view=diff
==============================================================================
--- openjpa/branches/2.0.x/openjpa-project/upload.xml (original)
+++ openjpa/branches/2.0.x/openjpa-project/upload.xml Fri Oct 15 19:04:07 2010
@@ -48,24 +48,27 @@
                 <include name="*.zip" />
             </fileset>
         </checksum>
-        
+
+        <!-- update ${build.dir}/apache-openjpa-${project.version}/docs -->
         <scp todir="${nightly.user.na...@${host}:${build.dir}" 
keyfile="${nightly.keyfile}" passphrase="${nightly.passphrase}" trust="true" 
sftp="true">
             <fileset dir="target/site/tempDocs"> 
                 <include name="docs.zip"/>
             </fileset>
         </scp>
-        <!-- remove directories, hopefully this fails silently. mkdir does not 
and stops the process these exist.-->
         <sshexec host="${host}" username="${nightly.user.name}" 
keyfile="${nightly.keyfile}" passphrase="${nightly.passphrase}" command="rm -Rf 
${build.dir}/apache-openjpa-${project.version}/docs" trust="true" />
-        <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" />
         <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" />
+
+        <!-- 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" />
         <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.na...@${host}:${build.dir}/apache-openjpa-${project.version}/downloads"
 keyfile="${nightly.keyfile}" passphrase="${nightly.passphrase}" trust="true">
             <fileset dir="target/site/downloads" />
         </scp>
         
-        <sshexec host="${host}" username="${nightly.user.name}" 
keyfile="${nightly.keyfile}" passphrase="${nightly.passphrase}" command="chmod 
-R g+w ${build.dir}/apache-openjpa-${project.version}" trust="true" />
+        <!-- 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" />
         
         <delete>
             <fileset dir="target/site/tempDocs" />


Reply via email to