pub struct CargoDocCommands { /* private fields */ }
Implementations§
Source§impl CargoDocCommands
impl CargoDocCommands
Sourcepub fn run(self, sh: &Shell) -> Result<PathBuf>
pub fn run(self, sh: &Shell) -> Result<PathBuf>
Execute the doc command(s), returning a path to the built docs directory.
Sourcepub fn run_with(
self,
sh: &Shell,
f: impl Fn(Cmd<'_>) -> Cmd<'_>,
) -> Result<PathBuf>
pub fn run_with( self, sh: &Shell, f: impl Fn(Cmd<'_>) -> Cmd<'_>, ) -> Result<PathBuf>
Execute the doc command(s), returning path(s) to the built artifact.
Unlike run
, this method allows tweaking the build command prior to
running it (e.g: to add env vars, change the working directory where the
artifacts will be placed, etc…).
Trait Implementations§
Source§impl<'de> Deserialize<'de> for CargoDocCommands
impl<'de> Deserialize<'de> for CargoDocCommands
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Auto Trait Implementations§
impl Freeze for CargoDocCommands
impl RefUnwindSafe for CargoDocCommands
impl Send for CargoDocCommands
impl Sync for CargoDocCommands
impl Unpin for CargoDocCommands
impl UnwindSafe for CargoDocCommands
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left
is true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left(&self)
returns true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read more