summaryrefslogtreecommitdiffstats
path: root/src/configs/nodejs.rs
blob: 2867d535ad26d91c30761e8d8dd874ed0160cc6f (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
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",
        }
    }
}