From: Phil E. <l2...@us...> - 2005-04-19 08:24:09
|
Update of /cvsroot/pythoncard/PythonCard/tools/standaloneBuilder In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv20638 Modified Files: changelog.txt customDialogs.py standaloneBuilder.py Log Message: Bug fix for exception raised when building a project that did not have a Windows icon file defined. Also added basic documentation with screenshots. Index: changelog.txt =================================================================== RCS file: /cvsroot/pythoncard/PythonCard/tools/standaloneBuilder/changelog.txt,v retrieving revision 1.3 retrieving revision 1.4 diff -C2 -d -r1.3 -r1.4 *** changelog.txt 18 Apr 2005 11:33:14 -0000 1.3 --- changelog.txt 19 Apr 2005 08:23:56 -0000 1.4 *************** *** 1,4 **** standaloneBuilder version Version 0.1.1 release date TBA ! --------------------------------------------------------------------------- - Fixed a bug which was causing an exception when creating a new project due to trying to incorrectly make a relative path out of a --- 1,7 ---- standaloneBuilder version Version 0.1.1 release date TBA ! -------------------------------------------------------- ! - Fixed bug in spec file generation which was causing an exception ! in McMillan Installer when no Windows icon file had been selected ! in the project - Fixed a bug which was causing an exception when creating a new project due to trying to incorrectly make a relative path out of a Index: customDialogs.py =================================================================== RCS file: /cvsroot/pythoncard/PythonCard/tools/standaloneBuilder/customDialogs.py,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -d -r1.4 -r1.5 *** customDialogs.py 15 Apr 2005 16:02:18 -0000 1.4 --- customDialogs.py 19 Apr 2005 08:23:56 -0000 1.5 *************** *** 362,368 **** def on_installerPathBtn_mouseClick(self, event): ! result = dialog.directoryDialog(self, self.components.StaticText1.text, self.components.installerPath.text) if result.accepted: ! self.components.installerPath.text = result.path def on_installerPathHelpBtn_mouseClick(self, event): --- 362,368 ---- def on_installerPathBtn_mouseClick(self, event): ! result = dialog.fileDialog(self, self.components.StaticText1.text, self.components.installerPath.text) if result.accepted: ! self.components.installerPath.text = result.paths[0] def on_installerPathHelpBtn_mouseClick(self, event): Index: standaloneBuilder.py =================================================================== RCS file: /cvsroot/pythoncard/PythonCard/tools/standaloneBuilder/standaloneBuilder.py,v retrieving revision 1.5 retrieving revision 1.6 diff -C2 -d -r1.5 -r1.6 *** standaloneBuilder.py 18 Apr 2005 11:33:14 -0000 1.5 --- standaloneBuilder.py 19 Apr 2005 08:23:56 -0000 1.6 *************** *** 136,140 **** chglogData = open(tmplfile, 'r').read() chglogData = chglogData % template ! fd.write(chglogData) fd.close() --- 136,142 ---- chglogData = open(tmplfile, 'r').read() chglogData = chglogData % template ! dashes = '-' * len(chglogData) ! fd.write(chglogData + '\n') ! fd.write(dashes + '\n') fd.close() *************** *** 820,824 **** exefile = os.path.join(self.pathJoin(self.project.get('Project', 'buildfilespath')), self.project.get('Project', 'name') + '.exe') - iconfile = os.path.join(basedir, self.components.projectIcon.text) spec = [] --- 822,825 ---- *************** *** 838,842 **** spec.append(" upx=%s," % int(self.project.getboolean('Project', 'compress'))) spec.append(" console=%s," % int(self.project.getboolean('Project', 'console'))) ! spec.append(" icon = '%s'," % iconfile) spec.append(" version = '%s')" % versionfile) spec.append("coll = COLLECT(exe,") --- 839,847 ---- spec.append(" upx=%s," % int(self.project.getboolean('Project', 'compress'))) spec.append(" console=%s," % int(self.project.getboolean('Project', 'console'))) ! ! if self.components.projectIcon.text != '': ! spec.append(" icon = '%s'," % iconfile) ! iconfile = os.path.join(basedir, self.components.projectIcon.text) ! spec.append(" version = '%s')" % versionfile) spec.append("coll = COLLECT(exe,") *************** *** 893,897 **** # all output to a temporary file and read the results from there # when done ! builder = os.path.join(self.cfg.get('ConfigData', 'installerpath'), 'Build.py') tfile = 'pmbuild.out' basedir = os.path.join(self.cfg.get('ConfigData', 'projects'), self.components.baseDir.text) --- 898,902 ---- # all output to a temporary file and read the results from there # when done ! builder = self.cfg.get('ConfigData', 'installerpath') tfile = 'pmbuild.out' basedir = os.path.join(self.cfg.get('ConfigData', 'projects'), self.components.baseDir.text) *************** *** 1036,1040 **** rdate = time.strftime('%B %d %Y') log[0] = string.replace(log[0], 'TBA', rdate) ! log[1] = '-' * len(log[0]) fd = open(newchglog, 'w') for line in log: --- 1041,1046 ---- rdate = time.strftime('%B %d %Y') log[0] = string.replace(log[0], 'TBA', rdate) ! dashes = '-' * (len(log[0]) - 1) ! log[1] = dashes + '\n' fd = open(newchglog, 'w') for line in log: *************** *** 1077,1080 **** --- 1083,1087 ---- chglogData = open(tmplfile, 'r').read() chglogData = chglogData % template + dashes = '-' * len(chglogData) chglog = os.path.join(basedir, 'changelog.txt') *************** *** 1085,1089 **** newchglog = os.path.join(basedir, 'changelog-new.txt') fd = open(newchglog, 'w') ! fd.write(chglogData + '\n') # new stuff for line in log: fd.write(line) --- 1092,1098 ---- newchglog = os.path.join(basedir, 'changelog-new.txt') fd = open(newchglog, 'w') ! fd.write(chglogData) # new stuff ! fd.write(dashes + '\n') ! fd.write('\n\n') # couple of blank lines for line in log: fd.write(line) *************** *** 1203,1207 **** cnt = 0 for item in self.components.scriptList.items: - print 'processing item %s, [%s]' % (cnt, item) self.project.set('Scripts', str(cnt), self.pathSplit(item)) cnt += 1 --- 1212,1215 ---- *************** *** 1337,1341 **** afile = os.path.join(afile, 'gpl.txt') fd = open(afile, 'w') ! fd.write(VINFO % vinfo) fd.close() --- 1345,1352 ---- afile = os.path.join(afile, 'gpl.txt') fd = open(afile, 'w') ! txtline = VINFO % vinfo ! dashes = '-' * len(txtline) ! fd.write(txtline + '\n') ! fd.write(dashes + '\n') fd.close() |