2019-10-04 20:42:33 +08:00
|
|
|
use crate::config::{ModuleConfig, RootModuleConfig, SegmentConfig};
|
|
|
|
|
|
|
|
use ansi_term::{Color, Style};
|
|
|
|
use starship_module_config_derive::ModuleConfig;
|
|
|
|
|
|
|
|
#[derive(Clone, ModuleConfig)]
|
|
|
|
pub struct AwsConfig<'a> {
|
|
|
|
pub symbol: SegmentConfig<'a>,
|
|
|
|
pub profile: SegmentConfig<'a>,
|
|
|
|
pub style: Style,
|
|
|
|
pub disabled: bool,
|
|
|
|
}
|
|
|
|
|
|
|
|
impl<'a> RootModuleConfig<'a> for AwsConfig<'a> {
|
|
|
|
fn new() -> Self {
|
|
|
|
AwsConfig {
|
2019-10-06 03:46:14 +02:00
|
|
|
symbol: SegmentConfig::new("☁️ "),
|
|
|
|
profile: SegmentConfig::default(),
|
2019-10-04 20:42:33 +08:00
|
|
|
style: Color::Yellow.bold(),
|
|
|
|
disabled: false,
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|