chemistry-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From dcaru...@apache.org
Subject svn commit: r1022614 - /incubator/chemistry/opencmis/trunk/chemistry-opencmis-workbench/chemistry-opencmis-workbench/src/main/resources/scripts/upload.groovy
Date Thu, 14 Oct 2010 17:08:13 GMT
Author: dcaruana
Date: Thu Oct 14 17:08:13 2010
New Revision: 1022614

URL: http://svn.apache.org/viewvc?rev=1022614&view=rev
Log:
Fix OpenCMIS workbench upload.groovy script
- compile error
- ignore files/folders with names starting "."

Modified:
    incubator/chemistry/opencmis/trunk/chemistry-opencmis-workbench/chemistry-opencmis-workbench/src/main/resources/scripts/upload.groovy

Modified: incubator/chemistry/opencmis/trunk/chemistry-opencmis-workbench/chemistry-opencmis-workbench/src/main/resources/scripts/upload.groovy
URL: http://svn.apache.org/viewvc/incubator/chemistry/opencmis/trunk/chemistry-opencmis-workbench/chemistry-opencmis-workbench/src/main/resources/scripts/upload.groovy?rev=1022614&r1=1022613&r2=1022614&view=diff
==============================================================================
--- incubator/chemistry/opencmis/trunk/chemistry-opencmis-workbench/chemistry-opencmis-workbench/src/main/resources/scripts/upload.groovy
(original)
+++ incubator/chemistry/opencmis/trunk/chemistry-opencmis-workbench/chemistry-opencmis-workbench/src/main/resources/scripts/upload.groovy
Thu Oct 14 17:08:13 2010
@@ -21,7 +21,7 @@ import org.apache.chemistry.opencmis.com
 import org.apache.chemistry.opencmis.commons.enums.*
 import org.apache.chemistry.opencmis.client.api.*
 
-CMIS cmis = new scripts.CMIS(session)
+cmis = new scripts.CMIS(session)
 
 // destination folder
 Folder destFolder = cmis.getFolder("/")
@@ -47,6 +47,12 @@ VersioningState versioningState = Versio
 
 def doUpload(Folder parent, File folder, String folderType, String documentType, VersioningState
versioningState) {
     folder.eachFile {
+        
+        if (it.getName().startsWith(".")) {
+            println "Skipping " + it.getName()
+            return;
+        }
+
         println it.getName()
         
         if(it.isFile()) {



Mime
View raw message