Rendering. Almost a pure function of the App state β the one
exception is the log view writing its viewport height and clamped scroll
offset back into the app, so paging and bounds always match the actual
terminal size.
--export-profiles: the resolved table, as JSON or TOML, to a file
or stdout. --builtin needs neither a profiles file nor systemd, so
it works on a machine without scx.service; the full export also
covers the installed schedulers, which takes the backend.
The options after --export-profiles. The target is the first
argument that is not an option, so --export-profiles --builtin
writes to stdout and --export-profiles out.toml --format toml to
the file; - is stdout explicitly.
Replaces path with text the way the environment file is
rewritten: through a scratch file in the same directory and a
rename, so that a failure midway leaves the file as it was, and with
an existing fileβs identity (the file behind a symlink, owner, POSIX
access ACL, mode) carried over. A new file is created as
File::create would create it, under the umask, which is what the
callerβs plain write used to do. For the profile export, whose
target is often the live profiles file.