Skip to main content

Crate yoctui_utils

Crate yoctui_utils 

Source
Expand description

Domain-independent platform, text and time helpers shared across Yoctui.

Structs§

ProcessGroupGuard
Kill an owned child process group when an asynchronous operation is dropped. Callers must start the child in a new group whose ID equals its PID, and disarm after normal completion. The child handle remains responsible for reaping.

Functions§

append_truncation_marker
Append bounded UTF-8 text without splitting characters.
config_dir
XDG configuration root. Relative or empty overrides are ignored.
format_duration
home_dir
Resolve the user’s home, falling back to the current directory for browsing. Do not use this fallback to choose a persistent configuration destination.
home_path
is_absolute_normal_path
Validate a non-root absolute path whose components never traverse upward or redundantly refer to the current directory.
is_absolute_normal_path_within
is_bounded_identifier
Validate the shared BitBake identifier alphabet used by recipe, machine, distro, image and test selector identities.
is_bounded_plain_text
is_csi_final_byte
ECMA-48 CSI final bytes include punctuation, not only letters.
is_transient_spawn_error
Return whether a failed spawn can succeed once the executable stops being rewritten by another process.
lower_process_priority
Best-effort Unix process-priority reduction for background discovery work. A larger nice value gives interactive work precedence. Callers choose whether inability to lower priority should fail the operation.
path_entry_exists
Report whether any filesystem entry occupies path, including a dangling symbolic link. Unlike Path::exists, this does not follow the final link.
poll_timeout_ms
A positive bounded poll timeout; callers handle nonblocking zero separately.
push_bounded
Append bounded UTF-8 text without splitting characters.
push_unique_bounded
state_dir
XDG state root. Relative or empty overrides are ignored.
strip_ansi
Strip terminal escape sequences while preserving ordinary text and whitespace. Unterminated control strings are discarded through the end of the input.
truncate_utf8
Truncate to a byte budget without splitting a UTF-8 character.
unix_ms
Current Unix milliseconds, saturating for out-of-range system clocks.
utf8_prefix
Return the longest prefix within the byte budget.