Enum cargo_subcommand::EnvOption
source · [−]Expand description
Serializable environment variable in cargo config, configurable as per https://doc.rust-lang.org/cargo/reference/config.html#env,
Variants
String(String)
Value
Implementations
sourceimpl EnvOption
impl EnvOption
sourcepub fn resolve_value(
&self,
config_parent: impl AsRef<Path>
) -> Result<Cow<'_, str>, EnvError>
pub fn resolve_value(
&self,
config_parent: impl AsRef<Path>
) -> Result<Cow<'_, str>, EnvError>
Retrieve the value and canonicalize it relative to config_parent when EnvOption::Value::relative is set.
config_parent is the directory containing .cargo/config.toml where this was parsed from.
Trait Implementations
sourceimpl<'de> Deserialize<'de> for EnvOption
impl<'de> Deserialize<'de> for EnvOption
sourcefn 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
impl StructuralPartialEq for EnvOption
Auto Trait Implementations
impl RefUnwindSafe for EnvOption
impl Send for EnvOption
impl Sync for EnvOption
impl Unpin for EnvOption
impl UnwindSafe for EnvOption
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
sourceimpl<T> ToOwned for T where
T: Clone,
impl<T> ToOwned for T where
T: Clone,
type Owned = T
type Owned = T
The resulting type after obtaining ownership.
sourcefn clone_into(&self, target: &mut T)
fn clone_into(&self, target: &mut T)
🔬 This is a nightly-only experimental API. (
toowned_clone_into)Uses borrowed data to replace owned data, usually by cloning. Read more