pub struct ToolchainConfig {
pub htl: Option<String>,
}Expand description
[toolchain] — the htl command a project expects to be checked by.
Cargo.toml already pins the htl crate a Rust host builds against, and nothing
pinned the command. The command is what decides whether the project checks: a default
lint added in a release turns a green project red on unchanged sources, and without
this key the first place that shows up is a teammate’s terminal rather than the line
in this file that says which release the project moved to.
htl does not install anything — it is one binary, not a toolchain manager — so a
mismatch is reported and the message names cargo install htl-cli.
Fields§
§htl: Option<String>A Cargo-style requirement the running command must satisfy: "0.4" for 0.4.x,
"1" for 1.x, ">=0.4.2, <0.6" when a project needs to say more. Absent, any
command runs the project, which is what every project did before the key existed.
Implementations§
Source§impl ToolchainConfig
impl ToolchainConfig
Sourcepub fn req(&self) -> Result<Option<VersionReq>>
pub fn req(&self) -> Result<Option<VersionReq>>
The requirement, parsed. Ok(None) when the key is absent; Err when it is there
and is not a requirement — which HtlConfig::parse raises with the rest of the
config errors, so a typo here is found where a typo in [lint] is.
Trait Implementations§
Source§impl Clone for ToolchainConfig
impl Clone for ToolchainConfig
Source§fn clone(&self) -> ToolchainConfig
fn clone(&self) -> ToolchainConfig
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for ToolchainConfig
impl Debug for ToolchainConfig
Source§impl Default for ToolchainConfig
impl Default for ToolchainConfig
Source§fn default() -> ToolchainConfig
fn default() -> ToolchainConfig
Source§impl<'de> Deserialize<'de> for ToolchainConfig
impl<'de> Deserialize<'de> for ToolchainConfig
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>,
Auto Trait Implementations§
impl Freeze for ToolchainConfig
impl RefUnwindSafe for ToolchainConfig
impl Send for ToolchainConfig
impl Sync for ToolchainConfig
impl Unpin for ToolchainConfig
impl UnsafeUnpin for ToolchainConfig
impl UnwindSafe for ToolchainConfig
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> DeserializeOwned for Twhere
T: for<'de> Deserialize<'de>,
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> ⓘ
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> ⓘ
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