mirror of
https://github.com/Llewellynvdm/starship.git
synced 2024-06-07 19:10:47 +00:00
89588a7391
* check node engines version in package.json * fix code, following review.
25 lines
606 B
Rust
25 lines
606 B
Rust
use crate::config::{ModuleConfig, RootModuleConfig};
|
|
|
|
use starship_module_config_derive::ModuleConfig;
|
|
|
|
#[derive(Clone, ModuleConfig)]
|
|
pub struct NodejsConfig<'a> {
|
|
pub format: &'a str,
|
|
pub symbol: &'a str,
|
|
pub style: &'a str,
|
|
pub disabled: bool,
|
|
pub not_capable_style: &'a str,
|
|
}
|
|
|
|
impl<'a> RootModuleConfig<'a> for NodejsConfig<'a> {
|
|
fn new() -> Self {
|
|
NodejsConfig {
|
|
format: "via [$symbol$version]($style) ",
|
|
symbol: "⬢ ",
|
|
style: "bold green",
|
|
disabled: false,
|
|
not_capable_style: "bold red",
|
|
}
|
|
}
|
|
}
|