pub fn stage_program(entry: &str, scripts: &[(&str, &[u8])]) -> StringExpand description
The Python a multi-file project pastes. It writes every staged file through
open(..., 'wb'), creating the directories the path needs, then runs the
entry file in the REPL’s own globals so __name__ stays __main__.
The shape is shared with the MicroPython path in runner.rs; the difference
is only which name is passed as entry. Neither runtime needs a boot.py:
CircuitPython runs the entry itself, and wiring files through boot.py
would execute them before the paste had a chance to finish.
An empty scripts list returns an empty string because there is nothing to
stage; the caller pastes a single file directly, as runner.rs does.