fix(gcloud): add double space after cloud emoji symbol (#2666)

* fix(gcloud): add double space after cloud emoji symbol

* docs(gcloud): update docs
This commit is contained in:
Dario Vladović 2021-04-29 19:18:20 +02:00 committed by GitHub
parent 16855fe8e2
commit 8a8dca71a6
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 8 additions and 8 deletions

View File

@ -1040,7 +1040,7 @@ This is based on the `~/.config/gcloud/active_config` file and the `~/.config/gc
| Option | Default | Description |
| ---------------- | ---------------------------------------------- | --------------------------------------------------------------- |
| `format` | `'on [$symbol$account(\($region\))]($style) '` | The format for the module. |
| `symbol` | `"☁️ "` | The symbol used before displaying the current GCP profile. |
| `symbol` | `"☁️ "` | The symbol used before displaying the current GCP profile. |
| `region_aliases` | | Table of region aliases to display in addition to the GCP name. |
| `style` | `"bold blue"` | The style for the module. |
| `disabled` | `false` | Disables the `gcloud` module. |

View File

@ -16,7 +16,7 @@ impl<'a> Default for GcloudConfig<'a> {
fn default() -> Self {
GcloudConfig {
format: "on [$symbol$account(\\($region\\))]($style) ",
symbol: "☁️ ",
symbol: "☁️ ",
style: "bold blue",
disabled: false,
region_aliases: HashMap::new(),

View File

@ -177,7 +177,7 @@ account = foo@example.com
.collect();
let expected = Some(format!(
"on {} ",
Color::Blue.bold().paint("☁️ foo@example.com")
Color::Blue.bold().paint("☁️ foo@example.com")
));
assert_eq!(actual, expected);
@ -209,7 +209,7 @@ region = us-central1
.collect();
let expected = Some(format!(
"on {} ",
Color::Blue.bold().paint("☁️ foo@example.com(us-central1)")
Color::Blue.bold().paint("☁️ foo@example.com(us-central1)")
));
assert_eq!(actual, expected);
@ -245,7 +245,7 @@ region = us-central1
.collect();
let expected = Some(format!(
"on {} ",
Color::Blue.bold().paint("☁️ foo@example.com(uc1)")
Color::Blue.bold().paint("☁️ foo@example.com(uc1)")
));
assert_eq!(actual, expected);
@ -266,7 +266,7 @@ region = us-central1
format = "on [$symbol$active]($style) "
})
.collect();
let expected = Some(format!("on {} ", Color::Blue.bold().paint("☁️ default1")));
let expected = Some(format!("on {} ", Color::Blue.bold().paint("☁️ default1")));
assert_eq!(actual, expected);
dir.close()
@ -296,7 +296,7 @@ project = abc
format = "on [$symbol$project]($style) "
})
.collect();
let expected = Some(format!("on {} ", Color::Blue.bold().paint("☁️ abc")));
let expected = Some(format!("on {} ", Color::Blue.bold().paint("☁️ abc")));
assert_eq!(actual, expected);
dir.close()
@ -352,7 +352,7 @@ project = overridden
format = "on [$symbol$project]($style) "
})
.collect();
let expected = Some(format!("on {} ", Color::Blue.bold().paint("☁️ overridden")));
let expected = Some(format!("on {} ", Color::Blue.bold().paint("☁️ overridden")));
assert_eq!(actual, expected);
dir.close()