mirror of
https://github.com/starship/starship.git
synced 2026-06-22 02:02:12 +07:00
docs(i18n): new Crowdin updates (#4719)
This commit is contained in:
@@ -149,14 +149,14 @@ description: Starship 是適合任何 shell 的最小、極速、高度客製化
|
||||
|
||||
::: warning
|
||||
|
||||
This will change in the future. Only Nushell v0.61+ is supported.
|
||||
This will change in the future. Only Nushell v0.73+ is supported.
|
||||
|
||||
:::
|
||||
|
||||
Add the following to to the end of your Nushell env file (find it by running `$nu.env-path` in Nushell):
|
||||
Add the following to the end of your Nushell env file (find it by running `$nu.env-path` in Nushell):
|
||||
```sh
|
||||
mkdir ~/.cache/starship
|
||||
starship init nu | save ~/.cache/starship/init.nu
|
||||
starship init nu | save -f ~/.cache/starship/init.nu
|
||||
```
|
||||
|
||||
And add the following to the end of your Nushell configuration (find it by running `$nu.config-path`):
|
||||
|
||||
@@ -207,8 +207,6 @@ Note: The right prompt is a single line following the input location. To right a
|
||||
|
||||
`right_format` is currently supported for the following shells: elvish, fish, zsh, xonsh, cmd, nushell.
|
||||
|
||||
Note: Nushell 0.71.0 or later is required
|
||||
|
||||
### 範例
|
||||
|
||||
```toml
|
||||
@@ -231,7 +229,7 @@ Produces a prompt like the following:
|
||||
|
||||
Some shells support a continuation prompt along with the normal prompt. This prompt is rendered instead of the normal prompt when the user has entered an incomplete statement (such as a single left parenthesis or quote).
|
||||
|
||||
Starship can set the continuation prompt using the `continuation_prompt` option. The default prompt is `"[∙](bright-black) "`.
|
||||
Starship can set the continuation prompt using the `continuation_prompt` option. The default prompt is `'[∙](bright-black) '`.
|
||||
|
||||
Note: `continuation_prompt` should be set to a literal string without any variables.
|
||||
|
||||
@@ -247,7 +245,7 @@ Note: Continuation prompts are only available in the following shells:
|
||||
# ~/.config/starship.toml
|
||||
|
||||
# A continuation prompt that displays two filled in arrows
|
||||
continuation_prompt = "▶▶"
|
||||
continuation_prompt = '▶▶ '
|
||||
```
|
||||
|
||||
## 風格字串
|
||||
|
||||
+264
-124
@@ -252,12 +252,14 @@ $singularity\
|
||||
$kubernetes\
|
||||
$directory\
|
||||
$vcsh\
|
||||
$fossil_branch\
|
||||
$git_branch\
|
||||
$git_commit\
|
||||
$git_state\
|
||||
$git_metrics\
|
||||
$git_status\
|
||||
$hg_branch\
|
||||
$pijul_channel\
|
||||
$docker_context\
|
||||
$package\
|
||||
$c\
|
||||
@@ -270,6 +272,7 @@ $dotnet\
|
||||
$elixir\
|
||||
$elm\
|
||||
$erlang\
|
||||
$fennel\
|
||||
$golang\
|
||||
$guix_shell\
|
||||
$haskell\
|
||||
@@ -278,6 +281,7 @@ $helm\
|
||||
$java\
|
||||
$julia\
|
||||
$kotlin\
|
||||
$gradle\
|
||||
$lua\
|
||||
$nim\
|
||||
$nodejs\
|
||||
@@ -1305,6 +1309,12 @@ The `env_var` module displays the current value of a selected environment variab
|
||||
|
||||
::: tip
|
||||
|
||||
The order in which env_var modules are shown can be individually set by including `${env_var.foo}` in the top level `format` (as it includes a dot, you need to use `${...}`). By default, the `env_var` module will simply show all env_var modules in the order they were defined.
|
||||
|
||||
:::
|
||||
|
||||
::: tip
|
||||
|
||||
Multiple environmental variables can be displayed by using a `.`. (see example) If the `variable` configuration option is not set, the module will display value of variable under the name of text after the `.` character.
|
||||
|
||||
Example: following configuration will display value of USER environment variable
|
||||
@@ -1320,13 +1330,14 @@ default = 'unknown user'
|
||||
|
||||
### 選項
|
||||
|
||||
| Option | 預設 | 說明 |
|
||||
| ---------- | ------------------------------ | -------------------------- |
|
||||
| `symbol` | `''` | 顯示在變數數值之前的符號。 |
|
||||
| `variable` | | 要顯示的環境變數。 |
|
||||
| `default` | | 在選擇的變數值沒有定義時,顯示的預設值。 |
|
||||
| `format` | `'with [$env_value]($style) '` | The format for the module. |
|
||||
| `disabled` | `false` | 停用 `env_var` 模組。 |
|
||||
| Option | 預設 | 說明 |
|
||||
| ------------- | ------------------------------ | ---------------------------------------------------------------------------- |
|
||||
| `symbol` | `""` | 顯示在變數數值之前的符號。 |
|
||||
| `variable` | | 要顯示的環境變數。 |
|
||||
| `default` | | 在選擇的變數值沒有定義時,顯示的預設值。 |
|
||||
| `format` | `"with [$env_value]($style) "` | The format for the module. |
|
||||
| `description` | `"<env_var module>"` | The description of the module that is shown when running `starship explain`. |
|
||||
| `disabled` | `false` | 停用 `env_var` 模組。 |
|
||||
|
||||
### Variables
|
||||
|
||||
@@ -1399,6 +1410,44 @@ The `erlang` module shows the currently installed version of [Erlang/OTP](https:
|
||||
format = 'via [e $version](bold red) '
|
||||
```
|
||||
|
||||
## Fennel
|
||||
|
||||
The `fennel` module shows the currently installed version of [Fennel](https://fennel-lang.org). By default the module will be shown if any of the following conditions are met:
|
||||
|
||||
- The current directory contains a file with the `.fnl` extension
|
||||
|
||||
### 選項
|
||||
|
||||
| Option | 預設 | 說明 |
|
||||
| ------------------- | ------------------------------------ | ------------------------------------------------------------------------- |
|
||||
| `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` | `'🧅 '` | The symbol used before displaying the version of fennel. |
|
||||
| `style` | `'bold green'` | 這個模組的風格。 |
|
||||
| `detect_extensions` | `[fnl]` | Which extensions should trigger this module. |
|
||||
| `detect_files` | `[]` | Which filenames should trigger this module. |
|
||||
| `detect_folders` | `[]` | Which folders should trigger this modules. |
|
||||
| `disabled` | `false` | Disables the `fennel` module. |
|
||||
|
||||
### Variables
|
||||
|
||||
| 變數 | 範例 | 說明 |
|
||||
| --------- | -------- | ------------------------------------ |
|
||||
| version | `v1.2.1` | The version of `fennel` |
|
||||
| symbol | | Mirrors the value of option `symbol` |
|
||||
| style\* | | Mirrors the value of option `style` |
|
||||
|
||||
*: This variable can only be used as a part of a style string
|
||||
|
||||
### 範例
|
||||
|
||||
```toml
|
||||
# ~/.config/starship.toml
|
||||
|
||||
[fennel]
|
||||
symbol = '⫰ '
|
||||
```
|
||||
|
||||
## Fill
|
||||
|
||||
The `fill` module fills any extra space on the line with a symbol. If multiple `fill` modules are present in a line they will split the space evenly between them. This is useful for aligning other modules.
|
||||
@@ -1428,6 +1477,42 @@ Produces a prompt that looks like:
|
||||
AA -------------------------------------------- BB -------------------------------------------- CC
|
||||
```
|
||||
|
||||
## Fossil Branch
|
||||
|
||||
The `fossil_branch` module shows the name of the active branch of the check-out in your current directory.
|
||||
|
||||
### 選項
|
||||
|
||||
| Option | 預設 | 說明 |
|
||||
| ------------------- | -------------------------------- | ---------------------------------------------------------------------------------------- |
|
||||
| `format` | `'on [$symbol$branch]($style) '` | The format for the module. Use `'$branch'` to refer to the current branch name. |
|
||||
| `symbol` | `' '` | The symbol used before the branch name of the check-out in your current directory. |
|
||||
| `style` | `'bold purple'` | 這個模組的風格。 |
|
||||
| `truncation_length` | `2^63 - 1` | Truncates a Fossil branch name to `N` graphemes |
|
||||
| `truncation_symbol` | `'…'` | The symbol used to indicate a branch name was truncated. You can use `''` for no symbol. |
|
||||
| `disabled` | `true` | Disables the `fossil_branch` module. |
|
||||
|
||||
### Variables
|
||||
|
||||
| 變數 | 範例 | 說明 |
|
||||
| --------- | ------- | ------------------------------------ |
|
||||
| branch | `trunk` | The active Fossil branch |
|
||||
| symbol | | Mirrors the value of option `symbol` |
|
||||
| style\* | | Mirrors the value of option `style` |
|
||||
|
||||
*: This variable can only be used as a part of a style string
|
||||
|
||||
### 範例
|
||||
|
||||
```toml
|
||||
# ~/.config/starship.toml
|
||||
|
||||
[fossil_branch]
|
||||
symbol = '🦎 '
|
||||
truncation_length = 4
|
||||
truncation_symbol = ''
|
||||
```
|
||||
|
||||
## Google Cloud (`gcloud`)
|
||||
|
||||
The `gcloud` module shows the current configuration for [`gcloud`](https://cloud.google.com/sdk/gcloud) CLI. This is based on the `~/.config/gcloud/active_config` file and the `~/.config/gcloud/configurations/config_{CONFIG NAME}` file and the `CLOUDSDK_CONFIG` env var.
|
||||
@@ -1501,23 +1586,23 @@ format = 'on [$symbol$account(@$domain)(\($project\))]($style) '
|
||||
very-long-project-name = 'vlpn'
|
||||
```
|
||||
|
||||
## Git 分支
|
||||
## Git Branch
|
||||
|
||||
`git_branch` 模組顯示現在的資料夾中使用中的儲存庫的分支。
|
||||
The `git_branch` module shows the active branch of the repo in your current directory.
|
||||
|
||||
### 選項
|
||||
|
||||
| Option | 預設 | 說明 |
|
||||
| -------------------- | ------------------------------------------------- | ------------------------------------------------------------------------------------ |
|
||||
| `always_show_remote` | `false` | Shows the remote tracking branch name, even if it is equal to the local branch name. |
|
||||
| `format` | `'on [$symbol$branch(:$remote_branch)]($style) '` | The format for the module. Use `'$branch'` to refer to the current branch name. |
|
||||
| `symbol` | `' '` | A format string representing the symbol of git branch. |
|
||||
| `style` | `'bold purple'` | 這個模組的風格。 |
|
||||
| `truncation_length` | `2^63 - 1` | Truncates a git branch to `N` graphemes. |
|
||||
| `truncation_symbol` | `'…'` | 用來指示分支名稱被縮減的符號。 You can use `''` for no symbol. |
|
||||
| `only_attached` | `false` | Only show the branch name when not in a detached `HEAD` state. |
|
||||
| `ignore_branches` | `[]` | A list of names to avoid displaying. Useful for 'master' or 'main'. |
|
||||
| `disabled` | `false` | 停用 `git_branch` 模組。 |
|
||||
| Option | 預設 | 說明 |
|
||||
| -------------------- | ------------------------------------------------- | ---------------------------------------------------------------------------------------- |
|
||||
| `always_show_remote` | `false` | Shows the remote tracking branch name, even if it is equal to the local branch name. |
|
||||
| `format` | `'on [$symbol$branch(:$remote_branch)]($style) '` | The format for the module. Use `'$branch'` to refer to the current branch name. |
|
||||
| `symbol` | `' '` | A format string representing the symbol of git branch. |
|
||||
| `style` | `'bold purple'` | 這個模組的風格。 |
|
||||
| `truncation_length` | `2^63 - 1` | Truncates a git branch to `N` graphemes. |
|
||||
| `truncation_symbol` | `'…'` | The symbol used to indicate a branch name was truncated. You can use `''` for no symbol. |
|
||||
| `only_attached` | `false` | Only show the branch name when not in a detached `HEAD` state. |
|
||||
| `ignore_branches` | `[]` | A list of names to avoid displaying. Useful for 'master' or 'main'. |
|
||||
| `disabled` | `false` | Disables the `git_branch` module. |
|
||||
|
||||
### Variables
|
||||
|
||||
@@ -1562,10 +1647,11 @@ The `git_commit` module shows the current commit hash and also the tag (if any)
|
||||
|
||||
### Variables
|
||||
|
||||
| 變數 | 範例 | 說明 |
|
||||
| --------- | --------- | ----------------------------------- |
|
||||
| hash | `b703eb3` | The current git commit hash |
|
||||
| style\* | | Mirrors the value of option `style` |
|
||||
| 變數 | 範例 | 說明 |
|
||||
| --------- | --------- | -------------------------------------------- |
|
||||
| hash | `b703eb3` | The current git commit hash |
|
||||
| tag | `v1.0.0` | The tag name if showing tag info is enabled. |
|
||||
| style\* | | Mirrors the value of option `style` |
|
||||
|
||||
*: This variable can only be used as a part of a style string
|
||||
|
||||
@@ -1581,7 +1667,7 @@ tag_symbol = '🔖 '
|
||||
|
||||
## Git State
|
||||
|
||||
`git_state` 模組會顯示在 git 儲存庫中的資料夾內,以及會在有作業正在進行時顯示,像是:_REBASING_、_BISECTING_ 等等。 如果有進展的資訊 (像是 REBASING 3/10),也會一併顯示出來。
|
||||
The `git_state` module will show in directories which are part of a git repository, and where there is an operation in progress, such as: _REBASING_, _BISECTING_, etc. If there is progress information (e.g., REBASING 3/10), that information will be shown too.
|
||||
|
||||
### 選項
|
||||
|
||||
@@ -1596,7 +1682,7 @@ tag_symbol = '🔖 '
|
||||
| `am_or_rebase` | `'AM/REBASE'` | A format string displayed when an ambiguous `apply-mailbox` or `rebase` is in progress. |
|
||||
| `style` | `'bold yellow'` | 這個模組的風格。 |
|
||||
| `format` | `'\([$state( $progress_current/$progress_total)]($style)\) '` | The format for the module. |
|
||||
| `disabled` | `false` | 停用 `git_state` 模組。 |
|
||||
| `disabled` | `false` | Disables the `git_state` module. |
|
||||
|
||||
### Variables
|
||||
|
||||
@@ -1625,7 +1711,7 @@ The `git_metrics` module will show the number of added and deleted lines in the
|
||||
|
||||
::: tip
|
||||
|
||||
這個模組預設是停用的。 想要啟用它的話,請在設定檔中將 `disabled` 設定為 `false`。
|
||||
This module is disabled by default. To enable it, set `disabled` to `false` in your configuration file.
|
||||
|
||||
:::
|
||||
|
||||
@@ -1662,7 +1748,7 @@ format = '[+$added]($added_style)/[-$deleted]($deleted_style) '
|
||||
|
||||
## Git Status
|
||||
|
||||
`git_status` 模組顯示用來表示現在資料夾之中儲存庫狀態的符號。
|
||||
The `git_status` module shows symbols representing the state of the repo in your current directory.
|
||||
|
||||
::: tip
|
||||
|
||||
@@ -1675,7 +1761,7 @@ The Git Status module is very slow in Windows directories (for example under `/m
|
||||
| Option | 預設 | 說明 |
|
||||
| ------------------- | ----------------------------------------------- | ----------------------------------------------------------------------------------------------------------- |
|
||||
| `format` | `'([\[$all_status$ahead_behind\]]($style) )'` | The default format for `git_status` |
|
||||
| `conflicted` | `'='` | 這個分支有合併衝突。 |
|
||||
| `conflicted` | `'='` | This branch has merge conflicts. |
|
||||
| `ahead` | `'⇡'` | The format of `ahead` |
|
||||
| `behind` | `'⇣'` | The format of `behind` |
|
||||
| `diverged` | `'⇕'` | The format of `diverged` |
|
||||
@@ -1688,7 +1774,7 @@ The Git Status module is very slow in Windows directories (for example under `/m
|
||||
| `deleted` | `'✘'` | The format of `deleted` |
|
||||
| `style` | `'bold red'` | 這個模組的風格。 |
|
||||
| `ignore_submodules` | `false` | Ignore changes to submodules. |
|
||||
| `disabled` | `false` | 停用 `git_status` 模組。 |
|
||||
| `disabled` | `false` | Disables the `git_status` module. |
|
||||
| `windows_starship` | | Use this (Linux) path to a Windows Starship executable to render `git_status` when on Windows paths in WSL. |
|
||||
|
||||
### Variables
|
||||
@@ -1787,7 +1873,7 @@ The `golang` module shows the currently installed version of [Go](https://golang
|
||||
| `detect_files` | `['go.mod', 'go.sum', 'go.work', 'glide.yaml', 'Gopkg.yml', 'Gopkg.lock', '.go-version']` | Which filenames should trigger this module. |
|
||||
| `detect_folders` | `['Godeps']` | Which folders should trigger this module. |
|
||||
| `style` | `'bold cyan'` | 這個模組的風格。 |
|
||||
| `disabled` | `false` | 停用 `golang` 模組。 |
|
||||
| `disabled` | `false` | Disables the `golang` module. |
|
||||
|
||||
### Variables
|
||||
|
||||
@@ -1840,6 +1926,41 @@ disabled = true
|
||||
format = 'via [🐂](yellow bold) '
|
||||
```
|
||||
|
||||
## Gradle
|
||||
|
||||
The `gradle` module shows the version of the [Gradle Wrapper](https://docs.gradle.org/current/userguide/gradle_wrapper.html) currently used in the project directory.
|
||||
|
||||
By default the module will be shown if any of the following conditions are met:
|
||||
|
||||
- The current directory contains a `gradle/wrapper/gradle-wrapper.properties` directory.
|
||||
- The current directory contains a file ending with `.gradle` or `.gradle.kts`.
|
||||
|
||||
The `gradle` module is only able to read your Gradle Wrapper version from your config file, we don't execute your wrapper, because of the security concerns.
|
||||
|
||||
### 選項
|
||||
|
||||
| Option | 預設 | 說明 |
|
||||
| ------------------- | ------------------------------------ | ------------------------------------------------------------------------- |
|
||||
| `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 Gradle. |
|
||||
| `detect_extensions` | `["gradle", "gradle.kts"]` | Which extensions should trigger this module. |
|
||||
| `detect_files` | `[]` | Which filenames should trigger this module. |
|
||||
| `detect_folders` | `["gradle"]` | Which folders should trigger this module. |
|
||||
| `style` | `"bold bright-cyan"` | 這個模組的風格。 |
|
||||
| `disabled` | `false` | Disables the `gradle` module. |
|
||||
| `recursive` | `false` | Enables recursive finding for the `gradle` directory. |
|
||||
|
||||
### Variables
|
||||
|
||||
| 變數 | 範例 | 說明 |
|
||||
| ------- | -------- | ------------------------------------ |
|
||||
| version | `v7.5.1` | The version of `gradle` |
|
||||
| symbol | | Mirrors the value of option `symbol` |
|
||||
| style* | | Mirrors the value of option `style` |
|
||||
|
||||
*: This variable can only be used as a part of a style string
|
||||
|
||||
## Haskell
|
||||
|
||||
The `haskell` module finds the current selected GHC version and/or the selected Stack snapshot.
|
||||
@@ -1954,24 +2075,24 @@ format = 'via [⎈ $version](bold white) '
|
||||
|
||||
## 主機名稱
|
||||
|
||||
`hostname` 模組顯示系統的主機名稱。
|
||||
The `hostname` module shows the system hostname.
|
||||
|
||||
### 選項
|
||||
|
||||
| Option | 預設 | 說明 |
|
||||
| ------------ | -------------------------------------- | ------------------------------------------------------------------------------------------- |
|
||||
| `ssh_only` | `true` | 只在連接到一個 SSH session 時顯示主機名稱。 |
|
||||
| `ssh_symbol` | `'🌐 '` | A format string representing the symbol when connected to SSH session. |
|
||||
| `trim_at` | `'.'` | 擷取出主機名稱的斷點,以第一個符合的為準。 `'.'` will stop after the first dot. `''` will disable any truncation |
|
||||
| `format` | `'[$ssh_symbol$hostname]($style) in '` | The format for the module. |
|
||||
| `style` | `'bold dimmed green'` | 這個模組的風格。 |
|
||||
| `disabled` | `false` | 停用 `hostname` 模組。 |
|
||||
| Option | 預設 | 說明 |
|
||||
| ------------ | -------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------ |
|
||||
| `ssh_only` | `true` | Only show hostname when connected to an SSH session. |
|
||||
| `ssh_symbol` | `'🌐 '` | A format string representing the symbol when connected to SSH session. |
|
||||
| `trim_at` | `'.'` | String that the hostname is cut off at, after the first match. `'.'` will stop after the first dot. `''` will disable any truncation |
|
||||
| `format` | `'[$ssh_symbol$hostname]($style) in '` | The format for the module. |
|
||||
| `style` | `'bold dimmed green'` | 這個模組的風格。 |
|
||||
| `disabled` | `false` | Disables the `hostname` module. |
|
||||
|
||||
### Variables
|
||||
|
||||
| 變數 | 範例 | 說明 |
|
||||
| ---------- | ---------- | ----------------------------------------------------- |
|
||||
| 主機名稱 | `computer` | The hostname of the computer |
|
||||
| hostname | `computer` | The hostname of the computer |
|
||||
| style\* | | Mirrors the value of option `style` |
|
||||
| ssh_symbol | `'🌏 '` | The symbol to represent when connected to SSH session |
|
||||
|
||||
@@ -2007,7 +2128,7 @@ The `java` module shows the currently installed version of [Java](https://www.or
|
||||
| `detect_folders` | `[]` | Which folders should trigger this modules. |
|
||||
| `symbol` | `'☕ '` | A format string representing the symbol of Java |
|
||||
| `style` | `'red dimmed'` | 這個模組的風格。 |
|
||||
| `disabled` | `false` | 停用 `java` 模組。 |
|
||||
| `disabled` | `false` | Disables the `java` module. |
|
||||
|
||||
### Variables
|
||||
|
||||
@@ -2028,9 +2149,9 @@ The `java` module shows the currently installed version of [Java](https://www.or
|
||||
symbol = '🌟 '
|
||||
```
|
||||
|
||||
## 工作
|
||||
## Jobs
|
||||
|
||||
`jobs` 模組顯示現在正在執行中的工作。 這個模組只會在有背景工作正在執行時顯示。 The module will show the number of jobs running if there are at least 2 jobs, or more than the `number_threshold` config value, if it exists. The module will show a symbol if there is at least 1 job, or more than the `symbol_threshold` config value, if it exists. You can set both values to 0 in order to _always_ show the symbol and number of jobs, even if there are 0 jobs running.
|
||||
The `jobs` module shows the current number of jobs running. The module will be shown only if there are background jobs running. The module will show the number of jobs running if there are at least 2 jobs, or more than the `number_threshold` config value, if it exists. The module will show a symbol if there is at least 1 job, or more than the `symbol_threshold` config value, if it exists. You can set both values to 0 in order to _always_ show the symbol and number of jobs, even if there are 0 jobs running.
|
||||
|
||||
The default functionality is:
|
||||
|
||||
@@ -2054,13 +2175,13 @@ The `threshold` option is deprecated, but if you want to use it, the module will
|
||||
|
||||
| Option | 預設 | 說明 |
|
||||
| ------------------ | ----------------------------- | ------------------------------------------------------------------------ |
|
||||
| `threshold`* | `1` | 在超過指定值時顯示工作數量。 |
|
||||
| `threshold`* | `1` | Show number of jobs if exceeded. |
|
||||
| `symbol_threshold` | `1` | Show `symbol` if the job count is at least `symbol_threshold`. |
|
||||
| `number_threshold` | `2` | Show the number of jobs if the job count is at least `number_threshold`. |
|
||||
| `format` | `'[$symbol$number]($style) '` | The format for the module. |
|
||||
| `symbol` | `'✦'` | The string used to represent the `symbol` variable. |
|
||||
| `style` | `'bold blue'` | 這個模組的風格。 |
|
||||
| `disabled` | `false` | 停用 `jobs` 模組。 |
|
||||
| `disabled` | `false` | Disables the `jobs` module. |
|
||||
|
||||
*: This option is deprecated, please use the `number_threshold` and `symbol_threshold` options instead.
|
||||
|
||||
@@ -2178,7 +2299,7 @@ Displays the current [Kubernetes context](https://kubernetes.io/docs/concepts/co
|
||||
|
||||
::: tip
|
||||
|
||||
這個模組預設是停用的。 想要啟用它的話,請在設定檔中將 `disabled` 設定為 `false`。
|
||||
This module is disabled by default. To enable it, set `disabled` to `false` in your configuration file.
|
||||
|
||||
When the module is enabled it will always be active, unless any of `detect_extensions`, `detect_files` or `detect_folders` have been set in which case the module will only be active in directories that match those conditions.
|
||||
|
||||
@@ -2259,15 +2380,15 @@ Long and automatically generated cluster names can be identified and shortened u
|
||||
'gke_.*_(?P<var_cluster>[\\w-]+)' = 'gke-$var_cluster'
|
||||
```
|
||||
|
||||
## 換行
|
||||
## Line Break
|
||||
|
||||
`line_break` 模組將提示字元分成兩行。
|
||||
The `line_break` module separates the prompt into two lines.
|
||||
|
||||
### 選項
|
||||
|
||||
| Option | 預設 | 說明 |
|
||||
| ---------- | ------- | ----------------------------- |
|
||||
| `disabled` | `false` | 停用 `line_break` 模組,讓提示字元變成一行。 |
|
||||
| Option | 預設 | 說明 |
|
||||
| ---------- | ------- | ------------------------------------------------------------------ |
|
||||
| `disabled` | `false` | Disables the `line_break` module, making the prompt a single line. |
|
||||
|
||||
### 範例
|
||||
|
||||
@@ -2352,27 +2473,27 @@ The `lua` module shows the currently installed version of [Lua](http://www.lua.o
|
||||
format = 'via [🌕 $version](bold blue) '
|
||||
```
|
||||
|
||||
## 記憶體使用量
|
||||
## Memory Usage
|
||||
|
||||
`memory_usage` 模組顯示現在系統記憶體與 swap 的使用量。
|
||||
The `memory_usage` module shows current system memory and swap usage.
|
||||
|
||||
預設 swap 使用量會在系統總 swap 使用量不為 0 時顯示出來。
|
||||
By default the swap usage is displayed if the total system swap is non-zero.
|
||||
|
||||
::: tip
|
||||
|
||||
這個模組預設是停用的。 想要啟用它的話,請在設定檔中將 `disabled` 設定為 `false`。
|
||||
This module is disabled by default. To enable it, set `disabled` to `false` in your configuration file.
|
||||
|
||||
:::
|
||||
|
||||
### 選項
|
||||
|
||||
| Option | 預設 | 說明 |
|
||||
| ----------- | ----------------------------------------------- | -------------------------- |
|
||||
| `threshold` | `75` | 將記憶體使用量隱藏,除非使用量超過指定值。 |
|
||||
| `format` | `'via $symbol [${ram}( \| ${swap})]($style) '` | The format for the module. |
|
||||
| `symbol` | `'🐏'` | 顯示在記憶體使用量之前的符號。 |
|
||||
| `style` | `'bold dimmed white'` | 這個模組的風格。 |
|
||||
| `disabled` | `true` | 停用 `memory_usage` 模組。 |
|
||||
| Option | 預設 | 說明 |
|
||||
| ----------- | ----------------------------------------------- | -------------------------------------------------------- |
|
||||
| `threshold` | `75` | Hide the memory usage unless it exceeds this percentage. |
|
||||
| `format` | `'via $symbol [${ram}( \| ${swap})]($style) '` | The format for the module. |
|
||||
| `symbol` | `'🐏'` | The symbol used before displaying the memory usage. |
|
||||
| `style` | `'bold dimmed white'` | 這個模組的風格。 |
|
||||
| `disabled` | `true` | Disables the `memory_usage` module. |
|
||||
|
||||
### Variables
|
||||
|
||||
@@ -2440,26 +2561,27 @@ style = 'bold dimmed green'
|
||||
|
||||
## Mercurial Branch
|
||||
|
||||
The `hg_branch` module shows the active branch of the repo in your current directory.
|
||||
The `hg_branch` module shows the active branch and topic of the repo in your current directory.
|
||||
|
||||
### 選項
|
||||
|
||||
| Option | 預設 | 說明 |
|
||||
| ------------------- | -------------------------------- | -------------------------------------------------------------------------------------------- |
|
||||
| `symbol` | `' '` | The symbol used before the hg bookmark or branch name of the repo in your current directory. |
|
||||
| `style` | `'bold purple'` | 這個模組的風格。 |
|
||||
| `format` | `'on [$symbol$branch]($style) '` | The format for the module. |
|
||||
| `truncation_length` | `2^63 - 1` | Truncates the hg branch name to `N` graphemes |
|
||||
| `truncation_symbol` | `'…'` | 用來指示分支名稱被縮減的符號。 |
|
||||
| `disabled` | `true` | Disables the `hg_branch` module. |
|
||||
| Option | 預設 | 說明 |
|
||||
| ------------------- | ----------------------------------------- | -------------------------------------------------------------------------------------------- |
|
||||
| `symbol` | `' '` | The symbol used before the hg bookmark or branch name of the repo in your current directory. |
|
||||
| `style` | `'bold purple'` | 這個模組的風格。 |
|
||||
| `format` | `'on [$symbol$branch(:$topic)]($style) '` | The format for the module. |
|
||||
| `truncation_length` | `2^63 - 1` | Truncates the hg branch / topic name to `N` graphemes |
|
||||
| `truncation_symbol` | `'…'` | The symbol used to indicate a branch name was truncated. |
|
||||
| `disabled` | `true` | Disables the `hg_branch` module. |
|
||||
|
||||
### Variables
|
||||
|
||||
| 變數 | 範例 | 說明 |
|
||||
| --------- | -------- | ------------------------------------ |
|
||||
| branch | `master` | The active mercurial branch |
|
||||
| symbol | | Mirrors the value of option `symbol` |
|
||||
| style\* | | Mirrors the value of option `style` |
|
||||
| 變數 | 範例 | 說明 |
|
||||
| --------- | --------- | ------------------------------------ |
|
||||
| branch | `master` | The active mercurial branch |
|
||||
| topic | `feature` | The active mercurial topic |
|
||||
| symbol | | Mirrors the value of option `symbol` |
|
||||
| style\* | | Mirrors the value of option `style` |
|
||||
|
||||
*: This variable can only be used as a part of a style string
|
||||
|
||||
@@ -2518,18 +2640,20 @@ symbol = '🎣 '
|
||||
|
||||
## Nix-shell
|
||||
|
||||
The `nix_shell` module shows the [nix-shell](https://nixos.org/guides/nix-pills/developing-with-nix-shell.html) environment. 這個模組會在 nix-shell 環境中顯示。
|
||||
The `nix_shell` module shows the [nix-shell](https://nixos.org/guides/nix-pills/developing-with-nix-shell.html) environment. The module will be shown when inside a nix-shell environment.
|
||||
|
||||
### 選項
|
||||
|
||||
| Option | 預設 | 說明 |
|
||||
| ------------ | ---------------------------------------------- | ----------------------------------------------------- |
|
||||
| `format` | `'via [$symbol$state( \($name\))]($style) '` | The format for the module. |
|
||||
| `symbol` | `'❄️ '` | A format string representing the symbol of nix-shell. |
|
||||
| `style` | `'bold blue'` | 這個模組的風格。 |
|
||||
| `impure_msg` | `'impure'` | A format string shown when the shell is impure. |
|
||||
| `pure_msg` | `'pure'` | A format string shown when the shell is pure. |
|
||||
| `disabled` | `false` | 停用 `nix_shell` 模組。 |
|
||||
| Option | 預設 | 說明 |
|
||||
| ------------- | ---------------------------------------------- | --------------------------------------------------------------------- |
|
||||
| `format` | `'via [$symbol$state( \($name\))]($style) '` | The format for the module. |
|
||||
| `symbol` | `'❄️ '` | A format string representing the symbol of nix-shell. |
|
||||
| `style` | `'bold blue'` | 這個模組的風格。 |
|
||||
| `impure_msg` | `'impure'` | A format string shown when the shell is impure. |
|
||||
| `pure_msg` | `'pure'` | A format string shown when the shell is pure. |
|
||||
| `unknown_msg` | `''` | A format string shown when it is unknown if the shell is pure/impure. |
|
||||
| `disabled` | `false` | Disables the `nix_shell` module. |
|
||||
| `heuristic` | `false` | Attempts to detect new `nix shell`-style shells with a heuristic. |
|
||||
|
||||
### Variables
|
||||
|
||||
@@ -2551,6 +2675,7 @@ The `nix_shell` module shows the [nix-shell](https://nixos.org/guides/nix-pills/
|
||||
disabled = true
|
||||
impure_msg = '[impure shell](bold red)'
|
||||
pure_msg = '[pure shell](bold green)'
|
||||
unknown_msg = '[unknown shell](bold yellow)'
|
||||
format = 'via [☃️ $state( \($name\))](bold blue) '
|
||||
```
|
||||
|
||||
@@ -2576,7 +2701,7 @@ The `nodejs` module shows the currently installed version of [Node.js](https://n
|
||||
| `detect_files` | `['package.json', '.node-version']` | Which filenames should trigger this module. |
|
||||
| `detect_folders` | `['node_modules']` | Which folders should trigger this module. |
|
||||
| `style` | `'bold green'` | 這個模組的風格。 |
|
||||
| `disabled` | `false` | 停用 `nodejs` 模組。 |
|
||||
| `disabled` | `false` | Disables the `nodejs` module. |
|
||||
| `not_capable_style` | `bold red` | The style for the module when an engines property in package.json does not match the Node.js version. |
|
||||
|
||||
### Variables
|
||||
@@ -2728,7 +2853,7 @@ The [os_info](https://lib.rs/crates/os_info) crate used by this module is known
|
||||
|
||||
::: tip
|
||||
|
||||
這個模組預設是停用的。 想要啟用它的話,請在設定檔中將 `disabled` 設定為 `false`。
|
||||
This module is disabled by default. To enable it, set `disabled` to `false` in your configuration file.
|
||||
|
||||
:::
|
||||
|
||||
@@ -2813,9 +2938,9 @@ Windows = " "
|
||||
Arch = "Arch is the best! "
|
||||
```
|
||||
|
||||
## 套件版本
|
||||
## Package Version
|
||||
|
||||
The `package` 模組在現在資料夾是一個套件的儲藏庫時出現,並顯示他的現在版本。 The module currently supports `npm`, `nimble`, `cargo`, `poetry`, `python`, `composer`, `gradle`, `julia`, `mix`, `helm`, `shards`, `daml` and `dart` packages.
|
||||
The `package` module is shown when the current directory is the repository for a package, and shows its current version. The module currently supports `npm`, `nimble`, `cargo`, `poetry`, `python`, `composer`, `gradle`, `julia`, `mix`, `helm`, `shards`, `daml` and `dart` packages.
|
||||
|
||||
- [**npm**](https://docs.npmjs.com/cli/commands/npm) – The `npm` package version is extracted from the `package.json` present in the current directory
|
||||
- [**Cargo**](https://doc.rust-lang.org/cargo/) – The `cargo` package version is extracted from the `Cargo.toml` present in the current directory
|
||||
@@ -2842,11 +2967,11 @@ The `package` 模組在現在資料夾是一個套件的儲藏庫時出現,並
|
||||
| Option | 預設 | 說明 |
|
||||
| ----------------- | --------------------------------- | ------------------------------------------------------------------------- |
|
||||
| `format` | `'is [$symbol$version]($style) '` | The format for the module. |
|
||||
| `symbol` | `'📦 '` | 顯示在套件的版本之前的符號。 |
|
||||
| `symbol` | `'📦 '` | The symbol used before displaying the version the package. |
|
||||
| `version_format` | `'v${raw}'` | The version format. Available vars are `raw`, `major`, `minor`, & `patch` |
|
||||
| `style` | `'bold 208'` | 這個模組的風格。 |
|
||||
| `display_private` | `false` | Enable displaying version for packages marked as private. |
|
||||
| `disabled` | `false` | 停用 `package` 模組。 |
|
||||
| `disabled` | `false` | Disables the `package` module. |
|
||||
|
||||
### Variables
|
||||
|
||||
@@ -2911,7 +3036,7 @@ format = 'via [🦪 $version]($style) '
|
||||
|
||||
The `php` module shows the currently installed version of [PHP](https://www.php.net/). By default the module will be shown if any of the following conditions are met:
|
||||
|
||||
- The current directory contains a `composer.json` file
|
||||
- 目前資料夾中有一個 `composer.json` 檔案
|
||||
- The current directory contains a `.php-version` file
|
||||
- The current directory contains a `.php` extension
|
||||
|
||||
@@ -2947,6 +3072,21 @@ The `php` module shows the currently installed version of [PHP](https://www.php.
|
||||
format = 'via [🔹 $version](147 bold) '
|
||||
```
|
||||
|
||||
## Pijul Channel
|
||||
|
||||
The `pijul_channel` module shows the active channel of the repo in your current directory.
|
||||
|
||||
### 選項
|
||||
|
||||
| Option | 預設 | 說明 |
|
||||
| ------------------- | --------------------------------- | ------------------------------------------------------------------------------------ |
|
||||
| `symbol` | `' '` | The symbol used before the pijul channel name of the repo in your current directory. |
|
||||
| `style` | `'bold purple'` | 這個模組的風格。 |
|
||||
| `format` | `'on [$symbol$channel]($style) '` | The format for the module. |
|
||||
| `truncation_length` | `2^63 - 1` | Truncates the pijul channel name to `N` graphemes |
|
||||
| `truncation_symbol` | `'…'` | The symbol used to indicate a branch name was truncated. |
|
||||
| `disabled` | `true` | Disables the `pijul` module. |
|
||||
|
||||
## Pulumi
|
||||
|
||||
The `pulumi` module shows the current username, selected [Pulumi Stack](https://www.pulumi.com/docs/intro/concepts/stack/), and version.
|
||||
@@ -2979,7 +3119,7 @@ By default the module will be shown if any of the following conditions are met:
|
||||
| --------- | ---------- | ------------------------------------ |
|
||||
| version | `v0.12.24` | The version of `pulumi` |
|
||||
| stack | `dev` | The current Pulumi stack |
|
||||
| 使用者名稱 | `alice` | The current Pulumi username |
|
||||
| username | `alice` | The current Pulumi username |
|
||||
| symbol | | Mirrors the value of option `symbol` |
|
||||
| style\* | | Mirrors the value of option `style` |
|
||||
|
||||
@@ -3070,13 +3210,13 @@ By default the module will be shown if any of the following conditions are met:
|
||||
| `version_format` | `'v${raw}'` | The version format. Available vars are `raw`, `major`, `minor`, & `patch` |
|
||||
| `symbol` | `'🐍 '` | A format string representing the symbol of Python |
|
||||
| `style` | `'yellow bold'` | 這個模組的風格。 |
|
||||
| `pyenv_version_name` | `false` | 使用 pyenv 取得 Python 的版本。 |
|
||||
| `pyenv_version_name` | `false` | Use pyenv to get Python version |
|
||||
| `pyenv_prefix` | `pyenv` | Prefix before pyenv version display, only used if pyenv is used |
|
||||
| `python_binary` | `['python', 'python3', 'python2']` | Configures the python binaries that Starship should executes when getting the version. |
|
||||
| `detect_extensions` | `['py']` | Which extensions should trigger this module |
|
||||
| `detect_files` | `['.python-version', 'Pipfile', '__init__.py', 'pyproject.toml', 'requirements.txt', 'setup.py', 'tox.ini']` | Which filenames should trigger this module |
|
||||
| `detect_folders` | `[]` | Which folders should trigger this module |
|
||||
| `disabled` | `false` | 停用 `python` 模組。 |
|
||||
| `disabled` | `false` | Disables the `python` module. |
|
||||
|
||||
::: tip
|
||||
|
||||
@@ -3215,7 +3355,7 @@ format = 'via [🦪 $version]($style) '
|
||||
|
||||
## Red
|
||||
|
||||
By default the `red` module shows the currently installed version of [Red](https://www.red-lang.org/). 這個模組將在下列其中一個條件滿足時顯示:
|
||||
By default the `red` module shows the currently installed version of [Red](https://www.red-lang.org/). The module will be shown if any of the following conditions are met:
|
||||
|
||||
- The current directory contains a file with `.red` or `.reds` extension
|
||||
|
||||
@@ -3253,7 +3393,7 @@ symbol = '🔴 '
|
||||
|
||||
## Ruby
|
||||
|
||||
By default the `ruby` module shows the currently installed version of [Ruby](https://www.ruby-lang.org/). 這個模組將在下列其中一個條件滿足時顯示:
|
||||
By default the `ruby` module shows the currently installed version of [Ruby](https://www.ruby-lang.org/). The module will be shown if any of the following conditions are met:
|
||||
|
||||
- 目前資料夾中有一個 `Gemfile` 檔案
|
||||
- The current directory contains a `.ruby-version` file
|
||||
@@ -3274,7 +3414,7 @@ Starship gets the current Ruby version by running `ruby -v`.
|
||||
| `detect_folders` | `[]` | Which folders should trigger this module. |
|
||||
| `detect_variables` | `['RUBY_VERSION', 'RBENV_VERSION']` | Which environment variables should trigger this module. |
|
||||
| `style` | `'bold red'` | 這個模組的風格。 |
|
||||
| `disabled` | `false` | 停用 `ruby` 模組。 |
|
||||
| `disabled` | `false` | Disables the `ruby` module. |
|
||||
|
||||
### Variables
|
||||
|
||||
@@ -3297,7 +3437,7 @@ symbol = '🔺 '
|
||||
|
||||
## Rust
|
||||
|
||||
By default the `rust` module shows the currently installed version of [Rust](https://www.rust-lang.org/). 這個模組將在下列其中一個條件滿足時顯示:
|
||||
By default the `rust` module shows the currently installed version of [Rust](https://www.rust-lang.org/). The module will be shown if any of the following conditions are met:
|
||||
|
||||
- 目前資料夾中有一個 `Cargo.toml` 檔案
|
||||
- 現在資料夾中包含一個檔案具有 `.rs` 副檔名
|
||||
@@ -3313,7 +3453,7 @@ By default the `rust` module shows the currently installed version of [Rust](htt
|
||||
| `detect_files` | `['Cargo.toml']` | Which filenames should trigger this module. |
|
||||
| `detect_folders` | `[]` | Which folders should trigger this module. |
|
||||
| `style` | `'bold red'` | 這個模組的風格。 |
|
||||
| `disabled` | `false` | 停用 `rust` 模組。 |
|
||||
| `disabled` | `false` | Disables the `rust` module. |
|
||||
|
||||
### Variables
|
||||
|
||||
@@ -3382,7 +3522,7 @@ The `shell` module shows an indicator for currently used shell.
|
||||
|
||||
::: tip
|
||||
|
||||
這個模組預設是停用的。 想要啟用它的話,請在設定檔中將 `disabled` 設定為 `false`。
|
||||
This module is disabled by default. To enable it, set `disabled` to `false` in your configuration file.
|
||||
|
||||
:::
|
||||
|
||||
@@ -3534,7 +3674,7 @@ The `status` module displays the exit code of the previous command. If $success_
|
||||
|
||||
::: tip
|
||||
|
||||
這個模組預設是停用的。 想要啟用它的話,請在設定檔中將 `disabled` 設定為 `false`。
|
||||
This module is disabled by default. To enable it, set `disabled` to `false` in your configuration file.
|
||||
|
||||
:::
|
||||
|
||||
@@ -3595,7 +3735,7 @@ The `sudo` module displays if sudo credentials are currently cached. The module
|
||||
|
||||
::: tip
|
||||
|
||||
這個模組預設是停用的。 想要啟用它的話,請在設定檔中將 `disabled` 設定為 `false`。
|
||||
This module is disabled by default. To enable it, set `disabled` to `false` in your configuration file.
|
||||
|
||||
:::
|
||||
|
||||
@@ -3640,7 +3780,7 @@ disabled = false
|
||||
|
||||
## Swift
|
||||
|
||||
By default the `swift` module shows the currently installed version of [Swift](https://swift.org/). 這個模組將在下列其中一個條件滿足時顯示:
|
||||
By default the `swift` module shows the currently installed version of [Swift](https://swift.org/). The module will be shown if any of the following conditions are met:
|
||||
|
||||
- The current directory contains a `Package.swift` file
|
||||
- The current directory contains a file with the `.swift` extension
|
||||
@@ -3738,25 +3878,25 @@ format = '[🏎💨 $workspace]($style) '
|
||||
|
||||
## 時間
|
||||
|
||||
`time` 模組顯示目前的**當地**時間. `format` 設定值被 [`chrono`](https://crates.io/crates/chrono) crate 用來控制時間如何顯示。 請看 [chrono 的 strftime 文件](https://docs.rs/chrono/0.4.7/chrono/format/strftime/index.html)來了解有那些選項可以使用。
|
||||
The `time` module shows the current **local** time. The `format` configuration value is used by the [`chrono`](https://crates.io/crates/chrono) crate to control how the time is displayed. Take a look [at the chrono strftime docs](https://docs.rs/chrono/0.4.7/chrono/format/strftime/index.html) to see what options are available.
|
||||
|
||||
::: tip
|
||||
|
||||
這個模組預設是停用的。 想要啟用它的話,請在設定檔中將 `disabled` 設定為 `false`。
|
||||
This module is disabled by default. To enable it, set `disabled` to `false` in your configuration file.
|
||||
|
||||
:::
|
||||
|
||||
### 選項
|
||||
|
||||
| Option | 預設 | 說明 |
|
||||
| ----------------- | ----------------------- | ----------------------------------------------------------------------------------------------------- |
|
||||
| `format` | `'at [$time]($style) '` | The format string for the module. |
|
||||
| `use_12hr` | `false` | 啟用 12 小時格式。 |
|
||||
| `time_format` | 請看下列 | 用來顯示時間的 [chrono 格式字串](https://docs.rs/chrono/0.4.7/chrono/format/strftime/index.html)。 |
|
||||
| `style` | `'bold yellow'` | 這個模組的時間的風格。 |
|
||||
| `utc_time_offset` | `'local'` | 設定相對於 UTC 的時差。 Range from -24 < x < 24. 允許使用浮點數來表示 30/45 分鐘時差的時區。 |
|
||||
| `disabled` | `true` | 停用 `time` 模組。 |
|
||||
| `time_range` | `'-'` | Sets the time range during which the module will be shown. Times must be specified in 24-hours format |
|
||||
| Option | 預設 | 說明 |
|
||||
| ----------------- | ----------------------- | ---------------------------------------------------------------------------------------------------------------------------------- |
|
||||
| `format` | `'at [$time]($style) '` | The format string for the module. |
|
||||
| `use_12hr` | `false` | Enables 12 hour formatting |
|
||||
| `time_format` | see below | The [chrono format string](https://docs.rs/chrono/0.4.7/chrono/format/strftime/index.html) used to format the time. |
|
||||
| `style` | `'bold yellow'` | The style for the module time |
|
||||
| `utc_time_offset` | `'local'` | Sets the UTC offset to use. Range from -24 < x < 24. Allows floats to accommodate 30/45 minute timezone offsets. |
|
||||
| `disabled` | `true` | Disables the `time` module. |
|
||||
| `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'`. Otherwise, it defaults to `'%T'`. Manually setting `time_format` will override the `use_12hr` setting.
|
||||
|
||||
@@ -3764,7 +3904,7 @@ If `use_12hr` is `true`, then `time_format` defaults to `'%r'`. Otherwise, it de
|
||||
|
||||
| 變數 | 範例 | 說明 |
|
||||
| --------- | ---------- | ----------------------------------- |
|
||||
| 時間 | `13:08:10` | The current time. |
|
||||
| time | `13:08:10` | The current time. |
|
||||
| style\* | | Mirrors the value of option `style` |
|
||||
|
||||
*: This variable can only be used as a part of a style string
|
||||
@@ -3782,9 +3922,9 @@ utc_time_offset = '-5'
|
||||
time_range = '10:00:00-14:00:00'
|
||||
```
|
||||
|
||||
## 使用者名稱
|
||||
## Username
|
||||
|
||||
`username` 模組顯示現在使用中的使用者名稱。 這個模組將在下列其中一個條件滿足時顯示:
|
||||
The `username` module shows active user's username. The module will be shown if any of the following conditions are met:
|
||||
|
||||
- The current user is root/admin
|
||||
- 目前使用者並非登入時的使用者
|
||||
@@ -3802,10 +3942,10 @@ SSH connection is detected by checking environment variables `SSH_CONNECTION`, `
|
||||
| Option | 預設 | 說明 |
|
||||
| ------------- | ----------------------- | ------------------------------------------- |
|
||||
| `style_root` | `'bold red'` | The style used when the user is root/admin. |
|
||||
| `style_user` | `'bold yellow'` | 非 root 使用者時使用的風格。 |
|
||||
| `style_user` | `'bold yellow'` | The style used for non-root users. |
|
||||
| `format` | `'[$user]($style) in '` | The format for the module. |
|
||||
| `show_always` | `false` | 總是顯示 `username` 模組。 |
|
||||
| `disabled` | `false` | 停用 `username` 模組。 |
|
||||
| `show_always` | `false` | Always shows the `username` module. |
|
||||
| `disabled` | `false` | Disables the `username` module. |
|
||||
|
||||
### Variables
|
||||
|
||||
@@ -3935,7 +4075,7 @@ format = '[🆅 $repo](bold blue) '
|
||||
|
||||
## Zig
|
||||
|
||||
By default the the `zig` module shows the currently installed version of [Zig](https://ziglang.org/). 這個模組將在下列其中一個條件滿足時顯示:
|
||||
By default the the `zig` module shows the currently installed version of [Zig](https://ziglang.org/). The module will be shown if any of the following conditions are met:
|
||||
|
||||
- The current directory contains a `.zig` file
|
||||
|
||||
@@ -4016,7 +4156,7 @@ Format strings can also contain shell specific prompt sequences, e.g. [Bash](htt
|
||||
| `command` | `''` | The command whose output should be printed. The command will be passed on stdin to the shell. |
|
||||
| `when` | `false` | Either a boolean value (`true` or `false`, without quotes) or a string shell command used as a condition to show the module. In case of a string, the module will be shown if the command returns a `0` status code. |
|
||||
| `shell` | | [See below](#custom-command-shell) |
|
||||
| `說明` | `'<custom module>'` | The description of the module that is shown when running `starship explain`. |
|
||||
| `description` | `'<custom module>'` | The description of the module that is shown when running `starship explain`. |
|
||||
| `detect_files` | `[]` | The files that will be searched in the working directory for a match. |
|
||||
| `detect_folders` | `[]` | The directories that will be searched in the working directory for a match. |
|
||||
| `detect_extensions` | `[]` | The extensions that will be searched in the working directory for a match. |
|
||||
|
||||
@@ -9,7 +9,7 @@
|
||||
<p align="center">
|
||||
<a href="https://github.com/starship/starship/actions"
|
||||
><img
|
||||
src="https://img.shields.io/github/workflow/status/starship/starship/Main workflow/master?label=workflow&style=flat-square"
|
||||
src="https://img.shields.io/github/actions/workflow/status/starship/starship/workflow.yml?branch=master&label=workflow&style=flat-square"
|
||||
alt="GitHub Actions workflow status"
|
||||
/></a>
|
||||
<a href="https://crates.io/crates/starship"
|
||||
@@ -331,7 +331,7 @@ Add the following to the end of your Nushell env file (find it by running `$nu.e
|
||||
|
||||
```sh
|
||||
mkdir ~/.cache/starship
|
||||
starship init nu | save ~/.cache/starship/init.nu
|
||||
starship init nu | save -f ~/.cache/starship/init.nu
|
||||
```
|
||||
|
||||
And add the following to the end of your Nushell configuration (find it by running `$nu.config-path`):
|
||||
@@ -340,7 +340,7 @@ And add the following to the end of your Nushell configuration (find it by runni
|
||||
source ~/.cache/starship/init.nu
|
||||
```
|
||||
|
||||
Note: Only Nushell v0.61+ is supported
|
||||
Note: Only Nushell v0.73+ is supported
|
||||
|
||||
</details>
|
||||
|
||||
@@ -423,6 +423,7 @@ Support this project by [becoming a sponsor](https://github.com/sponsors/starshi
|
||||
**Supporter Tier**
|
||||
|
||||
- [Dimension](https://dimension.dev/)
|
||||
- [Appwrite](https://appwrite.io/)
|
||||
|
||||
<p align="center">
|
||||
<br>
|
||||
|
||||
@@ -14,7 +14,11 @@ This preset changes the symbols for each module to use Nerd Font symbols.
|
||||
|
||||
This preset changes the symbols for several modules so that no Nerd Font symbols are used anywhere in the prompt.
|
||||
|
||||
::: tip This preset will become the default preset [in a future release of starship](https://github.com/starship/starship/pull/3544). :::
|
||||
::: tip
|
||||
|
||||
This preset will become the default preset [in a future release of starship](https://github.com/starship/starship/pull/3544).
|
||||
|
||||
:::
|
||||
|
||||
[Click to view No Nerd Font preset](./no-nerd-font)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user