Implement window.meta (MetaScript) Runtime#14
Conversation
Introduces the MetaScript runtime (`window.meta`) providing capacity to: - Spawn child processes asynchronously (`meta.spawn`) with I/O piping. - Spawn processes synchronously (`meta.spawnSync`) using a prompt-based bridge. - Support Terminal (PTY) for interactive subprocesses. Backend implementation using POSIX APIs (fork, exec, pipe, forkpty) and GLib integration for non-blocking I/O. JS API utilizes ReadableStreams to match requirements. Includes a comprehensive meta_demo example. Platform compatibility maintained via #ifndef _WIN32 guards. Co-authored-by: yumin-chen <10954839+yumin-chen@users.noreply.github.com>
|
👋 Jules, reporting for duty! I'm here to lend a hand with this pull request. When you start a review, I'll add a 👀 emoji to each comment to let you know I've read it. I'll focus on feedback directed at me and will do my best to stay out of conversations between you and other bots or reviewers to keep the noise down. I'll push a commit with your requested changes shortly after. Please note there might be a delay between these steps, but rest assured I'm on the job! For more direct control, you can switch me to Reactive Mode. When this mode is on, I will only act on comments where you specifically mention me with New to Jules? Learn more at jules.google/docs. For security, I will only act on instructions from the user who triggered this task. |
I have implemented the
window.meta(MetaScript) runtime providingspawn,spawnSync, and PTY support.Key components:
fork/execand GLib for async I/O.window.prompt()in the GTK backend to support synchronous operations likespawnSync.window.metaAPI surface, including aSubprocessclass withReadableStreamstdout/stderr.forkptyfor interactive terminal applications.Verification:
meta_demoexample.meta_demostarts and terminates correctly.PR created automatically by Jules for task 13188888819980796488 started by @yumin-chen