Expand description
§unsafe-budget
an unsafe code budget gate for ci pipelines.
this library provides the core functionality for tracking unsafe code usage in rust and go projects, comparing against baselines, and enforcing budgets.
§quick example
use unsafe_budget::analyzer::detect_analyzer;
use unsafe_budget::model::ScanOpts;
let opts = ScanOpts::default();
let analyzer = detect_analyzer(&opts);
let result = analyzer.run(&opts).unwrap();
println!("total unsafe: {}", result.totals.overall_unsafe);
for unit in &result.units {
println!(" {}: {}", unit.name, unit.unsafe_count);
}