[Python-checkins] r50570 - sandbox/trunk/welease/welease.py
anthony.baxter
python-checkins at python.org
Tue Jul 11 05:48:13 CEST 2006
Author: anthony.baxter
Date: Tue Jul 11 05:48:12 2006
New Revision: 50570
Modified:
sandbox/trunk/welease/welease.py
Log:
automatically do the touch of the generated AST files
Modified: sandbox/trunk/welease/welease.py
==============================================================================
--- sandbox/trunk/welease/welease.py (original)
+++ sandbox/trunk/welease/welease.py Tue Jul 11 05:48:12 2006
@@ -1,4 +1,6 @@
#!/usr/bin/python
+# -*- Mode: python -*-
+# vi:si:et:sw=4:sts=4:ts=4
# (C) 2006, Python Software Foundation.
# This code is available under the Python Software Foundation license.
@@ -340,14 +342,26 @@
d.addCallback(lambda x: x==True and self.exportSvnDone(0))
return
d = self.do_command(['svn', 'export', self.tagPath, self.exportPath])
- d.addCallback(self.exportSvnDone)
+ d.addCallback(self.touchAsdlFiles)
+
+ def touchAsdlFiles(self, exitval):
+ # These files need to be 'touched' to avoid make trying to rebuild
+ # them. You can't force a no-change checkin in svn to update timestamps :-(
+ # (I checked with gstein about this)
+ if exitval != 0:
+ self.warnPopup("svn export exited with code %d"%(exitval))
+ else:
+ touchedFiles = [ 'Include/Python-ast.h', 'Python/Python-ast.c' ]
+ touchedFiles = [ os.path.join(self.exportPath, x) for x in touchedFiles ]
+ d = self.do_command(['touch'] + touchedFiles)
+ d.addCallback(self.exportSvnDone)
def exportSvnDone(self, exitval):
if exitval == 0:
self.xml.get_widget('exportSvnLabel').set_text('Ok!')
self.xml.get_widget('buildTarballsButton').set_sensitive(True)
else:
- self.warnPopup("svn export exited with code %d"%(exitval))
+ self.warnPopup("touch ASDL files exited with code %d"%(exitval))
def on_buildTarballsButton_clicked(self, e):
os.chdir(cfg.BuildHome)
More information about the Python-checkins
mailing list