George, hello.

On 3 Aug 2021, at 17:38, George Neuner wrote:

Racket is multi-platform and tries to present a common API for dealing with underlying operating systems.  Windows is an important platform, but Windows does not have the concept of fork/exec ... so Racket doesn't offer it either. 

Ah: good point. That said, I'd have guessed that similar behaviour -- 'invoke and don't return' -- would be at least emulatable on Windows, though.

The closest (and simplest) you can achieve, I think, would to start Vi asynchronously using 'process*' and then terminate the Racket script.

I don't think that works, since terminating the Racket process would also terminate its child (unless I were to do something similar to the usual extra fork to disconnect the child from its parent, and... hmmm, this isn't sounding very rackety).

Doing the next simplest thing -- using (process* "/usr/bin/vi" '("foo")) and calling (control 'wait) using the result -- doesn't seem to work, but instead just hangs, until I kill the vi child process. Without digging into it too deeply, I'd guess that's because of the usual problems about wiring up FDs and buffers and so on, which I was rather hoping to avoid.

Best wishes,

Norman


--
Norman Gray  :  http://www.astro.gla.ac.uk/users/norman/it/
Research IT Coordinator  :  School of Physics and Astronomy

--
You received this message because you are subscribed to the Google Groups "Racket 
Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/racket-users/D9F0F60A-D41F-454B-AC8C-9E9FD140F9D9%40glasgow.ac.uk.

Reply via email to