fork_jtask_ takes an optional left argument:
0 no wait, _1 infinite, >0 timeout
With no left argument it defaults to 0 (no wait).

Sounds to me that Devon isn't so worried about a new jconsole window
popping up as spawning a separate process that will run independently
of the current one.

I have now successfully tested fork on Win7. In a jconsole session I ran:
   fork jpath '~bin/jconsole gtkide'
This successfully started a separate instance of J gtk, while
retaining jconsole interactivity

On Fri, Dec 31, 2010 at 2:01 PM, bill lam <[email protected]> wrote:
> The fork in jtask uses createprocess but it does not use the option to
> disable console window iirc.
>
> Птн, 31 Дек 2010, Tikkanz писал(а):
>> On windows fork_jtask_ does use the CreateProcess api so I'd have
>> thought it should work OK (can't test right now).
>>
>> On linux fork_jtask_ needs work to get around a bug in 2!:1 that
>> causes it to wait for the process to finish (much like 2!:0)
>>
>> http://www.jsoftware.com/pipermail/programming/2009-July/015387.html
>>
>> On Fri, Dec 31, 2010 at 11:47 AM, bill lam <[email protected]> wrote:
>> > This is a feature of console program, I imagine jconsole in J6 will behave
>> > in the same way. You can either use CreateProcess api to start a
>> > console-less process or start a new shell using CMD/C (or CMD/K?) to
>> > execute jconsole. (untested).
>> >
>> > Чтв, 30 Дек 2010, Devon McCormick писал(а):
>> >> All -
>> >>
>> >> I've recently gotten accustomed, in J6, to writing a few lines of code 
>> >> which
>> >> will run for a long time to a file, then running these lines by forking 
>> >> off
>> >> a non-display (console-less) version of J, e.g.
>> >>
>> >>    (0 : 0) fwrite 'bkpUsu.ijs'
>> >> load 'bkp'     NB. Start custom backup: gather info on all files and dirs:
>> >> 'FLNMS FLDTS FLSZS FLPARENT DIRNMS DIRDEP'=. PllDirInfoEG 'C:\'
>> >>    NB. Save these results since they took so long to gather:
>> >> (<'/Temp/')
>> >> fileVar_WS_&.>'FLNMS';'FLDTS';'FLSZS';'FLPARENT';'DIRNMS';'DIRDEP'
>> >>    NB. Use this information to copy most recent 10MB to dated dir:
>> >> 'batfl cmds'=. buildBatFl_parseDir_ 10e6;'C:/Temp/NWMM20101230/'
>> >> shell batfl
>> >> 2!:55 ''
>> >> )
>> >>
>> >>    JEXE=: 'C:\Program Files\J602\bin\J.exe'
>> >>    fork ('"',JEXE,'" -jijx '),'bkpUsu.ijs'
>> >>
>> >> Unfortunately, J7 seems to provide no such option, at least that I can 
>> >> see,
>> >> for spinning off an independent copy of the interpreter without tying up 
>> >> my
>> >> current session.
>> >> When I tried the above using
>> >>    JEXE=: '"C:\Program Files\J701\bin\j7console" '
>> >> the forked process runs in my existing console window (and using the 
>> >> "-jijx"
>> >> option returns an error, as one might expect).
>> >>
>> >> Thanks,
>> >>
>> >> Devon
>> >>
>> >> Is there an easy way to spin off an independent copy of J in J7?
>> >>
>> >> --
>> >> Devon McCormick, CFA
>> >> ^me^ at acm.
>> >> org is my
>> >> preferred e-mail
>> >> ----------------------------------------------------------------------
>> >> For information about J forums see http://www.jsoftware.com/forums.htm
>> >
>> > --
>> > regards,
>> > ====================================================
>> > GPG key 1024D/4434BAB3 2008-08-24
>> > gpg --keyserver subkeys.pgp.net --recv-keys 4434BAB3
>> > ----------------------------------------------------------------------
>> > For information about J forums see http://www.jsoftware.com/forums.htm
>> ----------------------------------------------------------------------
>> For information about J forums see http://www.jsoftware.com/forums.htm
>
> --
> regards,
> ====================================================
> GPG key 1024D/4434BAB3 2008-08-24
> gpg --keyserver subkeys.pgp.net --recv-keys 4434BAB3
> ----------------------------------------------------------------------
> For information about J forums see http://www.jsoftware.com/forums.htm
----------------------------------------------------------------------
For information about J forums see http://www.jsoftware.com/forums.htm

Reply via email to