Calling rebol under a non cmd.exe shell in windows.
[1/2] from: marten:hildell:gm:ail at: 6-Jan-2010 18:06
Hi,
I have some shell scripts that I use under bash but run under cygwin
or msys on windows (and under Linux and OS X)
The problem with this and rebol is that I must use use something like this:
$ powershell -Command "r3-a96.exe scripts\extract_req.r > result.txt"
OR
$ cmd.exe /S /K "r3-a96.exe scripts\extract_req.r > result.txt && exit"
to make it work. This will of course not run under any other OS unless
I check for it.
Is there any particular reason why this crashes with "REBOL System
Error #1405" when called directly under those shells?
Any workaround?
Cheers,
Marten
[2/2] from: gregg:pointillistic at: 6-Jan-2010 12:12
Hi Mårten,
MH> I have some shell scripts that I use under bash but run under cygwin
MH> or msys on windows (and under Linux and OS X)
...
MH> to make it work. This will of course not run under any other OS unless
MH> I check for it.
While it would be great if REBOL could hide every detail of
cross-platform portability, system calls and library interfaces can't
always work that way. I usually just put these things in wrappers, so
only one part of the code has to know about it.
MH> Is there any particular reason why this crashes with "REBOL System
MH> Error #1405" when called directly under those shells?
I think this is due to R3 being alpha, and not many people having
tested the shell interface. Submit the bug to CureCode and it will
get on RTs radar.
-- Gregg