Expand cargo dependencies in build.rs
Expand the entire dependency
rust
let expander = Expander::default();
// get the expanded output
let output = expander.expand("<a dependency in Cargo.toml>").unwrap();
Expand only a specific module or type or function
rust
let expander = Expander::default();
// get the expanded output of the given module
let output = expander
.expand_path(
"<a dependency in Cargo.toml>",
"path::to::module".parse().unwrap(),
)
.unwrap();
Licensed under either of these: