Function run_from_env

Source
pub fn run_from_env() -> Result<(), PackagingError>
Expand description

Runs the external Cargo subcommand using process arguments and current directory.

Cargo invokes an external subcommand as cargo-ailloli-ui ailloli-ui ...; the redundant second argument is removed when present. Parsing errors and help/version requests are handled by clap and may terminate the process. Successful packaging writes below Cargo’s target directory and may invoke both Cargo and the built consumer executable.

§Errors

Returns an error when the current directory is unavailable or any discovery, build, identity, staging, archive, or manifest step fails.

§Examples

let result: Result<(), ailloli_ui_packaging::PackagingError> =
    ailloli_ui_packaging::run_from_env();
result?;