Skip to main content

Module editmodeprocesssupervisor

Module editmodeprocesssupervisor 

Source
Expand description

caproni edit-mode-process-supervisor: hidden internal command started by caproni run for each reloader.

Port of Go’s cmd/editmodeprocesssupervisor package.

Structs§

CmdStatus
The outcome of a SupervisedCmd run.
EditModeProcessSupervisorArgs
ProcessOptions
Options for a supervised child process.
ProcessStatus
Ported from overseer.ProcessJSON’s subset collectProcessErrors reads.
SupervisedCmd
A single child process, configured but not yet started.

Enums§

ShellwordsError
Ported from escapeFilename-adjacent shellwords.Parse error path. This crate has no mattn/go-shellwords equivalent dependency, so a minimal POSIX-lite splitter (single/double quotes, backslash escapes outside quotes) is implemented here directly – just enough to detect the unbalanced-quote case Go’s library rejects, without adding a new external dependency for one narrow use.
SupervisorError
Ported from the package-level var sentinel errors.

Constants§

COMMAND_NAME
DEFAULT_PROCESS_CONTEXT
Default process context, mirroring Go’s latest.ProcessContextMirrord.

Functions§

collect_process_errors
Port of collectProcessErrors: checks the final state of each named process and returns a combined error for any that exited abnormally. Processes in the “interrupted” state are not treated as errors since they were stopped intentionally (e.g. via SIGTERM from the user).
new_cmd
Port of overseer.NewCmd(name, args, opts).
process_options
Port of processOptions.
run
run_supervisor
Port of editmodeprocesssupervisor.run: loads the configuration, resolves the edit-mode processes configured for reloader_name that run in proc_context, and supervises them.
split_command
Splits a command string into words, honoring single/double quotes and backslash escapes outside of quotes. Ported (narrowly) from mattn/go-shellwords’s Parse.