pub enum Hint {
CargoListFailed,
NetworkConnectTimeout,
InvalidGlob,
}Expand description
一条可执行提示。hint_for 只返回哪一条提示(locale key),具体文案由
main 通过 Language::get_text(hint.locale_key()) 按用户语言渲染——和 cargo-fresh
其它所有用户可见字符串走同一条 i18n 路径(src/locale/texts.rs),不在这里硬编码英文。
Variants§
CargoListFailed
cargo install --list 子进程失败:检查 cargo 是否在 PATH。
NetworkConnectTimeout
reqwest 连接/超时:检查网络连通性 / 代理。
InvalidGlob
--filter / --exclude 传了非法 glob。
Implementations§
Trait Implementations§
impl Copy for Hint
impl Eq for Hint
impl StructuralPartialEq for Hint
Auto Trait Implementations§
impl Freeze for Hint
impl RefUnwindSafe for Hint
impl Send for Hint
impl Sync for Hint
impl Unpin for Hint
impl UnsafeUnpin for Hint
impl UnwindSafe for Hint
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> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.