MCPcopy Create free account
hub / github.com/dylan-sutton-chavez/edge-python / build_report

Function build_report

cli/src/ui.rs:83–96  ·  view source on GitHub ↗

Summary printed by `edge build` after vendoring runtime + packages + scripts into dist/.

(dir: &std::path::Path, runtime_files: usize, packages: usize, scripts: usize, size: u64, elapsed: std::time::Duration)

Source from the content-addressed store, hash-verified

81
82/// Summary printed by `edge build` after vendoring runtime + packages + scripts into dist/.
83pub fn build_report(dir: &std::path::Path, runtime_files: usize, packages: usize, scripts: usize, size: u64, elapsed: std::time::Duration) {
84 println!();
85 if plain() {
86 println!(" bundled to {}/", dir.display());
87 } else {
88 println!(" bundled to {}/", dir.display().to_string().cyan());
89 }
90 println!();
91 println!(" {runtime_files} runtime files + compiler.wasm");
92 println!(" {packages} packages");
93 println!(" {scripts} scripts");
94 println!();
95 println!(" {:.2} MB · {:.1}s", size as f64 / 1_000_000.0, elapsed.as_secs_f64());
96}
97
98/// Render an error to stderr. `{:#}` joins the cause chain so the root reason isn't swallowed.
99pub fn error(e: &anyhow::Error) {

Callers 1

runFunction · 0.85

Calls 1

plainFunction · 0.85

Tested by

no test coverage detected