comparison rgToolFactory2.py @ 5:e9c858c8aa6e draft

Uploaded
author fubar
date Sun, 11 Jan 2015 23:06:21 -0500
parents b85a3b92e9f7
children 81198714ac8e
comparison
equal deleted inserted replaced
4:b85a3b92e9f7 5:e9c858c8aa6e
196 fhandle,self.sfile = tempfile.mkstemp(prefix=self.toolname,suffix=".%s" % (opts.interpreter)) 196 fhandle,self.sfile = tempfile.mkstemp(prefix=self.toolname,suffix=".%s" % (opts.interpreter))
197 tscript = open(self.sfile,'w') # use self.sfile as script source for Popen 197 tscript = open(self.sfile,'w') # use self.sfile as script source for Popen
198 tscript.write(self.script) 198 tscript.write(self.script)
199 tscript.close() 199 tscript.close()
200 self.indentedScript = "<![CDATA[%s]]>" % '\n'.join([' %s' % x for x in rx]) # for restructured text in help 200 self.indentedScript = "<![CDATA[%s]]>" % '\n'.join([' %s' % x for x in rx]) # for restructured text in help
201 self.escapedScript = "<![CDATA[%s]]>" % self.script) 201 self.escapedScript = "<![CDATA[%s]]>" % self.script
202 self.elog = os.path.join(self.opts.output_dir,"%s_error.log" % self.toolname) 202 self.elog = os.path.join(self.opts.output_dir,"%s_error.log" % self.toolname)
203 if opts.output_dir: # may not want these complexities 203 if opts.output_dir: # may not want these complexities
204 self.tlog = os.path.join(self.opts.output_dir,"%s_runner.log" % self.toolname) 204 self.tlog = os.path.join(self.opts.output_dir,"%s_runner.log" % self.toolname)
205 art = '%s.%s' % (self.toolname,opts.interpreter) 205 art = '%s.%s' % (self.toolname,opts.interpreter)
206 artpath = os.path.join(self.opts.output_dir,art) # need full path 206 artpath = os.path.join(self.opts.output_dir,art) # need full path