{"id":59527,"library":"rustfmt-wrapper","title":"Rustfmt Wrapper","description":"Library wrapper around rustfmt for use by code generators.","status":"active","version":"0.2.1","language":"rust","source_language":null,"source_url":"https://github.com/oxidecomputer/rustfmt-wrapper","tags":["rustfmt","code-generation","formatting"],"install":[{"cmd":"# Cargo.toml\n[dependencies]\nrustfmt-wrapper = \"0.2.1\"","lang":"toml","label":"Cargo.toml"},{"cmd":"cargo add rustfmt-wrapper","lang":"bash","label":"cargo add"}],"dependencies":[],"imports":[{"symbol":"rustfmt","correct":"use rustfmt_wrapper::rustfmt;"}],"quickstart":{"code":"use rustfmt_wrapper::rustfmt;\n\nfn main() -> Result<(), Box<dyn std::error::Error>> {\n    let code = \"fn main() {}\";\n    let formatted = rustfmt(code)?;\n    println!(\"{}\", formatted);\n    Ok(())\n}","lang":"rust","description":"Format Rust code using rustfmt."},"warnings":[{"fix":"Ensure rustfmt is installed via `rustup component add rustfmt`.","message":"Requires rustfmt to be installed and available in PATH.","severity":"gotcha","affected_versions":">=0.2.0"}],"env_vars":null,"search_vec":"'around':5 'code':10,14 'code-gener':13 'format':16 'generat':11,15 'librari':3 'rustfmt':1,6,12 'use':8 'wrapper':2,4","created_at":"2026-06-16T17:07:08.892074+00:00","updated_at":"2026-06-16T17:07:08.892074+00:00","problems":[],"ecosystem":"crates","meta_description":null,"install_score":null,"quickstart_score":null,"quickstart_tag":null,"pypi_latest":null,"cli_name":null,"cli_version":null,"type":"library","homepage":"https://github.com/oxidecomputer/rustfmt-wrapper","github":"https://github.com/oxidecomputer/rustfmt-wrapper","docs":"https://docs.rs/rustfmt-wrapper/","changelog":null,"pypi":null,"npm":null,"openapi_spec":null,"status_page":null,"smithery":null,"categories":["build-tool"],"base_url":null,"auth_type":null,"provenance":{"verified_status":null,"verified_at":null,"last_verified":"2026-06-16","next_check":"2026-12-13","install_tag":null}}