Add target method to Rustdoc type

This commit is contained in:
Guillaume Gomez 2024-05-13 15:04:10 +02:00
parent d25cf6fc14
commit eea00ca354

View file

@ -123,6 +123,12 @@ pub fn edition(&mut self, edition: &str) -> &mut Self {
self
}
/// Specify the target triple, or a path to a custom target json spec file.
pub fn target(&mut self, target: &str) -> &mut Self {
self.cmd.arg(format!("--target={target}"));
self
}
/// Specify the crate type.
pub fn crate_type(&mut self, crate_type: &str) -> &mut Self {
self.cmd.arg("--crate-type");