Aditya Mahajan wrote:
On Sun, 7 May 2006, Hans Hagen wrote:
Aditya Mahajan wrote:
On Fri, 5 May 2006, Hans Hagen wrote:
Hi,
I'd like to make the ruby version of texexec the default. Are there any strong objections to this?
Is ruby stable with respect to system calls? Is the behaviour consistent on Linux and Windows? Are there active Ruby users on the list who can comment on this?
we run newtexexec on windows and linux without problems (system calls in perl are actually more problematic, or at least in th epast few years differences between platforms have given me many headaches)
I have debugged my recent failure of metapost graphics to using one-click installer (RC2) for windows. From tex.rb
report(command) if getvariable('verbose') ok = system(command) if ok && File.appended(mptex, "\\end\n") then
This is failing on my system. Can others using windows test this.
you mean that ok is false?
Yes. For some reason, system(...) returns false whenever there is > in the command. Maybe, in the future, the functionality of mpto can be incorporated into (new)texexec. This is not needed right away, as I managed to get rid of the mess in my system by using cygwin binaries for ruby.
how about using the code: File.silentdelete(mptex) command = "mpto #{mpname} > #{mptex}" report(command) if getvariable('verbose') ok = system(command) # not "ok && ..." because of potential problem with return code and redirect (>) if FileTest.file?(mptex) && File.appended(mptex, "\\end\n") then so, instead of testing for a return code we test for a file existence
I am still confused on why windows ruby have trouble with cgywin being present, but I will leave debugging that to future. Right now, newtexec is working correctly.
well, the problem is probably cygwin being present -) Hans ----------------------------------------------------------------- Hans Hagen | PRAGMA ADE Ridderstraat 27 | 8061 GH Hasselt | The Netherlands tel: 038 477 53 69 | fax: 038 477 53 74 | www.pragma-ade.com | www.pragma-pod.nl -----------------------------------------------------------------