dabodoc Commit
Revision 77
Date: 2011-04-02 03:50:31 -0700 (Sat, 02 Apr 2011)
Author: Werner
Trac: http://trac.dabodev.com/changeset/77

Changed:
U   trunk/api/sphinx/makeSphinx.py

Log:
- Sphinx copies the .svn folder in sub-folders of _static, need to remove them 
in the build folder

Diff:
Modified: trunk/api/sphinx/makeSphinx.py
===================================================================
--- trunk/api/sphinx/makeSphinx.py      2011-04-02 10:49:39 UTC (rev 76)
+++ trunk/api/sphinx/makeSphinx.py      2011-04-02 10:50:31 UTC (rev 77)
@@ -75,6 +75,31 @@
        
 MakeSphinx(builder, rebuildall)
 
+import stat
+targetFolder = os.path.join(os.path.join(sc.baseFolder, 'build'), builder)
+# walk the tree to change files to writable
+svnFolder = os.path.join(targetFolder, '_static\\macWidgets\\.svn')
+if os.path.isdir(svnFolder):
+    print "remove from build folder: %s" % svnFolder
+    for top, dirs, files in os.walk(svnFolder):
+        for item in files:       
+            os.chmod(os.path.join(top, item), stat.S_IWRITE)  
+    shutil.rmtree(svnFolder)
+svnFolder = os.path.join(targetFolder, '_static\\winWidgets\\.svn')
+if os.path.isdir(svnFolder):
+    print "remove from build folder: %s" % svnFolder
+    for top, dirs, files in os.walk(svnFolder):
+        for item in files:       
+            os.chmod(os.path.join(top, item), stat.S_IWRITE)  
+    shutil.rmtree(svnFolder)
+svnFolder = os.path.join(targetFolder, '_static\\nixWidgets\\.svn')
+if os.path.isdir(svnFolder):
+    print "remove from build folder: %s" % svnFolder
+    for top, dirs, files in os.walk(svnFolder):
+        for item in files:       
+            os.chmod(os.path.join(top, item), stat.S_IWRITE)
+    shutil.rmtree(svnFolder)
+
 current = time.time()
 h, m, s = FractSec(int(current - start))
 



_______________________________________________
Post Messages to: [email protected]
Subscription Maintenance: http://leafe.com/mailman/listinfo/dabo-dev
Searchable Archives: http://leafe.com/archives/search/dabo-dev
This message: 
http://leafe.com/archives/byMID/[email protected]

Reply via email to