docs(i18n): new Crowdin updates (#4355)

This commit is contained in:
Matan Kushner
2022-10-14 21:53:32 -04:00
committed by GitHub
parent dfc9cf6861
commit 74951e630e
89 changed files with 9214 additions and 2495 deletions
+2 -3
View File
@@ -55,11 +55,10 @@ description: Starship - минимальная, быстрая и бесконе
```sh
brew install starship
```
С [Scoop](https://scoop.sh):
With [Winget](https://github.com/microsoft/winget-cli):
```powershell
scoop install starship
winget install starship
```
1. Добавить сценарий инициализации в конфигурационный файл вашей оболочки:
+26
View File
@@ -54,6 +54,32 @@ end
load(io.popen('starship init cmd'):read("*a"))()
```
## TransientPrompt and TransientRightPrompt in Fish
It is possible to replace the previous-printed prompt with a custom string. This is useful in cases where all the prompt information is not always needed. To enable this, run `enable_transience` in the shell session. To make it permanent, put this statement in your `~/.config/fish/config.fish`. Transience can be disabled on-the-fly with `disable_transience`.
Note that in case of Fish, the transient prompt is only printed if the commandline is non-empty, and syntactically correct.
- By default, the left side of input gets replaced with a bold-green ``. To customize this, define a new function called `starship_transient_prompt_func`. For example, to display Starship's `character` module here, you would do
```fish
function starship_transient_prompt_func
starship module character
end
starship init fish | source
enable_transience
```
- By default, the right side of input is empty. To customize this, define a new function called `starship_transient_rprompt_func`. For example, to display the time at which the last command was started here, you would do
```fish
function starship_transient_rprompt_func
starship module time
end
starship init fish | source
enable_transience
```
## Custom pre-prompt and pre-execution Commands in Cmd
Clink provides extremely flexible APIs to run pre-prompt and pre-exec commands in Cmd shell. It is fairly simple to use with Starship. Make the following changes to your `starship.lua` file as per your requirements:
+169 -117
View File
@@ -162,13 +162,15 @@ detect_extensions = ["ts", "!video.ts", "!audio.ts"]
### Опции
| Параметр | По умолчанию | Описание |
| ----------------- | -------------------------------- | ---------------------------------------------------------------- |
| `format` | [ссылка](#default-prompt-format) | Настройка форматирования оболочки. |
| `right_format` | `""` | See [Enable Right Prompt](/advanced-config/#enable-right-prompt) |
| `scan_timeout` | `30` | Тайм-аут запуска сканирования файлов (в миллисекундах). |
| `command_timeout` | `500` | Timeout for commands executed by starship (in milliseconds). |
| `add_newline` | `true` | Inserts blank line between shell prompts. |
| Параметр | По умолчанию | Описание |
| ----------------- | -------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `format` | [ссылка](#default-prompt-format) | Настройка форматирования оболочки. |
| `right_format` | `""` | See [Enable Right Prompt](/advanced-config/#enable-right-prompt) |
| `scan_timeout` | `30` | Тайм-аут запуска сканирования файлов (в миллисекундах). |
| `command_timeout` | `500` | Timeout for commands executed by starship (in milliseconds). |
| `add_newline` | `true` | Inserts blank line between shell prompts. |
| `palette` | `""` | Sets which color palette from `palettes` to use. |
| `palettes` | `{}` | Collection of color palettes that assign [colors](/advanced-config/#style-strings) to user-defined names. Note that color palettes cannot reference their own color definitions. |
### Пример
@@ -186,6 +188,16 @@ scan_timeout = 10
# Disable the blank line at the start of the prompt
add_newline = false
# Set "foo" as custom color palette
palette = "foo"
# Define custom colors
[palettes.foo]
# Overwrite existing color
blue = "21"
# Define new color
mustard = "#af8700"
```
### Формат оболочки по умолчанию
@@ -252,6 +264,7 @@ $zig\
$buf\
$nix_shell\
$conda\
$meson\
$spack\
$memory_usage\
$aws\
@@ -434,9 +447,9 @@ The default value for the `charging_symbol` and `discharging_symbol` option is r
| Параметр | По умолчанию | Описание |
| -------------------- | ------------ | --------------------------------------------------------------------------------------------------------- |
| `threshold` | `10` | Верхняя граница опции отображения. |
| `style` | `bold red` | Используемый стиль, если используется опция отображения. |
| `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. |
| `style` | `"red bold"` | Используемый стиль, если используется опция отображения. |
| `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. |
#### Пример
@@ -462,24 +475,24 @@ The `buf` module shows the currently installed version of [Buf](https://buf.buil
### Опции
| Параметр | По умолчанию | Описание |
| ------------------- | ------------------------------------------------------------ | ----------------------------------------------------- |
| `format` | `'with [$symbol($version \(Buf $buf_version\) )]($style)'` | The format for the `buf` module. |
| `version_format` | `"v${raw}"` | The version format. |
| `symbol` | `"🦬 "` | The symbol used before displaying the version of Buf. |
| `detect_extensions` | `[]` | Which extensions should trigger this module. |
| `detect_files` | `["buf.yaml", "buf.gen.yaml", "buf.work.yaml"]` | Which filenames should trigger this module. |
| `detect_folders` | `[]` | Which folders should trigger this modules. |
| `style` | `"bold blue"` | Стиль модуля. |
| `disabled` | `false` | Отключает модуль `elixir`. |
| Параметр | По умолчанию | Описание |
| ------------------- | ----------------------------------------------- | ----------------------------------------------------- |
| `format` | `"with [$symbol($version )]($style)"` | The format for the `buf` module. |
| `version_format` | `"v${raw}"` | The version format. |
| `symbol` | `"🦬 "` | The symbol used before displaying the version of Buf. |
| `detect_extensions` | `[]` | Which extensions should trigger this module. |
| `detect_files` | `["buf.yaml", "buf.gen.yaml", "buf.work.yaml"]` | Which filenames should trigger this module. |
| `detect_folders` | `[]` | Which folders should trigger this modules. |
| `style` | `"bold blue"` | Стиль модуля. |
| `disabled` | `false` | Отключает модуль `elixir`. |
### Переменные
| Переменная | Пример | Описание |
| ------------- | -------- | ------------------------------------ |
| `buf_version` | `v1.0.0` | The version of `buf` |
| `symbol` | | Отражает значение параметра `symbol` |
| `style`* | | Отражает значение параметра `style` |
| Переменная | Пример | Описание |
| ---------- | -------- | ------------------------------------ |
| `version` | `v1.0.0` | The version of `buf` |
| `symbol` | | Отражает значение параметра `symbol` |
| `style`* | | Отражает значение параметра `style` |
*: Эта переменная может использоваться только в качестве части строки style
@@ -609,9 +622,9 @@ By default it only changes color. If you also want to change its shape take a lo
### Переменные
| Переменная | Пример | Описание |
| ---------- | ------ | --------------------------------------------------------------------- |
| symbol | | A mirror of either `success_symbol`, `error_symbol` or `vicmd_symbol` |
| Переменная | Пример | Описание |
| ---------- | ------ | -------------------------------------------------------------------------------------------------------- |
| symbol | | A mirror of either `success_symbol`, `error_symbol`, `vimcmd_symbol` or `vimcmd_replace_one_symbol` etc. |
### Примеры
@@ -794,12 +807,12 @@ The `container` module displays a symbol and container name, if inside a contain
### Опции
| Параметр | По умолчанию | Описание |
| ---------- | -------------------------------------- | ----------------------------------------- |
| `symbol` | `"⬢"` | The symbol shown, when inside a container |
| `style` | `"bold red dimmed"` | Стиль модуля. |
| `format` | `"[$symbol \\[$name\\]]($style) "` | Формат модуля. |
| `disabled` | `false` | Disables the `container` module. |
| Параметр | По умолчанию | Описание |
| ---------- | ---------------------------------- | ----------------------------------------- |
| `symbol` | `"⬢"` | The symbol shown, when inside a container |
| `style` | `"bold red dimmed"` | Стиль модуля. |
| `format` | `'[$symbol \[$name\]]($style) '` | Формат модуля. |
| `disabled` | `false` | Disables the `container` module. |
### Переменные
@@ -817,7 +830,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
@@ -867,16 +880,16 @@ The `daml` module shows the currently used [Daml](https://www.digitalasset.com/d
### Опции
| Параметр | По умолчанию | Описание |
| ------------------- | ---------------------------------- | ------------------------------------------------------------------------- |
| `format` | `via [$symbol($version )]($style)` | Формат модуля. |
| `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"` | Стиль модуля. |
| `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. |
| Параметр | По умолчанию | Описание |
| ------------------- | ------------------------------------ | ------------------------------------------------------------------------- |
| `format` | `"via [$symbol($version )]($style)"` | Формат модуля. |
| `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"` | Стиль модуля. |
| `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. |
### Переменные
@@ -993,7 +1006,7 @@ format = "via [🦕 $version](green bold) "
| `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) |
@@ -1480,16 +1493,16 @@ The `git_commit` module shows the current commit hash and also the tag (if any)
### Опции
| Параметр | По умолчанию | Описание |
| -------------------- | ---------------------------------- | ------------------------------------------------------------------------------------ |
| `commit_hash_length` | `7` | Длина отображаемого хэша коммита git. |
| `format` | `"[\\($hash$tag\\)]($style) "` | Формат модуля. |
| `style` | `"bold green"` | Стиль модуля. |
| `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` | Отключает модуль `git_commit`. |
| Параметр | По умолчанию | Описание |
| -------------------- | ------------------------------ | ------------------------------------------------------------------------------------ |
| `commit_hash_length` | `7` | Длина отображаемого хэша коммита git. |
| `format` | `'[\($hash$tag\)]($style) '` | Формат модуля. |
| `style` | `"bold green"` | Стиль модуля. |
| `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` | Отключает модуль `git_commit`. |
### Переменные
@@ -1567,7 +1580,7 @@ The `git_metrics` module will show the number of added and deleted lines in the
| `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) )'` | Формат модуля. |
| `format` | `"([+$added]($added_style) )([-$deleted]($deleted_style) )"` | Формат модуля. |
| `disabled` | `true` | Disables the `git_metrics` module. |
### Переменные
@@ -1588,7 +1601,7 @@ The `git_metrics` module will show the number of added and deleted lines in the
[git_metrics]
added_style = "bold blue"
format = '[+$added]($added_style)/[-$deleted]($deleted_style) '
format = "[+$added]($added_style)/[-$deleted]($deleted_style) "
```
## Статус Git
@@ -1690,7 +1703,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
@@ -1852,21 +1865,21 @@ disabled = false
The `java` module shows the currently installed version of [Java](https://www.oracle.com/java/). By default the module will be shown if any of the following conditions are met:
- The current directory contains a `pom.xml`, `build.gradle.kts`, `build.sbt`, `.java-version`, `.deps.edn`, `project.clj`, or `build.boot` file
- The current directory contains a `pom.xml`, `build.gradle.kts`, `build.sbt`, `.java-version`, `deps.edn`, `project.clj`, or `build.boot` file
- The current directory contains a file with the `.java`, `.class`, `.gradle`, `.jar`, `.clj`, or `.cljc` extension
### Опции
| Параметр | По умолчанию | Описание |
| ------------------- | --------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------- |
| `format` | `"via [${symbol}(${version} )]($style)"` | Формат модуля. |
| `version_format` | `"v${raw}"` | The version format. Available vars are `raw`, `major`, `minor`, & `patch` |
| `detect_extensions` | `["java", "class", "gradle", "jar", "cljs", "cljc"]` | Which extensions should trigger this module. |
| `detect_files` | `["pom.xml", "build.gradle.kts", "build.sbt", ".java-version", ".deps.edn", "project.clj", "build.boot"]` | Which filenames should trigger this module. |
| `detect_folders` | `[]` | Which folders should trigger this modules. |
| `symbol` | `"☕ "` | A format string representing the symbol of Java |
| `style` | `"red dimmed"` | Стиль модуля. |
| `disabled` | `false` | Отключает модуль `java`. |
| Параметр | По умолчанию | Описание |
| ------------------- | -------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------- |
| `format` | `"via [${symbol}(${version} )]($style)"` | Формат модуля. |
| `version_format` | `"v${raw}"` | The version format. Available vars are `raw`, `major`, `minor`, & `patch` |
| `detect_extensions` | `["java", "class", "gradle", "jar", "cljs", "cljc"]` | Which extensions should trigger this module. |
| `detect_files` | `["pom.xml", "build.gradle.kts", "build.sbt", ".java-version", "deps.edn", "project.clj", "build.boot"]` | Which filenames should trigger this module. |
| `detect_folders` | `[]` | Which folders should trigger this modules. |
| `symbol` | `"☕ "` | A format string representing the symbol of Java |
| `style` | `"red dimmed"` | Стиль модуля. |
| `disabled` | `false` | Отключает модуль `java`. |
### Переменные
@@ -2258,15 +2271,54 @@ symbol = " "
style = "bold dimmed green"
```
## Ветка Mercurial
## Meson
Модуль `hg_branch` показывает активную ветку репозитория в вашем текущем каталоге.
The `meson` module shows the current Meson developer environment status.
By default the Meson project name is displayed, if `$MESON_DEVENV` is set.
### Опции
| Параметр | По умолчанию | Описание |
| ------------------- | ---------------------------------- | ----------------------------------------------------------------------------------------- |
| `truncation_length` | `2^32 - 1` | Truncates a project name to `N` graphemes. |
| `truncation_symbol` | `"…"` | The symbol used to indicate a project name was truncated. You can use `""` for no symbol. |
| `format` | `"via [$symbol$project]($style) "` | Формат модуля. |
| `symbol` | `"⬢ "` | The symbol used before displaying the project name. |
| `style` | `"blue bold"` | Стиль модуля. |
| `disabled` | `false` | Disables the `meson` module. |
### Переменные
| Переменная | Пример | Описание |
| ---------- | ---------- | ------------------------------------ |
| project | `starship` | The current Meson project name |
| symbol | `🐏` | Отражает значение параметра `symbol` |
| style\* | | Отражает значение параметра `style` |
*: Эта переменная может использоваться только в качестве части строки style
### Пример
```toml
# ~/.config/starship.toml
[meson]
disabled = false
truncation_symbol = "--"
symbol = " "
style = "bold dimmed green"
```
## Ветвь Mercurial
Модуль `hg_branch` показывает активную ветку репозитория в вашей текущей директории.
### Опции
| Параметр | По умолчанию | Описание |
| ------------------- | -------------------------------- | ---------------------------------------------------------------------------------------- |
| `symbol` | `" "` | Символ, используемый перед закладкой hg или именем ветки репозитория в текущем каталоге. |
| `symbol` | `" "` | Символ, используемый перед закладкой hg или именем ветви репозитория в текущем каталоге. |
| `style` | `"bold purple"` | Стиль модуля. |
| `format` | `"on [$symbol$branch]($style) "` | Формат модуля. |
| `truncation_length` | `2^63 - 1` | Truncates the hg branch name to `N` graphemes |
@@ -2471,12 +2523,12 @@ The `openstack` module shows the current OpenStack cloud and project. The module
### Опции
| Параметр | По умолчанию | Описание |
| ---------- | --------------------------------------------------- | -------------------------------------------------------------- |
| `format` | `"on [$symbol$cloud(\\($project\\))]($style) "` | Формат модуля. |
| `symbol` | `"☁️ "` | The symbol used before displaying the current OpenStack cloud. |
| `style` | `"bold yellow"` | Стиль модуля. |
| `disabled` | `false` | Disables the `openstack` module. |
| Параметр | По умолчанию | Описание |
| ---------- | ----------------------------------------------- | -------------------------------------------------------------- |
| `format` | `'on [$symbol$cloud(\($project\))]($style) '` | Формат модуля. |
| `symbol` | `"☁️ "` | The symbol used before displaying the current OpenStack cloud. |
| `style` | `"bold yellow"` | Стиль модуля. |
| `disabled` | `false` | Disables the `openstack` module. |
### Переменные
@@ -2495,7 +2547,7 @@ The `openstack` module shows the current OpenStack cloud and project. The module
# ~/.config/starship.toml
[openstack]
format = "on [$symbol$cloud(\\($project\\))]($style) "
format = 'on [$symbol$cloud(\($project\))]($style) '
style = "bold yellow"
symbol = "☁️ "
```
@@ -3077,16 +3129,16 @@ The `shell` module shows an indicator for currently used shell.
| Параметр | По умолчанию | Описание |
| ---------------------- | ------------------------- | ------------------------------------------------------------ |
| `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) "` | Формат модуля. |
| `style` | `"white bold"` | Стиль модуля. |
@@ -3227,23 +3279,23 @@ The `status` module displays the exit code of the previous command. If $success_
### Опции
| Параметр | По умолчанию | Описание |
| --------------------------- | ------------------------------------------------------------------------------------ | --------------------------------------------------------------------- |
| `format` | `"[$symbol$status]($style) "` | The format of the module |
| `symbol` | `"✖"` | The symbol displayed on program error |
| `success_symbol` | `""` | The symbol displayed on program success |
| `not_executable_symbol` | `"🚫"` | The symbol displayed when file isn't executable |
| `not_found_symbol` | `"🔍"` | The symbol displayed when the command can't be found |
| `sigint_symbol` | `"🧱"` | The symbol displayed on SIGINT (Ctrl + c) |
| `signal_symbol` | `"⚡"` | The symbol displayed on any signal |
| `style` | `"bold red"` | Стиль модуля. |
| `recognize_signal_code` | `true` | Enable signal mapping from exit code |
| `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_segment_format` | | When specified, replaces `format` when formatting pipestatus segments |
| `disabled` | `true` | Disables the `status` module. |
| Параметр | По умолчанию | Описание |
| --------------------------- | ---------------------------------------------------------------------------------- | --------------------------------------------------------------------- |
| `format` | `"[$symbol$status]($style) "` | The format of the module |
| `symbol` | `"✖"` | The symbol displayed on program error |
| `success_symbol` | `""` | The symbol displayed on program success |
| `not_executable_symbol` | `"🚫"` | The symbol displayed when file isn't executable |
| `not_found_symbol` | `"🔍"` | The symbol displayed when the command can't be found |
| `sigint_symbol` | `"🧱"` | The symbol displayed on SIGINT (Ctrl + c) |
| `signal_symbol` | `"⚡"` | The symbol displayed on any signal |
| `style` | `"bold red"` | Стиль модуля. |
| `recognize_signal_code` | `true` | Enable signal mapping from exit code |
| `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 (supports formatting) |
| `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. |
### Переменные
@@ -3288,13 +3340,13 @@ The `sudo` module displays if sudo credentials are currently cached. The module
### Опции
| Параметр | По умолчанию | Описание |
| --------------- | ----------------------- | ------------------------------------------------------- |
| `format` | `[as $symbol]($style)"` | The format of the module |
| `symbol` | `"🧙 "` | The symbol displayed when credentials are cached |
| `style` | `"bold blue"` | Стиль модуля. |
| `allow_windows` | `false` | Since windows has no default sudo, default is disabled. |
| `disabled` | `true` | Disables the `sudo` module. |
| Параметр | По умолчанию | Описание |
| --------------- | ------------------------ | ------------------------------------------------------- |
| `format` | `"[as $symbol]($style)"` | The format of the module |
| `symbol` | `"🧙 "` | The symbol displayed when credentials are cached |
| `style` | `"bold blue"` | Стиль модуля. |
| `allow_windows` | `false` | Since windows has no default sudo, default is disabled. |
| `disabled` | `true` | Disables the `sudo` module. |
### Переменные
@@ -3445,7 +3497,7 @@ format = "[🏎💨 $workspace]($style) "
| `disabled` | `true` | Отключает модуль `time`. |
| `time_range` | `"-"` | Sets the time range during which the module will be shown. Times must be specified in 24-hours format |
If `use_12hr` is `true`, then `time_format` defaults to `"%r"`. Иначе по умолчанию используется `"%T"`. Manually setting `time_format` will override the `use_12hr` setting.
If `use_12hr` is `true`, then `time_format` defaults to `"%r"`. Иначе, принимается значение `"%T"`. Manually setting `time_format` will override the `use_12hr` setting.
### Переменные
@@ -3471,7 +3523,7 @@ time_range = "10:00:00-14:00:00"
## Имя пользователя
Модуль `username` показывает имя активного пользователя. Модуль будет показан, если любое из следующих условий соблюдено:
Модуль `username` показывает имя текущего пользователя. Модуль будет показан, если любое из следующих условий соблюдено:
- The current user is root/admin
- Текущий пользователь отличается от залогиненного
@@ -3762,7 +3814,7 @@ Automatic detection of shells and proper parameters addition are currently imple
[custom.foo]
command = "echo foo" # shows output of command
detect_files = ["foo"] # can specify filters but wildcards are not supported
when = """ test "$HOME" == "$PWD" """
when = """ test "$HOME" = "$PWD" """
format = " transcending [$output]($style)"
[custom.time]
-1
View File
@@ -220,7 +220,6 @@ Alternatively, install Starship using any of the following package managers:
| Arch Linux | [Arch Linux Community](https://archlinux.org/packages/community/x86_64/starship) | `pacman -S starship` |
| CentOS 7+ | [Copr](https://copr.fedorainfracloud.org/coprs/atim/starship) | `dnf copr enable atim/starship` <br /> `dnf install starship` |
| Fedora 31+ | [Fedora Packages](https://src.fedoraproject.org/rpms/rust-starship) | `dnf install starship` |
| NixOS | [nixpkgs](https://github.com/NixOS/nixpkgs/blob/master/pkgs/tools/misc/starship/default.nix) | `nix-env -iA nixos.starship` |
| Gentoo | [Gentoo Packages](https://packages.gentoo.org/packages/app-shells/starship) | `emerge app-shells/starship` |
| Manjaro | | `pacman -S starship` |
| NixOS | [nixpkgs](https://github.com/NixOS/nixpkgs/blob/master/pkgs/tools/misc/starship/default.nix) | `nix-env -iA nixpkgs.starship` |