Crate bootc_internal_utils

Crate bootc_internal_utils 

Source
Expand description

The inevitable catchall “utils” crate. Generally only add things here that only depend on the standard library and “core” crates.

Modules§

command 🔒
Helpers intended for std::process::Command and related structures.
iterators 🔒
path 🔒
reexec
Re-execute the current process
result_ext 🔒
timestamp 🔒
tracing_util 🔒
Helpers related to tracing, used by main entrypoints

Structs§

PathQuotedDisplay
Helper to format a path.

Constants§

NAME
The name of our binary

Traits§

AsyncCommandRunExt
Helpers intended for [tokio::process::Command].
CommandRunExt
Helpers intended for std::process::Command.
ExitStatusExt
Helpers intended for std::process::ExitStatus.
ResultExt
Extension trait for Result types that provides logging capabilities

Functions§

collect_until
Gather the first N items, and provide the count of the remaining items. The max count cannot be zero as that’s a pathological case.
initialize_tracing
Initialize tracing with the default configuration.
iterator_split
Given an iterator that’s cloneable, split it into two iterators at a given maximum number of elements.
run_main
Intended for use in main, calls an inner function and handles errors by printing them.
try_deserialize_timestamp
Try to parse an RFC 3339, warn on error.