docs: canonicalize the use of quotes for default values (#4428)

* Fixed distortion of double and single quotes

* Run dprint fmt

* Use single quotes to avoid backslash escapes

* Update docs/config/README.md

Co-authored-by: David Knaack <davidkna@users.noreply.github.com>

Co-authored-by: David Knaack <davidkna@users.noreply.github.com>
This commit is contained in:
Masumi Kawasaki 2022-10-06 16:32:31 +09:00 committed by GitHub
parent 542cd3d633
commit 03c4165927
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 62 additions and 62 deletions

View File

@ -467,12 +467,12 @@ The default value for the `charging_symbol` and `discharging_symbol` option is r
The `display` option is an array of the following table.
| Option | Default | Description |
| -------------------- | ---------- | --------------------------------------------------------------------------------------------------------- |
| `threshold` | `10` | The upper bound for the display option. |
| `style` | `bold red` | The style used if the display option is in use. |
| `charging_symbol` | `-` | Optional symbol displayed if display option is in use, defaults to battery's `charging_symbol` option. |
| `discharging_symbol` | `-` | Optional symbol displayed if display option is in use, defaults to battery's `discharging_symbol` option. |
| Option | Default | Description |
| -------------------- | ------------ | --------------------------------------------------------------------------------------------------------- |
| `threshold` | `10` | The upper bound for the display option. |
| `style` | `"red bold"` | The style used if the display option is in use. |
| `charging_symbol` | | Optional symbol displayed if display option is in use, defaults to battery's `charging_symbol` option. |
| `discharging_symbol` | | Optional symbol displayed if display option is in use, defaults to battery's `discharging_symbol` option. |
#### Example
@ -846,12 +846,12 @@ The `container` module displays a symbol and container name, if inside a contain
### Options
| Option | Default | Description |
| ---------- | ---------------------------------- | ----------------------------------------- |
| `symbol` | `"⬢"` | The symbol shown, when inside a container |
| `style` | `"bold red dimmed"` | The style for the module. |
| `format` | `"[$symbol \\[$name\\]]($style) "` | The format for the module. |
| `disabled` | `false` | Disables the `container` module. |
| Option | Default | Description |
| ---------- | -------------------------------- | ----------------------------------------- |
| `symbol` | `"⬢"` | The symbol shown, when inside a container |
| `style` | `"bold red dimmed"` | The style for the module. |
| `format` | `'[$symbol \[$name\]]($style) '` | The format for the module. |
| `disabled` | `false` | Disables the `container` module. |
### Variables
@ -869,7 +869,7 @@ The `container` module displays a symbol and container name, if inside a contain
# ~/.config/starship.toml
[container]
format = "[$symbol \\[$name\\]]($style) "
format = '[$symbol \[$name\]]($style) '
```
## Crystal
@ -924,16 +924,16 @@ By default the module will be shown if any of the following conditions are met:
### Options
| Option | Default | Description |
| ------------------- | ---------------------------------- | ------------------------------------------------------------------------- |
| `format` | `via [$symbol($version )]($style)` | The format for the module. |
| `version_format` | `v${raw}` | The version format. Available vars are `raw`, `major`, `minor`, & `patch` |
| `symbol` | `"Λ "` | A format string representing the symbol of Daml |
| `style` | `"bold cyan"` | The style for the module. |
| `detect_extensions` | `[]` | Which extensions should trigger this module. |
| `detect_files` | `["daml.yaml"]` | Which filenames should trigger this module. |
| `detect_folders` | `[]` | Which folders should trigger this module. |
| `disabled` | `false` | Disables the `daml` module. |
| Option | Default | Description |
| ------------------- | ------------------------------------ | ------------------------------------------------------------------------- |
| `format` | `"via [$symbol($version )]($style)"` | The format for the module. |
| `version_format` | `"v${raw}"` | The version format. Available vars are `raw`, `major`, `minor`, & `patch` |
| `symbol` | `"Λ "` | A format string representing the symbol of Daml |
| `style` | `"bold cyan"` | The style for the module. |
| `detect_extensions` | `[]` | Which extensions should trigger this module. |
| `detect_files` | `["daml.yaml"]` | Which filenames should trigger this module. |
| `detect_folders` | `[]` | Which folders should trigger this module. |
| `disabled` | `false` | Disables the `daml` module. |
### Variables
@ -1058,7 +1058,7 @@ it would have been `nixpkgs/pkgs`.
| `read_only` | `"🔒"` | The symbol indicating current directory is read only. |
| `read_only_style` | `"red"` | The style for the read only symbol. |
| `truncation_symbol` | `""` | The symbol to prefix to truncated paths. eg: "…/" |
| `repo_root_style` | `None` | The style for the root of the git repo. The default value is equivalent to `style`. |
| `repo_root_style` | | The style for the root of the git repo. The default value is equivalent to `style`. |
| `repo_root_format` | `"[$before_root_path]($style)[$repo_root]($repo_root_style)[$path]($style)[$read_only]($read_only_style) "` | The format of a git repo when `repo_root_style` is defined. |
| `home_symbol` | `"~"` | The symbol indicating home directory. |
| `use_os_path_sep` | `true` | Use the OS specific path separator instead of always using `/` (e.g. `\` on Windows) |
@ -1570,16 +1570,16 @@ The `git_commit` module shows the current commit hash and also the tag (if any)
### Options
| Option | Default | Description |
| -------------------- | ------------------------------ | ------------------------------------------------------------------------------------ |
| `commit_hash_length` | `7` | The length of the displayed git commit hash. |
| `format` | `"[\\($hash$tag\\)]($style) "` | The format for the module. |
| `style` | `"bold green"` | The style for the module. |
| `only_detached` | `true` | Only show git commit hash when in detached `HEAD` state |
| `tag_disabled` | `true` | Disables showing tag info in `git_commit` module. |
| `tag_max_candidates` | `0` | How many commits to consider for tag display. The default only allows exact matches. |
| `tag_symbol` | `" 🏷 "` | Tag symbol prefixing the info shown |
| `disabled` | `false` | Disables the `git_commit` module. |
| Option | Default | Description |
| -------------------- | ---------------------------- | ------------------------------------------------------------------------------------ |
| `commit_hash_length` | `7` | The length of the displayed git commit hash. |
| `format` | `'[\($hash$tag\)]($style) '` | The format for the module. |
| `style` | `"bold green"` | The style for the module. |
| `only_detached` | `true` | Only show git commit hash when in detached `HEAD` state |
| `tag_disabled` | `true` | Disables showing tag info in `git_commit` module. |
| `tag_max_candidates` | `0` | How many commits to consider for tag display. The default only allows exact matches. |
| `tag_symbol` | `" 🏷 "` | Tag symbol prefixing the info shown |
| `disabled` | `false` | Disables the `git_commit` module. |
### Variables
@ -1662,7 +1662,7 @@ To enable it, set `disabled` to `false` in your configuration file.
| `added_style` | `"bold green"` | The style for the added count. |
| `deleted_style` | `"bold red"` | The style for the deleted count. |
| `only_nonzero_diffs` | `true` | Render status only for changed items. |
| `format` | `'([+$added]($added_style) )([-$deleted]($deleted_style) )'` | The format for the module. |
| `format` | `"([+$added]($added_style) )([-$deleted]($deleted_style) )"` | The format for the module. |
| `disabled` | `true` | Disables the `git_metrics` module. |
### Variables
@ -1683,7 +1683,7 @@ To enable it, set `disabled` to `false` in your configuration file.
[git_metrics]
added_style = "bold blue"
format = '[+$added]($added_style)/[-$deleted]($deleted_style) '
format = "[+$added]($added_style)/[-$deleted]($deleted_style) "
```
## Git Status
@ -1787,7 +1787,7 @@ Use Windows Starship executable on Windows paths in WSL
# ~/.config/starship.toml
[git_status]
windows_starship = '/mnt/c/Users/username/scoop/apps/starship/current/starship.exe'
windows_starship = "/mnt/c/Users/username/scoop/apps/starship/current/starship.exe"
```
## Go
@ -2604,12 +2604,12 @@ to fetch the current project in use.
### Options
| Option | Default | Description |
| ---------- | ----------------------------------------------- | -------------------------------------------------------------- |
| `format` | `"on [$symbol$cloud(\\($project\\))]($style) "` | The format for the module. |
| `symbol` | `"☁️ "` | The symbol used before displaying the current OpenStack cloud. |
| `style` | `"bold yellow"` | The style for the module. |
| `disabled` | `false` | Disables the `openstack` module. |
| Option | Default | Description |
| ---------- | --------------------------------------------- | -------------------------------------------------------------- |
| `format` | `'on [$symbol$cloud(\($project\))]($style) '` | The format for the module. |
| `symbol` | `"☁️ "` | The symbol used before displaying the current OpenStack cloud. |
| `style` | `"bold yellow"` | The style for the module. |
| `disabled` | `false` | Disables the `openstack` module. |
### Variables
@ -2628,7 +2628,7 @@ to fetch the current project in use.
# ~/.config/starship.toml
[openstack]
format = "on [$symbol$cloud(\\($project\\))]($style) "
format = 'on [$symbol$cloud(\($project\))]($style) '
style = "bold yellow"
symbol = "☁️ "
```
@ -3239,16 +3239,16 @@ To enable it, set `disabled` to `false` in your configuration file.
| Option | Default | Description |
| ---------------------- | ------------------------- | ------------------------------------------------------------ |
| `bash_indicator` | `bsh` | A format string used to represent bash. |
| `fish_indicator` | `fsh` | A format string used to represent fish. |
| `zsh_indicator` | `zsh` | A format string used to represent zsh. |
| `powershell_indicator` | `psh` | A format string used to represent powershell. |
| `ion_indicator` | `ion` | A format string used to represent ion. |
| `elvish_indicator` | `esh` | A format string used to represent elvish. |
| `tcsh_indicator` | `tsh` | A format string used to represent tcsh. |
| `xonsh_indicator` | `xsh` | A format string used to represent xonsh. |
| `cmd_indicator` | `cmd` | A format string used to represent cmd. |
| `nu_indicator` | `nu` | A format string used to represent nu. |
| `bash_indicator` | `"bsh"` | A format string used to represent bash. |
| `fish_indicator` | `"fsh"` | A format string used to represent fish. |
| `zsh_indicator` | `"zsh"` | A format string used to represent zsh. |
| `powershell_indicator` | `"psh"` | A format string used to represent powershell. |
| `ion_indicator` | `"ion"` | A format string used to represent ion. |
| `elvish_indicator` | `"esh"` | A format string used to represent elvish. |
| `tcsh_indicator` | `"tsh"` | A format string used to represent tcsh. |
| `xonsh_indicator` | `"xsh"` | A format string used to represent xonsh. |
| `cmd_indicator` | `"cmd"` | A format string used to represent cmd. |
| `nu_indicator` | `"nu"` | A format string used to represent nu. |
| `unknown_indicator` | | The default value to be displayed when the shell is unknown. |
| `format` | `"[$indicator]($style) "` | The format for the module. |
| `style` | `"white bold"` | The style for the module. |
@ -3408,7 +3408,7 @@ To enable it, set `disabled` to `false` in your configuration file.
| `map_symbol` | `false` | Enable symbols mapping from exit code |
| `pipestatus` | `false` | Enable pipestatus reporting |
| `pipestatus_separator` | <code>&vert;</code> | The symbol used to separate pipestatus segments |
| `pipestatus_format` | `\\[$pipestatus\\] => [$symbol$common_meaning$signal_name$maybe_int]($style)` | The format of the module when the command is a pipeline |
| `pipestatus_format` | `'\[$pipestatus\] => [$symbol$common_meaning$signal_name$maybe_int]($style)'` | The format of the module when the command is a pipeline |
| `pipestatus_segment_format` | | When specified, replaces `format` when formatting pipestatus segments |
| `disabled` | `true` | Disables the `status` module. |
@ -3457,13 +3457,13 @@ To enable it, set `disabled` to `false` in your configuration file.
### Options
| Option | Default | Description |
| --------------- | ----------------------- | ------------------------------------------------------- |
| `format` | `[as $symbol]($style)"` | The format of the module |
| `symbol` | `"🧙 "` | The symbol displayed when credentials are cached |
| `style` | `"bold blue"` | The style for the module. |
| `allow_windows` | `false` | Since windows has no default sudo, default is disabled. |
| `disabled` | `true` | Disables the `sudo` module. |
| Option | Default | Description |
| --------------- | ------------------------ | ------------------------------------------------------- |
| `format` | `"[as $symbol]($style)"` | The format of the module |
| `symbol` | `"🧙 "` | The symbol displayed when credentials are cached |
| `style` | `"bold blue"` | The style for the module. |
| `allow_windows` | `false` | Since windows has no default sudo, default is disabled. |
| `disabled` | `true` | Disables the `sudo` module. |
### Variables