diff --git a/docs/ar-SA/advanced-config/README.md b/docs/ar-SA/advanced-config/README.md index d423cdc5..cabf9cdf 100644 --- a/docs/ar-SA/advanced-config/README.md +++ b/docs/ar-SA/advanced-config/README.md @@ -68,6 +68,33 @@ function set_win_title(){ starship_precmd_user_func="set_win_title" ``` +## Enable Right Prompt + +Some shells support a right prompt which renders on the same line as the input. Starship can set the content of the right prompt using the `right_format` option. Any module that can be used in `format` is also supported in `right_format`. The `$all` variable will only contain modules not explicitly used in either `format` or `right_format`. + +Note: The right prompt is a single line following the input location. To right align modules above the input line in a multi-line prompt, see the [fill module](/config/#fill). + +`right_format` is currently supported for the following shells: elvish, fish, zsh. + +### Example + +```toml +# ~/.config/starship.toml + +# A minimal left prompt +format = """$character""" + +# move the rest of the prompt to the right +right_format = """$all""" +``` + +Produces a prompt like the following: + +``` +▶ starship on  rprompt [!] is 📦 v0.57.0 via 🦀 v1.54.0 took 17s +``` + + ## Style Strings Style strings are a list of words, separated by whitespace. The words are not case sensitive (i.e. `bold` and `BoLd` are considered the same string). Each word can be one of the following: diff --git a/docs/ar-SA/config/README.md b/docs/ar-SA/config/README.md index 61f8fcfd..2fb31aa1 100644 --- a/docs/ar-SA/config/README.md +++ b/docs/ar-SA/config/README.md @@ -75,7 +75,7 @@ A text group is made up of two different parts. The first part, which is enclosed in a `[]`, is a [format string](#format-strings). You can add texts, variables, or even nested text groups in it. -In the second part, which is enclosed in a `()`, is a [style string](#style-strings). This can be used style the first part. +In the second part, which is enclosed in a `()`, is a [style string](#style-strings). This can be used to style the first part. For example: @@ -142,12 +142,14 @@ This is the list of prompt-wide configuration options. ### Options -| Option | Default | Description | -| ----------------- | ------------------------------ | ------------------------------------------------------------ | -| `format` | [link](#default-prompt-format) | Configure the format of the prompt. | -| `scan_timeout` | `30` | Timeout for starship to scan files (in milliseconds). | -| `command_timeout` | `500` | Timeout for commands executed by starship (in milliseconds). | -| `add_newline` | `true` | Inserts blank line between shell prompts. | +| Option | Default | Description | +| ----------------- | ------------------------------ | ---------------------------------------------------------------- | +| `format` | [link](#default-prompt-format) | Configure the format of the prompt. | +| `right_format` | `""` | See [Enable Right Prompt](/advanced-config/#enable-right-prompt) | +| `scan_timeout` | `30` | Timeout for starship to scan files (in milliseconds). | +| `command_timeout` | `500` | Timeout for commands executed by starship (in milliseconds). | +| `add_newline` | `true` | Inserts blank line between shell prompts. | + ### Example @@ -179,6 +181,7 @@ format = """ $username\ $hostname\ $shlvl\ +$singularity\ $kubernetes\ $directory\ $vcsh\ @@ -191,6 +194,7 @@ $hg_branch\ $docker_context\ $package\ $cmake\ +$cobol\ $dart\ $deno\ $dotnet\ @@ -202,6 +206,7 @@ $helm\ $java\ $julia\ $kotlin\ +$lua\ $nim\ $nodejs\ $ocaml\ @@ -209,6 +214,7 @@ $perl\ $php\ $purescript\ $python\ +$rlang\ $red\ $ruby\ $rust\ @@ -229,7 +235,6 @@ $crystal\ $custom\ $cmd_duration\ $line_break\ -$lua\ $jobs\ $battery\ $time\ @@ -238,6 +243,13 @@ $shell\ $character""" ``` +If you just want to extend the default format, you can use `$all`; modules you explicitly add to the format will not be duplicated. Eg. + +```toml +# Move the directory to the second line +format="$all$directory$character" +``` + ## AWS The `aws` module shows the current AWS region and profile. This is based on `AWS_REGION`, `AWS_DEFAULT_REGION`, and `AWS_PROFILE` env var with `~/.aws/config` file. This module also shows an expiration timer when using temporary credentials. @@ -479,6 +491,36 @@ The `cmake` module shows the currently installed version of [CMake](https://cmak \*: This variable can only be used as a part of a style string +## COBOL / GNUCOBOL + +The `cobol` module shows the currently installed version of COBOL. By default, the module will be shown if any of the following conditions are met: + +- The current directory contains any files ending in `.cob` or `.COB` +- The current directory contains any files ending in `.cbl` or `.CBL` + +### Options + +| Option | Default | Description | +| ------------------- | ------------------------------------ | ------------------------------------------------------------------------- | +| `symbol` | `"⚙️ "` | The symbol used before displaying the version of COBOL. | +| `format` | `"via [$symbol($version )]($style)"` | The format for the module. | +| `version_format` | `"v${raw}"` | The version format. Available vars are `raw`, `major`, `minor`, & `patch` | +| `style` | `"bold blue"` | The style for the module. | +| `detect_extensions` | `["cbl", "cob", "CBL", "COB"]` | Which extensions should trigger this module. | +| `detect_files` | `[]` | Which filenames should trigger this module. | +| `detect_folders` | `[]` | Which folders should trigger this module. | +| `disabled` | `false` | Disables the `cobol` module. | + +### Variables + +| Variable | Example | Description | +| --------- | ---------- | ------------------------------------ | +| version | `v3.1.2.0` | The version of `cobol` | +| 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 + ## Command Duration The `cmd_duration` module shows how long the last command took to execute. The module will be shown only if the command took longer than two seconds, or the `min_time` config value, if it exists. @@ -530,7 +572,7 @@ format = "underwent [$duration](bold yellow)" ## Conda -The `conda` module shows the current conda environment, if `$CONDA_DEFAULT_ENV` is set. +The `conda` module shows the current [Conda](https://docs.conda.io/en/latest/) environment, if `$CONDA_DEFAULT_ENV` is set. ::: tip @@ -1017,6 +1059,35 @@ The `erlang` module shows the currently installed version of [Erlang/OTP](https: format = "via [e $version](bold red) " ``` +## 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. + +### Options + +| Option | Default | Description | +| -------- | -------------- | --------------------------------- | +| `symbol` | `"."` | The symbol used to fill the line. | +| `style` | `"bold black"` | The style for the module. | + +### Example + +```toml +# ~/.config/starship.toml +format="AA $fill BB $fill CC" + +[fill] +symbol = "-" +style = "bold green" +``` + +Produces a prompt that looks like: + +``` +AA -------------------------------------------- BB -------------------------------------------- CC + +``` + ## 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. @@ -1205,12 +1276,13 @@ This module is disabled by default. To enable it, set `disabled` to `false` in y ### Options -| Option | Default | Description | -| --------------- | -------------------------------------------------------- | ---------------------------------- | -| `added_style` | `"bold green"` | The style for the added count. | -| `deleted_style` | `"bold red"` | The style for the deleted count. | -| `format` | `'[+$added]($added_style) [-$deleted]($deleted_style) '` | The format for the module. | -| `disabled` | `true` | Disables the `git_metrics` module. | +| Option | Default | Description | +| -------------------- | ------------------------------------------------------------ | ------------------------------------- | +| `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. | +| `disabled` | `true` | Disables the `git_metrics` module. | ### Variables @@ -1318,9 +1390,9 @@ diverged = "⇕⇡${ahead_count}⇣${behind_count}" behind = "⇣${count}" ``` -## Golang +## Go -The `golang` module shows the currently installed version of [Golang](https://golang.org/). By default the module will be shown if any of the following conditions are met: +The `golang` module shows the currently installed version of [Go](https://golang.org/). By default the module will be shown if any of the following conditions are met: - The current directory contains a `go.mod` file - The current directory contains a `go.sum` file @@ -2041,18 +2113,18 @@ symbol = "☁️ " 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`, `composer`, `gradle`, `julia`, `mix` and `helm` 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 -- [**nimble**](https://github.com/nim-lang/nimble) - The `nimble` package version is extracted from the `*.nimble` file present in the current directory with the `nimble dump` command -- [**poetry**](https://python-poetry.org/) – The `poetry` package version is extracted from the `pyproject.toml` present in the current directory -- [**python**](https://www.python.org) - The `python` package version is extracted from the `setup.cfg` present in the current directory -- [**composer**](https://getcomposer.org/) – The `composer` package version is extracted from the `composer.json` present in the current directory -- [**gradle**](https://gradle.org/) – The `gradle` package version is extracted from the `build.gradle` present -- [**julia**](https://docs.julialang.org/en/v1/stdlib/Pkg/) - The package version is extracted from the `Project.toml` present -- [**mix**](https://hexdocs.pm/mix/) - The `mix` package version is extracted from the `mix.exs` present -- [**helm**](https://helm.sh/docs/helm/helm_package/) - The `helm` chart version is extracted from the `Chart.yaml` present -- [**maven**](https://maven.apache.org/) - The `maven` package version is extracted from the `pom.xml` present -- [**meson**](https://mesonbuild.com/) - The `meson` package version is extracted from the `meson.build` present -- [**vlang**](https://vlang.io) - The `vlang` package version is extracted from the `v.mod` present +- [**Cargo**](https://doc.rust-lang.org/cargo/) – The `cargo` package version is extracted from the `Cargo.toml` present in the current directory +- [**Nimble**](https://github.com/nim-lang/nimble) - The `nimble` package version is extracted from the `*.nimble` file present in the current directory with the `nimble dump` command +- [**Poetry**](https://python-poetry.org/) – The `poetry` package version is extracted from the `pyproject.toml` present in the current directory +- [**Python**](https://www.python.org) - The `python` package version is extracted from the `setup.cfg` present in the current directory +- [**Composer**](https://getcomposer.org/) – The `composer` package version is extracted from the `composer.json` present in the current directory +- [**Gradle**](https://gradle.org/) – The `gradle` package version is extracted from the `build.gradle` present +- [**Julia**](https://docs.julialang.org/en/v1/stdlib/Pkg/) - The package version is extracted from the `Project.toml` present +- [**Mix**](https://hexdocs.pm/mix/) - The `mix` package version is extracted from the `mix.exs` present +- [**Helm**](https://helm.sh/docs/helm/helm_package/) - The `helm` chart version is extracted from the `Chart.yaml` present +- [**Maven**](https://maven.apache.org/) - The `maven` package version is extracted from the `pom.xml` present +- [**Meson**](https://mesonbuild.com/) - The `meson` package version is extracted from the `meson.build` present +- [**V**](https://vlang.io) - The `vlang` package version is extracted from the `v.mod` present > ⚠️ The version being shown is that of the package whose source code is in your current directory, not your package manager. @@ -2296,7 +2368,7 @@ python_binary = ["./venv/bin/python", "python", "python3", "python2"] ## R -The `rlang` module shows the currently installed version of R. The module will be shown if any of the following conditions are met: +The `rlang` module shows the currently installed version of [R](https://www.r-project.org/). The module will be shown if any of the following conditions are met: - The current directory contains a file with the `.R` extension. - The current directory contains a file with the `.Rd` extension. @@ -2539,7 +2611,7 @@ disabled = false ## SHLVL -The `shlvl` module shows the current `SHLVL` ("shell level") environment variable, if it is set to a number and meets or exceeds the specified threshold. +The `shlvl` module shows the current [`SHLVL`](https://tldp.org/LDP/abs/html/internalvariables.html#SHLVLREF) ("shell level") environment variable, if it is set to a number and meets or exceeds the specified threshold. ### Options @@ -2894,9 +2966,9 @@ The `vagrant` module shows the currently installed version of [Vagrant](https:// format = "via [⍱ $version](bold white) " ``` -## VLang +## V -The `vlang` module shows you your currently installed version of V. By default the module will be shown if any of the following conditions are met: +The `vlang` module shows you your currently installed version of [V](https://vlang.io/). By default the module will be shown if any of the following conditions are met: - The current directory contains a file with `.v` extension - The current directory contains a `v.mod`, `vpkg.json` or `.vpkg-lock.json` file @@ -2925,7 +2997,7 @@ The `vlang` module shows you your currently installed version of V. By default t ```toml # ~/.config/starship.toml -[v] +[vlang] format = "via [V $version](blue bold) " ``` diff --git a/docs/ar-SA/guide/README.md b/docs/ar-SA/guide/README.md index 5641182f..b91ef6c4 100644 --- a/docs/ar-SA/guide/README.md +++ b/docs/ar-SA/guide/README.md @@ -48,30 +48,6 @@ height="20" src="https://raw.githubusercontent.com/starship/starship/master/media/flag-us.png" alt="English" - /> -   - 日本語 -   - 繁體中文 -   - Русский   -   - 简体中文   +   + 日本語 +   + Português do Brasil +   + Русский   +   + 简体中文 +   + 繁體中文

@@ -160,8 +168,8 @@ ```sh sh -c "$(curl -fsSL https://starship.rs/install.sh)" ``` - To update the Starship itself, rerun the above script. It will replace the current version without touching Starship's configuration. + To update the Starship itself, rerun the above script. It will replace the current version without touching Starship's configuration. **Note** - The defaults of the install script can be overridden see the built-in help. diff --git a/docs/ar-SA/presets/README.md b/docs/ar-SA/presets/README.md index c6cc6f60..61165f5b 100644 --- a/docs/ar-SA/presets/README.md +++ b/docs/ar-SA/presets/README.md @@ -112,6 +112,9 @@ format = '\[[$symbol($version)]($style)\]' [cmd_duration] format = '\[[⏱ $duration ]($style)\]' +[cobol] +format = '\[[$symbol($version)]($style)\]' + [conda] format = '\[[$symbol$environment]($style)\]' @@ -272,6 +275,9 @@ deleted = "x" [aws] symbol = "aws " +[cobol] +symbol = "cobol " + [conda] symbol = "conda " @@ -375,6 +381,9 @@ This preset hides the version of language runtimes. If you work in containers or [cmake] format = "via [$symbol]($style)" +[cobol] +format = "via [$symbol]($style)" + [crystal] format = "via [$symbol]($style)" diff --git a/docs/ckb-IR/advanced-config/README.md b/docs/ckb-IR/advanced-config/README.md index fc7a8fa1..903a9edc 100644 --- a/docs/ckb-IR/advanced-config/README.md +++ b/docs/ckb-IR/advanced-config/README.md @@ -68,6 +68,33 @@ function set_win_title(){ starship_precmd_user_func="set_win_title" ``` +## Enable Right Prompt + +Some shells support a right prompt which renders on the same line as the input. Starship can set the content of the right prompt using the `right_format` option. Any module that can be used in `format` is also supported in `right_format`. The `$all` variable will only contain modules not explicitly used in either `format` or `right_format`. + +Note: The right prompt is a single line following the input location. To right align modules above the input line in a multi-line prompt, see the [fill module](/config/#fill). + +`right_format` is currently supported for the following shells: elvish, fish, zsh. + +### Example + +```toml +# ~/.config/starship.toml + +# A minimal left prompt +format = """$character""" + +# move the rest of the prompt to the right +right_format = """$all""" +``` + +Produces a prompt like the following: + +``` +▶ starship on  rprompt [!] is 📦 v0.57.0 via 🦀 v1.54.0 took 17s +``` + + ## Style Strings Style strings are a list of words, separated by whitespace. The words are not case sensitive (i.e. `bold` and `BoLd` are considered the same string). Each word can be one of the following: diff --git a/docs/ckb-IR/config/README.md b/docs/ckb-IR/config/README.md index 61f8fcfd..2fb31aa1 100644 --- a/docs/ckb-IR/config/README.md +++ b/docs/ckb-IR/config/README.md @@ -75,7 +75,7 @@ A text group is made up of two different parts. The first part, which is enclosed in a `[]`, is a [format string](#format-strings). You can add texts, variables, or even nested text groups in it. -In the second part, which is enclosed in a `()`, is a [style string](#style-strings). This can be used style the first part. +In the second part, which is enclosed in a `()`, is a [style string](#style-strings). This can be used to style the first part. For example: @@ -142,12 +142,14 @@ This is the list of prompt-wide configuration options. ### Options -| Option | Default | Description | -| ----------------- | ------------------------------ | ------------------------------------------------------------ | -| `format` | [link](#default-prompt-format) | Configure the format of the prompt. | -| `scan_timeout` | `30` | Timeout for starship to scan files (in milliseconds). | -| `command_timeout` | `500` | Timeout for commands executed by starship (in milliseconds). | -| `add_newline` | `true` | Inserts blank line between shell prompts. | +| Option | Default | Description | +| ----------------- | ------------------------------ | ---------------------------------------------------------------- | +| `format` | [link](#default-prompt-format) | Configure the format of the prompt. | +| `right_format` | `""` | See [Enable Right Prompt](/advanced-config/#enable-right-prompt) | +| `scan_timeout` | `30` | Timeout for starship to scan files (in milliseconds). | +| `command_timeout` | `500` | Timeout for commands executed by starship (in milliseconds). | +| `add_newline` | `true` | Inserts blank line between shell prompts. | + ### Example @@ -179,6 +181,7 @@ format = """ $username\ $hostname\ $shlvl\ +$singularity\ $kubernetes\ $directory\ $vcsh\ @@ -191,6 +194,7 @@ $hg_branch\ $docker_context\ $package\ $cmake\ +$cobol\ $dart\ $deno\ $dotnet\ @@ -202,6 +206,7 @@ $helm\ $java\ $julia\ $kotlin\ +$lua\ $nim\ $nodejs\ $ocaml\ @@ -209,6 +214,7 @@ $perl\ $php\ $purescript\ $python\ +$rlang\ $red\ $ruby\ $rust\ @@ -229,7 +235,6 @@ $crystal\ $custom\ $cmd_duration\ $line_break\ -$lua\ $jobs\ $battery\ $time\ @@ -238,6 +243,13 @@ $shell\ $character""" ``` +If you just want to extend the default format, you can use `$all`; modules you explicitly add to the format will not be duplicated. Eg. + +```toml +# Move the directory to the second line +format="$all$directory$character" +``` + ## AWS The `aws` module shows the current AWS region and profile. This is based on `AWS_REGION`, `AWS_DEFAULT_REGION`, and `AWS_PROFILE` env var with `~/.aws/config` file. This module also shows an expiration timer when using temporary credentials. @@ -479,6 +491,36 @@ The `cmake` module shows the currently installed version of [CMake](https://cmak \*: This variable can only be used as a part of a style string +## COBOL / GNUCOBOL + +The `cobol` module shows the currently installed version of COBOL. By default, the module will be shown if any of the following conditions are met: + +- The current directory contains any files ending in `.cob` or `.COB` +- The current directory contains any files ending in `.cbl` or `.CBL` + +### Options + +| Option | Default | Description | +| ------------------- | ------------------------------------ | ------------------------------------------------------------------------- | +| `symbol` | `"⚙️ "` | The symbol used before displaying the version of COBOL. | +| `format` | `"via [$symbol($version )]($style)"` | The format for the module. | +| `version_format` | `"v${raw}"` | The version format. Available vars are `raw`, `major`, `minor`, & `patch` | +| `style` | `"bold blue"` | The style for the module. | +| `detect_extensions` | `["cbl", "cob", "CBL", "COB"]` | Which extensions should trigger this module. | +| `detect_files` | `[]` | Which filenames should trigger this module. | +| `detect_folders` | `[]` | Which folders should trigger this module. | +| `disabled` | `false` | Disables the `cobol` module. | + +### Variables + +| Variable | Example | Description | +| --------- | ---------- | ------------------------------------ | +| version | `v3.1.2.0` | The version of `cobol` | +| 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 + ## Command Duration The `cmd_duration` module shows how long the last command took to execute. The module will be shown only if the command took longer than two seconds, or the `min_time` config value, if it exists. @@ -530,7 +572,7 @@ format = "underwent [$duration](bold yellow)" ## Conda -The `conda` module shows the current conda environment, if `$CONDA_DEFAULT_ENV` is set. +The `conda` module shows the current [Conda](https://docs.conda.io/en/latest/) environment, if `$CONDA_DEFAULT_ENV` is set. ::: tip @@ -1017,6 +1059,35 @@ The `erlang` module shows the currently installed version of [Erlang/OTP](https: format = "via [e $version](bold red) " ``` +## 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. + +### Options + +| Option | Default | Description | +| -------- | -------------- | --------------------------------- | +| `symbol` | `"."` | The symbol used to fill the line. | +| `style` | `"bold black"` | The style for the module. | + +### Example + +```toml +# ~/.config/starship.toml +format="AA $fill BB $fill CC" + +[fill] +symbol = "-" +style = "bold green" +``` + +Produces a prompt that looks like: + +``` +AA -------------------------------------------- BB -------------------------------------------- CC + +``` + ## 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. @@ -1205,12 +1276,13 @@ This module is disabled by default. To enable it, set `disabled` to `false` in y ### Options -| Option | Default | Description | -| --------------- | -------------------------------------------------------- | ---------------------------------- | -| `added_style` | `"bold green"` | The style for the added count. | -| `deleted_style` | `"bold red"` | The style for the deleted count. | -| `format` | `'[+$added]($added_style) [-$deleted]($deleted_style) '` | The format for the module. | -| `disabled` | `true` | Disables the `git_metrics` module. | +| Option | Default | Description | +| -------------------- | ------------------------------------------------------------ | ------------------------------------- | +| `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. | +| `disabled` | `true` | Disables the `git_metrics` module. | ### Variables @@ -1318,9 +1390,9 @@ diverged = "⇕⇡${ahead_count}⇣${behind_count}" behind = "⇣${count}" ``` -## Golang +## Go -The `golang` module shows the currently installed version of [Golang](https://golang.org/). By default the module will be shown if any of the following conditions are met: +The `golang` module shows the currently installed version of [Go](https://golang.org/). By default the module will be shown if any of the following conditions are met: - The current directory contains a `go.mod` file - The current directory contains a `go.sum` file @@ -2041,18 +2113,18 @@ symbol = "☁️ " 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`, `composer`, `gradle`, `julia`, `mix` and `helm` 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 -- [**nimble**](https://github.com/nim-lang/nimble) - The `nimble` package version is extracted from the `*.nimble` file present in the current directory with the `nimble dump` command -- [**poetry**](https://python-poetry.org/) – The `poetry` package version is extracted from the `pyproject.toml` present in the current directory -- [**python**](https://www.python.org) - The `python` package version is extracted from the `setup.cfg` present in the current directory -- [**composer**](https://getcomposer.org/) – The `composer` package version is extracted from the `composer.json` present in the current directory -- [**gradle**](https://gradle.org/) – The `gradle` package version is extracted from the `build.gradle` present -- [**julia**](https://docs.julialang.org/en/v1/stdlib/Pkg/) - The package version is extracted from the `Project.toml` present -- [**mix**](https://hexdocs.pm/mix/) - The `mix` package version is extracted from the `mix.exs` present -- [**helm**](https://helm.sh/docs/helm/helm_package/) - The `helm` chart version is extracted from the `Chart.yaml` present -- [**maven**](https://maven.apache.org/) - The `maven` package version is extracted from the `pom.xml` present -- [**meson**](https://mesonbuild.com/) - The `meson` package version is extracted from the `meson.build` present -- [**vlang**](https://vlang.io) - The `vlang` package version is extracted from the `v.mod` present +- [**Cargo**](https://doc.rust-lang.org/cargo/) – The `cargo` package version is extracted from the `Cargo.toml` present in the current directory +- [**Nimble**](https://github.com/nim-lang/nimble) - The `nimble` package version is extracted from the `*.nimble` file present in the current directory with the `nimble dump` command +- [**Poetry**](https://python-poetry.org/) – The `poetry` package version is extracted from the `pyproject.toml` present in the current directory +- [**Python**](https://www.python.org) - The `python` package version is extracted from the `setup.cfg` present in the current directory +- [**Composer**](https://getcomposer.org/) – The `composer` package version is extracted from the `composer.json` present in the current directory +- [**Gradle**](https://gradle.org/) – The `gradle` package version is extracted from the `build.gradle` present +- [**Julia**](https://docs.julialang.org/en/v1/stdlib/Pkg/) - The package version is extracted from the `Project.toml` present +- [**Mix**](https://hexdocs.pm/mix/) - The `mix` package version is extracted from the `mix.exs` present +- [**Helm**](https://helm.sh/docs/helm/helm_package/) - The `helm` chart version is extracted from the `Chart.yaml` present +- [**Maven**](https://maven.apache.org/) - The `maven` package version is extracted from the `pom.xml` present +- [**Meson**](https://mesonbuild.com/) - The `meson` package version is extracted from the `meson.build` present +- [**V**](https://vlang.io) - The `vlang` package version is extracted from the `v.mod` present > ⚠️ The version being shown is that of the package whose source code is in your current directory, not your package manager. @@ -2296,7 +2368,7 @@ python_binary = ["./venv/bin/python", "python", "python3", "python2"] ## R -The `rlang` module shows the currently installed version of R. The module will be shown if any of the following conditions are met: +The `rlang` module shows the currently installed version of [R](https://www.r-project.org/). The module will be shown if any of the following conditions are met: - The current directory contains a file with the `.R` extension. - The current directory contains a file with the `.Rd` extension. @@ -2539,7 +2611,7 @@ disabled = false ## SHLVL -The `shlvl` module shows the current `SHLVL` ("shell level") environment variable, if it is set to a number and meets or exceeds the specified threshold. +The `shlvl` module shows the current [`SHLVL`](https://tldp.org/LDP/abs/html/internalvariables.html#SHLVLREF) ("shell level") environment variable, if it is set to a number and meets or exceeds the specified threshold. ### Options @@ -2894,9 +2966,9 @@ The `vagrant` module shows the currently installed version of [Vagrant](https:// format = "via [⍱ $version](bold white) " ``` -## VLang +## V -The `vlang` module shows you your currently installed version of V. By default the module will be shown if any of the following conditions are met: +The `vlang` module shows you your currently installed version of [V](https://vlang.io/). By default the module will be shown if any of the following conditions are met: - The current directory contains a file with `.v` extension - The current directory contains a `v.mod`, `vpkg.json` or `.vpkg-lock.json` file @@ -2925,7 +2997,7 @@ The `vlang` module shows you your currently installed version of V. By default t ```toml # ~/.config/starship.toml -[v] +[vlang] format = "via [V $version](blue bold) " ``` diff --git a/docs/ckb-IR/guide/README.md b/docs/ckb-IR/guide/README.md index fe70c18b..9aaf119a 100644 --- a/docs/ckb-IR/guide/README.md +++ b/docs/ckb-IR/guide/README.md @@ -44,30 +44,6 @@ height="20" src="https://raw.githubusercontent.com/starship/starship/master/media/flag-us.png" alt="English" - /> -   - 日本語 -   - 繁體中文 -   - Русский   -   - 简体中文   +   + 日本語 +   + Português do Brasil +   + Русский   +   + 简体中文 +   + 繁體中文

@@ -156,8 +164,8 @@ ```sh sh -c "$(curl -fsSL https://starship.rs/install.sh)" ``` - بۆ نوێکردنەوەی Starship خۆی، نووسینەکەی سەرەوە ڕەن بکەوە. وەشانی ئێستا دەگۆڕێت بێ ئەوەی دەسکاری ڕێکخستنەکانی Starship بکات. + بۆ نوێکردنەوەی Starship خۆی، نووسینەکەی سەرەوە ڕەن بکەوە. وەشانی ئێستا دەگۆڕێت بێ ئەوەی دەسکاری ڕێکخستنەکانی Starship بکات. **تێبینی** - بنەڕەتییەکانی سکریپتی دامەزراندن ئەتوانرێ بگۆڕدرێ سەیری یارمەتی نێوخۆیی بکە. diff --git a/docs/ckb-IR/presets/README.md b/docs/ckb-IR/presets/README.md index 2f7c008d..90e6b314 100644 --- a/docs/ckb-IR/presets/README.md +++ b/docs/ckb-IR/presets/README.md @@ -112,6 +112,9 @@ format = '\[[$symbol($version)]($style)\]' [cmd_duration] format = '\[[⏱ $duration ]($style)\]' +[cobol] +format = '\[[$symbol($version)]($style)\]' + [conda] format = '\[[$symbol$environment]($style)\]' @@ -272,6 +275,9 @@ deleted = "x" [aws] symbol = "aws " +[cobol] +symbol = "cobol " + [conda] symbol = "conda " @@ -375,6 +381,9 @@ This preset hides the version of language runtimes. If you work in containers or [cmake] format = "via [$symbol]($style)" +[cobol] +format = "via [$symbol]($style)" + [crystal] format = "via [$symbol]($style)" diff --git a/docs/de-DE/advanced-config/README.md b/docs/de-DE/advanced-config/README.md index 357bfa0c..88daed46 100644 --- a/docs/de-DE/advanced-config/README.md +++ b/docs/de-DE/advanced-config/README.md @@ -68,9 +68,36 @@ function set_win_title(){ starship_precmd_user_func="set_win_title" ``` +## Enable Right Prompt + +Some shells support a right prompt which renders on the same line as the input. Starship can set the content of the right prompt using the `right_format` option. Any module that can be used in `format` is also supported in `right_format`. The `$all` variable will only contain modules not explicitly used in either `format` or `right_format`. + +Note: The right prompt is a single line following the input location. To right align modules above the input line in a multi-line prompt, see the [fill module](/config/#fill). + +`right_format` is currently supported for the following shells: elvish, fish, zsh. + +### Beispiel + +```toml +# ~/.config/starship.toml + +# A minimal left prompt +format = """$character""" + +# move the rest of the prompt to the right +right_format = """$all""" +``` + +Produces a prompt like the following: + +``` +▶ starship on  rprompt [!] is 📦 v0.57.0 via 🦀 v1.54.0 took 17s +``` + + ## Style-Strings -Style-String sind Wortlisten, getrennt durch Leerzeichen. Die Wörter haben keine Groß- und Kleinschreibung (z.B. `bold` und `BoLd` werden als dieselbe Zeichenkette betrachtet). Jedes Wort kann eines der folgenden sein: +Style strings are a list of words, separated by whitespace. The words are not case sensitive (i.e. `bold` and `BoLd` are considered the same string). Each word can be one of the following: - `bold` - `italic` @@ -82,14 +109,14 @@ Style-String sind Wortlisten, getrennt durch Leerzeichen. Die Wörter haben kein - `` - `none` -wobei `` eine Farbspezifikation ist (siehe unten). `fg:` and `` currently do the same thing, though this may change in the future. `inverted` swaps the background and foreground colors. Die Reihenfolge der Wörter in der Liste spielt keine Rolle. +where `` is a color specifier (discussed below). `fg:` and `` currently do the same thing, though this may change in the future. `inverted` swaps the background and foreground colors. The order of words in the string does not matter. -The `none` token overrides all other tokens in a string if it is not part of a `bg:` specifier, so that e.g. `fg:red none fg:blue` will still create a string with no styling. `bg:none` sets the background to the default color so `fg:red bg:none` is equivalent to `red` or `fg:red` and `bg:green fg:red bg:none` is also equivalent to `fg:red` or `red`. In der Zukunft könnte die Unterstützung von `none` in Verbindung mit anderen Tokens fallen gelassen werden. +The `none` token overrides all other tokens in a string if it is not part of a `bg:` specifier, so that e.g. `fg:red none fg:blue` will still create a string with no styling. `bg:none` sets the background to the default color so `fg:red bg:none` is equivalent to `red` or `fg:red` and `bg:green fg:red bg:none` is also equivalent to `fg:red` or `red`. It may become an error to use `none` in conjunction with other tokens in the future. -Eine Farbspezifikation kann wie folgt aussehen: +A color specifier can be one of the following: - Einer der Standardfarben der Konsole: `black`, `red`, `green`, `blue`, `yellow`, `purple`, `cyan`, `white`. Optional kann ein `bright-` vorangestellt werden um die helle Version zu erhalten (z.B. `bright-white`). - Eine `#` gefolgt von einer sechsstelligen Hexadezimalnummer. Dies ergibt einen [RGB hex Farbcode](https://www.w3schools.com/colors/colors_hexadecimal.asp). - Eine Zahl zwischen 0-255. Dies ergibt einen [8-bit ANSI-Farbcode](https://i.stack.imgur.com/KTSQa.png). -Wenn mehrere Farben für Vordergrund oder Hintergrund angegeben werden, hat die letzte Farbe der Zeichenkette Priorität. +If multiple colors are specified for foreground/background, the last one in the string will take priority. diff --git a/docs/de-DE/config/README.md b/docs/de-DE/config/README.md index 4d6bcb55..66620076 100644 --- a/docs/de-DE/config/README.md +++ b/docs/de-DE/config/README.md @@ -75,7 +75,7 @@ A text group is made up of two different parts. The first part, which is enclosed in a `[]`, is a [format string](#format-strings). You can add texts, variables, or even nested text groups in it. -In the second part, which is enclosed in a `()`, is a [style string](#style-strings). This can be used style the first part. +In the second part, which is enclosed in a `()`, is a [style string](#style-strings). Dies kann verwendet werden, um den ersten Teil zu gestalten. For example: @@ -142,12 +142,14 @@ Dies ist eine Liste mit Prompt-weiten Konfigurationsoptionen. ### Optionen -| Option | Standardwert | Beschreibung | -| ----------------- | ------------------------------ | ------------------------------------------------------------ | -| `format` | [link](#default-prompt-format) | Configure the format of the prompt. | -| `scan_timeout` | `30` | Timeout für das Scannen von Dateien (in Millisekunden). | -| `command_timeout` | `500` | Timeout for commands executed by starship (in milliseconds). | -| `add_newline` | `true` | Inserts blank line between shell prompts. | +| Option | Standardwert | Beschreibung | +| ----------------- | ------------------------------ | ---------------------------------------------------------------- | +| `format` | [link](#default-prompt-format) | Configure the format of the prompt. | +| `right_format` | `""` | See [Enable Right Prompt](/advanced-config/#enable-right-prompt) | +| `scan_timeout` | `30` | Timeout for starship to scan files (in milliseconds). | +| `command_timeout` | `500` | Timeout for commands executed by starship (in milliseconds). | +| `add_newline` | `true` | Inserts blank line between shell prompts. | + ### Beispiel @@ -179,6 +181,7 @@ format = """ $username\ $hostname\ $shlvl\ +$singularity\ $kubernetes\ $directory\ $vcsh\ @@ -191,6 +194,7 @@ $hg_branch\ $docker_context\ $package\ $cmake\ +$cobol\ $dart\ $deno\ $dotnet\ @@ -202,6 +206,7 @@ $helm\ $java\ $julia\ $kotlin\ +$lua\ $nim\ $nodejs\ $ocaml\ @@ -209,6 +214,7 @@ $perl\ $php\ $purescript\ $python\ +$rlang\ $red\ $ruby\ $rust\ @@ -229,7 +235,6 @@ $crystal\ $custom\ $cmd_duration\ $line_break\ -$lua\ $jobs\ $battery\ $time\ @@ -238,9 +243,16 @@ $shell\ $character""" ``` +If you just want to extend the default format, you can use `$all`; modules you explicitly add to the format will not be duplicated. Eg. + +```toml +# Move the directory to the second line +format="$all$directory$character" +``` + ## AWS -Das `aws`-Modul zeigt das aktuelle AWS-Profil an. Dies basiert auf den Umgebungsvariablen: `AWS_REGION`, `AWS_DEFAULT_REGION`, `AWS_PROFILE` und der `~/.aws/config` Datei. This module also shows an expiration timer when using temporary credentials. +The `aws` module shows the current AWS region and profile. This is based on `AWS_REGION`, `AWS_DEFAULT_REGION`, and `AWS_PROFILE` env var with `~/.aws/config` file. This module also shows an expiration timer when using temporary credentials. When using [aws-vault](https://github.com/99designs/aws-vault) the profile is read from the `AWS_VAULT` env var and the credentials expiration date is read from the `AWS_SESSION_EXPIRATION` env var. @@ -314,7 +326,7 @@ symbol = "🅰 " ## Akkustand -Das `battery` Modul zeigt, wie hoch der Akku des Geräts geladen ist und den aktuellen Ladestatus. Das Modul ist nur sichtbar, wenn der Akku des Geräts unter 10% geladen ist. +The `battery` module shows how charged the device's battery is and its current charging status. The module is only visible when the device's battery is below 10%. ### Optionen @@ -342,7 +354,7 @@ discharging_symbol = "💀 " ### Anzeige des Akkustandes -The `display` configuration option is used to define when the battery indicator should be shown (threshold), which symbol would be used (symbol), and what it would like (style). Wenn `display` nicht angegeben ist. Die Standardwerte sind folgende: +The `display` configuration option is used to define when the battery indicator should be shown (threshold), which symbol would be used (symbol), and what it would like (style). If no `display` is provided. Die Standardwerte sind folgende: ```toml [[battery.display]] @@ -354,7 +366,7 @@ The default value for the `charging_symbol` and `discharging_symbol` option is r #### Optionen -Die `display`-Option beinhaltet ein Array mit den folgenden Werten. +The `display` option is an array of the following table. | Option | Standardwert | Beschreibung | | -------------------- | ------------ | --------------------------------------------------------------------------------------------------------- | @@ -381,9 +393,9 @@ discharging_symbol = 💦 ## Zeichen -Das `character` Modul zeigt ein Zeichen ( meistens einen Pfeil "❯") vor der Texteingabe an. +The `character` module shows a character (usually an arrow) beside where the text is entered in your terminal. -Das Zeichen zeigt an ob der letzte Befehl erfolgreich war, oder einen Fehler erzeugt hat. It can do this in two ways: +The character will tell you whether the last command was successful or not. It can do this in two ways: - changing color (`red`/`green`) - changing shape (`❯`/`✖`) @@ -479,31 +491,61 @@ The `cmake` module shows the currently installed version of [CMake](https://cmak \*: This variable can only be used as a part of a style string -## Befehlsdauer +## COBOL / GNUCOBOL -Das `cmd_duration` Modul zeigt an wie lange der letzte Befehl ausgeführt wurde. Das Modul wird nur angezeigt wenn der letzte Befehl länger als zwei Sekunden ausgeführt wurde. Mit der `min_time` Option kann die Zeit eingestellt werden ab der <0>cmd_duration angezeigt wird. +The `cobol` module shows the currently installed version of COBOL. By default, the module will be shown if any of the following conditions are met: -::: warning Nicht die DEBUG-trap in der Bash hooken - -Ist `bash` die Konsole der Wahl, dann nicht die `DEBUG`-trap nach der Ausführung von `eval $(starship init $0)` hooken, andernfalls **wird** dieses Modul unweigerlich untergehen. - -::: - -Bash Nutzer, die eine "preexec" ähnliche Funktion benötigen, können [rcaloras bash_preexec Framework](https://github.com/rcaloras/bash-preexec) verwenden. Definieren Sie einfach die Arrays `preexec_functions` und `precmd_functions` bevor sie `eval $(starship init $0)` ausführen, und fahren Sie dann wie gewohnt fort. +- The current directory contains any files ending in `.cob` or `.COB` +- The current directory contains any files ending in `.cbl` or `.CBL` ### Optionen -| Option | Standardwert | Beschreibung | -| -------------------- | ----------------------------- | ------------------------------------------------------------------ | -| `min_time` | `2_000` | Schwellwert für kleinste anzuzeigende Laufzeit (in Millisekunden). | -| `show_milliseconds` | `false` | Zeige Millisekunden zusätzlich zu Sekunden. | -| `format` | `"took [$duration]($style) "` | The format for the module. | -| `style` | `"bold yellow"` | Stil für dieses Modul. | -| `disabled` | `false` | Deaktiviert das `cmd_duration`-Modul. | -| `show_notifications` | `false` | Show desktop notifications when command completes. | -| `min_time_to_notify` | `45_000` | Shortest duration for notification (in milliseconds). | +| Option | Standardwert | Beschreibung | +| ------------------- | ------------------------------------ | ------------------------------------------------------------------------- | +| `symbol` | `"⚙️ "` | The symbol used before displaying the version of COBOL. | +| `format` | `"via [$symbol($version )]($style)"` | The format for the module. | +| `version_format` | `"v${raw}"` | The version format. Available vars are `raw`, `major`, `minor`, & `patch` | +| `style` | `"bold blue"` | Stil für dieses Modul. | +| `detect_extensions` | `["cbl", "cob", "CBL", "COB"]` | Which extensions should trigger this module. | +| `detect_files` | `[]` | Which filenames should trigger this module. | +| `detect_folders` | `[]` | Which folders should trigger this module. | +| `disabled` | `false` | Disables the `cobol` module. | -::: Tipp +### Variables + +| Variable | Beispiel | Beschreibung | +| --------- | ---------- | ------------------------------------ | +| version | `v3.1.2.0` | The version of `cobol` | +| 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 + +## Befehlsdauer + +The `cmd_duration` module shows how long the last command took to execute. The module will be shown only if the command took longer than two seconds, or the `min_time` config value, if it exists. + +::: warning Do not hook the DEBUG trap in Bash + +If you are running Starship in `bash`, do not hook the `DEBUG` trap after running `eval $(starship init $0)`, or this module **will** break. + +::: + +Bash users who need preexec-like functionality can use [rcaloras's bash_preexec framework](https://github.com/rcaloras/bash-preexec). Simply define the arrays `preexec_functions` and `precmd_functions` before running `eval $(starship init $0)`, and then proceed as normal. + +### Optionen + +| Option | Standardwert | Beschreibung | +| -------------------- | ----------------------------- | ---------------------------------------------------------- | +| `min_time` | `2_000` | Shortest duration to show time for (in milliseconds). | +| `show_milliseconds` | `false` | Show milliseconds in addition to seconds for the duration. | +| `format` | `"took [$duration]($style) "` | The format for the module. | +| `style` | `"bold yellow"` | Stil für dieses Modul. | +| `disabled` | `false` | Disables the `cmd_duration` module. | +| `show_notifications` | `false` | Show desktop notifications when command completes. | +| `min_time_to_notify` | `45_000` | Shortest duration for notification (in milliseconds). | + +::: tip Showing desktop notifications requires starship to be built with `rust-notify` support. You check if your starship supports notifications by running `STARSHIP_LOG=debug starship module cmd_duration -d 60000` when `show_notifications` is set to `true`. @@ -530,24 +572,24 @@ format = "underwent [$duration](bold yellow)" ## Conda -Das `conda`-Modul zeigt dessen aktuelle Umgebung an, sofern `$CONDA_DEFAULT_ENV` gesetzt ist. +The `conda` module shows the current [Conda](https://docs.conda.io/en/latest/) environment, if `$CONDA_DEFAULT_ENV` is set. -::: Tipp +::: tip -Hinweis: Dies unterdrückt nicht conda's eigenen Prompt-Modifikator, sie können jedoch conda mit `conda config --set changeps1 False` konfigurieren, um die Ausgabe von conda selbst auszuschalten. +This does not suppress conda's own prompt modifier, you may want to run `conda config --set changeps1 False`. ::: ### Optionen -| Option | Standardwert | Beschreibung | -| ------------------- | -------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -| `truncation_length` | `1` | Die Anzahl der Verzeichnisse, auf die der Verzeichnisspfad abgeschnitten werden soll, wenn die Umgebung über `conda erstellt wurde -p [path]`. `0` bedeutet keine Kürzung. Beachte auch die Beschreibung für das [`directory`](#directory) Modul. | -| `symbol` | `"🅒 "` | Symbol das vor dem Umgebungsnamen angezeigt wird. | -| `style` | `"bold green"` | Stil für dieses Modul. | -| `format` | `"via [$symbol$environment]($style) "` | The format for the module. | -| `ignore_base` | `true` | Ignores `base` environment when activated. | -| `disabled` | `false` | Deaktiviert das `conda`-Modul. | +| Option | Standardwert | Beschreibung | +| ------------------- | -------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | +| `truncation_length` | `1` | The number of directories the environment path should be truncated to, if the environment was created via `conda create -p [path]`. `0` means no truncation. Also see the [`directory`](#directory) module. | +| `symbol` | `"🅒 "` | The symbol used before the environment name. | +| `style` | `"bold green"` | Stil für dieses Modul. | +| `format` | `"via [$symbol$environment]($style) "` | The format for the module. | +| `ignore_base` | `true` | Ignores `base` environment when activated. | +| `disabled` | `false` | Disables the `conda` module. | ### Variables @@ -572,7 +614,7 @@ format = "[$symbol$environment](dimmed green) " The `crystal` module shows the currently installed version of [Crystal](https://crystal-lang.org/). By default the module will be shown if any of the following conditions are met: -- Das aktuelle Verzeichnis enthält eine `shard.yml`-Datei +- The current directory contains a `shard.yml` file - The current directory contains a `.cr` file ### Optionen @@ -613,7 +655,7 @@ The `dart` module shows the currently installed version of [Dart](https://dart.d - The current directory contains a file with `.dart` extension - The current directory contains a `.dart_tool` directory -- Das aktuelle Verzeichnis enthält `pubspec.yaml`, `pubspec.yml` oder `pubspec.lock` +- The current directory contains a `pubspec.yaml`, `pubspec.yml` or `pubspec.lock` file ### Optionen @@ -684,7 +726,7 @@ format = "via [🦕 $version](green bold) " ## Verzeichnis -Das `directory` -Modul zeigt den Pfad zu Ihrem aktuellen Verzeichnis an, abgeschnitten auf drei übergeordnete Ordner. Your directory will also be truncated to the root of the git repo that you're currently in. +The `directory` module shows the path to your current directory, truncated to three parent folders. Your directory will also be truncated to the root of the git repo that you're currently in. When using the fish style pwd option, instead of hiding the path that is truncated, you will see a shortened name of each directory based on the number you enable for the option. @@ -694,18 +736,18 @@ For example, given `~/Dev/Nix/nixpkgs/pkgs` where `nixpkgs` is the repo root, an | Option | Standardwert | Beschreibung | | ------------------- | -------------------------------------------------- | -------------------------------------------------------------------------------- | -| `truncation_length` | `3` | Die Anzahl der übergeordneten Ordner, die angezeigt werden. | +| `truncation_length` | `3` | The number of parent folders that the current directory should be truncated to. | | `truncate_to_repo` | `true` | Whether or not to truncate to the root of the git repo that you're currently in. | | `format` | `"[$path]($style)[$read_only]($read_only_style) "` | The format for the module. | | `style` | `"bold cyan"` | Stil für dieses Modul. | -| `disabled` | `false` | Deaktiviert das `directory`-Modul. | +| `disabled` | `false` | Disables the `directory` module. | | `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: "…/" | | `home_symbol` | `"~"` | The symbol indicating home directory. |
-Dieses Modul hat einige erweiterte Konfigurationsoptionen, welche die Darstellung von Verzeichnissen steuern. +This module has a few advanced configuration options that control how the directory is displayed. | Advanced Option | Standardwert | Beschreibung | | --------------------------- | ------------ | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------- | @@ -807,13 +849,13 @@ The module will also show the Target Framework Moniker ([\\w-]+)" = "gke-$cluster" ``` -## Zeilenumbruch +## Line Break -Das `line_break`-Modul unterteilt den Prompt in zwei Zeilen. +The `line_break` module separates the prompt into two lines. ### Optionen -| Option | Standardwert | Beschreibung | -| ---------- | ------------ | ---------------------------------------------------------------------- | -| `disabled` | `false` | Deaktiviert das `line_break`-Modul, wodurch der Prompt einzeilig wird. | +| Option | Standardwert | Beschreibung | +| ---------- | ------------ | ------------------------------------------------------------------ | +| `disabled` | `false` | Disables the `line_break` module, making the prompt a single line. | ### Beispiel @@ -1747,27 +1819,27 @@ The `lua` module shows the currently installed version of [Lua](http://www.lua.o format = "via [🌕 $version](bold blue) " ``` -## Speicherauslastung +## Memory Usage -Das `memory_usage` Modul zeigt den aktuellen Systemspeicher und die swap-Nutzung an. +The `memory_usage` module shows current system memory and swap usage. -Standardmäßig wird die swap-Nutzung angezeigt, wenn der gesamte System-swap nicht Null ist. +By default the swap usage is displayed if the total system swap is non-zero. -::: Tipp +::: tip -Dieses Modul ist standardmäßig deaktiviert. Setze in deiner Konfiguration `disabled` auf `false` um es zu aktivieren. +This module is disabled by default. To enable it, set `disabled` to `false` in your configuration file. ::: ### Optionen -| Option | Standardwert | Beschreibung | -| ----------- | ----------------------------------------------- | --------------------------------------------------------------------- | -| `threshold` | `75` | Speicherauslastung ausblenden, wenn sie unter diesem Prozentsatz ist. | -| `format` | `"via $symbol [${ram}( \| ${swap})]($style) "` | The format for the module. | -| `symbol` | `"🐏"` | Symbol das vor der Speicherauslastung angezeigt wird. | -| `style` | `"bold dimmed white"` | Stil für dieses Modul. | -| `disabled` | `true` | Deaktiviert das `memory_usage`-Modul. | +| Option | Standardwert | Beschreibung | +| ----------- | ----------------------------------------------- | -------------------------------------------------------- | +| `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"` | Stil für dieses Modul. | +| `disabled` | `true` | Disables the `memory_usage` module. | ### Variables @@ -1834,7 +1906,7 @@ truncation_symbol = "" The `nim` module shows the currently installed version of [Nim](https://nim-lang.org/). By default the module will be shown if any of the following conditions are met: -- Das aktuelle Verzeichnis enthält eine `nim.cfg`-Datei +- The current directory contains a `nim.cfg` file - The current directory contains a file with the `.nim` extension - The current directory contains a file with the `.nims` extension - The current directory contains a file with the `.nimble` extension @@ -1872,9 +1944,9 @@ style = "yellow" symbol = "🎣 " ``` -## Nix-Shell +## Nix-shell -The `nix_shell` module shows the [nix-shell](https://nixos.org/guides/nix-pills/developing-with-nix-shell.html) environment. Das Modul wird angezeigt, wenn es sich in einer nix-Shell-Umgebung befindet. +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. ### Optionen @@ -1885,7 +1957,7 @@ The `nix_shell` module shows the [nix-shell](https://nixos.org/guides/nix-pills/ | `style` | `"bold blue"` | Stil für dieses Modul. | | `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` | Deaktiviert das `nix_shell`-Modul. | +| `disabled` | `false` | Disables the `nix_shell` module. | ### Variables @@ -1914,10 +1986,10 @@ format = 'via [☃️ $state( \($name\))](bold blue) ' The `nodejs` module shows the currently installed version of [Node.js](https://nodejs.org/). By default the module will be shown if any of the following conditions are met: -- Das aktuelle Verzeichnis enthält eine `package.json`-Datei +- The current directory contains a `package.json` file - The current directory contains a `.node-version` file - The current directory contains a `.nvmrc` file -- Das aktuelle Verzeichnis enthält ein `node_modules`-Verzeichnis +- The current directory contains a `node_modules` directory - The current directory contains a file with the `.js`, `.mjs` or `.cjs` extension - The current directory contains a file with the `.ts` extension @@ -1932,7 +2004,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"` | Stil für dieses Modul. | -| `disabled` | `false` | Deaktiviert das `nodejs`-Modul. | +| `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 @@ -2036,23 +2108,23 @@ style = "bold yellow" symbol = "☁️ " ``` -## Paketversion +## Package Version -Das `Package` Modul wird angezeigt, wenn das aktuelle Verzeichnis das Repository für ein Paket ist, und zeigt dessen aktuelle Version an. The module currently supports `npm`, `nimble`, `cargo`, `poetry`, `composer`, `gradle`, `julia`, `mix` and `helm` 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`, `composer`, `gradle`, `julia`, `mix` and `helm` 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 -- [**nimble**](https://github.com/nim-lang/nimble) - The `nimble` package version is extracted from the `*.nimble` file present in the current directory with the `nimble dump` command -- [**poetry**](https://python-poetry.org/) – The `poetry` package version is extracted from the `pyproject.toml` present in the current directory -- [**python**](https://www.python.org) - The `python` package version is extracted from the `setup.cfg` present in the current directory -- [**composer**](https://getcomposer.org/) – The `composer` package version is extracted from the `composer.json` present in the current directory -- [**gradle**](https://gradle.org/) – The `gradle` package version is extracted from the `build.gradle` present -- [**julia**](https://docs.julialang.org/en/v1/stdlib/Pkg/) - The package version is extracted from the `Project.toml` present -- [**mix**](https://hexdocs.pm/mix/) - The `mix` package version is extracted from the `mix.exs` present -- [**helm**](https://helm.sh/docs/helm/helm_package/) - The `helm` chart version is extracted from the `Chart.yaml` present -- [**maven**](https://maven.apache.org/) - The `maven` package version is extracted from the `pom.xml` present -- [**meson**](https://mesonbuild.com/) - The `meson` package version is extracted from the `meson.build` present -- [**vlang**](https://vlang.io) - The `vlang` package version is extracted from the `v.mod` present +- [**Cargo**](https://doc.rust-lang.org/cargo/) – The `cargo` package version is extracted from the `Cargo.toml` present in the current directory +- [**Nimble**](https://github.com/nim-lang/nimble) - The `nimble` package version is extracted from the `*.nimble` file present in the current directory with the `nimble dump` command +- [**Poetry**](https://python-poetry.org/) – The `poetry` package version is extracted from the `pyproject.toml` present in the current directory +- [**Python**](https://www.python.org) - The `python` package version is extracted from the `setup.cfg` present in the current directory +- [**Composer**](https://getcomposer.org/) – The `composer` package version is extracted from the `composer.json` present in the current directory +- [**Gradle**](https://gradle.org/) – The `gradle` package version is extracted from the `build.gradle` present +- [**Julia**](https://docs.julialang.org/en/v1/stdlib/Pkg/) - The package version is extracted from the `Project.toml` present +- [**Mix**](https://hexdocs.pm/mix/) - The `mix` package version is extracted from the `mix.exs` present +- [**Helm**](https://helm.sh/docs/helm/helm_package/) - The `helm` chart version is extracted from the `Chart.yaml` present +- [**Maven**](https://maven.apache.org/) - The `maven` package version is extracted from the `pom.xml` present +- [**Meson**](https://mesonbuild.com/) - The `meson` package version is extracted from the `meson.build` present +- [**V**](https://vlang.io) - The `vlang` package version is extracted from the `v.mod` present > ⚠️ Die angezeigte Version ist die des Pakets, dessen Quellcode im Verzeichnis liegt, nicht die des Paketmanagers. @@ -2061,11 +2133,11 @@ Das `Package` Modul wird angezeigt, wenn das aktuelle Verzeichnis das Repository | Option | Standardwert | Beschreibung | | ----------------- | --------------------------------- | ------------------------------------------------------------------------- | | `format` | `"is [$symbol$version]($style) "` | The format for the module. | -| `symbol` | `"📦 "` | Symbol das vor der Paketversion angezeigt wird. | +| `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"` | Stil für dieses Modul. | | `display_private` | `false` | Enable displaying version for packages marked as private. | -| `disabled` | `false` | Deaktiviert das `package`-Modul. | +| `disabled` | `false` | Disables the `package` module. | ### Variables @@ -2130,7 +2202,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: -- Das aktuelle Verzeichnis enthält eine `composer.json`-Datei +- The current directory contains a `composer.json` file - The current directory contains a `.php-version` file - The current directory contains a `.php` extension @@ -2140,12 +2212,12 @@ The `php` module shows the currently installed version of [PHP](https://www.php. | ------------------- | ------------------------------------ | ------------------------------------------------------------------------- | | `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` | `"🐘 "` | Symbol das vor der PHP-Version angezeigt wird. | +| `symbol` | `"🐘 "` | The symbol used before displaying the version of PHP. | | `detect_extensions` | `["php"]` | Which extensions should trigger this module. | | `detect_files` | `["composer.json", ".php-version"]` | Which filenames should trigger this module. | | `detect_folders` | `[]` | Which folders should trigger this module. | | `style` | `"147 bold"` | Stil für dieses Modul. | -| `disabled` | `false` | Deaktiviert das `php`-Modul. | +| `disabled` | `false` | Disables the `php` module. | ### Variables @@ -2170,7 +2242,7 @@ format = "via [🔹 $version](147 bold) " The `purescript` module shows the currently installed version of [PureScript](https://www.purescript.org/) version. By default the module will be shown if any of the following conditions are met: -- Das aktuelle Verzeichnis enthält eine `spago.dhall`-Datei +- The current directory contains a `spago.dhall` file - The current directory contains a file with the `.purs` extension ### Optionen @@ -2213,15 +2285,15 @@ If `pyenv_version_name` is set to `true`, it will display the pyenv version name By default the module will be shown if any of the following conditions are met: -- Das aktuelle Verzeichnis enthält eine `.python-version`-Datei -- Das aktuelle Verzeichnis enthält eine `Pipfile`-Datei +- The current directory contains a `.python-version` file +- The current directory contains a `Pipfile` file - The current directory contains a `__init__.py` file -- Das aktuelle Verzeichnis enthält eine `pyproject.toml`-Datei -- Das aktuelle Verzeichnis enthält eine `requirements.txt`-Datei -- Das aktuelle Verzeichnis enthält eine `setup.py`-Datei -- Das aktuelle Verzeichnis enthält eine `tox.ini`-Datei -- Das aktuelle Verzeichnis enthält eine Datei mit der `.py`-Erweiterung. -- Ein virtualenv ist momentan aktiv +- The current directory contains a `pyproject.toml` file +- The current directory contains a `requirements.txt` file +- The current directory contains a `setup.py` file +- The current directory contains a `tox.ini` file +- The current directory contains a file with the `.py` extension. +- A virtual environment is currently activated ### Optionen @@ -2231,15 +2303,15 @@ 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"` | Stil für dieses Modul. | -| `pyenv_version_name` | `false` | Verwende `pyenv` um die Python-Versionzu beziehen. | +| `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` | Deaktiviert das `python`-Modul. | +| `disabled` | `false` | Disables the `python` module. | -::: Tipp +::: tip The `python_binary` variable accepts either a string or a list of strings. Starship will try executing each binary until it gets a result. Note you can only change the binary that Starship executes to get the version of Python not the arguments that are used. @@ -2296,7 +2368,7 @@ python_binary = ["./venv/bin/python", "python", "python3", "python2"] ## R -The `rlang` module shows the currently installed version of R. The module will be shown if any of the following conditions are met: +The `rlang` module shows the currently installed version of [R](https://www.r-project.org/). The module will be shown if any of the following conditions are met: - The current directory contains a file with the `.R` extension. - The current directory contains a file with the `.Rd` extension. @@ -2338,7 +2410,7 @@ format = "with [📐 $version](blue bold) " ## Red -By default the `red` module shows the currently installed version of [Red](https://www.red-lang.org/). Das Modul wird nur dann angezeigt, wenn eine der folgenden Bedingungen zutrifft: +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 @@ -2376,11 +2448,11 @@ symbol = "🔴 " ## Ruby -By default the `ruby` module shows the currently installed version of [Ruby](https://www.ruby-lang.org/). Das Modul wird nur dann angezeigt, wenn eine der folgenden Bedingungen zutrifft: +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: -- Das aktuelle Verzeichnis enthält eine `Gemfile`-Datei +- The current directory contains a `Gemfile` file - The current directory contains a `.ruby-version` file -- Das aktuelle Verzeichnis enthält eine `.rb`-Datei +- The current directory contains a `.rb` file ### Optionen @@ -2393,7 +2465,7 @@ By default the `ruby` module shows the currently installed version of [Ruby](htt | `detect_files` | `["Gemfile", ".ruby-version"]` | Which filenames should trigger this module. | | `detect_folders` | `[]` | Which folders should trigger this module. | | `style` | `"bold red"` | Stil für dieses Modul. | -| `disabled` | `false` | Deaktiviert das `ruby`-Modul. | +| `disabled` | `false` | Disables the `ruby` module. | ### Variables @@ -2416,10 +2488,10 @@ symbol = "🔺 " ## Rust -By default the `rust` module shows the currently installed version of [Rust](https://www.rust-lang.org/). Das Modul wird nur dann angezeigt, wenn eine der folgenden Bedingungen zutrifft: +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: -- Das aktuelle Verzeichnis enthält eine `Cargo.toml`-Datei -- Das aktuelle Verzeichnis enthält eine Datei mit der `.rs`-Erweiterung +- The current directory contains a `Cargo.toml` file +- The current directory contains a file with the `.rs` extension ### Optionen @@ -2432,7 +2504,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"` | Stil für dieses Modul. | -| `disabled` | `false` | Deaktiviert das `rust`-Modul. | +| `disabled` | `false` | Disables the `rust` module. | ### Variables @@ -2497,9 +2569,9 @@ symbol = "🌟 " The `shell` module shows an indicator for currently used shell. -::: Tipp +::: tip -Dieses Modul ist standardmäßig deaktiviert. Setze in deiner Konfiguration `disabled` auf `false` um es zu aktivieren. +This module is disabled by default. To enable it, set `disabled` to `false` in your configuration file. ::: @@ -2539,7 +2611,7 @@ disabled = false ## SHLVL -The `shlvl` module shows the current `SHLVL` ("shell level") environment variable, if it is set to a number and meets or exceeds the specified threshold. +The `shlvl` module shows the current [`SHLVL`](https://tldp.org/LDP/abs/html/internalvariables.html#SHLVLREF) ("shell level") environment variable, if it is set to a number and meets or exceeds the specified threshold. ### Optionen @@ -2609,9 +2681,9 @@ format = '[📦 \[$env\]]($style) ' The `status` module displays the exit code of the previous command. The module will be shown only if the exit code is not `0`. -::: Tipp +::: tip -Dieses Modul ist standardmäßig deaktiviert. Setze in deiner Konfiguration `disabled` auf `false` um es zu aktivieren. +This module is disabled by default. To enable it, set `disabled` to `false` in your configuration file. ::: @@ -2669,7 +2741,7 @@ disabled = false ## Swift -By default the `swift` module shows the currently installed version of [Swift](https://swift.org/). Das Modul wird nur dann angezeigt, wenn eine der folgenden Bedingungen zutrifft: +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 @@ -2710,7 +2782,7 @@ format = "via [🏎 $version](red bold)" The `terraform` module shows the currently selected [Terraform workspace](https://www.terraform.io/docs/language/state/workspaces.html) and version. -::: Tipp +::: tip By default the Terraform version is not shown, since this is slow for current versions of Terraform when a lot of plugins are in use. If you still want to enable it, [follow the example shown below](#with-terraform-version). @@ -2718,7 +2790,7 @@ By default the Terraform version is not shown, since this is slow for current ve By default the module will be shown if any of the following conditions are met: -- Das aktuelle Verzeichnis enthält eine `.terraform`-Datei +- The current directory contains a `.terraform` folder - Current directory contains a file with the `.tf` or `.hcl` extensions ### Optionen @@ -2732,7 +2804,7 @@ By default the module will be shown if any of the following conditions are met: | `detect_files` | `[]` | Which filenames should trigger this module. | | `detect_folders` | `[".terraform"]` | Which folders should trigger this module. | | `style` | `"bold 105"` | Stil für dieses Modul. | -| `disabled` | `false` | Deaktiviert das `terraform` Modul. | +| `disabled` | `false` | Disables the `terraform` module. | ### Variables @@ -2767,33 +2839,33 @@ format = "[🏎💨 $workspace]($style) " ## Zeit -Das `time` Modul zeigt die aktuelle **lokale** Zeit an. Der `format` Wert wird von der crate [`chrono`](https://crates.io/crates/chrono) benutzt um die Zeit zu formatieren. Schau dir [die chrono strftime Dokumentation](https://docs.rs/chrono/0.4.7/chrono/format/strftime/index.html) an, um die möglichen Optionen zu sehen. +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. -::: Tipp +::: tip -Dieses Modul ist standardmäßig deaktiviert. Setze in deiner Konfiguration `disabled` auf `false` um es zu aktivieren. +This module is disabled by default. To enable it, set `disabled` to `false` in your configuration file. ::: ### Optionen -| Option | Standardwert | Beschreibung | -| ----------------- | ----------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------- | -| `format` | `"at [$time]($style) "` | The format string for the module. | -| `use_12hr` | `false` | Aktiviert die Formatierung der Uhrzeit im 12-Stunden-Format. | -| `time_format` | Siehe unten | Das Format zum Anzeigen der Uhrzeit in [chrono-Formatierung](https://docs.rs/chrono/0.4.7/chrono/format/strftime/index.html). | -| `style` | `"bold yellow"` | Stil für dieses Modul. | -| `utc_time_offset` | `"local"` | Legt das UTC-Offset fest, das verwendet werden soll. Range from -24 < x < 24. Allows floats to accommodate 30/45 minute timezone offsets. | -| `disabled` | `true` | Deaktiviert das `time`-Modul. | -| `time_range` | `"-"` | Sets the time range during which the module will be shown. Times must be specified in 24-hours format | +| Option | Standardwert | Beschreibung | +| ----------------- | ----------------------- | ---------------------------------------------------------------------------------------------------------------------------------- | +| `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"`. Ansonsten ist der Standardwert hierfür `"%T"`. Manually setting `time_format` will override the `use_12hr` setting. +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. ### Variables | Variable | Beispiel | Beschreibung | | --------- | ---------- | ----------------------------------- | -| uhrzeit | `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 @@ -2811,16 +2883,16 @@ utc_time_offset = "-5" time_range = "10:00:00-14:00:00" ``` -## Benutzername +## Username -Das Modul `username` zeigt den Benutzernamen des aktiven Benutzers. Das Modul wird nur dann angezeigt, wenn eine der folgenden Bedingungen zutrifft: +The `username` module shows active user's username. The module will be shown if any of the following conditions are met: -- Der aktuelle Benutzer ist root -- Der aktuelle Benutzer ist nicht derjenige, der derzeit angemeldet ist -- Der Benutzer ist über eine SSH-Sitzung verbunden -- Die Variale `show_always` ist auf `true` gesetzt +- The current user is root +- The current user isn't the same as the one that is logged in +- The user is currently connected as an SSH session +- The variable `show_always` is set to true -::: Tipp +::: tip SSH connection is detected by checking environment variables `SSH_CONNECTION`, `SSH_CLIENT`, and `SSH_TTY`. If your SSH host does not set up these variables, one workaround is to set one of them with a dummy value. @@ -2828,13 +2900,13 @@ SSH connection is detected by checking environment variables `SSH_CONNECTION`, ` ### Optionen -| Option | Standardwert | Beschreibung | -| ------------- | ----------------------- | --------------------------------- | -| `style_root` | `"bold red"` | Stil beim root-Benutzer. | -| `style_user` | `"bold yellow"` | Stil bei allen anderen Benutzern. | -| `format` | `"[$user]($style) in "` | The format for the module. | -| `show_always` | `false` | `username`-Modul immer anzeigen. | -| `disabled` | `false` | Deaktiviert das `username`-Modul. | +| Option | Standardwert | Beschreibung | +| ------------- | ----------------------- | ------------------------------------- | +| `style_root` | `"bold red"` | The style used when the user is root. | +| `style_user` | `"bold yellow"` | The style used for non-root users. | +| `format` | `"[$user]($style) in "` | The format for the module. | +| `show_always` | `false` | Always shows the `username` module. | +| `disabled` | `false` | Disables the `username` module. | ### Variables @@ -2894,9 +2966,9 @@ The `vagrant` module shows the currently installed version of [Vagrant](https:// format = "via [⍱ $version](bold white) " ``` -## VLang +## V -The `vlang` module shows you your currently installed version of V. By default the module will be shown if any of the following conditions are met: +The `vlang` module shows you your currently installed version of [V](https://vlang.io/). By default the module will be shown if any of the following conditions are met: - The current directory contains a file with `.v` extension - The current directory contains a `v.mod`, `vpkg.json` or `.vpkg-lock.json` file @@ -2925,7 +2997,7 @@ The `vlang` module shows you your currently installed version of V. By default t ```toml # ~/.config/starship.toml -[v] +[vlang] format = "via [V $version](blue bold) " ``` @@ -2963,7 +3035,7 @@ format = "[🆅 $repo](bold blue) " ## Zig -By default the the `zig` module shows the currently installed version of [Zig](https://ziglang.org/). Das Modul wird nur dann angezeigt, wenn eine der folgenden Bedingungen zutrifft: +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 @@ -3011,19 +3083,19 @@ These modules will be shown if any of the following conditions are met: - The `when` command returns 0 - The current Operating System (std::env::consts::OS) matchs with `os` field if defined. -::: Tipp +::: tip Multiple custom modules can be defined by using a `.`. ::: -::: Tipp +::: tip The order in which custom modules are shown can be individually set by including `${custom.foo}` in the top level `format` (as it includes a dot, you need to use `${...}`). By default, the `custom` module will simply show all custom modules in the order they were defined. ::: -::: Tipp +::: tip [Issue #1252](https://github.com/starship/starship/discussions/1252) contains examples of custom modules. If you have an interesting example not covered there, feel free to share it there! @@ -3031,20 +3103,20 @@ The order in which custom modules are shown can be individually set by including ### Optionen -| Option | Standardwert | Beschreibung | -| -------------- | ------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -| `command` | | The command whose output should be printed. The command will be passed on stdin to the shell. | -| `when` | | A shell command used as a condition to show the module. The module will be shown if the command returns a `0` status code. | -| `shell` | | [See below](#custom-command-shell) | -| `beschreibung` | `""` | The description of the module that is shown when running `starship explain`. | -| `files` | `[]` | The files that will be searched in the working directory for a match. | -| `directories` | `[]` | The directories that will be searched in the working directory for a match. | -| `extensions` | `[]` | The extensions that will be searched in the working directory for a match. | -| `symbol` | `""` | The symbol used before displaying the command output. | -| `style` | `"bold green"` | Stil für dieses Modul. | -| `format` | `"[$symbol($output )]($style)"` | The format for the module. | -| `disabled` | `false` | Disables this `custom` module. | -| `os` | | Operating System name on which the module will be shown (unix, linux, macos, windows, ... ) [See possible values](https://doc.rust-lang.org/std/env/consts/constant.OS.html). | +| Option | Standardwert | Beschreibung | +| ------------- | ------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | +| `command` | | The command whose output should be printed. The command will be passed on stdin to the shell. | +| `when` | | A shell command used as a condition to show the module. The module will be shown if the command returns a `0` status code. | +| `shell` | | [See below](#custom-command-shell) | +| `description` | `""` | The description of the module that is shown when running `starship explain`. | +| `files` | `[]` | The files that will be searched in the working directory for a match. | +| `directories` | `[]` | The directories that will be searched in the working directory for a match. | +| `extensions` | `[]` | The extensions that will be searched in the working directory for a match. | +| `symbol` | `""` | The symbol used before displaying the command output. | +| `style` | `"bold green"` | Stil für dieses Modul. | +| `format` | `"[$symbol($output )]($style)"` | The format for the module. | +| `disabled` | `false` | Disables this `custom` module. | +| `os` | | Operating System name on which the module will be shown (unix, linux, macos, windows, ... ) [See possible values](https://doc.rust-lang.org/std/env/consts/constant.OS.html). | ### Variables diff --git a/docs/de-DE/guide/README.md b/docs/de-DE/guide/README.md index 2e6f8a95..5a12f618 100644 --- a/docs/de-DE/guide/README.md +++ b/docs/de-DE/guide/README.md @@ -48,30 +48,6 @@ height="20" src="https://raw.githubusercontent.com/starship/starship/master/media/flag-us.png" alt="Englisch" - /> -   - 日本語 -   - 繁體中文 -   - Russisch   -   - 简体中文   +   + 日本語 +   + Português do Brasil +   + Русский   Vietnamesisch +   + 简体中文 +   + 繁體中文

@@ -160,8 +168,8 @@ ```sh sh -c "$(curl -fsSL https://starship.rs/install.sh)" ``` - Um Starship selbst zu aktualisieren, lasse das Skript oben nochmal laufen. Es wird die vorhandene Version ersetzen, ohne die Konfiguration von Starship zu berühren. + Um Starship selbst zu aktualisieren, lasse das Skript oben nochmal laufen. Es wird die vorhandene Version ersetzen, ohne die Konfiguration von Starship zu berühren. **Note** - The defaults of the install script can be overridden see the built-in help. diff --git a/docs/de-DE/presets/README.md b/docs/de-DE/presets/README.md index d5b429d2..c265f7df 100644 --- a/docs/de-DE/presets/README.md +++ b/docs/de-DE/presets/README.md @@ -112,6 +112,9 @@ format = '\[[$symbol($version)]($style)\]' [cmd_duration] format = '\[[⏱ $duration ]($style)\]' +[cobol] +format = '\[[$symbol($version)]($style)\]' + [conda] format = '\[[$symbol$environment]($style)\]' @@ -272,6 +275,9 @@ deleted = "x" [aws] symbol = "aws " +[cobol] +symbol = "cobol " + [conda] symbol = "conda " @@ -375,6 +381,9 @@ This preset hides the version of language runtimes. If you work in containers or [cmake] format = "via [$symbol]($style)" +[cobol] +format = "via [$symbol]($style)" + [crystal] format = "via [$symbol]($style)" diff --git a/docs/es-ES/README.md b/docs/es-ES/README.md index 9e6f519c..00b403a6 100644 --- a/docs/es-ES/README.md +++ b/docs/es-ES/README.md @@ -18,7 +18,7 @@ features: footer: Bajo una licencia ISC | Derechos de autor © 2019-presente Colaboradores de Starship #Used for the description meta tag, for SEO metaTitle: "Starship: el prompt multi-intérprete" -description: '¡Starship es el prompt minimalista, ultrarápido e infinitamente personalizable para cualquier intérprete de comandos! Muestra la información que necesitas, a la par que es elegante y minimalista. Quick installation available for Bash, Fish, ZSH, Ion, Tcsh, Elvish, Nu, Xonsh, and PowerShell.' +description: '¡Starship es el prompt minimalista, ultrarápido e infinitamente personalizable para cualquier intérprete de comandos! Muestra la información que necesitas, a la par que es elegante y minimalista. Instalación rápida disponible para Bash, Fish, ZSH, Ion, Tcsh, Elvish, Nu, Xonsh, y PowerShell.' ---
@@ -143,7 +143,7 @@ description: '¡Starship es el prompt minimalista, ultrarápido e infinitamente #### Nushell - ::: warning This will change in the future. Only nu version v0.33 or higher is supported. ::: Add the following to your nu config file. You can check the location of this file by running `config path` in nu. + ::: advertencia Esto cambiará en el futuro. Sólo se admite la versión nu v0.33 o superior. ::: Añade lo siguiente a tu archivo de configuración nu. Puedes comprobar la ubicación de este archivo ejecutando `ruta de configuración` en nu. ```toml startup = [ @@ -157,7 +157,7 @@ description: '¡Starship es el prompt minimalista, ultrarápido e infinitamente #### Xonsh - Add the following to the end of `~/.xonshrc`: + Añade lo siguiente al final de `~/.xonshrc`: ```sh # ~/.xonshrc diff --git a/docs/es-ES/advanced-config/README.md b/docs/es-ES/advanced-config/README.md index c14a7263..d40b72b7 100644 --- a/docs/es-ES/advanced-config/README.md +++ b/docs/es-ES/advanced-config/README.md @@ -21,7 +21,7 @@ function blastoff(){ starship_precmd_user_func="blastoff" ``` -- To run a custom function right before a command runs, you can use the [`DEBUG` trap mechanism](https://jichu4n.com/posts/debug-trap-and-prompt_command-in-bash/). No obstante, ¡**debes** atrapar la señal DEBUG *antes* de inicializar Starship! Starship puede preservar el valor de la trampa DEBUG, pero si la trampa es reemplazada después de que Starship inicie, alguna funcionalidad fallará. +- Para ejecutar una función personalizada antes de que un comando sea ejecutado, es posible usar el [mecanismo de trampa `DEBUG`](https://jichu4n.com/posts/debug-trap-and-prompt_command-in-bash/). No obstante, ¡**debes** atrapar la señal DEBUG *antes* de inicializar Starship! Starship puede preservar el valor de la trampa DEBUG, pero si la trampa es reemplazada después de que Starship inicie, alguna funcionalidad fallará. ```bash function blastoff(){ @@ -33,7 +33,7 @@ eval $(starship init bash) ## Cambiar el Título de la Ventana -Some shell prompts will automatically change the window title for you (e.g. to reflect your working directory). Fish incluso lo hace por defecto. Starship no hace esto, pero es bastante sencillo añadir esta funcionalidad a `Bash` o `zsh`. +Algunos intérpretes de comandos van a cambiar automáticamente el título de la ventana por ti (p. ej., para mostrar tu directorio actual). Fish incluso lo hace por defecto. Starship no hace esto, pero es bastante sencillo añadir esta funcionalidad a `Bash` o `zsh`. Primero, define una función para el cambio de título de la ventana (idéntico en Bash y zsh): @@ -57,7 +57,7 @@ En `zsh`, añade esto al array `precmd_functions`: precmd_functions+=(set_win_title) ``` -If you like the result, add these lines to your shell configuration file (`~/.bashrc` or `~/.zshrc`) to make it permanent. +Si te gusta el resultado, añade estas líneas a tu archivo de configuración del intérprete de comandos (`~/.bashrc` o `~/.zsrhc`) para hacerlo permanente. Por ejemplo, si quieres mostrar tu directorio actual en el título de la pestaña de la terminal, añade el siguiente fragmento a tu `~/.bashrc` o `~/.zshrc`: @@ -68,7 +68,34 @@ function set_win_title(){ starship_precmd_user_func="set_win_title" ``` -## Cadenas de Estilo +## Gabilitar Prompt Derecho + +Algunos intérpretes de órdenes soportan un prompt derecho que se renderiza en la misma línea que la entrada. Starship puede establecer el contenido del prompt correcto usando la opción `right_format`. Cualquier módulo que pueda ser usado en `format` también es soportado en `right_format`. La variable `$all` solo contendrá módulos no utilizados explícitamente en `format` o `right_format`. + +Nota: El prompt derecho es una sola línea siguiendo la ubicación de entrada. Para alinear módulos arriba de la línea de entrada en un prompt multi-línea, vea el [módulo fill](/config/#fill). + +`right_format` está actualmente soportado para los siguientes intérpretes de comandos: elvish, fish, zsh. + +### Ejemplo + +```toml +# ~/.config/starship. oml + +# Un prompt izquierdo mínimo +format = """$character""" + +# mueve el resto del mensaje a la derecha +right_format = """$all""" +``` + +Produce un prompt como el siguiente: + +``` +▶ starship on  rprompt [!] is 📦 v0.57.0 via 🦀 v1.54.0 took 17s +``` + + +## Cadenas de estilo Las cadenas de estilo son una lista de palabras, separadas por espacios en blanco. Las palabras no son sensibles a mayúsculas (es decir, `bold` y `BoLd` se consideran la misma cadena). Cada palabra puede ser una de las siguientes: @@ -82,9 +109,9 @@ Las cadenas de estilo son una lista de palabras, separadas por espacios en blanc - `` - `none` -donde `` es un especificador de color (discutido a continuación). `fg:` and `` currently do the same thing, though this may change in the future. `inverted` swaps the background and foreground colors. El orden de las palabras en la cadena no importa. +donde `` es un especificador de color (discutido a continuación). `fg:` y `` hacen actualmente lo mismo, aunque esto puede cambiar en el futuro. `inverted` cambia el fondo y los colores de primer plano. El orden de las palabras en la cadena no importa. -El token `none` anula todos los demás tokens en una cadena si no es parte de un especificador `bg:`, de modo que por ejemplo `fg:red none fg:blue` creará una cadena sin ningún estilo. `bg:none` sets the background to the default color so `fg:red bg:none` is equivalent to `red` or `fg:red` and `bg:green fg:red bg:none` is also equivalent to `fg:red` or `red`. Puede convertirse en un error usar `none` junto con otros tokens en el futuro. +El token `none` anula todos los demás tokens en una cadena si no es parte de un especificador `bg:`, de modo que por ejemplo `fg:red none fg:blue` creará una cadena sin ningún estilo. `bg:none` establece el fondo al color por defecto, así que `fg:red bg:none` es equivalente a `red` o `fg:red` y `bg:green fg:red bg:none` también es equivalente a `fg:red` o `red`. Puede convertirse en un error usar `none` junto con otros tokens en el futuro. Un especificador de color puede ser uno de los siguientes: diff --git a/docs/es-ES/config/README.md b/docs/es-ES/config/README.md index 93e5a402..c1438aaa 100644 --- a/docs/es-ES/config/README.md +++ b/docs/es-ES/config/README.md @@ -75,7 +75,7 @@ Un grupo de texto se compone de dos partes diferentes. La primera parte, que está encerrada en un `[]`, es una [cadena de formato](#format-strings). Se puede agregar textos, variables, o incluso grupos de texto anidados. -En la segunda parte, que está encerrada entre `()`, es una [cadena de estilo](#style-strings). Se puede utilizar el estilo de la primera parte. +En la segunda parte, que está encerrada entre `()`, es una [cadena de estilo](#style-strings). Esto se puede utilizar para diseñar la primera parte. Por ejemplo: @@ -102,7 +102,7 @@ Una cadena de formato condicional envuelto en `(` y `)` no se renderizará si to Por ejemplo: -- `(@$region)` will show nothing if the variable `region` is `None` or empty string, otherwise `@` followed by the value of region. +- `(@$region)` no mostrará nada si la variable `region` es `None` o una cadena vacía, de lo contrario `@` seguido por el valor de la región. - `(algún texto)` siempre mostrará nada ya que no hay variables envueltas entre llaves. - Cuando `$all` es un atajo para `\[$a$b\]`, `($all)` no mostrará nada solo si `$a` y `$b` ambos son `None`. Esto funciona igual que `(\[$a$b\] )`. @@ -145,10 +145,12 @@ Esta es la lista de opciones de configuración del prompt. | Opción | Por defecto | Descripción | | ----------------- | ---------------------------------- | ------------------------------------------------------------------------------ | | `format` | [ver aquí](#default-prompt-format) | Configura el formato del prompt. | -| `scan_timeout` | `30` | Tiempo de espera tras el que Starship escanea los archivos (en milisegundos). | -| `command_timeout` | `500` | Tiempo de espera para los comandos ejecutados por starship (en milisegundos). | +| `right_format` | `""` | Ver [Habilitar prompt derecho](/advanced-config/#enable-right-prompt) | +| `scan_timeout` | `30` | Tiempo de espera tras el que Starship escanea archivos (en milisegundos). | +| `command_timeout` | `500` | Tiempo de espera para los comandos ejecutados por Starship (en milisegundos). | | `add_newline` | `true` | Inserta un línea en blanco entre las instrucciones del intérprete de comandos. | + ### Ejemplo ```toml @@ -179,6 +181,7 @@ format = """ $username\ $hostname\ $shlvl\ +$singularity\ $kubernetes\ $directory\ $vcsh\ @@ -191,6 +194,7 @@ $hg_branch\ $docker_context\ $package\ $cmake\ +$cobol\ $dart\ $deno\ $dotnet\ @@ -202,6 +206,7 @@ $helm\ $java\ $julia\ $kotlin\ +$lua\ $nim\ $nodejs\ $ocaml\ @@ -209,6 +214,7 @@ $perl\ $php\ $purescript\ $python\ +$rlang\ $red\ $ruby\ $rust\ @@ -229,7 +235,6 @@ $crystal\ $custom\ $cmd_duration\ $line_break\ -$lua\ $jobs\ $battery\ $time\ @@ -238,13 +243,20 @@ $shell\ $character""" ``` +Si solo quieres extender el formato predeterminado, puedes usar `$all`; los módulos que se añaden explícitamente al formato no serán duplicados. Por ejemplo. + +```toml +# Mueve el directorio a la segunda línea +format="$all$directory$character" +``` + ## AWS -El módulo `aws` muestra la región y el perfil actual de AWS. Éste se basa en las variables de entorno `AWS_REGION`, `AWS_DEFAULT_REGION`, y `AWS_PROFILE` del fichero `~/.aws/config`. Este módulo también muestra un temporizador de caducidad al usar credenciales temporales. +El módulo `aws` muestra la región y el perfil AWS actuales. Éste se basa en las variables de entorno `AWS_REGION`, `AWS_DEFAULT_REGION`, y `AWS_PROFILE` del fichero `~/.aws/config`. Este módulo también muestra un temporizador de caducidad al usar credenciales temporales. Cuando se utiliza [aws-vault](https://github.com/99designs/aws-vault), el perfil se lee de la variable de entorno `AWS_VAULT` y la fecha de expiración de credenciales se lee de la variable de entorno `AWS_SESSION_EXPIRATION`. -Cuando uses [awsu](https://github.com/kreuzwerker/awsu) el perfil se obtiene de la variable de entorno `AWSU_PROFILE`. +Cuando se utiliza [awsu](https://github.com/kreuzwerker/awsu) el perfil se lee de la variable de entorno `AWSU_PROFILE`. Cuando se utiliza [AWSume](https://awsu.me), el perfil se lee de la variable de entorno `AWSUME_PROFILE` y la fecha de expiración de credenciales se lee de la variable de entorno `AWSUME_EXPIRATION`. @@ -293,7 +305,7 @@ us-east-1 = "va" # ~/.config/starship.toml [aws] -format = "en [$symbol$region]($style) " +format = "on [$symbol$region]($style) " style = "bold blue" symbol = "🅰 " [aws.region_aliases] @@ -307,14 +319,14 @@ us-east-1 = "va" # ~/.config/starship.toml [aws] -format = "en [$symbol$profile]($style) " +format = "on [$symbol$profile]($style) " style = "bold blue" symbol = "🅰 " ``` ## Battery -El módulo `battery` muestra la cantidad de batería y si se está cargando o no. El módulo es solo visible cuando la batería está por debajo del 10%. +El módulo `battery` muestra qué tan cargada está la batería del dispositivo y su estado de carga actual. El módulo es solo visible cuando la batería está por debajo del 10%. ### Opciones @@ -342,7 +354,7 @@ discharging_symbol = "💀 " ### Indicador de batería -La opción de configuración `display` se utiliza para definir cuándo debe mostrarse el indicador de batería (threshold), qué symbol se utilizaría (symbol), y cómo sería (style). Si no se provee ningún valor para `display` El valor por defecto es el siguiente: +La opción de configuración `display` se utiliza para definir cuándo debe mostrarse el indicador de batería (threshold), cuál símbolo se utilizaría (symbol), y cómo sería (style). Si no se provee ningún valor para `display`, el valor por defecto es el siguiente: ```toml [[battery.display]] @@ -350,11 +362,11 @@ threshold = 10 style = "bold red" ``` -El valor por defecto para las opciones `charging_symbol` y `discharging_symbol` son respectivamente los valores `charging_symbol` y `discharging_symbol` de las opción de `battery`. +El valor por defecto para las opciones `charging_symbol` y `discharging_symbol` son respectivamente los valores `charging_symbol` y `discharging_symbol` de las opciones de `battery`. #### Opciones -La opción `display` es un array de la siguiente tabla. +La opción `display` es un arreglo de la siguiente tabla. | Opción | Por defecto | Descripción | | -------------------- | ----------- | --------------------------------------------------------------------------------------------------------------------------------------- | @@ -366,23 +378,24 @@ La opción `display` es un array de la siguiente tabla. #### Ejemplo ```toml -[[battery.display]] # estilo "bold red" y discharning_symbol cuando la capacidad está entre 0% y 10% +[[battery.display]] # "bold red" style and discharging_symbol when capacity is between 0% and 10% threshold = 10 style = "bold red" -[[battery.display]] # estilo "bold yellow" y el símbolo 💦 cuando la capacidad está entre 10% y 30% +[[battery.display]] # "bold yellow" style and 💦 symbol when capacity is between 10% and 30% threshold = 30 style = "bold yellow" +discharging_symbol = 💦 -# cuando la capadidad está por encima del 30% el indicador no se mostrará +# when capacity is over 30%, the battery indicator will not be displayed ``` ## Character -El módulo `character` muestra un carácter (normalmente una flecha) tras el texto que introduces en el terminal. +El módulo `character` muestra un caracter (normalmente una flecha) tras el texto que introduces en el terminal. -El carácter te dirá si el último comando funcionó o no. Se puede hacer de dos maneras: +El caracter te dirá si el último comando fue exitoso o no. Se puede hacer de dos maneras: - Cambiando el color (`red`/`green`) - Cambiando la forma (`.`/`✖`) @@ -391,13 +404,13 @@ Por defecto sólo cambia el color. Si también se quiere cambiar su forma, ver [ ::: aviso -`error_symbol` is not supported on elvish and nu shell. +`error_symbol` no es compatible con el intérprete de comandos Elvish y Nu. ::: ::: aviso -`vicmd_symbol` sólo es compatible con fish y zsh. +`vicmd_symbol` sólo es compatible con Fish y ZSH. ::: @@ -478,33 +491,63 @@ El módulo `cmake` muestra la versión actualmente instalada de [CMake](https:// \*: Esta variable sólo puede ser usada como parte de una cadena de estilo +## COBOL / GNUCOBOL + +El módulo `cobol` muestra la versión instalada de COBOL. Por defecto, el módulo se mostrará si se cumplen cualquiera de las siguientes condiciones: + +- El directorio actual contiene cualquier archivo que termine en `.cob` o `.COB` +- El directorio actual contiene cualquier archivo que termine en `.cbl` o `.CBL` + +### Opciones + +| Opción | Por defecto | Descripción | +| ------------------- | ------------------------------------ | --------------------------------------------------------------------------------------- | +| `symbol` | `"⚙️ "` | El símbolo usado antes de mostrar la versión de COBOL. | +| `format` | `"via [$symbol($version )]($style)"` | El formato del módulo. | +| `version_format` | `"v${raw}"` | El formato de versión. Las variables disponibles son `raw`, `major`, `minor`, & `patch` | +| `style` | `"bold blue"` | El estilo del módulo. | +| `detect_extensions` | `["cbl", "cob", "CBL", "COB"]` | Qué extensiones deberían activar este módulo. | +| `detect_files` | `[]` | Qué nombres de archivo deberían activar este módulo. | +| `detect_folders` | `[]` | Qué carpetas deberían activar este módulo. | +| `disabled` | `false` | Deshabilita el módulo `cobol`. | + +### Variables + +| Variable | Ejemplo | Descripción | +| --------- | ---------- | -------------------------------------- | +| version | `v3.1.2.0` | La versión de `cobol` | +| symbol | | Refleja el valor de la opción `symbol` | +| style\* | | Refleja el valor de la opción `style` | + +\*: Esta variable sólo puede ser usada como parte de una cadena de estilo + ## Tiempo de Ejecución El módulo `cmd_duration` muestra cuánto tiempo tardó el último comando en ejecutarse. El módulo se mostrará solo si el comando llevó dos segundos o más, o el valor de `min_time`, si existe. -::: warning No utilizar DEBUG en Bash +::: advertencia No utilizar la trampa DEBUG en Bash Si estás usando Starship con `bash`, no uses `DEBUG` después de ejecutar `eval $(starship init $0)`, o el módulo **se romperá**. ::: -Los usuarios de bash que necesiten la funcionalidad preexec-like pueden usar el framework rcaloras's bash_preexec. Simplemente define los arrays preexec_functions y precmd_functions antes de ejecutar eval $(starship init $0), y continúa con normalidad. Basta con definir los arrays `preexec_functions` y `precmd_functions` antes de ejecutar `eval $(starship init $0)`, y luego proceder como siempre. +Los usuarios de Bash que necesiten la funcionalidad como preexec pueden usar el [framework bash_preexec de rcaloras](https://github.com/rcaloras/bash-preexec). Simplemente definir los arreglos `preexec_functions` y `precmd_functions` antes de ejecutar `eval $(starship init $0)`, y luego proceder de forma normal. ### Opciones -| Opción | Por defecto | Descripción | -| -------------------- | ----------------------------- | ---------------------------------------------------------------------- | -| `min_time` | `2_000` | Duración mínima para mostrar el tiempo de ejecución (en milisegundos) | -| `show_milliseconds` | `false` | Muestra la duración con precisión en milisegundos. | -| `format` | `"took [$duration]($style) "` | El formato del módulo. | -| `style` | `"bold yellow"` | El estilo del módulo. | -| `disabled` | `false` | Desactiva el módulo `cmd_duration`. | -| `show_notifications` | `false` | Muestra notificaciones de escritorio cuando se complete el comando. | -| `min_time_to_notify` | `45_000` | Duración mínima para mostrar el tiempo de ejecución (en milisegundos). | +| Opción | Por defecto | Descripción | +| -------------------- | ----------------------------- | ------------------------------------------------------------------- | +| `min_time` | `2_000` | Duración más corta para mostrar el tiempo (en milisegundos). | +| `show_milliseconds` | `false` | Mostrar milisegundos además de segundos para la duración. | +| `format` | `"took [$duration]($style) "` | El formato del módulo. | +| `style` | `"bold yellow"` | El estilo del módulo. | +| `disabled` | `false` | Deshabilita el módulo `cmd_duration`. | +| `show_notifications` | `false` | Muestra notificaciones de escritorio cuando se complete el comando. | +| `min_time_to_notify` | `45_000` | Duración más corta para la notificación (en milisegundos). | ::: consejo -Mostrar notificaciones de escritorio requiere que se construya starship con soporte de `rust-notify`. Comprueba si tu Starship soporta notificaciones ejecutando `STARSHIP_LOG=debug starship module cmd_duration -d 60000` cuando `show_notifications` está establecido en `true`. +Mostrar notificaciones de escritorio requiere que se construya Starship con soporte de `rust-notify`. Comprueba si tu Starship soporta notificaciones ejecutando `STARSHIP_LOG=debug starship module cmd_duration -d 60000` cuando `show_notifications` está establecido en `true`. ::: @@ -529,30 +572,30 @@ format = "underwent [$duration](bold yellow)" ## Conda -El módulo `conda` muestra el actual entorno conda, si la variable `$CONDA_DEFAULT_ENV` existe. +El módulo `conda` muestra el entorno actual [Conda](https://docs.conda.io/en/latest/), si `$CONDA_DEFAULT_ENV` está configurado. ::: consejo -Esto no modifica el propio símbolo de sistema de conda. En caso de querer suprimirlo, ejecuta `conda config --set changeps1 False`. +Esto no modifica el propio símbolo de sistema de Conda. En caso de querer suprimirlo, ejecuta `conda config --set changeps1 False`. ::: ### Opciones -| Opción | Por defecto | Descripción | -| ------------------- | -------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -| `truncation_length` | `1` | El número de directorios a los que se debe truncar la variable de entorno, si el entorno fue creado usando `conda create -p [path]`. `0` significa sin truncamiento. Mirar también el módulo [`directory`](#directory). | -| `symbol` | `"🅒 "` | El símbolo usado antes del nombre del entorno. | -| `style` | `"bold green"` | El estilo del módulo. | -| `format` | `"via [$symbol$environment]($style) "` | El formato del módulo. | -| `ignore_base` | `true` | Ignora el entorno `base` cuando se activa. | -| `disabled` | `false` | Desactiva el módulo `conda`. | +| Opción | Por defecto | Descripción | +| ------------------- | -------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | +| `truncation_length` | `1` | El número de directorios a los que se debe truncar la ruta de entorno, si el entorno fue creado a través de `conda create -p [path]`. `0` significa sin truncamiento. Vea también el módulo [`directory`](#directory). | +| `symbol` | `"🅒 "` | El símbolo usado antes del nombre del entorno. | +| `style` | `"bold green"` | El estilo del módulo. | +| `format` | `"via [$symbol$environment]($style) "` | El formato del módulo. | +| `ignore_base` | `true` | Ignora el entorno `base` cuando se activa. | +| `disabled` | `false` | Deshabilita el módulo `conda`. | ### Variables | Variable | Ejemplo | Descripción | | ----------- | ------------ | -------------------------------------- | -| environment | `astronauts` | El entorno conda actual | +| environment | `astronauts` | El entorno Conda actual | | symbol | | Refleja el valor de la opción `symbol` | | style\* | | Refleja el valor de la opción `style` | @@ -569,7 +612,7 @@ format = "[$symbol$environment](dimmed green) " ## Crystal -The `crystal` module shows the currently installed version of [Crystal](https://crystal-lang.org/). Por defecto, el módulo se mostrará si se cumplen cualquiera de las siguientes condiciones: +El módulo `cristal` muestra la versión instalada de [Crystal](https://crystal-lang.org/). Por defecto, el módulo se mostrará si se cumplen cualquiera de las siguientes condiciones: - El directorio actual contiene un fichero `shard.yml` - El directorio actual contiene un fichero `.cr` @@ -578,14 +621,14 @@ The `crystal` module shows the currently installed version of [Crystal](https:// | Opción | Por defecto | Descripción | | ------------------- | ------------------------------------ | --------------------------------------------------------------------------------------- | -| `symbol` | `"🔮 "` | Símbolo usado antes de la versión de Crystal. | +| `symbol` | `"🔮 "` | El símbolo usado antes de mostrar la versión del crystal. | | `format` | `"via [$symbol($version )]($style)"` | El formato del módulo. | | `version_format` | `"v${raw}"` | El formato de versión. Las variables disponibles son `raw`, `major`, `minor`, & `patch` | | `style` | `"bold red"` | El estilo del módulo. | | `detect_extensions` | `["cr"]` | Qué extensiones deberían activar este módulo. | | `detect_files` | `["shard.yml"]` | Qué nombres de archivo deberían activar este módulo. | | `detect_folders` | `[]` | Qué carpetas deberían activar este módulo. | -| `disabled` | `false` | Desactiva el módulo `crystal`. | +| `disabled` | `false` | Deshabilita el módulo `crystal`. | ### Variables @@ -625,7 +668,7 @@ El módulo `dart` muestra la versión instalada de [Dart](https://dart.dev/). Po | `detect_files` | `["pubspec.yaml", "pubspec.yml", "pubspec.lock"]` | Qué nombres de archivo deberían activar este módulo. | | `detect_folders` | `[".dart_tool"]` | Qué carpetas deberían activar este módulo. | | `style` | `"bold blue"` | El estilo del módulo. | -| `disabled` | `false` | Desactiva el módulo `dart`. | +| `disabled` | `false` | Deshabilita el módulo `dart`. | ### Variables @@ -648,7 +691,7 @@ format = "via [🔰 $version](bold red) " ## Deno -The `deno` module shows you your currently installed version of [Deno](https://deno.land/). Por defecto, el módulo se mostrará si se cumplen cualquiera de las siguientes condiciones: +El módulo `deno` le muestra la versión instalada de [Deno](https://deno.land/). Por defecto, el módulo se mostrará si se cumplen cualquiera de las siguientes condiciones: - El directorio actual contiene un archivo `mod.ts`, `mod.js`, `deps.ts` o `deps.js` ### Opciones @@ -683,36 +726,36 @@ format = "via [🦕 $version](green bold) " ## Directory -El módulo `directory` muestra la ruta hasta el directorio actual, mostrando tres directorios padre como máximo. Tu directorio se truncará a la raíz del repositorio git en el que estés. +The `directory` module shows the path to your current directory, truncated to three parent folders. Your directory will also be truncated to the root of the git repo that you're currently in. -Cuando usas el estilo fish de la opción pwd, en lugar de ocultar la ruta truncada, verás una versión acortada del nombre de cada directorio basada en el número que activa la opción. +When using the fish style pwd option, instead of hiding the path that is truncated, you will see a shortened name of each directory based on the number you enable for the option. -Por ejemplo, dado `~/Dev/Nix/nixpkgs/pkgs` donde `nixpkgs` es la raíz del repositorio y el valor de la opción es `1`. En ese caso, verás `~/D/N/nixpkgs/pkgs`, cuando antes hubiera sido `nixpkgs/pkgs`. +For example, given `~/Dev/Nix/nixpkgs/pkgs` where `nixpkgs` is the repo root, and the option set to `1`. You will now see `~/D/N/nixpkgs/pkgs`, whereas before it would have been `nixpkgs/pkgs`. ### Opciones -| Opción | Por defecto | Descripción | -| ------------------- | -------------------------------------------------- | ------------------------------------------------------------------------------ | -| `truncation_length` | `3` | El número de directorios padre a los que se debe truncar el directorio actual. | -| `truncate_to_repo` | `true` | Truncar o no hasta la raíz del repositorio git en el que se esté. | -| `format` | `"[$path]($style)[$read_only]($read_only_style) "` | El formato del módulo. | -| `style` | `"bold cyan"` | El estilo del módulo. | -| `disabled` | `false` | Deshabilita el módulo `directory`. | -| `read_only` | `"🔒"` | El símbolo que indica si el directorio actual es de sólo lectura. | -| `read_only_style` | `"red"` | El estilo para el símbolo de sólo lectura. | -| `truncation_symbol` | `""` | El símbolo a prefijar a las rutas truncadas. p. ej.: "…/" | -| `home_symbol` | `"~"` | El símbolo que indica el directorio personal. | +| Opción | Por defecto | Descripción | +| ------------------- | -------------------------------------------------- | -------------------------------------------------------------------------------- | +| `truncation_length` | `3` | The number of parent folders that the current directory should be truncated to. | +| `truncate_to_repo` | `true` | Whether or not to truncate to the root of the git repo that you're currently in. | +| `format` | `"[$path]($style)[$read_only]($read_only_style) "` | El formato del módulo. | +| `style` | `"bold cyan"` | El estilo del módulo. | +| `disabled` | `false` | Deshabilita el módulo `directory`. | +| `read_only` | `"🔒"` | El símbolo que indica el directorio actual es de sólo lectura. | +| `read_only_style` | `"red"` | El estilo para el símbolo de sólo lectura. | +| `truncation_symbol` | `""` | El símbolo a prefijar a las rutas truncadas. p. ej.: "…/" | +| `home_symbol` | `"~"` | El símbolo que indica el directorio de inicio. |
Este módulo tiene algunas opciones avanzadas de configuración que controlan cómo se muestra el directorio. -| Opciones Avanzadas | Por defecto | Descripción | -| --------------------------- | ----------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -| `substitutions` | | Una tabla de sustituciones que se deben hacer a la ruta. | -| `fish_style_pwd_dir_length` | `0` | El número de caracteres a usar al aplicar la lógica de ruta pwd del intérprete de comandos de Fish. | -| `use_logical_path` | `true` | Si `true` renderiza la ruta lógica originada desde el intérprete de comandos a través de `PWD` o `--logical-path`. Si `false` en su lugar renderiza la ruta física del sistema de archivos con enlaces simbólicos resueltos. | +| Opción avanzada | Por defecto | Descripción | +| --------------------------- | ----------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------- | +| `sustituciones` | | A table of substitutions to be made to the path. | +| `fish_style_pwd_dir_length` | `0` | The number of characters to use when applying fish shell pwd path logic. | +| `use_logical_path` | `true` | If `true` render the logical path sourced from the shell via `PWD` or `--logical-path`. If `false` instead render the physical filesystem path with symlinks resolved. | -`substitutions` permite definir reemplazos arbitrarios para cadenas literales que ocurren en la ruta, por ejemplo prefijos largos de red o directorios de desarrollo (p. ej. Java). Ten en cuenta que esto desactivará el estilo PWD de fish. +`substitutions` allows you to define arbitrary replacements for literal strings that occur in the path, for example long network prefixes or development directories (i.e. Java). Note that this will disable the fish style PWD. ```toml [directory.substitutions] @@ -720,7 +763,7 @@ Por ejemplo, dado `~/Dev/Nix/nixpkgs/pkgs` donde `nixpkgs` es la raíz del repos "src/com/long/java/path" = "mypath" ``` -`fish_style_pwd_dir_length` interactúa con las opciones de truncamiento estándar de una manera que puede sorprenderse primero: si no es cero, los componentes de la ruta que normalmente se truncarían se muestran con esa cantidad de caracteres. Por ejemplo, la ruta `/built/this/city/on/rock/and/roll`, que normalmente se mostraría como `rock/and/roll`, se mostraría como `/b/t/c/o/rock/and/roll` con `fish_style_pwd_dir_length = 1`--los componentes de ruta que normalmente se eliminarían se muestran con un solo carácter. Para `fish_style_pwd_dir_length = 2`, sería `/bu/th/ci/on/rock/and/roll`. +`fish_style_pwd_dir_length` interacts with the standard truncation options in a way that can be surprising at first: if it's non-zero, the components of the path that would normally be truncated are instead displayed with that many characters. For example, the path `/built/this/city/on/rock/and/roll`, which would normally be displayed as as `rock/and/roll`, would be displayed as `/b/t/c/o/rock/and/roll` with `fish_style_pwd_dir_length = 1`--the path components that would normally be removed are displayed with a single character. For `fish_style_pwd_dir_length = 2`, it would be `/bu/th/ci/on/rock/and/roll`.
@@ -728,7 +771,7 @@ Por ejemplo, dado `~/Dev/Nix/nixpkgs/pkgs` donde `nixpkgs` es la raíz del repos | Variable | Ejemplo | Descripción | | --------- | --------------------- | ------------------------------------- | -| path | `"D:/Projects"` | La ruta del directorio actual | +| path | `"D:/Projects"` | La ruta de directorio actual | | style\* | `"black bold dimmed"` | Refleja el valor de la opción `style` | \*: Esta variable sólo puede ser usada como parte de una cadena de estilo @@ -743,22 +786,22 @@ truncation_length = 8 truncation_symbol = "…/" ``` -## Docker Context +## Contexto de Docker The `docker_context` module shows the currently active [Docker context](https://docs.docker.com/engine/context/working-with-contexts/) if it's not set to `default` or if the `DOCKER_HOST` or `DOCKER_CONTEXT` environment variables are set (as they are meant to override the context in use). ### Opciones -| Opción | Por defecto | Descripción | -| ------------------- | ------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------ | -| `format` | `"via [$symbol$context]($style) "` | El formato del módulo. | -| `symbol` | `"🐳 "` | El símbolo usado antes de mostrar el contexto de Docker. | -| `only_with_files` | `true` | Mostrar solo cuando haya una coincidencia | -| `detect_extensions` | `[]` | Qué extensiones deberían activar este módulo (necesita que `only_with_files` sea verdadero, con un valor "true"). | -| `detect_files` | `["docker-compose.yml", "docker-compose.yaml", "Dockerfile"]` | Qué nombres de archivo deberían activar este módulo (necesita que `only_with_files` sea verdadero, con un valor "true"). | -| `detect_folders` | `[]` | Qué carpetas deberían activar este módulo (necesita que `only_with_files` sea verdadero, con un valor "true"). | -| `style` | `"blue bold"` | El estilo del módulo. | -| `disabled` | `false` | Deshabilita el módulo `docker_context`. | +| Opción | Por defecto | Descripción | +| ------------------- | ------------------------------------------------------------- | ------------------------------------------------------------------------------------------- | +| `format` | `"via [$symbol$context]($style) "` | El formato del módulo. | +| `symbol` | `"🐳 "` | The symbol used before displaying the Docker context. | +| `only_with_files` | `true` | Mostrar solo cuando haya una coincidencia | +| `detect_extensions` | `[]` | Qué extensiones deben activar este módulo (necesita `solly_with_files` para ser verdadero). | +| `detect_files` | `["docker-compose.yml", "docker-compose.yaml", "Dockerfile"]` | Which filenames should trigger this module (needs `only_with_files` to be true). | +| `detect_folders` | `[]` | Which folders should trigger this module (needs `only_with_files` to be true). | +| `style` | `"blue bold"` | El estilo del módulo. | +| `disabled` | `false` | Deshabilita el módulo `docker_context`. | ### Variables @@ -781,9 +824,9 @@ format = "via [🐋 $context](blue bold)" ## Dotnet -El módulo `dotnet` muestra la versión usada de .NET Core SDK para el directorio actual. Si el SDK ha sido anclado en el directorio actual, se mostrará la versión fijada. De lo contrario, el módulo muestra la última versión instalada del SDK. +El módulo `dotnet` muestra la versión relevante del [.NET Core SDK](https://dotnet.microsoft.com/) para el directorio actual. Si el SDK ha sido anclado en el directorio actual, se mostrará la versión fijada. Otherwise the module shows the latest installed version of the SDK. -Por defecto, este módulo solo se mostrará en tu prompt cuando uno o más de de los siguientes archivos estén presentes en el directorio actual: +By default this module will only be shown in your prompt when one or more of the following files are present in the current directory: - `global.json` - `project.json` @@ -794,11 +837,11 @@ Por defecto, este módulo solo se mostrará en tu prompt cuando uno o más de de - `*.fsproj` - `*.xproj` -También necesitará tener instalado .NET Core SDK para poder usarlo correctamente. +You'll also need the .NET Core SDK installed in order to use it correctly. -Internamente, este módulo utiliza su propio mecanismo para la detección de versiones. Normalmente es el doble de rápido que ejecutar `dotnet --version`, pero puede mostrar una versión incorrecta si tu proyecto .NET tiene un diseño de directorio inusual. Si la precisión es más importante que la velocidad, puede desactivar el mecanismo estableciendo `heuristic = false` en las opciones del módulo. +Internamente, este módulo utiliza su propio mecanismo para la detección de versiones. Typically it is twice as fast as running `dotnet --version`, but it may show an incorrect version if your .NET project has an unusual directory layout. If accuracy is more important than speed, you can disable the mechanism by setting `heuristic = false` in the module options. -El módulo también mostrará el Target Framework Moniker ([https://docs.microsoft. om/es/dotnet/standard/frameworks#supported-target-framework-versions](https://docs.microsoft.com/en-us/dotnet/standard/frameworks#supported-target-framework-versions)) cuando exista un archivo csproj en el directorio actual. +The module will also show the Target Framework Moniker () when there is a csproj file in the current directory. ### Opciones @@ -806,22 +849,22 @@ El módulo también mostrará el Target Framework Moniker ([https://docs.microso | ------------------- | ------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------- | | `format` | `"via [$symbol($version )(🎯 $tfm )]($style)"` | El formato del módulo. | | `version_format` | `"v${raw}"` | El formato de versión. Las variables disponibles son `raw`, `major`, `minor`, & `patch` | -| `symbol` | `".NET "` | Símbolo usado antes de mostrar la versión de .NET | -| `heuristic` | `true` | Usa una detección de versiones más rápida para mantener a starship veloz. | +| `symbol` | `".NET "` | The symbol used before displaying the version of dotnet. | +| `heuristic` | `true` | Use faster version detection to keep starship snappy. | | `detect_extensions` | `["csproj", "fsproj", "xproj"]` | Qué extensiones deberían activar este módulo. | | `detect_files` | `["global.json", "project.json", "Directory.Build.props", "Directory.Build.targets", "Packages.props"]` | Qué nombres de archivo deberían activar este módulo. | | `detect_folders` | `[]` | Qué carpetas deberían activar estos módulos. | | `style` | `"bold blue"` | El estilo del módulo. | -| `disabled` | `false` | Deshabilita el módulo `dotnet`. | +| `disabled` | `false` | Disables the `dotnet` module. | ### Variables -| Variable | Ejemplo | Descripción | -| --------- | ---------------- | --------------------------------------------------------------- | -| version | `v3.1.201` | La version del SDK de `dotnet` | -| tfm | `netstandard2.0` | El Target Framework Moniker al que se dirige el proyecto actual | -| symbol | | Refleja el valor de la opción `symbol` | -| style\* | | Refleja el valor de la opción `style` | +| Variable | Ejemplo | Descripción | +| --------- | ---------------- | ------------------------------------------------------------------ | +| version | `v3.1.201` | The version of `dotnet` sdk | +| tfm | `netstandard2.0` | The Target Framework Moniker that the current project is targeting | +| symbol | | Refleja el valor de la opción `symbol` | +| style\* | | Refleja el valor de la opción `style` | \*: Esta variable sólo puede ser usada como parte de una cadena de estilo @@ -840,27 +883,27 @@ heuristic = false The `elixir` module shows the currently installed version of [Elixir](https://elixir-lang.org/) and [Erlang/OTP](https://erlang.org/doc/). Por defecto, el módulo se mostrará si se cumplen cualquiera de las siguientes condiciones: -- El directorio actual contiene un archivo `mix.exs`. +- The current directory contains a `mix.exs` file. ### Opciones | Opción | Por defecto | Descripción | | ------------------- | ----------------------------------------------------------- | --------------------------------------------------------------------------------------- | -| `format` | `'via [$symbol($version \(OTP $otp_version\) )]($style)'` | El formato para el módulo elixir. | +| `format` | `'via [$symbol($version \(OTP $otp_version\) )]($style)'` | The format for the module elixir. | | `version_format` | `"v${raw}"` | El formato de versión. Las variables disponibles son `raw`, `major`, `minor`, & `patch` | -| `symbol` | `"💧 "` | El símbolo usado antes de mostrar la version de Elixir/Erlang. | +| `symbol` | `"💧 "` | The symbol used before displaying the version of Elixir/Erlang. | | `detect_extensions` | `[]` | Qué extensiones deberían activar este módulo. | | `detect_files` | `["mix.exs"]` | Qué nombres de archivo deberían activar este módulo. | | `detect_folders` | `[]` | Qué carpetas deberían activar estos módulos. | | `style` | `"bold purple"` | El estilo del módulo. | -| `disabled` | `false` | Desactiva el módulo `elixir`. | +| `disabled` | `false` | Disables the `elixir` module. | ### Variables | Variable | Ejemplo | Descripción | | ----------- | ------- | -------------------------------------- | -| version | `v1.10` | La version de `elixir` | -| otp_version | | La versión de otp de `elixir` | +| version | `v1.10` | The version of `elixir` | +| otp_version | | The otp version of `elixir` | | symbol | | Refleja el valor de la opción `symbol` | | style\* | | Refleja el valor de la opción `style` | @@ -879,11 +922,11 @@ symbol = "🔮 " The `elm` module shows the currently installed version of [Elm](https://elm-lang.org/). Por defecto, el módulo se mostrará si se cumplen cualquiera de las siguientes condiciones: -- El directorio actual contiene un archivo `elm.json` -- El directorio actual contiene un archivo `elm-package.json` -- El directorio actual contiene un archivo `.elm-version` -- El directorio actual contiene una carpeta `elm-stuff` -- El directorio actual contiene archivos `*.elm` +- The current directory contains a `elm.json` file +- The current directory contains a `elm-package.json` file +- The current directory contains a `.elm-version` file +- The current directory contains a `elm-stuff` folder +- The current directory contains a `*.elm` files ### Opciones @@ -891,18 +934,18 @@ The `elm` module shows the currently installed version of [Elm](https://elm-lang | ------------------- | -------------------------------------------------- | --------------------------------------------------------------------------------------- | | `format` | `"via [$symbol($version )]($style)"` | El formato del módulo. | | `version_format` | `"v${raw}"` | El formato de versión. Las variables disponibles son `raw`, `major`, `minor`, & `patch` | -| `symbol` | `"🌳 "` | Una cadena de formato que representa el símbolo de Elm. | +| `symbol` | `"🌳 "` | A format string representing the symbol of Elm. | | `detect_extensions` | `["elm"]` | Qué extensiones deberían activar este módulo. | | `detect_files` | `["elm.json", "elm-package.json", ".elm-version"]` | Qué nombres de archivo deberían activar este módulo. | | `detect_folders` | `["elm-stuff"]` | Qué carpetas deberían activar estos módulos. | | `style` | `"cyan bold"` | El estilo del módulo. | -| `disabled` | `false` | Desactiva el módulo `elm`. | +| `disabled` | `false` | Disables the `elm` module. | ### Variables | Variable | Ejemplo | Descripción | | --------- | --------- | -------------------------------------- | -| version | `v0.19.1` | La versión de `elm` | +| version | `v0.19.1` | The version of `elm` | | symbol | | Refleja el valor de la opción `symbol` | | style\* | | Refleja el valor de la opción `style` | @@ -919,10 +962,10 @@ format = "via [ $version](cyan bold) " ## Variable de entorno -The `env_var` module displays the current value of a selected environment variables. El módulo se mostrará sólo si se cumplen cualquiera de las siguientes condiciones: +The `env_var` module displays the current value of a selected environment variables. The module will be shown only if any of the following conditions are met: -- La opción de configuración de `variable` coincide con una variable de entorno existente -- La opción de configuración de `variable` no está definida, pero la opción de configuración se encuentra `por defecto` +- The `variable` configuration option matches an existing environment variable +- The `variable` configuration option is not defined, but the `default` configuration option is ::: 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. @@ -938,21 +981,21 @@ default = "unknown user" ### Opciones -| Opción | Por defecto | Descripción | -| ---------- | ------------------------------ | -------------------------------------------------------------------------------------- | -| `symbol` | | El símbolo usado antes de mostrar el valor de la variable. | -| `variable` | | La variable de entorno a mostrar. | -| `default` | | El valor por defecto que se mostrará cuando la variable seleccionada no está definida. | -| `format` | `"with [$env_value]($style) "` | El formato del módulo. | -| `disabled` | `false` | Deshabilita el módulo `env_var`. | +| Opción | Por defecto | Descripción | +| ---------- | ------------------------------ | ---------------------------------------------------------------------------- | +| `symbol` | | The symbol used before displaying the variable value. | +| `variable` | | The environment variable to be displayed. | +| `default` | | The default value to be displayed when the selected variable is not defined. | +| `format` | `"with [$env_value]($style) "` | El formato del módulo. | +| `disabled` | `false` | Disables the `env_var` module. | ### Variables -| Variable | Ejemplo | Descripción | -| --------- | ------------------------------------- | ------------------------------------------- | -| env_value | `Windows NT` (si _variable_ es `$OS`) | El valor de entorno de la opción `variable` | -| symbol | | Refleja el valor de la opción `symbol` | -| style\* | `black bold dimmed` | Refleja el valor de la opción `style` | +| Variable | Ejemplo | Descripción | +| --------- | ------------------------------------------- | ------------------------------------------ | +| env_value | `Windows NT` (if _variable_ would be `$OS`) | The environment value of option `variable` | +| symbol | | Refleja el valor de la opción `symbol` | +| style\* | `black bold dimmed` | Refleja el valor de la opción `style` | \*: Esta variable sólo puede ser usada como parte de una cadena de estilo @@ -981,8 +1024,8 @@ default = "unknown user" The `erlang` module shows the currently installed version of [Erlang/OTP](https://erlang.org/doc/). Por defecto, el módulo se mostrará si se cumplen cualquiera de las siguientes condiciones: -- El directorio actual contiene un fichero `rebar.config`. -- El directorio actual contiene un fichero `erlang.mk`. +- The current directory contains a `rebar.config` file. +- The current directory contains a `erlang.mk` file. ### Opciones @@ -990,18 +1033,18 @@ The `erlang` module shows the currently installed version of [Erlang/OTP](https: | ------------------- | ------------------------------------ | --------------------------------------------------------------------------------------- | | `format` | `"via [$symbol($version )]($style)"` | El formato del módulo. | | `version_format` | `"v${raw}"` | El formato de versión. Las variables disponibles son `raw`, `major`, `minor`, & `patch` | -| `symbol` | `" "` | El símbolo usado antes de mostrar la versión de Erlang. | +| `symbol` | `" "` | The symbol used before displaying the version of erlang. | | `style` | `"bold red"` | El estilo del módulo. | | `detect_extensions` | `[]` | Qué extensiones deberían activar este módulo. | | `detect_files` | `["rebar.config", "elang.mk"]` | Qué nombres de archivo deberían activar este módulo. | | `detect_folders` | `[]` | Qué carpetas deberían activar estos módulos. | -| `disabled` | `false` | Desactiva el módulo `erlang`. | +| `disabled` | `false` | Disables the `erlang` module. | ### Variables | Variable | Ejemplo | Descripción | | --------- | --------- | -------------------------------------- | -| version | `v22.1.3` | La versión de `erlang` | +| version | `v22.1.3` | The version of `erlang` | | symbol | | Refleja el valor de la opción `symbol` | | style\* | | Refleja el valor de la opción `style` | @@ -1016,31 +1059,60 @@ The `erlang` module shows the currently installed version of [Erlang/OTP](https: format = "via [e $version](bold red) " ``` -## Google Cloud (`gcloud`) +## Llenar -El módulo `gcloud` muestra la configuración actual para el CLI de [`gcloud`](https://cloud.google.com/sdk/gcloud). Esto se basa en el archivo `~/.config/gcloud/active_config`, el archivo `~/.config/gcloud/configurations/config_{CONFIG NAME}` y la variable de entorno `CLOUDSDK_CONFIG`. +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. Esto es útil para alinear otros módulos. ### Opciones -| Opción | Por defecto | Descripción | -| ---------------- | ---------------------------------------------------------- | ---------------------------------------------------------- | -| `format` | `'on [$symbol$account(@$domain)(\($region\))]($style) '` | El formato del módulo. | -| `symbol` | `"☁️ "` | El símbolo usado antes de mostrar el perfil actual de GCP. | -| `region_aliases` | | Tabla de alias de región a mostrar además del nombre GCP. | -| `style` | `"bold blue"` | El estilo del módulo. | -| `disabled` | `false` | Deshabilita el módulo `gcloud`. | +| Opción | Por defecto | Descripción | +| -------- | -------------- | ------------------------------------------ | +| `symbol` | `"."` | El símbolo utilizado para llenar la línea. | +| `style` | `"bold black"` | El estilo del módulo. | + +### Ejemplo + +```toml +# ~/.config/starship.toml +format="AA $fill BB $fill CC" + +[fill] +symbol = "-" +style = "bold green" +``` + +Produces a prompt that looks like: + +``` +AA -------------------------------------------- BB -------------------------------------------- CC + +``` + +## 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. + +### Opciones + +| Opción | Por defecto | Descripción | +| ---------------- | ---------------------------------------------------------- | --------------------------------------------------------------- | +| `format` | `'on [$symbol$account(@$domain)(\($region\))]($style) '` | El formato del módulo. | +| `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"` | El estilo del módulo. | +| `disabled` | `false` | Deshabilita el módulo `gcloud`. | ### Variables -| Variable | Ejemplo | Descripción | -| --------- | ------------- | ----------------------------------------------------------------------------- | -| region | `us-central1` | La región GCP actual | -| account | `foo` | El perfil actual de GCP | -| domain | `example.com` | The current GCP profile domain | -| project | | El proyecto GCP actual | -| active | `default` | El nombre de configuración activo escrito en `~/.config/gcloud/active_config` | -| symbol | | Refleja el valor de la opción `symbol` | -| style\* | | Refleja el valor de la opción `style` | +| Variable | Ejemplo | Descripción | +| --------- | ------------- | ------------------------------------------------------------------ | +| region | `us-central1` | The current GCP region | +| cuenta | `foo` | El perfil actual de GCP | +| dominio | `ejemplo.com` | The current GCP profile domain | +| proyecto | | The current GCP project | +| activo | `default` | The active config name written in `~/.config/gcloud/active_config` | +| symbol | | Refleja el valor de la opción `symbol` | +| style\* | | Refleja el valor de la opción `style` | \*: Esta variable sólo puede ser usada como parte de una cadena de estilo @@ -1079,30 +1151,30 @@ asia-northeast1 = "an1" ## Git Branch -El módulo `git_branch` muestra la rama activa del repositorio en tu directorio actual. +The `git_branch` module shows the active branch of the repo in your current directory. ### Opciones -| Opción | Por defecto | Descripción | -| -------------------- | -------------------------------- | ------------------------------------------------------------------------------------------------------------- | -| `always_show_remote` | `false` | Muestra el nombre de la rama de seguimiento remoto, incluso si es igual al nombre de la rama local. | -| `format` | `"on [$symbol$branch]($style) "` | El formato del módulo. Usar `"$branch"` para referirse al nombre de la rama actual. | -| `symbol` | `" "` | Una cadena de formato que representa el símbolo de la rama git. | -| `style` | `"bold purple"` | El estilo del módulo. | -| `truncation_length` | `2^63 - 1` | Trunca el nombre de la rama a `N` grafemas. | -| `truncation_symbol` | `"…"` | El símbolo usado para indicar que un nombre de rama fue truncado. Se puede utilizar `""` para ningún símbolo. | -| `only_attached` | `false` | Mostrar solo el hash de la confirmación de git cuando esté en estado "detached `HEAD`" | -| `disabled` | `false` | Deshabilita el módulo `git_branch`. | +| Opción | Por defecto | Descripción | +| -------------------- | -------------------------------- | ---------------------------------------------------------------------------------------- | +| `always_show_remote` | `false` | Shows the remote tracking branch name, even if it is equal to the local branch name. | +| `format` | `"on [$symbol$branch]($style) "` | El formato del módulo. Use `"$branch"` to refer to the current branch name. | +| `symbol` | `" "` | A format string representing the symbol of git branch. | +| `style` | `"bold purple"` | El estilo del módulo. | +| `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. | +| `disabled` | `false` | Disables the `git_branch` module. | ### Variables -| Variable | Ejemplo | Descripción | -| ------------- | -------- | -------------------------------------------------------------------------------------------------------------- | -| branch | `master` | El nombre de la rama actual, vuelve a `HEAD` si no hay ninguna rama actual (por ejemplo, git detached `HEAD`). | -| remote_name | `origin` | El nombre remoto. | -| remote_branch | `master` | El nombre de la rama rastreada en `remote_name`. | -| symbol | | Refleja el valor de la opción `symbol` | -| style\* | | Refleja el valor de la opción `style` | +| Variable | Ejemplo | Descripción | +| ------------- | --------- | ------------------------------------------------------------------------------------------------------ | +| rama | `maestro` | The current branch name, falls back to `HEAD` if there's no current branch (e.g. git detached `HEAD`). | +| remote_name | `origen` | El nombre remoto. | +| remote_branch | `maestro` | The name of the branch tracked on `remote_name`. | +| symbol | | Refleja el valor de la opción `symbol` | +| style\* | | Refleja el valor de la opción `style` | \*: Esta variable sólo puede ser usada como parte de una cadena de estilo @@ -1119,26 +1191,26 @@ truncation_symbol = "" ## Git commit -El módulo `git_commit` muestra el hash de la confirmación actual y también la etiqueta (si existe) del repositorio en su directorio actual. +The `git_commit` module shows the current commit hash and also the tag (if any) of the repo in your current directory. ### Opciones -| Opción | Por defecto | Descripción | -| -------------------- | ---------------------------------- | -------------------------------------------------------------------------------------- | -| `commit_hash_length` | `7` | La longitud del hash de la confirmación de git mostrado. | -| `format` | `"[\\($hash$tag\\)]($style) "` | El formato del módulo. | -| `style` | `"bold green"` | El estilo del módulo. | -| `only_detached` | `true` | Mostrar solo el hash de la confirmación de git cuando esté en estado "detached `HEAD`" | -| `tag_disabled` | `true` | Deshabilita mostrar información de etiquetas en el módulo `git_commit`. | -| `tag_symbol` | `" 🏷 "` | Símbolo de etiqueta prefijando la información mostrada | -| `disabled` | `false` | Deshabilita el módulo `git_commit`. | +| Opción | Por defecto | Descripción | +| -------------------- | ---------------------------------- | ------------------------------------------------------- | +| `commit_hash_length` | `7` | The length of the displayed git commit hash. | +| `format` | `"[\\($hash$tag\\)]($style) "` | El formato del módulo. | +| `style` | `"bold green"` | El estilo del módulo. | +| `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_symbol` | `" 🏷 "` | Tag symbol prefixing the info shown | +| `disabled` | `false` | Disables the `git_commit` module. | ### Variables -| Variable | Ejemplo | Descripción | -| --------- | --------- | ---------------------------------------- | -| hash | `b703eb3` | El hash actual de la confirmación de git | -| style\* | | Refleja el valor de la opción `style` | +| Variable | Ejemplo | Descripción | +| --------- | --------- | ------------------------------------- | +| hash | `b703eb3` | The current git commit hash | +| style\* | | Refleja el valor de la opción `style` | \*: Esta variable sólo puede ser usada como parte de una cadena de estilo @@ -1154,30 +1226,30 @@ tag_symbol = "🔖 " ## Git State -El módulo `git_state` se mostrará en directorios que son parte de un repositorio git, y donde hay una operación en curso, tales como: _REBASING_, _BISECTING_, etc. Si hay información de progreso (por ejemplo, REBASING 3/10), esa información será mostrada también. +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. ### Opciones -| Opción | Por defecto | Descripción | -| -------------- | --------------------------------------------------------------- | --------------------------------------------------------------------------------------------------- | -| `rebase` | `"REBASING"` | Una cadena de formato que se muestra cuando un `rebase` está en progreso. | -| `merge` | `"MERGING"` | Una cadena de formato que se muestra cuando un `merge` está en progreso. | -| `revert` | `"REVERTING"` | Una cadena de formato mostrada cuando un `revert` está en progreso. | -| `cherry_pick` | `"CHERRY-PICKING"` | Una cadena de formato que se muestra cuando un `cherry-pick` está en progreso. | -| `bisect` | `"BISECTING"` | Una cadena de formato que se muestra cuando un `bisect` está en progreso. | -| `am` | `"AM"` | Una cadena de formato que se muestra cuando un `apply-mailbox` (`git am`) está en progeso. | -| `am_or_rebase` | `"AM/REBASE"` | Una cadena de formato que se muestra cuando un ambiguo `apply-mailbox` o `rebase` está en progreso. | -| `style` | `"bold yellow"` | El estilo del módulo. | -| `format` | `'\([$state( $progress_current/$progress_total)]($style)\) '` | El formato del módulo. | -| `disabled` | `false` | Deshabilita el módulo `git_state`. | +| Opción | Por defecto | Descripción | +| -------------- | --------------------------------------------------------------- | --------------------------------------------------------------------------------------- | +| `rebase` | `"REBASING"` | A format string displayed when a `rebase` is in progress. | +| `merge` | `"MERGING"` | A format string displayed when a `merge` is in progress. | +| `revertir` | `"REVERTING"` | A format string displayed when a `revert` is in progress. | +| `cherry_pick` | `"CHERRY-PICKING"` | A format string displayed when a `cherry-pick` is in progress. | +| `bisect` | `"BISECTING"` | A format string displayed when a `bisect` is in progress. | +| `am` | `"AM"` | A format string displayed when an `apply-mailbox` (`git am`) is in progress. | +| `am_or_rebase` | `"AM/REBASE"` | A format string displayed when an ambiguous `apply-mailbox` or `rebase` is in progress. | +| `style` | `"bold yellow"` | El estilo del módulo. | +| `format` | `'\([$state( $progress_current/$progress_total)]($style)\) '` | El formato del módulo. | +| `disabled` | `false` | Disables the `git_state` module. | ### Variables | Variable | Ejemplo | Descripción | | ---------------- | ---------- | ------------------------------------- | -| state | `REBASING` | El estado actual del repositorio | -| progress_current | `1` | El progreso de la operación actual | -| progress_total | `2` | El progreso total de la operación | +| state | `REBASING` | The current state of the repo | +| progress_current | `1` | The current operation progress | +| progress_total | `2` | The total operation progress | | style\* | | Refleja el valor de la opción `style` | \*: Esta variable sólo puede ser usada como parte de una cadena de estilo @@ -1198,18 +1270,19 @@ The `git_metrics` module will show the number of added and deleted lines in the ::: consejo -Este módulo está deshabilitado por defecto. Para activarlo, establece `disabled` a `false` en tu archivo de configuración. +This module is disabled by default. To enable it, set `disabled` to `false` in your configuration file. ::: ### Opciones -| Opción | Por defecto | Descripción | -| --------------- | -------------------------------------------------------- | ---------------------------------- | -| `added_style` | `"bold green"` | The style for the added count. | -| `deleted_style` | `"bold red"` | The style for the deleted count. | -| `format` | `'[+$added]($added_style) [-$deleted]($deleted_style) '` | El formato del módulo. | -| `disabled` | `true` | Disables the `git_metrics` module. | +| Opción | Por defecto | Descripción | +| -------------------- | ------------------------------------------------------------ | ------------------------------------- | +| `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) )'` | El formato del módulo. | +| `disabled` | `true` | Disables the `git_metrics` module. | ### Variables @@ -1234,58 +1307,58 @@ format = '[+$added]($added_style)/[-$deleted]($deleted_style) ' ## Git status -El módulo `git_status` muestra símbolos que representan el estado del repositorio en su directorio actual. +The `git_status` module shows symbols representing the state of the repo in your current directory. ### Opciones -| Opción | Por defecto | Descripción | -| ------------ | ----------------------------------------------- | ---------------------------------------- | -| `format` | `'([\[$all_status$ahead_behind\]]($style) )'` | El formato por defecto para `git_status` | -| `conflicted` | `"="` | Esta rama tiene conflictos de fusión. | -| `ahead` | `"⇡"` | El formato de `ahead` | -| `behind` | `"⇣"` | El formato de `behind` | -| `diverged` | `"⇕"` | El formato de `diverged` | -| `up_to_date` | `""` | The format of `up_to_date` | -| `untracked` | `"?"` | El formato de `untracked` | -| `stashed` | `"$"` | El formato de `stashed` | -| `modified` | `"!"` | El formato de `modified` | -| `staged` | `"+"` | El formato de `staged` | -| `renamed` | `"»"` | El formato de `renamed` | -| `deleted` | `"✘"` | El formato de `deleted` | -| `style` | `"bold red"` | El estilo del módulo. | -| `disabled` | `false` | Desactiva el módulo `git_status`. | +| Opción | Por defecto | Descripción | +| ------------ | ----------------------------------------------- | ----------------------------------- | +| `format` | `'([\[$all_status$ahead_behind\]]($style) )'` | The default format for `git_status` | +| `conflicted` | `"="` | This branch has merge conflicts. | +| `ahead` | `"⇡"` | The format of `ahead` | +| `behind` | `"⇣"` | The format of `behind` | +| `diverged` | `"⇕"` | The format of `diverged` | +| `up_to_date` | `""` | The format of `up_to_date` | +| `untracked` | `"?"` | The format of `untracked` | +| `stashed` | `"$"` | The format of `stashed` | +| `modificado` | `"!"` | The format of `modified` | +| `staged` | `"+"` | The format of `staged` | +| `renamed` | `"»"` | The format of `renamed` | +| `eliminado` | `"✘"` | The format of `deleted` | +| `style` | `"bold red"` | El estilo del módulo. | +| `disabled` | `false` | Disables the `git_status` module. | ### Variables -Las siguientes variables se pueden utilizar en `format`: +The following variables can be used in `format`: | Variable | Descripción | | -------------- | ------------------------------------------------------------------------------------------------------------- | -| `all_status` | Atajo para `$conflicted$stashed$deleted$renamed$modified$staged$untracked` | +| `all_status` | Shortcut for`$conflicted$stashed$deleted$renamed$modified$staged$untracked` | | `ahead_behind` | Displays `diverged`, `ahead`, `behind` or `up_to_date` format string based on the current status of the repo. | -| `conflicted` | Muestra `conflicted` cuando esta rama tiene conflictos de fusión. | -| `untracked` | Muestra `untracked` cuando hay archivos sin rastrear en el directorio de trabajo. | -| `stashed` | Muestra `stashed` cuando existe un "stash" para el repositorio local. | -| `modified` | Muestra `modified` cuando hay modificaciones de archivo en el directorio de trabajo. | -| `staged` | Muestra `staged` cuando se ha añadido un nuevo archivo al área de "stash". | -| `renamed` | Muestra `renamed` cuando un archivo renombrado ha sido añadido al área de "stash". | -| `deleted` | Muestra `deleted` cuando un archivo ha sido añadido al área de "stash". | +| `conflicted` | Displays `conflicted` when this branch has merge conflicts. | +| `untracked` | Displays `untracked` when there are untracked files in the working directory. | +| `stashed` | Displays `stashed` when a stash exists for the local repository. | +| `modificado` | Displays `modified` when there are file modifications in the working directory. | +| `staged` | Displays `staged` when a new file has been added to the staging area. | +| `renamed` | Displays `renamed` when a renamed file has been added to the staging area. | +| `deleted` | Displays `deleted` when a file's deletion has been added to the staging area. | | style\* | Refleja el valor de la opción `style` | \*: Esta variable sólo puede ser usada como parte de una cadena de estilo -Las siguientes variables pueden ser usadas en `diverged`: +The following variables can be used in `diverged`: -| Variable | Descripción | -| -------------- | ------------------------------------------------------- | -| `ahead_count` | Número de commits por delante de la rama de seguimiento | -| `behind_count` | Número de commits detrás de la rama de seguimiento | +| Variable | Descripción | +| -------------- | ---------------------------------------------- | +| `ahead_count` | Number of commits ahead of the tracking branch | +| `behind_count` | Number of commits behind the tracking branch | -Las siguientes variales pueden ser usadas en `conflicted`, `ahead`, `behind`, `untracked`, `stashed`, `modified`, `staged`, `renamed` y `deleted`: +The following variables can be used in `conflicted`, `ahead`, `behind`, `untracked`, `stashed`, `modified`, `staged`, `renamed` and `deleted`: | Variable | Descripción | | -------- | ----------------------------- | -| `count` | Muestra el número de archivos | +| `count` | Mostrar el número de archivos | ### Ejemplo @@ -1306,7 +1379,7 @@ renamed = "👅" deleted = "🗑" ``` -Mostrar el recuento delante/detrás de la rama que está siendo rastreada +Show ahead/behind count of the branch being tracked ```toml # ~/.config/starship.toml @@ -1317,18 +1390,18 @@ diverged = "⇕⇡${ahead_count}⇣${behind_count}" behind = "⇣${count}" ``` -## Golang +## Go -The `golang` module shows the currently installed version of [Golang](https://golang.org/). Por defecto, el módulo se mostrará si se cumplen cualquiera de las siguientes condiciones: +The `golang` module shows the currently installed version of [Go](https://golang.org/). Por defecto, el módulo se mostrará si se cumplen cualquiera de las siguientes condiciones: -- El directorio actual contiene un archivo `go.mod` -- El directorio actual contiene un archivo `go.sum` -- El directorio actual contiene un archivo `glide.yaml` -- El directorio actual contiene un archivo `Gopkg.yml` -- El directorio actual contiene un archivo `Gopkg.lock` -- El directorio actual contiene un archivo `.go-version` -- El directorio actual contiene un directorio `Godeps` -- El directorio actual contiene un archivo con la extensión `.go` +- The current directory contains a `go.mod` file +- The current directory contains a `go.sum` file +- The current directory contains a `glide.yaml` file +- The current directory contains a `Gopkg.yml` file +- The current directory contains a `Gopkg.lock` file +- The current directory contains a `.go-version` file +- The current directory contains a `Godeps` directory +- The current directory contains a file with the `.go` extension ### Opciones @@ -1336,12 +1409,12 @@ The `golang` module shows the currently installed version of [Golang](https://go | ------------------- | ------------------------------------------------------------------------------ | --------------------------------------------------------------------------------------- | | `format` | `"via [$symbol($version )]($style)"` | El formato del módulo. | | `version_format` | `"v${raw}"` | El formato de versión. Las variables disponibles son `raw`, `major`, `minor`, & `patch` | -| `symbol` | `"🐹 "` | Una cadena de formato que representa el símbolo de Go. | +| `symbol` | `"🐹 "` | A format string representing the symbol of Go. | | `detect_extensions` | `["go"]` | Qué extensiones deberían activar este módulo. | | `detect_files` | `["go.mod", "go.sum", "glide.yaml", "Gopkg.yml", "Gopkg.lock", ".go-version"]` | Qué nombres de archivo deberían activar este módulo. | | `detect_folders` | `["Godeps"]` | Qué carpetas deberían activar este módulo. | | `style` | `"bold cyan"` | El estilo del módulo. | -| `disabled` | `false` | Desactiva el módulo de `golang`. | +| `disabled` | `false` | Deshabilita el módulo de `golang`. | ### Variables @@ -1366,8 +1439,8 @@ format = "via [🏎💨 $version](bold cyan) " The `helm` module shows the currently installed version of [Helm](https://helm.sh/). Por defecto, el módulo se mostrará si se cumplen cualquiera de las siguientes condiciones: -- El directorio actual contiene un fichero `helmfile.yaml` -- El directorio actual contiene un archivo `Chart.yaml` +- The current directory contains a `helmfile.yaml` file +- The current directory contains a `Chart.yaml` file ### Opciones @@ -1378,9 +1451,9 @@ The `helm` module shows the currently installed version of [Helm](https://helm.s | `detect_extensions` | `[]` | Qué extensiones deberían activar este módulo. | | `detect_files` | `["helmfile.yaml", "Chart.yaml"]` | Qué nombres de archivo deberían activar este módulo. | | `detect_folders` | `[]` | Qué carpetas deberían activar estos módulos. | -| `symbol` | `"⎈ "` | Una cadena de formato que representa el símbolo de Helm. | +| `symbol` | `"⎈ "` | A format string representing the symbol of Helm. | | `style` | `"bold white"` | El estilo del módulo. | -| `disabled` | `false` | Desactiva el módulo `helm`. | +| `disabled` | `false` | Disables the `helm` module. | ### Variables @@ -1403,17 +1476,17 @@ format = "via [⎈ $version](bold white) " ## Hostname -El módulo `hostname` muestra el nombre de host del sistema. +The `hostname` module shows the system hostname. ### Opciones -| Opción | Por defecto | Descripción | -| ---------- | --------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------- | -| `ssh_only` | `true` | Mostrar sólo el nombre de host cuando esté conectado a una sesión SSH. | -| `trim_at` | `"."` | Cadena en la que el nombre de host se corta, después de la primera partida. `"."` se detendrá después del primer punto. `""` deshabilitará cualquier truncamiento | -| `format` | `"[$hostname]($style) in "` | El formato del módulo. | -| `style` | `"bold dimmed green"` | El estilo del módulo. | -| `disabled` | `false` | Desactiva el módulo `hostname`. | +| Opción | Por defecto | Descripción | +| ---------- | --------------------------- | ------------------------------------------------------------------------------------------------------------------------------------ | +| `ssh_only` | `true` | Only show hostname when connected to an 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` | `"[$hostname]($style) in "` | El formato del módulo. | +| `style` | `"bold dimmed green"` | El estilo del módulo. | +| `disabled` | `false` | Disables the `hostname` module. | ### Variables @@ -1440,8 +1513,8 @@ disabled = false The `java` module shows the currently installed version of [Java](https://www.oracle.com/java/). Por defecto, el módulo se mostrará si se cumplen cualquiera de las siguientes condiciones: -- El directorio actual contiene un archivo `pom.xml`, `build.gradle.kts`, `build.sbt`, `.java-version`, `.deps.edn`, `project.clj`, o `build.boot` -- El directorio actual contiene un archivo con la extensión `.java`, `.class`, `.gradle` o `.jar`, `.clj` o `.cljc` +- 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 ### Opciones @@ -1452,9 +1525,9 @@ The `java` module shows the currently installed version of [Java](https://www.or | `detect_extensions` | `["java", "class", "gradle", "jar", "cljs", "cljc"]` | Qué extensiones deberían activar este módulo. | | `detect_files` | `["pom.xml", "build.gradle.kts", "build.sbt", ".java-version", ".deps.edn", "project.clj", "build.boot"]` | Qué nombres de archivo deberían activar este módulo. | | `detect_folders` | `[]` | Qué carpetas deberían activar estos módulos. | -| `symbol` | `"☕ "` | Una cadena de formato que representa el símbolo de Java | +| `symbol` | `"☕ "` | A format string representing the symbol of Java | | `style` | `"red dimmed"` | El estilo del módulo. | -| `disabled` | `false` | Desactiva el módulo `java`. | +| `disabled` | `false` | Disables the `java` module. | ### Variables @@ -1475,9 +1548,9 @@ The `java` module shows the currently installed version of [Java](https://www.or symbol = "🌟 " ``` -## Jobs +## Trabajos -El módulo `jobs` muestra el número actual de tareas en ejecución. El módulo se mostrará sólo si hay tareas en segundo plano ejecutándose. 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: @@ -1501,13 +1574,13 @@ The `threshold` option is deprecated, but if you want to use it, the module will | Opción | Por defecto | Descripción | | ------------------ | ----------------------------- | ------------------------------------------------------------------------ | -| `threshold`\* | `1` | Muestra el número de tareas si se exceden. | +| `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) "` | El formato del módulo. | | `symbol` | `"✦"` | The string used to represent the `symbol` variable. | | `style` | `"bold blue"` | El estilo del módulo. | -| `disabled` | `false` | Desactiva el módulo `jobs`. | +| `disabled` | `false` | Disables the `jobs` module. | \*: This option is deprecated, please use the `number_threshold` and `symbol_threshold` options instead. @@ -1516,7 +1589,7 @@ The `threshold` option is deprecated, but if you want to use it, the module will | Variable | Ejemplo | Descripción | | --------- | ------- | -------------------------------------- | -| number | `1` | El número de tareas | +| número | `1` | The number of jobs | | symbol | | Refleja el valor de la opción `symbol` | | style\* | | Refleja el valor de la opción `style` | @@ -1537,9 +1610,9 @@ symbol_threshold = 0 The `julia` module shows the currently installed version of [Julia](https://julialang.org/). Por defecto, el módulo se mostrará si se cumplen cualquiera de las siguientes condiciones: -- El directorio actual contiene un archivo `Project.toml` -- El directorio actual contiene un archivo `Manifest.toml` -- El directorio actual contiene un archivo con la extensión `.jl` +- The current directory contains a `Project.toml` file +- The current directory contains a `Manifest.toml` file +- The current directory contains a file with the `.jl` extension ### Opciones @@ -1550,15 +1623,15 @@ The `julia` module shows the currently installed version of [Julia](https://juli | `detect_extensions` | `["jl"]` | Qué extensiones deberían activar este módulo. | | `detect_files` | `["Project.toml", "Manifest.toml"]` | Qué nombres de archivo deberían activar este módulo. | | `detect_folders` | `[]` | Qué carpetas deberían activar estos módulos. | -| `symbol` | `"ஃ "` | Una cadena de formato que representa el símbolo de Julia. | +| `symbol` | `"ஃ "` | A format string representing the symbol of Julia. | | `style` | `"bold purple"` | El estilo del módulo. | -| `disabled` | `false` | Desactiva el módulo `julia`. | +| `disabled` | `false` | Disables the `julia` module. | ### Variables | Variable | Ejemplo | Descripción | | --------- | -------- | -------------------------------------- | -| version | `v1.4.0` | La versión de `julia` | +| version | `v1.4.0` | The version of `julia` | | symbol | | Refleja el valor de la opción `symbol` | | style\* | | Refleja el valor de la opción `style` | @@ -1577,7 +1650,7 @@ symbol = "∴ " The `kotlin` module shows the currently installed version of [Kotlin](https://kotlinlang.org/). Por defecto, el módulo se mostrará si se cumplen cualquiera de las siguientes condiciones: -- El directorio actual contiene un archivo `.kt` o `.kts` +- El directorio actual contiene un archivo `.kt` o un `.kts` ### Opciones @@ -1588,10 +1661,10 @@ The `kotlin` module shows the currently installed version of [Kotlin](https://ko | `detect_extensions` | `["kt", "kts"]` | Qué extensiones deberían activar este módulo. | | `detect_files` | `[]` | Qué nombres de archivo deberían activar este módulo. | | `detect_folders` | `[]` | Qué carpetas deberían activar estos módulos. | -| `symbol` | `"🅺 "` | Una cadena de formato que representa el símbolo de Kotlin. | +| `symbol` | `"🅺 "` | A format string representing the symbol of Kotlin. | | `style` | `"bold blue"` | El estilo del módulo. | -| `kotlin_binary` | `"kotlin"` | Configura el binario kotlin que Starship ejecuta al obtener la versión. | -| `disabled` | `false` | Deshabilita el módulo `kotlin`. | +| `kotlin_binary` | `"kotlin"` | Configures the kotlin binary that Starship executes when getting the version. | +| `disabled` | `false` | Disables the `kotlin` module. | ### Variables @@ -1616,38 +1689,38 @@ symbol = "🅺 " # ~/.config/starship.toml [kotlin] -# Utiliza el binario del Compilador de Kotlin para obtener la versión instalada +# Uses the Kotlin Compiler binary to get the installed version kotlin_binary = "kotlinc" ``` ## Kubernetes -Displays the current [Kubernetes context](https://kubernetes.io/docs/concepts/configuration/organize-cluster-access-kubeconfig/#context) name and, if set, the namespace from the kubeconfig file. El espacio de nombres necesita establecerse en el archivo kubeconfig, esto puede hacerse mediante `kubectl config set-context starship-cluster --namespace astronaut`. Si se establece la variable de entorno `$KUBECONFIG`, el módulo usará eso si no usará el `~/.kube/config`. +Displays the current [Kubernetes context](https://kubernetes.io/docs/concepts/configuration/organize-cluster-access-kubeconfig/#context) name and, if set, the namespace from the kubeconfig file. The namespace needs to be set in the kubeconfig file, this can be done via `kubectl config set-context starship-cluster --namespace astronaut`. If the `$KUBECONFIG` env var is set the module will use that if not it will use the `~/.kube/config`. ::: consejo -Este módulo está deshabilitado por defecto. Para activarlo, establece `disabled` a `false` en tu archivo de configuración. +This module is disabled by default. To enable it, set `disabled` to `false` in your configuration file. ::: ### Opciones -| Opción | Por defecto | Descripción | -| ----------------- | ---------------------------------------------------- | --------------------------------------------------------------------------- | -| `symbol` | `"☸ "` | Una cadena de formato que representa el símbolo mostrado antes del Cluster. | -| `format` | `'[$symbol$context( \($namespace\))]($style) in '` | El formato del módulo. | -| `style` | `"cyan bold"` | El estilo del módulo. | -| `context_aliases` | | Tabla de alias de contexto a mostrar. | -| `disabled` | `true` | Desactiva el módulo `kubernetes`. | +| Opción | Por defecto | Descripción | +| ----------------- | ---------------------------------------------------- | --------------------------------------------------------------------- | +| `symbol` | `"☸ "` | A format string representing the symbol displayed before the Cluster. | +| `format` | `'[$symbol$context( \($namespace\))]($style) in '` | El formato del módulo. | +| `style` | `"cyan bold"` | El estilo del módulo. | +| `context_aliases` | | Table of context aliases to display. | +| `disabled` | `true` | Disables the `kubernetes` module. | ### Variables -| Variable | Ejemplo | Descripción | -| --------- | -------------------- | ----------------------------------------------------------- | -| context | `starship-cluster` | El contexto actual de kubernetes | -| namespace | `starship-namespace` | Si se establece, el espacio de nombres actual de kubernetes | -| symbol | | Refleja el valor de la opción `symbol` | -| style\* | | Refleja el valor de la opción `style` | +| Variable | Ejemplo | Descripción | +| --------- | -------------------- | ---------------------------------------- | +| context | `starship-cluster` | The current kubernetes context | +| namespace | `starship-namespace` | If set, the current kubernetes namespace | +| symbol | | Refleja el valor de la opción `symbol` | +| style\* | | Refleja el valor de la opción `style` | \*: Esta variable sólo puede ser usada como parte de una cadena de estilo @@ -1686,15 +1759,15 @@ Long and automatically generated cluster names can be identified and shortened u "gke_.*_(?P[\\w-]+)" = "gke-$cluster" ``` -## Salto de línea +## Line Break -El módulo `line_break` separa el indicador en dos líneas. +The `line_break` module separates the prompt into two lines. ### Opciones -| Opción | Por defecto | Descripción | -| ---------- | ----------- | ------------------------------------------------------------------------------- | -| `disabled` | `false` | Deshabilita el módulo `line_break`, haciendo que el mensaje sea una sola línea. | +| Opción | Por defecto | Descripción | +| ---------- | ----------- | ------------------------------------------------------------------ | +| `disabled` | `false` | Disables the `line_break` module, making the prompt a single line. | ### Ejemplo @@ -1709,9 +1782,9 @@ disabled = true The `lua` module shows the currently installed version of [Lua](http://www.lua.org/). Por defecto, el módulo se mostrará si se cumplen cualquiera de las siguientes condiciones: -- El directorio actual contiene un archivo `.lua-version` -- El directorio actual contiene un directorio `lua` -- El directorio actual contiene un archivo con la extensión `.lua` +- The current directory contains a `.lua-version` file +- The current directory contains a `lua` directory +- The current directory contains a file with the `.lua` extension ### Opciones @@ -1719,19 +1792,19 @@ The `lua` module shows the currently installed version of [Lua](http://www.lua.o | ------------------- | ------------------------------------ | --------------------------------------------------------------------------------------- | | `format` | `"via [$symbol($version )]($style)"` | El formato del módulo. | | `version_format` | `"v${raw}"` | El formato de versión. Las variables disponibles son `raw`, `major`, `minor`, & `patch` | -| `symbol` | `"🌙 "` | Una cadena de formato que representa el símbolo de Lua. | +| `symbol` | `"🌙 "` | A format string representing the symbol of Lua. | | `detect_extensions` | `["lua"]` | Qué extensiones deberían activar este módulo. | | `detect_files` | `[".lua-version"]` | Qué nombres de archivo deberían activar este módulo. | | `detect_folders` | `["lua"]` | Qué carpetas deberían activar este módulo. | | `style` | `"bold blue"` | El estilo del módulo. | -| `lua_binary` | `"lua"` | Configura el binario de lua que Starship ejecuta al obtener la versión. | -| `disabled` | `false` | Desactiva el módulo `lua`. | +| `lua_binary` | `"lua"` | Configures the lua binary that Starship executes when getting the version. | +| `disabled` | `false` | Disables the `lua` module. | ### Variables | Variable | Ejemplo | Descripción | | --------- | -------- | -------------------------------------- | -| version | `v5.4.0` | La versión de `lua` | +| version | `v5.4.0` | The version of `lua` | | symbol | | Refleja el valor de la opción `symbol` | | style\* | | Refleja el valor de la opción `style` | @@ -1746,40 +1819,40 @@ The `lua` module shows the currently installed version of [Lua](http://www.lua.o format = "via [🌕 $version](bold blue) " ``` -## Memoria utilizada +## Memory Usage -El módulo `memory_usage` muestra la memoria del sistema actual y el uso de memoria de intercambio. +The `memory_usage` module shows current system memory and swap usage. -Por defecto, el uso de swap se muestra si el intercambio total del sistema no es cero. +By default the swap usage is displayed if the total system swap is non-zero. ::: consejo -Este módulo está deshabilitado por defecto. Para activarlo, establece `disabled` a `false` en tu archivo de configuración. +This module is disabled by default. To enable it, set `disabled` to `false` in your configuration file. ::: ### Opciones -| Opción | Por defecto | Descripción | -| ----------- | ----------------------------------------------- | ------------------------------------------------------------- | -| `threshold` | `75` | Ocultar el uso de memoria a menos que supere este porcentaje. | -| `format` | `"via $symbol [${ram}( \| ${swap})]($style) "` | El formato del módulo. | -| `symbol` | `"🐏"` | El símbolo usado antes de mostrar el uso de memoria. | -| `style` | `"bold dimmed white"` | El estilo del módulo. | -| `disabled` | `true` | Desactiva el módulo `memory_usage`. | +| Opción | Por defecto | Descripción | +| ----------- | ----------------------------------------------- | -------------------------------------------------------- | +| `threshold` | `75` | Hide the memory usage unless it exceeds this percentage. | +| `format` | `"via $symbol [${ram}( \| ${swap})]($style) "` | El formato del módulo. | +| `symbol` | `"🐏"` | The symbol used before displaying the memory usage. | +| `style` | `"bold dimmed white"` | El estilo del módulo. | +| `disabled` | `true` | Disables the `memory_usage` module. | ### Variables -| Variable | Ejemplo | Descripción | -| ---------------- | ------------- | ---------------------------------------------------------------------------------- | -| ram | `31GiB/65GiB` | La memoria RAM usada/total del sistema actual. | -| ram_pct | `48%` | El porcentaje de la memoria actual del sistema. | -| swap\*\* | `1GiB/4GiB` | El tamaño de la memoria de intercambio del archivo de memoria del sistema actual. | -| swap_pct\*\* | `77%` | El porcentaje de memoria de intercambio del archivo de memoria del sistema actual. | -| symbol | `🐏` | Refleja el valor de la opción `symbol` | -| style\* | | Refleja el valor de la opción `style` | +| Variable | Ejemplo | Descripción | +| ---------------- | ------------- | ------------------------------------------------------------------ | +| ram | `31GiB/65GiB` | The usage/total RAM of the current system memory. | +| ram_pct | `48%` | The percentage of the current system memory. | +| swap\*\* | `1GiB/4GiB` | The swap memory size of the current system swap memory file. | +| swap_pct\*\* | `77%` | The swap memory percentage of the current system swap memory file. | +| symbol | `🐏` | Refleja el valor de la opción `symbol` | +| style\* | | Refleja el valor de la opción `style` | -\*: Esta variable sólo puede utilizarse como parte de una cadena de estilo \*\*: La información del archivo SWAP sólo se muestra si se detecta en el sistema actual +\*: This variable can only be used as a part of a style string \*\*: The SWAP file information is only displayed if detected on the current system ### Ejemplo @@ -1795,26 +1868,26 @@ style = "bold dimmed green" ## Mercurial Branch -El módulo `hg_branch` muestra la rama activa del repositorio en su directorio actual. +The `hg_branch` module shows the active branch of the repo in your current directory. ### Opciones -| Opción | Por defecto | Descripción | -| ------------------- | -------------------------------- | --------------------------------------------------------------------------------------------------- | -| `symbol` | `" "` | El símbolo usado antes del marcador hg o nombre de la rama del repositorio en su directorio actual. | -| `style` | `"bold purple"` | El estilo del módulo. | -| `format` | `"on [$symbol$branch]($style) "` | El formato del módulo. | -| `truncation_length` | `2^63 - 1` | Trunca el nombre de la rama hg a `N` grafemas | -| `truncation_symbol` | `"…"` | El símbolo usado para indicar que un nombre de rama fue truncado. | -| `disabled` | `true` | Desactiva el módulo `hg_branch`. | +| Opción | Por defecto | Descripción | +| ------------------- | -------------------------------- | -------------------------------------------------------------------------------------------- | +| `symbol` | `" "` | The symbol used before the hg bookmark or branch name of the repo in your current directory. | +| `style` | `"bold purple"` | El estilo del módulo. | +| `format` | `"on [$symbol$branch]($style) "` | El formato del módulo. | +| `truncation_length` | `2^63 - 1` | Truncates the hg branch name to `N` graphemes | +| `truncation_symbol` | `"…"` | The symbol used to indicate a branch name was truncated. | +| `disabled` | `true` | Deshabilita el módulo `hg_branch`. | ### Variables -| Variable | Ejemplo | Descripción | -| --------- | -------- | -------------------------------------- | -| branch | `master` | La rama de mercurial activa | -| symbol | | Refleja el valor de la opción `symbol` | -| style\* | | Refleja el valor de la opción `style` | +| Variable | Ejemplo | Descripción | +| --------- | --------- | -------------------------------------- | +| rama | `maestro` | La rama mercurial activa | +| symbol | | Refleja el valor de la opción `symbol` | +| style\* | | Refleja el valor de la opción `style` | \*: Esta variable sólo puede ser usada como parte de una cadena de estilo @@ -1833,10 +1906,10 @@ truncation_symbol = "" The `nim` module shows the currently installed version of [Nim](https://nim-lang.org/). Por defecto, el módulo se mostrará si se cumplen cualquiera de las siguientes condiciones: -- El directorio actual contiene un archivo `nim.cfg` -- El directorio actual contiene un archivo con la extensión `.nim` -- El directorio actual contiene un archivo con la extensión `.nims` -- El directorio actual contiene un archivo con la extensión `.nimble` +- The current directory contains a `nim.cfg` file +- The current directory contains a file with the `.nim` extension +- The current directory contains a file with the `.nims` extension +- The current directory contains a file with the `.nimble` extension ### Opciones @@ -1844,12 +1917,12 @@ The `nim` module shows the currently installed version of [Nim](https://nim-lang | ------------------- | ------------------------------------ | --------------------------------------------------------------------------------------- | | `format` | `"via [$symbol($version )]($style)"` | El formato del módulo | | `version_format` | `"v${raw}"` | El formato de versión. Las variables disponibles son `raw`, `major`, `minor`, & `patch` | -| `symbol` | `"👑 "` | El símbolo usado antes de mostrar la versión de Nim. | +| `symbol` | `"👑 "` | The symbol used before displaying the version of Nim. | | `detect_extensions` | `["nim", "nims", "nimble"]` | Qué extensiones deberían activar este módulo. | | `detect_files` | `["nim.cfg"]` | Qué nombres de archivo deberían activar este módulo. | | `detect_folders` | `[]` | Qué carpetas deberían activar este módulo. | | `style` | `"bold yellow"` | El estilo del módulo. | -| `disabled` | `false` | Desactiva el módulo `nim`. | +| `disabled` | `false` | Disables the `nim` module. | ### Variables @@ -1873,25 +1946,25 @@ symbol = "🎣 " ## Nix-shell -The `nix_shell` module shows the [nix-shell](https://nixos.org/guides/nix-pills/developing-with-nix-shell.html) environment. El módulo se mostrará dentro de un entorno 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. ### Opciones -| Opción | Por defecto | Descripción | -| ------------ | ---------------------------------------------- | -------------------------------------------------------------------------------- | -| `format` | `'via [$symbol$state( \($name\))]($style) '` | El formato del módulo. | -| `symbol` | `"❄️ "` | Una cadena de formato que representa el símbolo de nix-shell. | -| `style` | `"bold blue"` | El estilo del módulo. | -| `impure_msg` | `"impure"` | Una cadena de formato que se muestra cuando el intérprete de comandos es impuro. | -| `pure_msg` | `"pure"` | Una cadena de formato que se muestra cuando el intérprete de comandos es puro. | -| `disabled` | `false` | Desactiva el módulo `nix_shell`. | +| Opción | Por defecto | Descripción | +| ------------ | ---------------------------------------------- | ----------------------------------------------------- | +| `format` | `'via [$symbol$state( \($name\))]($style) '` | El formato del módulo. | +| `symbol` | `"❄️ "` | A format string representing the symbol of nix-shell. | +| `style` | `"bold blue"` | El estilo del módulo. | +| `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` | Disables the `nix_shell` module. | ### Variables | Variable | Ejemplo | Descripción | | --------- | ------- | -------------------------------------- | -| state | `pure` | El estado de nix-shell | -| name | `lorri` | El nombre de nix-shell | +| state | `pure` | The state of the nix-shell | +| name | `lorri` | The name of the nix-shell | | symbol | | Refleja el valor de la opción `symbol` | | style\* | | Refleja el valor de la opción `style` | @@ -1913,12 +1986,12 @@ format = 'via [☃️ $state( \($name\))](bold blue) ' The `nodejs` module shows the currently installed version of [Node.js](https://nodejs.org/). Por defecto, el módulo se mostrará si se cumplen cualquiera de las siguientes condiciones: -- El directorio actual contiene un archivo `package.json` -- El directorio actual contiene un archivo `.node-version` +- The current directory contains a `package.json` file +- The current directory contains a `.node-version` file - The current directory contains a `.nvmrc` file -- El directorio actual contiene un directorio `node_modules` -- El directorio actual contiene un archivo con la extensión `.js`, `.mjs` o `.cjs` -- El directorio actual contiene un archivo con la extensión `.ts` +- The current directory contains a `node_modules` directory +- The current directory contains a file with the `.js`, `.mjs` or `.cjs` extension +- The current directory contains a file with the `.ts` extension ### Opciones @@ -1931,7 +2004,7 @@ The `nodejs` module shows the currently installed version of [Node.js](https://n | `detect_files` | `["package.json", ".node-version"]` | Qué nombres de archivo deberían activar este módulo. | | `detect_folders` | `["node_modules"]` | Qué carpetas deberían activar este módulo. | | `style` | `"bold green"` | El estilo del módulo. | -| `disabled` | `false` | Desactiva el módulo `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 @@ -1953,41 +2026,41 @@ The `nodejs` module shows the currently installed version of [Node.js](https://n format = "via [🤖 $version](bold green) " ``` -## OCaml +## OCamlz The `ocaml` module shows the currently installed version of [OCaml](https://ocaml.org/). Por defecto, el módulo se mostrará si se cumplen cualquiera de las siguientes condiciones: -- El directorio actual contiene un archivo con extensión `.opam` o directorio `_opam` -- El directorio actual contiene un directorio `esy.lock` -- El directorio actual contiene un archivo `dune` o `dune-project` -- El directorio actual contiene un archivo `jbuild` o `jbuild-ignore` -- El directorio actual contiene un archivo `.merlin` -- El directorio actual contiene un archivo con la extensión `.ml`, `.mli`, `.re` o `.rei` +- The current directory contains a file with `.opam` extension or `_opam` directory +- The current directory contains a `esy.lock` directory +- The current directory contains a `dune` or `dune-project` file +- The current directory contains a `jbuild` or `jbuild-ignore` file +- The current directory contains a `.merlin` file +- The current directory contains a file with `.ml`, `.mli`, `.re` or `.rei` extension ### Opciones | Opción | Por defecto | Descripción | | ------------------------- | -------------------------------------------------------------------------- | --------------------------------------------------------------------------------------- | -| `format` | `"via [$symbol($version )(\($switch_indicator$switch_name\) )]($style)"` | La cadena de formato para el módulo. | +| `format` | `"via [$symbol($version )(\($switch_indicator$switch_name\) )]($style)"` | The format string for the module. | | `version_format` | `"v${raw}"` | El formato de versión. Las variables disponibles son `raw`, `major`, `minor`, & `patch` | -| `symbol` | `"🐫 "` | El símbolo usado antes de mostrar la versión de OCaml. | -| `global_switch_indicator` | `""` | La cadena de formato usada para representar el interruptor global de OPAM. | -| `local_switch_indicator` | `"*"` | La cadena de formato usada para representar el interruptor local de OPAM. | +| `symbol` | `"🐫 "` | The symbol used before displaying the version of OCaml. | +| `global_switch_indicator` | `""` | The format string used to represent global OPAM switch. | +| `local_switch_indicator` | `"*"` | The format string used to represent local OPAM switch. | | `detect_extensions` | `["opam", "ml", "mli", "re", "rei"]` | Qué extensiones deberían activar este módulo. | | `detect_files` | `["dune", "dune-project", "jbuild", "jbuild-ignore", ".merlin"]` | Qué nombres de archivo deberían activar este módulo. | | `detect_folders` | `["_opam", "esy.lock"]` | Qué carpetas deberían activar este módulo. | | `style` | `"bold yellow"` | El estilo del módulo. | -| `disabled` | `false` | Desactiva el módulo `ocaml`. | +| `disabled` | `false` | Disables the `ocaml` module. | ### Variables -| Variable | Ejemplo | Descripción | -| ---------------- | ------------ | --------------------------------------------------------------------------- | -| version | `v4.10.0` | La versión de `ocaml` | -| switch_name | `my-project` | El interruptor OPAM activo | -| switch_indicator | | Refleja el valor de `indicator` para el interruptor OPAM activo actualmente | -| symbol | | Refleja el valor de la opción `symbol` | -| style\* | | Refleja el valor de la opción `style` | +| Variable | Ejemplo | Descripción | +| ---------------- | ------------ | ----------------------------------------------------------------- | +| version | `v4.10.0` | La versión de `ocaml` | +| switch_name | `my-project` | The active OPAM switch | +| switch_indicator | | Mirrors the value of `indicator` for currently active OPAM switch | +| symbol | | Refleja el valor de la opción `symbol` | +| style\* | | Refleja el valor de la opción `style` | \*: Esta variable sólo puede ser usada como parte de una cadena de estilo @@ -2002,23 +2075,23 @@ format = "via [🐪 $version]($style) " ## OpenStack -El módulo `openstack` muestra la nube OpenStack actual y el proyecto. El módulo solo está activo cuando la variable env `OS_CLOUD` está definida en cuyo caso leerá el archivo `nubes. aml` desde cualquiera de las [ubicaciones por defecto](https://docs.openstack.org/python-openstackclient/latest/configuration/index.html#configuration-files) para obtener el proyecto actual en uso. +The `openstack` module shows the current OpenStack cloud and project. The module only active when the `OS_CLOUD` env var is set, in which case it will read `clouds.yaml` file from any of the [default locations](https://docs.openstack.org/python-openstackclient/latest/configuration/index.html#configuration-files). to fetch the current project in use. ### Opciones -| Opción | Por defecto | Descripción | -| ---------- | --------------------------------------------------- | ----------------------------------------------------------- | -| `format` | `"on [$symbol$cloud(\\($project\\))]($style) "` | El formato del módulo. | -| `symbol` | `"☁️ "` | El símbolo usado antes de mostrar la nube OpenStack actual. | -| `style` | `"bold yellow"` | El estilo del módulo. | -| `disabled` | `false` | Deshabilita el módulo `openstack`. | +| Opción | Por defecto | Descripción | +| ---------- | --------------------------------------------------- | -------------------------------------------------------------- | +| `format` | `"on [$symbol$cloud(\\($project\\))]($style) "` | El formato del módulo. | +| `symbol` | `"☁️ "` | The symbol used before displaying the current OpenStack cloud. | +| `style` | `"bold yellow"` | El estilo del módulo. | +| `disabled` | `false` | Disables the `openstack` module. | ### Variables | Variable | Ejemplo | Descripción | | --------- | ------- | -------------------------------------- | -| cloud | `corp` | La nube OpenStack actual | -| project | `dev` | El proyecto OpenStack actual | +| cloud | `corp` | The current OpenStack cloud | +| proyecto | `dev` | The current OpenStack project | | symbol | | Refleja el valor de la opción `symbol` | | style\* | | Refleja el valor de la opción `style` | @@ -2037,21 +2110,21 @@ symbol = "☁️ " ## Versión del paquete -El módulo `package` se muestra cuando el directorio actual es el repositorio de un paquete, y muestra su versión actual. The module currently supports `npm`, `nimble`, `cargo`, `poetry`, `composer`, `gradle`, `julia`, `mix` and `helm` 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`, `composer`, `gradle`, `julia`, `mix` and `helm` 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 -- [**nimble**](https://github.com/nim-lang/nimble) - The `nimble` package version is extracted from the `*.nimble` file present in the current directory with the `nimble dump` command -- [**poetry**](https://python-poetry.org/) – The `poetry` package version is extracted from the `pyproject.toml` present in the current directory -- [**python**](https://www.python.org) - The `python` package version is extracted from the `setup.cfg` present in the current directory -- [**composer**](https://getcomposer.org/) – The `composer` package version is extracted from the `composer.json` present in the current directory -- [**gradle**](https://gradle.org/) – The `gradle` package version is extracted from the `build.gradle` present -- [**julia**](https://docs.julialang.org/en/v1/stdlib/Pkg/) - The package version is extracted from the `Project.toml` present -- [**mix**](https://hexdocs.pm/mix/) - The `mix` package version is extracted from the `mix.exs` present -- [**helm**](https://helm.sh/docs/helm/helm_package/) - The `helm` chart version is extracted from the `Chart.yaml` present -- [**maven**](https://maven.apache.org/) - The `maven` package version is extracted from the `pom.xml` present -- [**meson**](https://mesonbuild.com/) - The `meson` package version is extracted from the `meson.build` present -- [**vlang**](https://vlang.io) - The `vlang` package version is extracted from the `v.mod` present +- [**Cargo**](https://doc.rust-lang.org/cargo/) – The `cargo` package version is extracted from the `Cargo.toml` present in the current directory +- [**Nimble**](https://github.com/nim-lang/nimble) - The `nimble` package version is extracted from the `*.nimble` file present in the current directory with the `nimble dump` command +- [**Poetry**](https://python-poetry.org/) – The `poetry` package version is extracted from the `pyproject.toml` present in the current directory +- [**Python**](https://www.python.org) - The `python` package version is extracted from the `setup.cfg` present in the current directory +- [**Composer**](https://getcomposer.org/) – The `composer` package version is extracted from the `composer.json` present in the current directory +- [**Gradle**](https://gradle.org/) – The `gradle` package version is extracted from the `build.gradle` present +- [**Julia**](https://docs.julialang.org/en/v1/stdlib/Pkg/) - The package version is extracted from the `Project.toml` present +- [**Mix**](https://hexdocs.pm/mix/) - The `mix` package version is extracted from the `mix.exs` present +- [**Helm**](https://helm.sh/docs/helm/helm_package/) - The `helm` chart version is extracted from the `Chart.yaml` present +- [**Maven**](https://maven.apache.org/) - The `maven` package version is extracted from the `pom.xml` present +- [**Meson**](https://mesonbuild.com/) - The `meson` package version is extracted from the `meson.build` present +- [**V**](https://vlang.io) - The `vlang` package version is extracted from the `v.mod` present > ⚠️ La versión que se muestra es la del paquete cuyo código fuente está en tu directorio actual, no en tu gestor de paquetes. @@ -2060,11 +2133,11 @@ El módulo `package` se muestra cuando el directorio actual es el repositorio de | Opción | Por defecto | Descripción | | ----------------- | --------------------------------- | --------------------------------------------------------------------------------------- | | `format` | `"is [$symbol$version]($style) "` | El formato del módulo. | -| `symbol` | `"📦 "` | El símbolo usado antes de mostrar la versión del paquete. | +| `symbol` | `"📦 "` | The symbol used before displaying the version the package. | | `version_format` | `"v${raw}"` | El formato de versión. Las variables disponibles son `raw`, `major`, `minor`, & `patch` | | `style` | `"bold 208"` | El estilo del módulo. | -| `display_private` | `false` | Activar la visualización de la versión para los paquetes marcados como privados. | -| `disabled` | `false` | Desactiva el módulo `package`. | +| `display_private` | `false` | Enable displaying version for packages marked as private. | +| `disabled` | `false` | Disables the `package` module. | ### Variables @@ -2089,24 +2162,24 @@ format = "via [🎁 $version](208 bold) " The `perl` module shows the currently installed version of [Perl](https://www.perl.org/). Por defecto, el módulo se mostrará si se cumplen cualquiera de las siguientes condiciones: -- El directorio actual contiene un archivo `Makefile.PL` o `Build.PL` -- El directorio actual contiene un archivo `cpanfile` o `cpanfile.snapshot` -- El directorio actual contiene un archivo `META.json` o `META.yml` -- El directorio actual contiene un archivo `.perl-version` -- El directorio actual contiene un `.pl`, `.pm` o `.pod` +- The current directory contains a `Makefile.PL` or `Build.PL` file +- The current directory contains a `cpanfile` or `cpanfile.snapshot` file +- The current directory contains a `META.json` file or `META.yml` file +- The current directory contains a `.perl-version` file +- The current directory contains a `.pl`, `.pm` or `.pod` ### Opciones | Opción | Por defecto | Descripción | | ------------------- | -------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------- | -| `format` | `"via [$symbol($version )]($style)"` | La cadena de formato para el módulo. | +| `format` | `"via [$symbol($version )]($style)"` | The format string for the module. | | `version_format` | `"v${raw}"` | El formato de versión. Las variables disponibles son `raw`, `major`, `minor`, & `patch` | -| `symbol` | `"🐪 "` | El símbolo usado antes de mostrar la versión de Perl | +| `symbol` | `"🐪 "` | The symbol used before displaying the version of Perl | | `detect_extensions` | `["pl", "pm", "pod"]` | Qué extensiones deberían activar este módulo. | | `detect_files` | `["Makefile.PL", "Build.PL", "cpanfile", "cpanfile.snapshot", "META.json", "META.yml", ".perl-version"]` | Qué nombres de archivo deberían activar este módulo. | | `detect_folders` | `[]` | Qué carpetas deberían activar este módulo. | | `style` | `"bold 149"` | El estilo del módulo. | -| `disabled` | `false` | Desactiva el módulo `perl`. | +| `disabled` | `false` | Deshabilita el módulo `perl`. | ### Variables @@ -2129,9 +2202,9 @@ format = "via [🦪 $version]($style) " The `php` module shows the currently installed version of [PHP](https://www.php.net/). Por defecto, el módulo se mostrará si se cumplen cualquiera de las siguientes condiciones: -- El directorio actual contiene un archivo `composer.json` -- El directorio actual contiene un archivo `.php-version` -- El directorio actual contiene una extensión `.php` +- The current directory contains a `composer.json` file +- The current directory contains a `.php-version` file +- The current directory contains a `.php` extension ### Opciones @@ -2139,7 +2212,7 @@ The `php` module shows the currently installed version of [PHP](https://www.php. | ------------------- | ------------------------------------ | --------------------------------------------------------------------------------------- | | `format` | `"via [$symbol($version )]($style)"` | El formato del módulo. | | `version_format` | `"v${raw}"` | El formato de versión. Las variables disponibles son `raw`, `major`, `minor`, & `patch` | -| `symbol` | `"🐘 "` | El símbolo usado antes de mostrar la versión de PHP. | +| `symbol` | `"🐘 "` | The symbol used before displaying the version of PHP. | | `detect_extensions` | `["php"]` | Qué extensiones deberían activar este módulo. | | `detect_files` | `["composer.json", ".php-version"]` | Qué nombres de archivo deberían activar este módulo. | | `detect_folders` | `[]` | Qué carpetas deberían activar este módulo. | @@ -2169,8 +2242,8 @@ format = "via [🔹 $version](147 bold) " The `purescript` module shows the currently installed version of [PureScript](https://www.purescript.org/) version. Por defecto, el módulo se mostrará si se cumplen cualquiera de las siguientes condiciones: -- El directorio actual contiene un archivo `spago.dhall` -- El directorio actual contiene un archivo con la extensión `.purs` +- The current directory contains a `spago.dhall` file +- The current directory contains a file with the `.purs` extension ### Opciones @@ -2178,18 +2251,18 @@ The `purescript` module shows the currently installed version of [PureScript](ht | ------------------- | ------------------------------------ | --------------------------------------------------------------------------------------- | | `format` | `"via [$symbol($version )]($style)"` | El formato del módulo. | | `version_format` | `"v${raw}"` | El formato de versión. Las variables disponibles son `raw`, `major`, `minor`, & `patch` | -| `symbol` | `"<=> "` | El símbolo usado antes de mostrar la versión de PureScript. | +| `symbol` | `"<=> "` | The symbol used before displaying the version of PureScript. | | `detect_extensions` | `["purs"]` | Qué extensiones deberían activar este módulo. | | `detect_files` | `["spago.dhall"]` | Qué nombres de archivo deberían activar este módulo. | | `detect_folders` | `[]` | Qué carpetas deberían activar este módulo. | | `style` | `"bold white"` | El estilo del módulo. | -| `disabled` | `false` | Deshabilita el módulo `purescript`. | +| `disabled` | `false` | Disables the `purescript` module. | ### Variables | Variable | Ejemplo | Descripción | | --------- | -------- | -------------------------------------- | -| version | `0.13.5` | La versión de `purescript` | +| version | `0.13.5` | The version of `purescript` | | symbol | | Refleja el valor de la opción `symbol` | | style\* | | Refleja el valor de la opción `style` | @@ -2208,19 +2281,19 @@ format = "via [$symbol$version](bold white)" The `python` module shows the currently installed version of [Python](https://www.python.org/) and the current [Python virtual environment](https://docs.python.org/tutorial/venv.html) if one is activated. -Si `pyenv_version_name` se establece en `true`, mostrará el nombre de la versión de pyenv. De lo contrario, se mostrará el número de versión de `python --version`. +If `pyenv_version_name` is set to `true`, it will display the pyenv version name. Otherwise, it will display the version number from `python --version`. Por defecto, el módulo se mostrará si se cumplen cualquiera de las siguientes condiciones: -- El directorio actual contiene un archivo `.python-version` -- El directorio actual contiene un archivo `Pipfile` -- El directorio actual contiene un archivo `__init__.py` -- El directorio actual contiene un archivo `pyproject.toml` -- El directorio actual contiene un archivo `requirements.txt` -- El directorio actual contiene un archivo `setup.py` -- El directorio actual contiene un archivo `tox.ini` -- El directorio actual contiene un archivo con la extensión `.py`. -- Un entorno virtual está activado actualmente +- The current directory contains a `.python-version` file +- The current directory contains a `Pipfile` file +- The current directory contains a `__init__.py` file +- The current directory contains a `pyproject.toml` file +- The current directory contains a `requirements.txt` file +- The current directory contains a `setup.py` file +- The current directory contains a `tox.ini` file +- The current directory contains a file with the `.py` extension. +- A virtual environment is currently activated ### Opciones @@ -2228,33 +2301,33 @@ Por defecto, el módulo se mostrará si se cumplen cualquiera de las siguientes | -------------------- | ------------------------------------------------------------------------------------------------------------ | --------------------------------------------------------------------------------------- | | `format` | `'via [${symbol}${pyenv_prefix}(${version} )(\($virtualenv\) )]($style)'` | El formato del módulo. | | `version_format` | `"v${raw}"` | El formato de versión. Las variables disponibles son `raw`, `major`, `minor`, & `patch` | -| `symbol` | `"🐍 "` | Una cadena de formato que representa el símbolo de Python | +| `symbol` | `"🐍 "` | A format string representing the symbol of Python | | `style` | `"yellow bold"` | El estilo del módulo. | -| `pyenv_version_name` | `false` | Usar pyenv para obtener la versión de Python | -| `pyenv_prefix` | `pyenv` | Prefijo antes de mostrar la versión de pyenv sólo se utiliza si se utiliza pyenv | -| `python_binary` | `["python", "python3", "python2"]` | Configura los binarios de python que Starship debería ejecutar al obtener la versión. | +| `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"]` | Qué extensiones deben activar este módulo | | `detect_files` | `[".python-version", "Pipfile", "__init__.py", "pyproject.toml", "requirements.txt", "setup.py", "tox.ini"]` | Qué nombres de archivo deben activar este módulo | | `detect_folders` | `[]` | Qué carpetas deben activar este módulo | -| `disabled` | `false` | Desactiva el módulo `python`. | +| `disabled` | `false` | Disables the `python` module. | ::: consejo -La variable `python_binary` acepta una cadena o una lista de cadenas. Starship intentará ejecutar cada binario hasta que obtenga un resultado. Ten en cuenta que sólo puedes cambiar el binario que Starship ejecuta para obtener la versión de Python no los argumentos que se utilizan. +The `python_binary` variable accepts either a string or a list of strings. Starship will try executing each binary until it gets a result. Note you can only change the binary that Starship executes to get the version of Python not the arguments that are used. -Los valores por defecto y el orden para `python_binary` fue elegido para identificar primero la versión de Python en un entorno virtualenv/conda (que actualmente añade un `python`, no importa si apunta a `pithon3` o `pithon2`). Esto tiene el efecto secundario que si todavía tienes un sistema de Python 2 instalado, puede ser recogido antes de cualquier Python 3 (al menos en las Distros de Linux que siempre enlazan `/usr/bin/python` a Python 2). Si ya no trabajas con Python 2 pero no puedes removerlo del sistema, cambiando esto a `"python3"` ocultará cualquier versión de Python 2, ver ejemplo a continuación. +The default values and order for `python_binary` was chosen to first identify the Python version in a virtualenv/conda environments (which currently still add a `python`, no matter if it points to `python3` or `python2`). This has the side effect that if you still have a system Python 2 installed, it may be picked up before any Python 3 (at least on Linux Distros that always symlink `/usr/bin/python` to Python 2). If you do not work with Python 2 anymore but cannot remove the system Python 2, changing this to `"python3"` will hide any Python version 2, see example below. ::: ### Variables -| Variable | Ejemplo | Descripción | -| ------------ | --------------- | ------------------------------------------- | -| version | `"v3.8.1"` | La versión de `python` | -| symbol | `"🐍 "` | Refleja el valor de la opción `symbol` | -| style | `"yellow bold"` | Refleja el valor de la opción `style` | -| pyenv_prefix | `"pyenv "` | Ordena el valor de la opción `pyenv_prefix` | -| virtualenv | `"venv"` | El nombre actual del `virtualenv` | +| Variable | Ejemplo | Descripción | +| ------------ | --------------- | ------------------------------------------ | +| version | `"v3.8.1"` | The version of `python` | +| symbol | `"🐍 "` | Refleja el valor de la opción `symbol` | +| style | `"yellow bold"` | Refleja el valor de la opción `style` | +| pyenv_prefix | `"pyenv "` | Mirrors the value of option `pyenv_prefix` | +| virtualenv | `"venv"` | The current `virtualenv` name | ### Ejemplo @@ -2270,7 +2343,7 @@ pyenv_version_name = true # ~/.config/starship.toml [python] -# Solo usa el binario `python3` para obtener la versión. +# Only use the `python3` binary to get the version. python_binary = "python3" ``` @@ -2278,7 +2351,7 @@ python_binary = "python3" # ~/.config/starship.toml [python] -# No se dispara con archivos con extensión py +# Don't trigger for files with the py extension detect_extensions = [] ``` @@ -2295,7 +2368,7 @@ python_binary = ["./venv/bin/python", "python", "python3", "python2"] ## R -The `rlang` module shows the currently installed version of R. The module will be shown if any of the following conditions are met: +The `rlang` module shows the currently installed version of [R](https://www.r-project.org/). The module will be shown if any of the following conditions are met: - The current directory contains a file with the `.R` extension. - The current directory contains a file with the `.Rd` extension. @@ -2322,7 +2395,7 @@ The `rlang` module shows the currently installed version of R. The module will b | Variable | Ejemplo | Descripción | | -------- | ------------- | -------------------------------------- | -| version | `v4.0.5` | The version of `R` | +| version | `v4.0.5` | La versión de `R` | | symbol | | Refleja el valor de la opción `symbol` | | style | `"blue bold"` | Refleja el valor de la opción `style` | @@ -2337,7 +2410,7 @@ format = "with [📐 $version](blue bold) " ## Red -By default the `red` module shows the currently installed version of [Red](https://www.red-lang.org/). El módulo se muestra si algunas de las siguientes condiciones se cumplen: +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 @@ -2375,11 +2448,11 @@ symbol = "🔴 " ## Ruby -By default the `ruby` module shows the currently installed version of [Ruby](https://www.ruby-lang.org/). El módulo se muestra si algunas de las siguientes condiciones se cumplen: +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: -- El directorio actual contiene un archivo `Gemfile` -- El directorio actual contiene un archivo `.ruby-version` -- El directorio actual contiene un archivo `.rb` +- The current directory contains a `Gemfile` file +- The current directory contains a `.ruby-version` file +- The current directory contains a `.rb` file ### Opciones @@ -2387,18 +2460,18 @@ By default the `ruby` module shows the currently installed version of [Ruby](htt | ------------------- | ------------------------------------ | --------------------------------------------------------------------------------------- | | `format` | `"via [$symbol($version )]($style)"` | El formato del módulo. | | `version_format` | `"v${raw}"` | El formato de versión. Las variables disponibles son `raw`, `major`, `minor`, & `patch` | -| `symbol` | `"💎 "` | Una cadena de formato que representa el símbolo de Ruby. | +| `symbol` | `"💎 "` | A format string representing the symbol of Ruby. | | `detect_extensions` | `["rb"]` | Qué extensiones deberían activar este módulo. | | `detect_files` | `["Gemfile", ".ruby-version"]` | Qué nombres de archivo deberían activar este módulo. | | `detect_folders` | `[]` | Qué carpetas deberían activar este módulo. | | `style` | `"bold red"` | El estilo del módulo. | -| `disabled` | `false` | Desactiva el módulo `ruby`. | +| `disabled` | `false` | Disables the `ruby` module. | ### Variables | Variable | Ejemplo | Descripción | | --------- | -------- | -------------------------------------- | -| version | `v2.5.1` | La versión de `ruby` | +| version | `v2.5.1` | The version of `ruby` | | symbol | | Refleja el valor de la opción `symbol` | | style\* | | Refleja el valor de la opción `style` | @@ -2415,10 +2488,10 @@ symbol = "🔺 " ## Rust -By default the `rust` module shows the currently installed version of [Rust](https://www.rust-lang.org/). El módulo se muestra si algunas de las siguientes condiciones se cumplen: +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: -- El directorio actual contiene un archivo `Cargo.toml` -- El directorio actual contiene un archivo con la extensión `.rs` +- The current directory contains a `Cargo.toml` file +- The current directory contains a file with the `.rs` extension ### Opciones @@ -2426,18 +2499,18 @@ By default the `rust` module shows the currently installed version of [Rust](htt | ------------------- | ------------------------------------ | --------------------------------------------------------------------------------------- | | `format` | `"via [$symbol($version )]($style)"` | El formato del módulo. | | `version_format` | `"v${raw}"` | El formato de versión. Las variables disponibles son `raw`, `major`, `minor`, & `patch` | -| `symbol` | `"🦀 "` | Una cadena de formato que representa el símbolo de Rust | +| `symbol` | `"🦀 "` | A format string representing the symbol of Rust | | `detect_extensions` | `["rs"]` | Qué extensiones deberían activar este módulo. | | `detect_files` | `["Cargo.toml"]` | Qué nombres de archivo deberían activar este módulo. | | `detect_folders` | `[]` | Qué carpetas deberían activar este módulo. | | `style` | `"bold red"` | El estilo del módulo. | -| `disabled` | `false` | Desactiva el módulo `rust`. | +| `disabled` | `false` | Deshabilita el módulo `rust`. | ### Variables | Variable | Ejemplo | Descripción | | --------- | ----------------- | -------------------------------------- | -| version | `v1.43.0-nightly` | La versión de `rustc` | +| version | `v1.43.0-nightly` | The version of `rustc` | | symbol | | Refleja el valor de la opción `symbol` | | style\* | | Refleja el valor de la opción `style` | @@ -2456,9 +2529,9 @@ format = "via [⚙️ $version](red bold)" The `scala` module shows the currently installed version of [Scala](https://www.scala-lang.org/). Por defecto, el módulo se mostrará si se cumplen cualquiera de las siguientes condiciones: -- El directorio actual contiene un archivo `build.sbt`, `.scalaenv` o `.sbtenv` -- El directorio actual contiene un archivo con la extensión `.scala` o `.sbt` -- El directorio actual contiene un directorio llamado `.metals` +- The current directory contains a `build.sbt`, `.scalaenv` or `.sbtenv` file +- The current directory contains a file with the `.scala` or `.sbt` extension +- The current directory contains a directory named `.metals` ### Opciones @@ -2469,15 +2542,15 @@ The `scala` module shows the currently installed version of [Scala](https://www. | `detect_extensions` | `["sbt", "scala"]` | Qué extensiones deberían activar este módulo. | | `detect_files` | `[".scalaenv", ".sbtenv", "build.sbt"]` | Qué nombres de archivo deberían activar este módulo. | | `detect_folders` | `[".metals"]` | Qué carpetas deberían activar estos módulos. | -| `symbol` | `"🆂 "` | Una cadena de formato que representa el símbolo de Scala. | +| `symbol` | `"🆂 "` | A format string representing the symbol of Scala. | | `style` | `"red dimmed"` | El estilo del módulo. | -| `disabled` | `false` | Deshabilita el módulo `scala`. | +| `disabled` | `false` | Disables the `scala` module. | ### Variables | Variable | Ejemplo | Descripción | | --------- | -------- | -------------------------------------- | -| version | `2.13.5` | La versión de `scala` | +| version | `2.13.5` | The version of `scala` | | symbol | | Refleja el valor de la opción `symbol` | | style\* | | Refleja el valor de la opción `style` | @@ -2494,35 +2567,35 @@ symbol = "🌟 " ## Shell -El módulo `shell` muestra un indicador para el intérprete de comandos actualmente utilizado. +The `shell` module shows an indicator for currently used shell. ::: consejo -Este módulo está deshabilitado por defecto. Para activarlo, establece `disabled` a `false` en tu archivo de configuración. +This module is disabled by default. To enable it, set `disabled` to `false` in your configuration file. ::: ### Opciones -| Opción | Por defecto | Descripción | -| ---------------------- | ------------ | -------------------------------------------------------------------- | -| `bash_indicator` | `bsh` | Una cadena de formato usada para representar Bash. | -| `fish_indicator` | `fsh` | Una cadena de formato usada para representar Fish. | -| `zsh_indicator` | `zsh` | Una cadena de formato usada para representar Zsh. | -| `powershell_indicator` | `psh` | Una cadena de formato usada para representar Powershell. | -| `ion_indicator` | `ion` | Una cadena de formato usada para representar Ion. | -| `elvish_indicator` | `esh` | Una cadena de formato usada para representar Elvish. | -| `tcsh_indicator` | `tsh` | Una cadena de formato usada para representar tcsh. | -| `xonsh_indicator` | `xsh` | A format string used to represent xonsh. | -| `unknown_indicator` | | El valor por defecto que se mostrará cuando se desconoce el comando. | -| `format` | `$indicator` | El formato del módulo. | -| `disabled` | `true` | Deshabilita el módulo `shell`. | +| Opción | Por defecto | Descripción | +| ---------------------- | ------------ | ------------------------------------------------------------ | +| `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. | +| `unknown_indicator` | | The default value to be displayed when the shell is unknown. | +| `format` | `$indicator` | El formato del módulo. | +| `disabled` | `true` | Disables the `shell` module. | ### Variables -| Variable | Por defecto | Descripción | -| --------- | ----------- | ------------------------------------------------------------------------------------ | -| indicator | | Ordena el valor de `indicator` para el intérprete de comandos actualmente utilizado. | +| Variable | Por defecto | Descripción | +| --------- | ----------- | ---------------------------------------------------------- | +| indicador | | Mirrors the value of `indicator` for currently used shell. | ### Ejemplos @@ -2538,24 +2611,24 @@ disabled = false ## SHLVL -El módulo `shlvl` muestra la variable de entorno actual `SHLVL` ("nivel de shell"), si está establecido en un número y alcanza o supera el umbral especificado. +The `shlvl` module shows the current [`SHLVL`](https://tldp.org/LDP/abs/html/internalvariables.html#SHLVLREF) ("shell level") environment variable, if it is set to a number and meets or exceeds the specified threshold. ### Opciones -| Opción | Por defecto | Descripción | -| ----------- | ---------------------------- | ----------------------------------------------------------------- | -| `threshold` | `2` | Mostrar umbral. | -| `format` | `"[$symbol$shlvl]($style) "` | El formato del módulo. | -| `symbol` | `"↕️ "` | El símbolo utilizado para representar el `SHLVL`. | -| `repeat` | `false` | Hace que el `symbol` se repita con la cantidad actual de `SHLVL`. | -| `style` | `"bold yellow"` | El estilo del módulo. | -| `disabled` | `true` | Desactiva el módulo `shlvl`. | +| Opción | Por defecto | Descripción | +| ----------- | ---------------------------- | ------------------------------------------------------------- | +| `threshold` | `2` | Display threshold. | +| `format` | `"[$symbol$shlvl]($style) "` | El formato del módulo. | +| `symbol` | `"↕️ "` | The symbol used to represent the `SHLVL`. | +| `repeat` | `false` | Causes `symbol` to be repeated by the current `SHLVL` amount. | +| `style` | `"bold yellow"` | El estilo del módulo. | +| `disabled` | `true` | Disables the `shlvl` module. | ### Variables | Variable | Ejemplo | Descripción | | --------- | ------- | -------------------------------------- | -| shlvl | `3` | El valor actual de `SHLVL` | +| shlvl | `3` | The current value of `SHLVL` | | symbol | | Refleja el valor de la opción `symbol` | | style\* | | Refleja el valor de la opción `style` | @@ -2578,12 +2651,12 @@ The `singularity` module shows the current [Singularity](https://sylabs.io/singu ### Opciones -| Opción | Por defecto | Descripción | -| ---------- | -------------------------------- | ------------------------------------------------------------------- | -| `format` | `'[$symbol\[$env\]]($style) '` | El formato del módulo. | -| `symbol` | `""` | Una cadena de formato que se muestra antes del nombre de la imagen. | -| `style` | `"bold dimmed blue"` | El estilo del módulo. | -| `disabled` | `false` | Desactiva el módulo `singularity`. | +| Opción | Por defecto | Descripción | +| ---------- | -------------------------------- | ------------------------------------------------ | +| `format` | `'[$symbol\[$env\]]($style) '` | El formato del módulo. | +| `symbol` | `""` | A format string displayed before the image name. | +| `style` | `"bold dimmed blue"` | El estilo del módulo. | +| `disabled` | `false` | Disables the `singularity` module. | ### Variables @@ -2604,13 +2677,13 @@ The `singularity` module shows the current [Singularity](https://sylabs.io/singu format = '[📦 \[$env\]]($style) ' ``` -## Status +## Estado -El módulo `status` muestra el código de salida del comando anterior. El módulo se mostrará sólo si el código de salida no es `0`. +The `status` module displays the exit code of the previous command. The module will be shown only if the exit code is not `0`. ::: consejo -Este módulo está deshabilitado por defecto. Para activarlo, establece `disabled` a `false` en tu archivo de configuración. +This module is disabled by default. To enable it, set `disabled` to `false` in your configuration file. ::: @@ -2620,31 +2693,31 @@ Este módulo está deshabilitado por defecto. Para activarlo, establece `disable | Opción | Por defecto | Descripción | | ----------------------- | ------------------------------------------------------------------------------------ | ------------------------------------------------------- | -| `format` | `"[$symbol$status]($style) "` | El formato del módulo | -| `symbol` | `"✖"` | El símbolo mostrado en error del programa | +| `format` | `"[$symbol$status]($style) "` | The format of the module | +| `symbol` | `"✖"` | El símbolo mostrado en un error del programa | | `success_symbol` | `"✔️"` | The symbol displayed on program success | -| `not_executable_symbol` | `"🚫"` | El símbolo mostrado cuando el archivo no es ejecutable | -| `not_found_symbol` | `"🔍"` | El símbolo mostrado cuando no se encuentra el comando | -| `sigint_symbol` | `"🧱"` | El símbolo mostrado en SIGINT (Ctrl + c) | -| `signal_symbol` | `"⚡"` | El símbolo mostrado en cualquier señal | +| `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"` | El estilo del módulo. | -| `recognize_signal_code` | `true` | Activar mapeo de señales desde el código de salida | -| `map_symbol` | `false` | Activar mapeo de símbolos desde el código de salida | +| `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` | `|` | The symbol that separate in pipe program exit codes | | `pipestatus_format` | `\\[$pipestatus\\] => [$symbol$common_meaning$signal_name$maybe_int]($style)` | The format of the module when the command is a pipeline | -| `disabled` | `true` | Desactiva el módulo `status`. | +| `disabled` | `true` | Disables the `status` module. | ### Variables | Variable | Ejemplo | Descripción | | -------------- | ------- | ------------------------------------------------------------------------------------------- | -| status | `127` | El código de salida del último comando | -| int | `127` | El código de salida del último comando | -| common_meaning | `ERROR` | Comprobación del código si no es una señal | -| signal_number | `9` | Número de señal correspondiente al código de salida, sólo si está señalizada | -| signal_name | `KILL` | Nombre de la señal correspondiente al código de salida, sólo si está señalizada | -| maybe_int | `7` | Contiene el número de código de salida cuando no se ha encontrado ningún significado | +| estado | `127` | The exit code of the last command | +| int | `127` | The exit code of the last command | +| common_meaning | `ERROR` | Meaning of the code if not a signal | +| signal_number | `9` | Signal number corresponding to the exit code, only if signalled | +| signal_name | `KILL` | Name of the signal corresponding to the exit code, only if signalled | +| maybe_int | `7` | Contains the exit code number when no meaning has been found | | pipestatus | | Rendering of in pipeline programs's exit codes, this is only available in pipestatus_format | | symbol | | Refleja el valor de la opción `symbol` | | style\* | | Refleja el valor de la opción `style` | @@ -2668,10 +2741,10 @@ disabled = false ## Swift -By default the `swift` module shows the currently installed version of [Swift](https://swift.org/). El módulo se muestra si algunas de las siguientes condiciones se cumplen: +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: -- El directorio actual contiene un archivo `Package.swift` -- El directorio actual contiene un archivo con la extensión `.swift` +- The current directory contains a `Package.swift` file +- The current directory contains a file with the `.swift` extension ### Opciones @@ -2679,12 +2752,12 @@ By default the `swift` module shows the currently installed version of [Swift](h | ------------------- | ------------------------------------ | --------------------------------------------------------------------------------------- | | `format` | `"via [$symbol($version )]($style)"` | El formato del módulo. | | `version_format` | `"v${raw}"` | El formato de versión. Las variables disponibles son `raw`, `major`, `minor`, & `patch` | -| `symbol` | `"🐦 "` | Una cadena de formato que representa el símbolo de Swift | +| `symbol` | `"🐦 "` | A format string representing the symbol of Swift | | `detect_extensions` | `["swift"]` | Qué extensiones deberían activar este módulo. | | `detect_files` | `["Package.swift"]` | Qué nombres de archivo deberían activar este módulo. | | `detect_folders` | `[]` | Qué carpetas deberían activar este módulo. | | `style` | `"bold 202"` | El estilo del módulo. | -| `disabled` | `false` | Desactiva el módulo `swift`. | +| `disabled` | `false` | Disables the `swift` module. | ### Variables @@ -2711,36 +2784,36 @@ The `terraform` module shows the currently selected [Terraform workspace](https: ::: consejo -By default the Terraform version is not shown, since this is slow for current versions of Terraform when a lot of plugins are in use. Si aún deseas activarlo, [sigue el ejemplo que se muestra a continuación](#with-terraform-version). +By default the Terraform version is not shown, since this is slow for current versions of Terraform when a lot of plugins are in use. If you still want to enable it, [follow the example shown below](#with-terraform-version). ::: Por defecto, el módulo se mostrará si se cumplen cualquiera de las siguientes condiciones: -- El directorio actual contiene una carpeta `.terraform` -- El directorio actual contiene un archivo con las extensiones `.tf` o `.hcl` +- The current directory contains a `.terraform` folder +- Current directory contains a file with the `.tf` or `.hcl` extensions ### Opciones | Opción | Por defecto | Descripción | | ------------------- | ------------------------------------ | --------------------------------------------------------------------------------------- | -| `format` | `"via [$symbol$workspace]($style) "` | La cadena de formato para el módulo. | +| `format` | `"via [$symbol$workspace]($style) "` | The format string for the module. | | `version_format` | `"v${raw}"` | El formato de versión. Las variables disponibles son `raw`, `major`, `minor`, & `patch` | -| `symbol` | `"💠"` | Una cadena de formato que se muestra antes del espacio de trabajo de terraform. | +| `symbol` | `"💠"` | A format string shown before the terraform workspace. | | `detect_extensions` | `["tf", "hcl"]` | Qué extensiones deberían activar este módulo. | | `detect_files` | `[]` | Qué nombres de archivo deberían activar este módulo. | | `detect_folders` | `[".terraform"]` | Qué carpetas deberían activar este módulo. | | `style` | `"bold 105"` | El estilo del módulo. | -| `disabled` | `false` | Desactiva el módulo `terraform`. | +| `disabled` | `false` | Disables the `terraform` module. | ### Variables -| Variable | Ejemplo | Descripción | -| --------- | ---------- | -------------------------------------- | -| version | `v0.12.24` | La versión de `terraform` | -| workspace | `default` | The current Terraform workspace | -| symbol | | Refleja el valor de la opción `symbol` | -| style\* | | Refleja el valor de la opción `style` | +| Variable | Ejemplo | Descripción | +| --------------- | ---------- | -------------------------------------- | +| version | `v0.12.24` | The version of `terraform` | +| área de trabajo | `default` | The current Terraform workspace | +| symbol | | Refleja el valor de la opción `symbol` | +| style\* | | Refleja el valor de la opción `style` | \*: Esta variable sólo puede ser usada como parte de una cadena de estilo @@ -2766,33 +2839,33 @@ format = "[🏎💨 $workspace]($style) " ## Hora -El módulo `time` muestra la hora **local** actual. El valor de configuración de `format` es usado por la caja de [`chrono`](https://crates.io/crates/chrono) para controlar cómo se muestra la hora. Echa un vistazo a [los documentos de chrono strftime](https://docs.rs/chrono/0.4.7/chrono/format/strftime/index.html) para ver qué opciones están disponibles. +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. ::: consejo -Este módulo está deshabilitado por defecto. Para activarlo, establece `disabled` a `false` en tu archivo de configuración. +This module is disabled by default. To enable it, set `disabled` to `false` in your configuration file. ::: ### Opciones -| Opción | Por defecto | Descripción | -| ----------------- | ----------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -| `format` | `"at [$time]($style) "` | La cadena de formato para el módulo. | -| `use_12hr` | `false` | Habilita el formato de 12 horas | -| `time_format` | see below | La [cadena de formato de chrono](https://docs.rs/chrono/0.4.7/chrono/format/strftime/index.html) utilizada para formatear la hora. | -| `style` | `"bold yellow"` | El estilo para la hora del módulo | -| `utc_time_offset` | `"local"` | Establece el desplazamiento UTC a utilizar. Rango de -24 < x < 24. Permite a los flotantes acomodar los desplazamientos de zona horaria de 30/45 minutos. | -| `disabled` | `true` | Desactiva el módulo `time`. | -| `time_range` | `"-"` | Establece el intervalo de tiempo durante el cual el módulo se mostrará. La hora debe ser especificada en formato de 24 horas | +| Opción | Por defecto | Descripción | +| ----------------- | ----------------------- | ---------------------------------------------------------------------------------------------------------------------------------- | +| `format` | `"at [$time]($style) "` | The format string for the module. | +| `use_12hr` | `false` | Enables 12 hour formatting | +| `time_format` | ver abajo | 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 | -Si `use_12hr` es `true`, entonces `time_format` por defecto `"%r"`. De lo contrario, el valor por defecto es `"%T"`. Configurar manualmente `time_format` sobrescribirá la configuración `use_12hr`. +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. ### Variables | Variable | Ejemplo | Descripción | | --------- | ---------- | ------------------------------------- | -| time | `13:08:10` | La hora actual. | +| tiempo | `13:08:10` | La hora actual. | | style\* | | Refleja el valor de la opción `style` | \*: Esta variable sólo puede ser usada como parte de una cadena de estilo @@ -2812,35 +2885,35 @@ time_range = "10:00:00-14:00:00" ## Nombre de usuario -El módulo `username` muestra el nombre de usuario activo. El módulo se muestra si algunas de las siguientes condiciones se cumplen: +The `username` module shows active user's username. The module will be shown if any of the following conditions are met: -- El usuario actual es root -- El usuario actual no es el mismo que el que está conectado -- El usuario está actualmente conectado como una sesión SSH -- La variable `show_always` se establece en true +- The current user is root +- The current user isn't the same as the one that is logged in +- The user is currently connected as an SSH session +- The variable `show_always` is set to true ::: consejo -La conexión SSH se detecta comprobando las variables de entorno `SSH_CONNECTION`, `SSH_CLIENT`, y `SSH_TTY`. Si su host SSH no configura estas variables, una solución es establecer una de ellas con un valor tonto. +SSH connection is detected by checking environment variables `SSH_CONNECTION`, `SSH_CLIENT`, and `SSH_TTY`. If your SSH host does not set up these variables, one workaround is to set one of them with a dummy value. ::: ### Opciones -| Opción | Por defecto | Descripción | -| ------------- | ----------------------- | ------------------------------------------ | -| `style_root` | `"bold red"` | El estilo usado cuando el usuario es root. | -| `style_user` | `"bold yellow"` | El estilo usado para usuarios no root. | -| `format` | `"[$user]($style) in "` | El formato del módulo. | -| `show_always` | `false` | Siempre muestra el módulo `username`. | -| `disabled` | `false` | Desactiva el módulo `username`. | +| Opción | Por defecto | Descripción | +| ------------- | ----------------------- | ------------------------------------- | +| `style_root` | `"bold red"` | The style used when the user is root. | +| `style_user` | `"bold yellow"` | The style used for non-root users. | +| `format` | `"[$user]($style) in "` | El formato del módulo. | +| `show_always` | `false` | Always shows the `username` module. | +| `disabled` | `false` | Disables the `username` module. | ### Variables -| Variable | Ejemplo | Descripción | -| -------- | ------------ | --------------------------------------------------------------------------------------------------- | -| `style` | `"red bold"` | Refleja el valor de la opción `style_root` cuando root inició sesión y `style_user` por otra parte. | -| `user` | `"matchai"` | El ID de usuario conectado actualmente. | +| Variable | Ejemplo | Descripción | +| -------- | ------------ | ------------------------------------------------------------------------------------------- | +| `style` | `"red bold"` | Mirrors the value of option `style_root` when root is logged in and `style_user` otherwise. | +| `user` | `"matchai"` | The currently logged-in user ID. | ### Ejemplo @@ -2859,7 +2932,7 @@ show_always = true The `vagrant` module shows the currently installed version of [Vagrant](https://www.vagrantup.com/). Por defecto, el módulo se mostrará si se cumplen cualquiera de las siguientes condiciones: -- El directorio actual contiene un archivo `Vagrantfile` +- The current directory contains a `Vagrantfile` file ### Opciones @@ -2867,18 +2940,18 @@ The `vagrant` module shows the currently installed version of [Vagrant](https:// | ------------------- | ------------------------------------ | --------------------------------------------------------------------------------------- | | `format` | `"via [$symbol($version )]($style)"` | El formato del módulo. | | `version_format` | `"v${raw}"` | El formato de versión. Las variables disponibles son `raw`, `major`, `minor`, & `patch` | -| `symbol` | `"⍱ "` | Una cadena de formato que representa el símbolo de Vagrant. | +| `symbol` | `"⍱ "` | A format string representing the symbol of Vagrant. | | `detect_extensions` | `[]` | Qué extensiones deberían activar este módulo. | | `detect_files` | `["Vagrantfile"]` | Qué nombres de archivo deberían activar este módulo. | | `detect_folders` | `[]` | Qué carpetas deberían activar este módulo. | | `style` | `"cyan bold"` | El estilo del módulo. | -| `disabled` | `false` | Deshabilita el módulo `vagrant`. | +| `disabled` | `false` | Disables the `vagrant` module. | ### Variables | Variable | Ejemplo | Descripción | | --------- | ---------------- | -------------------------------------- | -| version | `Vagrant 2.2.10` | La versión de `Vagrant` | +| version | `Vagrant 2.2.10` | The version of `Vagrant` | | symbol | | Refleja el valor de la opción `symbol` | | style\* | | Refleja el valor de la opción `style` | @@ -2893,9 +2966,9 @@ The `vagrant` module shows the currently installed version of [Vagrant](https:// format = "via [⍱ $version](bold white) " ``` -## VLang +## V -The `vlang` module shows you your currently installed version of V. By default the module will be shown if any of the following conditions are met: +The `vlang` module shows you your currently installed version of [V](https://vlang.io/). Por defecto, el módulo se mostrará si se cumplen cualquiera de las siguientes condiciones: - The current directory contains a file with `.v` extension - The current directory contains a `v.mod`, `vpkg.json` or `.vpkg-lock.json` file @@ -2924,30 +2997,30 @@ The `vlang` module shows you your currently installed version of V. By default t ```toml # ~/.config/starship.toml -[v] +[vlang] format = "via [V $version](blue bold) " ``` ## VCSH -The `vcsh` module displays the current active [VCSH](https://github.com/RichiH/vcsh) repository. El módulo sólo se mostrará si un repositorio está actualmente en uso. +The `vcsh` module displays the current active [VCSH](https://github.com/RichiH/vcsh) repository. The module will be shown only if a repository is currently in use. ### Opciones -| Opción | Por defecto | Descripción | -| ---------- | -------------------------------- | ------------------------------------------------------------ | -| `symbol` | | El símbolo usado antes de mostrar el nombre del repositorio. | -| `style` | `"bold yellow"` | El estilo del módulo. | -| `format` | `"vcsh [$symbol$repo]($style) "` | El formato del módulo. | -| `disabled` | `false` | Deshabilita el módulo `vcsh`. | +| Opción | Por defecto | Descripción | +| ---------- | -------------------------------- | ------------------------------------------------------ | +| `symbol` | | The symbol used before displaying the repository name. | +| `style` | `"bold yellow"` | El estilo del módulo. | +| `format` | `"vcsh [$symbol$repo]($style) "` | El formato del módulo. | +| `disabled` | `false` | Disables the `vcsh` module. | ### Variables -| Variable | Ejemplo | Descripción | -| ----------- | ----------------------------------------------------------- | -------------------------------------- | -| repositorio | `dotfiles` si está en un repositorio VCSH nombrado dotfiles | El nombre del repositorio activo | -| symbol | | Refleja el valor de la opción `symbol` | -| style\* | `black bold dimmed` | Refleja el valor de la opción `style` | +| Variable | Ejemplo | Descripción | +| ----------- | ------------------------------------------- | -------------------------------------- | +| repositorio | `dotfiles` if in a VCSH repo named dotfiles | The active repository name | +| symbol | | Refleja el valor de la opción `symbol` | +| style\* | `black bold dimmed` | Refleja el valor de la opción `style` | \*: Esta variable sólo puede ser usada como parte de una cadena de estilo @@ -2962,9 +3035,9 @@ format = "[🆅 $repo](bold blue) " ## Zig -By default the the `zig` module shows the currently installed version of [Zig](https://ziglang.org/). El módulo se muestra si algunas de las siguientes condiciones se cumplen: +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: -- El directorio actual contiene un archivo `.zig` +- The current directory contains a `.zig` file ### Opciones @@ -2972,9 +3045,9 @@ By default the the `zig` module shows the currently installed version of [Zig](h | ------------------- | ------------------------------------ | --------------------------------------------------------------------------------------- | | `format` | `"via [$symbol($version )]($style)"` | El formato del módulo. | | `version_format` | `"v${raw}"` | El formato de versión. Las variables disponibles son `raw`, `major`, `minor`, & `patch` | -| `symbol` | `"↯ "` | El símbolo usado antes de mostrar la versión de Zig. | +| `symbol` | `"↯ "` | The symbol used before displaying the version of Zig. | | `style` | `"bold yellow"` | El estilo del módulo. | -| `disabled` | `false` | Desactiva el módulo `zig`. | +| `disabled` | `false` | Disables the `zig` module. | | `detect_extensions` | `["zig"]` | Qué extensiones deberían activar este módulo. | | `detect_files` | `[]` | Qué nombres de archivo deberían activar este módulo. | | `detect_folders` | `[]` | Qué carpetas deberían activar este módulo. | @@ -2983,7 +3056,7 @@ By default the the `zig` module shows the currently installed version of [Zig](h | Variable | Ejemplo | Descripción | | --------- | -------- | -------------------------------------- | -| version | `v0.6.0` | La versión de `zig` | +| version | `v0.6.0` | The version of `zig` | | symbol | | Refleja el valor de la opción `symbol` | | style\* | | Refleja el valor de la opción `style` | @@ -3000,87 +3073,87 @@ symbol = "⚡️ " ## Comandos personalizados -Los módulos `personalizados` muestran la salida de algunos comandos arbitrarios. +The `custom` modules show the output of some arbitrary commands. -Estos módulos se mostrarán si se cumplen alguna de las siguientes condiciones: +These modules will be shown if any of the following conditions are met: -- El directorio actual contiene un archivo cuyo nombre está en `files` -- El directorio actual contiene un directorio cuyo nombre está en `directories` -- El directorio actual contiene un archivo cuya extensión está en `extensions` -- El comando `when` devuelve 0 -- El sistema operativo actual (std::env::consts::OS) coincide con el campo `os` si está definido. +- The current directory contains a file whose name is in `files` +- The current directory contains a directory whose name is in `directories` +- The current directory contains a file whose extension is in `extensions` +- The `when` command returns 0 +- The current Operating System (std::env::consts::OS) matchs with `os` field if defined. ::: consejo -Múltiples módulos personalizados pueden definirse usando una `.`. +Multiple custom modules can be defined by using a `.`. ::: ::: consejo -El orden en el que se muestran los módulos personalizados se puede establecer individualmente incluyendo `${custom.foo}` en el `format` de nivel superior (ya que incluye un punto, necesita usar `${...}`). Por defecto, el módulo `custom` simplemente mostrará todos los módulos personalizados en el orden en que fueron definidos. +The order in which custom modules are shown can be individually set by including `${custom.foo}` in the top level `format` (as it includes a dot, you need to use `${...}`). By default, the `custom` module will simply show all custom modules in the order they were defined. ::: ::: consejo -[El issue #1252](https://github.com/starship/starship/discussions/1252) contiene ejemplos de módulos personalizados. Si tiene un ejemplo interesante no cubierto allí, no dude en compartirlo allí! +[Issue #1252](https://github.com/starship/starship/discussions/1252) contains examples of custom modules. If you have an interesting example not covered there, feel free to share it there! ::: ### Opciones -| Opción | Por defecto | Descripción | -| ------------- | ------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -| `command` | | El comando cuya salida debe ser impresa. El comando se pasará en stdin al shell. | -| `when` | | Comando de shell usado como condición para mostrar el módulo. El módulo se mostrará si el comando devuelve un código de estado `0`. | -| `shell` | | [Ver abajo](#custom-command-shell) | -| `description` | `""` | La descripción del módulo que se muestra al ejecutar `starship explain`. | -| `files` | `[]` | Los archivos que se buscarán en el directorio de trabajo para obtener una coincidencia. | -| `directories` | `[]` | Los directorios que se buscarán en el directorio de trabajo para una coincidencia. | -| `extensions` | `[]` | Las extensiones que se buscarán en el directorio de trabajo para obtener una coincidencia. | -| `symbol` | `""` | El símbolo usado antes de mostrar la salida del comando. | -| `style` | `"bold green"` | El estilo del módulo. | -| `format` | `"[$symbol($output )]($style)"` | El formato del módulo. | -| `disabled` | `false` | Desactiva este módulo `custom`. | -| `os` | | Nombre del sistema operativo en el que se mostrará el módulo (unix, linux, macos, windows, ... ) [Ver valores posibles](https://doc.rust-lang.org/std/env/consts/constant.OS.html). | +| Opción | Por defecto | Descripción | +| ------------- | ------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | +| `command` | | The command whose output should be printed. The command will be passed on stdin to the shell. | +| `when` | | A shell command used as a condition to show the module. The module will be shown if the command returns a `0` status code. | +| `shell` | | [See below](#custom-command-shell) | +| `description` | `""` | The description of the module that is shown when running `starship explain`. | +| `files` | `[]` | The files that will be searched in the working directory for a match. | +| `directories` | `[]` | The directories that will be searched in the working directory for a match. | +| `extensions` | `[]` | The extensions that will be searched in the working directory for a match. | +| `symbol` | `""` | The symbol used before displaying the command output. | +| `style` | `"bold green"` | El estilo del módulo. | +| `format` | `"[$symbol($output )]($style)"` | El formato del módulo. | +| `disabled` | `false` | Disables this `custom` module. | +| `os` | | Operating System name on which the module will be shown (unix, linux, macos, windows, ... ) [See possible values](https://doc.rust-lang.org/std/env/consts/constant.OS.html). | ### Variables -| Variable | Descripción | -| --------- | ----------------------------------------- | -| output | La salida del comando de shell en `shell` | -| symbol | Refleja el valor de la opción `symbol` | -| style\* | Refleja el valor de la opción `style` | +| Variable | Descripción | +| --------- | -------------------------------------- | +| output | The output of shell command in `shell` | +| symbol | Refleja el valor de la opción `symbol` | +| style\* | Refleja el valor de la opción `style` | \*: Esta variable sólo puede ser usada como parte de una cadena de estilo #### Comando personalizado del intérprete de comandos -`shell` acepta una lista no vacía de cadenas, donde: +`shell` accepts a non-empty list of strings, where: -- La primera cadena es la ruta al intérprete de comandos a usar para ejecutar el comando. -- Otros argumentos siguientes son pasados al shell. +- The first string is the path to the shell to use to execute the command. +- Other following arguments are passed to the shell. -Si no está activado, se retornará a STARSHIP_SHELL y luego a "sh" en Linux, y "cmd /C" en Windows. +If unset, it will fallback to STARSHIP_SHELL and then to "sh" on Linux, and "cmd /C" on Windows. -El `comando` será pasado en stdin. +The `command` will be passed in on stdin. -Si no se da el `shell` o solo contiene un elemento y Starship detecta PowerShell los siguientes argumentos se añadirán automáticamente: `-NoProfile -Command -`. Este comportamiento puede evitarse pasando explícitamente argumentos al intérprete, p.ej. +If `shell` is not given or only contains one element and Starship detects PowerShell will be used, the following arguments will automatically be added: `-NoProfile -Command -`. This behavior can be avoided by explicitly passing arguments to the shell, e.g. ```toml shell = ["pwsh", "-Command", "-"] ``` -::: advertencia Asegúrate de que tu configuración personalizada de shell salga con éxito +::: warning Make sure your custom shell configuration exits gracefully -Si establece un comando personalizado, asegúrese de que el Shell por defecto usado por starship ejecutará correctamente el comando con una salida elgante (a través de la opción `shell`). +If you set a custom command, make sure that the default Shell used by starship will properly execute the command with a graceful exit (via the `shell` option). -Por ejemplo, PowerShell requiere el parámetro `-Command` para ejecutar una sola línea. Omitir este parámetro puede arrojar a starchip a un bucle recursivo donde el shell podría intentar cargar un entorno de perfil completo con starship en sí misma y volver a ejecutar el comando personalizado, entrando en un bucle infinito. +For example, PowerShell requires the `-Command` parameter to execute a one liner. Omitting this parameter might throw starship into a recursive loop where the shell might try to load a full profile environment with starship itself again and hence re-execute the custom command, getting into a never ending loop. -Se recomiendan parámetros similares a `-NoProfile` en PowerShell para otros shells para evitar tiempo extra de carga de un perfil personalizado en cada invocación de starship. +Parameters similar to `-NoProfile` in PowerShell are recommended for other shells as well to avoid extra loading time of a custom profile on every starship invocation. -La detección automática de shells y la adición adecuada de parámetros están actualmente implementados, pero es posible que no todos los shells estén cubiertos. Por favor, [abre un issue](https://github.com/starship/starship/issues/new/choose) con los detalles del intérprete de comandos y la configuración de Starship si te encuentras en tal escenario. +Automatic detection of shells and proper parameters addition are currently implemented, but it's possible that not all shells are covered. [Please open an issue](https://github.com/starship/starship/issues/new/choose) with shell details and starship configuration if you hit such scenario. ::: @@ -3090,8 +3163,8 @@ La detección automática de shells y la adición adecuada de parámetros están # ~/.config/starship.toml [custom.foo] -command = "echo foo" # muestra la salida del comando -files = ["foo"] # se pueden especificar filtros +command = "echo foo" # shows output of command +files = ["foo"] # can specify filters when = """ test "$HOME" == "$PWD" """ format = " transcending [$output]($style)" diff --git a/docs/es-ES/guide/README.md b/docs/es-ES/guide/README.md index c95dd20e..964198b9 100644 --- a/docs/es-ES/guide/README.md +++ b/docs/es-ES/guide/README.md @@ -48,30 +48,6 @@ height="20" src="https://raw.githubusercontent.com/starship/starship/master/media/flag-us.png" alt="English" - /> -   - 日本語 -   - 繁體中文 -   - Русский   -   - 简体中文   Francés +   + 日本語 +   + Português do Brasil +   + Русский   +   + 简体中文 +   + 繁體中文

@@ -160,8 +168,8 @@ ```sh sh -c "$(curl -fsSL https://starship.rs/install.sh)" ``` - Para actualizar Starship, vuelve a ejecutar el guión anterior. Reemplazará la versión actual sin tocar la configuración de Starship. + Para actualizar Starship, vuelve a ejecutar el guión anterior. Reemplazará la versión actual sin tocar la configuración de Starship. **Nota** - Los valores por defecto del guión de instalación se pueden anular (ver la ayuda incorporada). @@ -266,7 +274,7 @@ #### Xonsh - Add the following to the end of `~/.xonshrc`: + Añade lo siguiente al final de `~/.xonshrc`: ```sh # ~/.xonshrc @@ -277,7 +285,7 @@ #### Nushell - **Warning** This will change in the future. Only nu version v0.33 or higher is supported. Add the following to your nu config file. You can check the location of this file by running `config path` in nu. + **Advertencia** Esto cambiará en el futuro. Sólo se admite la versión nu v0.33 o superior. Añade lo siguiente a tu archivo de configuración nu. Puedes comprobar la ubicación de este archivo ejecutando `ruta de configuración` en nu. ```toml startup = [ diff --git a/docs/es-ES/presets/README.md b/docs/es-ES/presets/README.md index 72e39b38..ec70717a 100644 --- a/docs/es-ES/presets/README.md +++ b/docs/es-ES/presets/README.md @@ -112,6 +112,9 @@ format = '\[[$symbol($version)]($style)\]' [cmd_duration] format = '\[[⏱ $duration ]($style)\]' +[cobol] +format = '\[[$symbol($version)]($style)\]' + [conda] format = '\[[$symbol$environment]($style)\]' @@ -272,6 +275,9 @@ deleted = "x" [aws] symbol = "aws " +[cobol] +symbol = "cobol " + [conda] symbol = "conda " @@ -363,11 +369,11 @@ symbol = "scala " symbol = "swift " ``` -## Hide Runtime Versions +## Ocultar versiones en tiempo de ejecución -This preset hides the version of language runtimes. If you work in containers or virtualized environments, this one is for you! +Esta configuración predeterminada oculta la versión de los tiempos de ejecución del idioma. Si trabajas en contenedores o entornos virtualizados, ¡ésto es para ti! -![Screenshot of Hide Runtime Versions preset](/presets/hide-runtime-versions.png) +![Captura de pantalla ajustes de Ocultar versiones de tiempo de ejecución](/presets/hide-runtime-versions.png) ### Configuración @@ -375,6 +381,9 @@ This preset hides the version of language runtimes. If you work in containers or [cmake] format = "via [$symbol]($style)" +[cobol] +format = "via [$symbol]($style)" + [crystal] format = "via [$symbol]($style)" diff --git a/docs/fr-FR/advanced-config/README.md b/docs/fr-FR/advanced-config/README.md index a34638ce..8169ed5b 100644 --- a/docs/fr-FR/advanced-config/README.md +++ b/docs/fr-FR/advanced-config/README.md @@ -68,9 +68,36 @@ function set_win_title(){ starship_precmd_user_func="set_win_title" ``` +## Enable Right Prompt + +Some shells support a right prompt which renders on the same line as the input. Starship can set the content of the right prompt using the `right_format` option. Any module that can be used in `format` is also supported in `right_format`. The `$all` variable will only contain modules not explicitly used in either `format` or `right_format`. + +Note: The right prompt is a single line following the input location. To right align modules above the input line in a multi-line prompt, see the [fill module](/config/#fill). + +`right_format` is currently supported for the following shells: elvish, fish, zsh. + +### Exemple + +```toml +# ~/.config/starship.toml + +# A minimal left prompt +format = """$character""" + +# move the rest of the prompt to the right +right_format = """$all""" +``` + +Produces a prompt like the following: + +``` +▶ starship on  rprompt [!] is 📦 v0.57.0 via 🦀 v1.54.0 took 17s +``` + + ## Chaînes de style -Les chaînes de style sont une liste de mots, séparés par des espaces. Les mots ne sont pas sensibles à la casse (c'est-à-dire `gras` et `GrAs` sont considérés comme le même mot). Chaque mot peut être l'un des suivants : +Style strings are a list of words, separated by whitespace. The words are not case sensitive (i.e. `bold` and `BoLd` are considered the same string). Each word can be one of the following: - `bold` - `italic` @@ -82,14 +109,14 @@ Les chaînes de style sont une liste de mots, séparés par des espaces. Les mot - `` - `none` -où `` est un spécificateur de couleur (discuté ci-dessous). `fg:` et `` font actuellement la même chose, bien que cela puisse changer dans le futur. `inverted` permute les couleurs de fond et de premier plan. L'ordre des mots dans la chaîne n'a pas d'importance. +where `` is a color specifier (discussed below). `fg:` and `` currently do the same thing, though this may change in the future. `inverted` swaps the background and foreground colors. The order of words in the string does not matter. -La valeur `none` remplace toutes les autres valeurs si elle n'est pas incluse dans un spécificateur `bg:`, de sorte que par exemple `fg: red none fg:blue` créera une chaîne sans style. `bg:none` définit l'arrière plan sur la couleur par défaut, donc `fg:red bg:none` est équivalent à `red` ou `fg:red` et `bg:green fg:red bg:none` est aussi équivalent à `fg:red` ou `red`. Utiliser `none` avec d'autres valeurs peut éventuellement devenir une erreur dans le futur. +The `none` token overrides all other tokens in a string if it is not part of a `bg:` specifier, so that e.g. `fg:red none fg:blue` will still create a string with no styling. `bg:none` sets the background to the default color so `fg:red bg:none` is equivalent to `red` or `fg:red` and `bg:green fg:red bg:none` is also equivalent to `fg:red` or `red`. It may become an error to use `none` in conjunction with other tokens in the future. -Un spécificateur de couleur peut être l'un des éléments suivants : +A color specifier can be one of the following: - Une des couleurs standard du terminal : `black`, `red`, `green`, `blue`, `yellow`, `purple`, `cyan`, `white`. Vous pouvez éventuellement les préfixer avec `bright-` pour obtenir la version lumineuse (par exemple `bright-white`). - Un `#` suivi d'un nombre hexadécimal de six chiffres. Ceci spécifie un [ Code hexadécimal de couleur RVB ](https://www.w3schools.com/colors/colors_hexadecimal.asp). - Un nombre entre 0 et 255. Ceci spécifie un [code de couleur ANSI 8 bits](https://i.stack.imgur.com/KTSQa.png). -Si plusieurs couleurs sont spécifiées pour le premier plan ou l'arrière-plan, celle spécifiée en dernier sera prioritaire. +If multiple colors are specified for foreground/background, the last one in the string will take priority. diff --git a/docs/fr-FR/config/README.md b/docs/fr-FR/config/README.md index e96aab61..3743fbf0 100644 --- a/docs/fr-FR/config/README.md +++ b/docs/fr-FR/config/README.md @@ -75,7 +75,7 @@ Un groupe de texte se compose de deux parties différentes. La première partie, qui est entourée dans un `[]`, est une [chaîne de formatage](#format-strings). Vous pouvez y ajouter des textes, des variables, ou même des groupes de texte imbriqués. -La deuxième partie, qui est entourée par `()`, est une [chaîne de style](#style-strings). Ceci peut être utilisé pour styliser la première partie. +La deuxième partie, qui est entourée par `()`, est une [chaîne de style](#style-strings). This can be used to style the first part. Par exemple : @@ -142,12 +142,14 @@ Voici la liste des options de configuration de l'invite en lui-même. ### Options -| Option | Défaut | Description | -| ----------------- | ------------------------------ | --------------------------------------------------------------------------- | -| `format` | [lien](#default-prompt-format) | Configure le format de l'invite. | -| `scan_timeout` | `30` | Délai maximal pour le scan des fichiers par starship (en millisecondes). | -| `command_timeout` | `500` | Délai maximal pour les commandes exécutées par starship (en millisecondes). | -| `add_newline` | `true` | Insère une ligne vide entre les invites du shell. | +| Option | Défaut | Description | +| ----------------- | ------------------------------ | ---------------------------------------------------------------- | +| `format` | [lien](#default-prompt-format) | Configure le format de l'invite. | +| `right_format` | `""` | See [Enable Right Prompt](/advanced-config/#enable-right-prompt) | +| `scan_timeout` | `30` | Timeout for starship to scan files (in milliseconds). | +| `command_timeout` | `500` | Timeout for commands executed by starship (in milliseconds). | +| `add_newline` | `true` | Inserts blank line between shell prompts. | + ### Exemple @@ -179,6 +181,7 @@ format = """ $username\ $hostname\ $shlvl\ +$singularity\ $kubernetes\ $directory\ $vcsh\ @@ -191,6 +194,7 @@ $hg_branch\ $docker_context\ $package\ $cmake\ +$cobol\ $dart\ $deno\ $dotnet\ @@ -202,6 +206,7 @@ $helm\ $java\ $julia\ $kotlin\ +$lua\ $nim\ $nodejs\ $ocaml\ @@ -209,6 +214,7 @@ $perl\ $php\ $purescript\ $python\ +$rlang\ $red\ $ruby\ $rust\ @@ -229,7 +235,6 @@ $crystal\ $custom\ $cmd_duration\ $line_break\ -$lua\ $jobs\ $battery\ $time\ @@ -238,15 +243,22 @@ $shell\ $character""" ``` +If you just want to extend the default format, you can use `$all`; modules you explicitly add to the format will not be duplicated. Eg. + +```toml +# Move the directory to the second line +format="$all$directory$character" +``` + ## AWS -Le module `aws` affiche la région et le profil AWS courant. Ces informations sont basées sur les variables d'environnement `AWS_REGION`, `AWS_DEFAULT_REGION`, et `AWS_PROFILE` ainsi que le fichier `~/.aws/config`. Ce module affiche également un minuteur d'expiration lorsque vous utilisez des identifiants temporaires. +The `aws` module shows the current AWS region and profile. This is based on `AWS_REGION`, `AWS_DEFAULT_REGION`, and `AWS_PROFILE` env var with `~/.aws/config` file. This module also shows an expiration timer when using temporary credentials. -Lorsque vous utilisez [aws-vault](https://github.com/99designs/aws-vault) le profil est lu à partir de la variable d'environnement `AWS_VAULT` et la date d'expiration des identifiants est lue à partir de la variable d'environnement `AWS_SESSION_EXPIRATION`. +When using [aws-vault](https://github.com/99designs/aws-vault) the profile is read from the `AWS_VAULT` env var and the credentials expiration date is read from the `AWS_SESSION_EXPIRATION` env var. -Lorsque vous utilisez [awsu](https://github.com/kreuzwerker/awsu) le profil est lu depuis la variable d'environnement `AWSU_PROFILE`. +When using [awsu](https://github.com/kreuzwerker/awsu) the profile is read from the `AWSU_PROFILE` env var. -Lorsque vous utilisez [AWSume](https://awsu.me) le profil est lu à partir de la variable d'environnement `AWSUME_PROFILE` et la date d'expiration des identifiants est lue à partir de la variable d'environnement `AWSUME_EXPIRATION`. +When using [AWSume](https://awsu.me) the profile is read from the `AWSUME_PROFILE` env var and the credentials expiration date is read from the `AWSUME_EXPIRATION` env var. ### Options @@ -269,7 +281,7 @@ Lorsque vous utilisez [AWSume](https://awsu.me) le profil est lu à partir de la | symbol | | Reflète la valeur de l'option `symbol` | | style\* | | Reflète la valeur de l'option `style` | -\* : Cette variable ne peut être utilisée que comme partie d'une chaîne de style +\*: This variable can only be used as a part of a style string ### Exemples @@ -314,7 +326,7 @@ symbol = "🅰 " ## Battery -Le module `battery` montre à quel point la batterie de l'appareil est chargée et son état de charge actuel. Ce module n'est visible que lorsque la batterie de l'appareil est inférieure à 10%. +The `battery` module shows how charged the device's battery is and its current charging status. The module is only visible when the device's battery is below 10%. ### Options @@ -342,7 +354,7 @@ discharging_symbol = "💀 " ### Indicateur de batterie -L'option de configuration `display` est utilisée pour définir quand l'indicateur de batterie doit être affiché (threshold), quel symbole doit être utilisé (symbol) et à quoi il ressemble (style). Si aucun `display` n'est fourni. La valeur par défaut est la suivante : +The `display` configuration option is used to define when the battery indicator should be shown (threshold), which symbol would be used (symbol), and what it would like (style). If no `display` is provided. La valeur par défaut est la suivante : ```toml [[battery.display]] @@ -350,11 +362,11 @@ threshold = 10 style = "bold red" ``` -La valeur par défaut pour les options `charging_symbol` et `discharging_symbol` est respectivement la valeur des options `charging_symbol` et `discharging_symbol` du module `battery`. +The default value for the `charging_symbol` and `discharging_symbol` option is respectively the value of `battery`'s `charging_symbol` and `discharging_symbol` option. #### Options -L'option `display` est un tableau des propriétés suivantes. +The `display` option is an array of the following table. | Option | Défaut | Description | | -------------------- | ---------- | --------------------------------------------------------------------------------------------------------------------------------------- | @@ -366,29 +378,29 @@ L'option `display` est un tableau des propriétés suivantes. #### Exemple ```toml -[[battery.display]] # Style "rouge gras" et affichage de discharging_symbol lorsque la batterie est entre 0% et 10% de sa capacité +[[battery.display]] # "bold red" style and discharging_symbol when capacity is between 0% and 10% threshold = 10 style = "bold red" -[[battery.display]] # Style "jaune gras" et affichage de💦 lorsque la batterie est entre 10% et 30% de sa capacité +[[battery.display]] # "bold yellow" style and 💦 symbol when capacity is between 10% and 30% threshold = 30 style = "bold yellow" discharging_symbol = 💦 -# Au-dessus de 30% de charge, l'indicateur de batterie ne sera pas affiché +# when capacity is over 30%, the battery indicator will not be displayed ``` ## Caractères -Le module `character` affiche un caractère (habituellement une flèche) à côté de l'endroit où le texte est entré dans votre terminal. +The `character` module shows a character (usually an arrow) beside where the text is entered in your terminal. -Le caractère vous dira si la dernière commande a été réussie ou pas. Il y a deux façons de faire : +The character will tell you whether the last command was successful or not. It can do this in two ways: - changement de couleur (`red`/`green`) - changement de forme (`❯`/`✖`) -Par défaut, seule la couleur change. Si vous désirez également changer sa forme, jetez un œil à [cet exemple](#with-custom-error-shape). +By default it only changes color. If you also want to change its shape take a look at [this example](#with-custom-error-shape). ::: warning @@ -398,7 +410,7 @@ Par défaut, seule la couleur change. Si vous désirez également changer sa for ::: warning -`vicmd_symbol` n'est supporté qu'avec fish et zsh. +`vicmd_symbol` is only supported in fish and zsh. ::: @@ -451,7 +463,7 @@ vicmd_symbol = "[V](bold green) " ## CMake -Le module `cmake` affiche la version actuellement installée de [CMake](https://cmake.org/). Par défaut le module sera activé si au moins l'une des conditions suivantes est remplie: +The `cmake` module shows the currently installed version of [CMake](https://cmake.org/). By default the module will be activated if any of the following conditions are met: - Le répertoire actuel contient un fichier `CMakeLists.txt` - Le répertoire actuel contient un fichier ` CMakeCache.txt` @@ -477,46 +489,76 @@ Le module `cmake` affiche la version actuellement installée de [CMake](https:// | symbol | | Reflète la valeur de l'option `symbol` | | style\* | | Reflète la valeur de l'option `style` | -\* : Cette variable ne peut être utilisée que comme partie d'une chaîne de style +\*: This variable can only be used as a part of a style string -## Temps d'exécution +## COBOL / GNUCOBOL -Le module `cmd_duration` montre combien de temps la dernière commande a pris pour s'exécuter. Le module ne sera affiché que si la commande a pris plus de deux secondes, ou plus que la valeur `min_time`, si elle existe. +The `cobol` module shows the currently installed version of COBOL. By default, the module will be shown if any of the following conditions are met: -::: warning N'interceptez pas le signal DEBUG avec Bash - -Si vous utilisez starship avec `bash`, n'interceptez pas `DEBUG` après avoir exécuté `eval $(starship init $0)`, ou ce module **ne fonctionnera pas**. - -::: - -Les utilisateurs de Bash qui ont besoin de fonctionnalité pré-exec peuvent utiliser [rcaloras's bash_preexec framework](https://github.com/rcaloras/bash-preexec). Définissez simplement les tableaux `preexec_functions` et `precmd_functions` avant d'exécuter `eval $(starship init $0)`, puis procédez comme d'habitude. +- The current directory contains any files ending in `.cob` or `.COB` +- The current directory contains any files ending in `.cbl` or `.CBL` ### Options -| Option | Défaut | Description | -| -------------------- | ----------------------------- | ------------------------------------------------------------------------- | -| `min_time` | `2_000` | Durée la plus courte quand afficher le temps (en millisecondes). | -| `show_milliseconds` | `false` | Afficher les millisecondes en plus des secondes pendant la durée. | -| `format` | `"took [$duration]($style) "` | Format du module. | -| `style` | `"bold yellow"` | Le style du module. | -| `disabled` | `false` | Désactive le module `cmd_duration`. | -| `show_notifications` | `false` | Afficher les notifications du bureau lorsque la commande est terminée. | -| `min_time_to_notify` | `45_000` | Durée minimale après laquelle activer la notification (en millisecondes). | +| Option | Défaut | Description | +| ------------------- | ------------------------------------ | ------------------------------------------------------------------------------------------ | +| `symbol` | `"⚙️ "` | The symbol used before displaying the version of COBOL. | +| `format` | `"via [$symbol($version )]($style)"` | Format du module. | +| `version_format` | `"v${raw}"` | Le format de la version. Les variables disponibles sont `raw`, `major`, `minor`, & `patch` | +| `style` | `"bold blue"` | Le style du module. | +| `detect_extensions` | `["cbl", "cob", "CBL", "COB"]` | Quelles extensions devraient activer ce module. | +| `detect_files` | `[]` | Quels fichiers devraient activer ce module. | +| `detect_folders` | `[]` | Quels dossiers devraient activer ce module. | +| `disabled` | `false` | Disables the `cobol` module. | + +### Variables + +| Variable | Exemple | Description | +| --------- | ---------- | -------------------------------------- | +| version | `v3.1.2.0` | The version of `cobol` | +| symbol | | Reflète la valeur de l'option `symbol` | +| style\* | | Reflète la valeur de l'option `style` | + +\*: This variable can only be used as a part of a style string + +## Temps d'exécution + +The `cmd_duration` module shows how long the last command took to execute. The module will be shown only if the command took longer than two seconds, or the `min_time` config value, if it exists. + +::: warning Do not hook the DEBUG trap in Bash + +If you are running Starship in `bash`, do not hook the `DEBUG` trap after running `eval $(starship init $0)`, or this module **will** break. + +::: + +Bash users who need preexec-like functionality can use [rcaloras's bash_preexec framework](https://github.com/rcaloras/bash-preexec). Simply define the arrays `preexec_functions` and `precmd_functions` before running `eval $(starship init $0)`, and then proceed as normal. + +### Options + +| Option | Défaut | Description | +| -------------------- | ----------------------------- | ---------------------------------------------------------- | +| `min_time` | `2_000` | Shortest duration to show time for (in milliseconds). | +| `show_milliseconds` | `false` | Show milliseconds in addition to seconds for the duration. | +| `format` | `"took [$duration]($style) "` | Format du module. | +| `style` | `"bold yellow"` | Le style du module. | +| `disabled` | `false` | Disables the `cmd_duration` module. | +| `show_notifications` | `false` | Show desktop notifications when command completes. | +| `min_time_to_notify` | `45_000` | Shortest duration for notification (in milliseconds). | ::: tip -L'affichage des notifications de bureau nécessite que starship soit compilé avec la prise en charge de `rust-notify`. Vérifiez si starship supporte les notifications en exécutant `STARSHIP_LOG=debug starship module cmd_duration -d 60000` lorsque `show_notifications` est défini à `true`. +Showing desktop notifications requires starship to be built with `rust-notify` support. You check if your starship supports notifications by running `STARSHIP_LOG=debug starship module cmd_duration -d 60000` when `show_notifications` is set to `true`. ::: ### Variables -| Variable | Exemple | Description | -| --------- | -------- | --------------------------------------------- | -| duration | `16m40s` | Le temps nécessaire pour exécuter la commande | -| style\* | | Reflète la valeur de l'option `style` | +| Variable | Exemple | Description | +| --------- | -------- | --------------------------------------- | +| duration | `16m40s` | The time it took to execute the command | +| style\* | | Reflète la valeur de l'option `style` | -\* : Cette variable ne peut être utilisée que comme partie d'une chaîne de style +\*: This variable can only be used as a part of a style string ### Exemple @@ -530,34 +572,34 @@ format = "underwent [$duration](bold yellow)" ## Conda -Le module `conda` affiche l'environnement conda actuel, si `$CONDA_DEFAULT_ENV` est défini. +The `conda` module shows the current [Conda](https://docs.conda.io/en/latest/) environment, if `$CONDA_DEFAULT_ENV` is set. ::: tip -Cela ne supprime pas le modificateur d'invite de conda, vous pourriez vouloir exécuter `conda config --set changeps1 False` pour le désactiver. +This does not suppress conda's own prompt modifier, you may want to run `conda config --set changeps1 False`. ::: ### Options -| Option | Défaut | Description | -| ------------------- | -------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -| `truncation_length` | `1` | Le nombre de répertoires dans lesquels le chemin d'environnement (Path) doit être tronqué, si l'environnement a été créé via `conda create -p [path]`. `0` ne signifie pas de troncature. Regardez aussi le module [`directory`](#directory). | -| `symbol` | `"🅒 "` | Le symbole utilisé avant le nom d'environnement. | -| `style` | `"bold green"` | Le style du module. | -| `format` | `"via [$symbol$environment]($style) "` | Format du module. | -| `ignore_base` | `true` | Ignore l'environnement `base` lorsqu'il est activé. | -| `disabled` | `false` | Désactive le module `conda`. | +| Option | Défaut | Description | +| ------------------- | -------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | +| `truncation_length` | `1` | The number of directories the environment path should be truncated to, if the environment was created via `conda create -p [path]`. `0` means no truncation. Also see the [`directory`](#directory) module. | +| `symbol` | `"🅒 "` | The symbol used before the environment name. | +| `style` | `"bold green"` | Le style du module. | +| `format` | `"via [$symbol$environment]($style) "` | Format du module. | +| `ignore_base` | `true` | Ignores `base` environment when activated. | +| `disabled` | `false` | Disables the `conda` module. | ### Variables -| Variable | Exemple | Description | -| ------------- | ------------ | -------------------------------------- | -| environnement | `astronauts` | La version courante de conda | -| symbol | | Reflète la valeur de l'option `symbol` | -| style\* | | Reflète la valeur de l'option `style` | +| Variable | Exemple | Description | +| ----------- | ------------ | -------------------------------------- | +| environment | `astronauts` | The current conda environment | +| symbol | | Reflète la valeur de l'option `symbol` | +| style\* | | Reflète la valeur de l'option `style` | -\* : Cette variable ne peut être utilisée que comme partie d'une chaîne de style +\*: This variable can only be used as a part of a style string ### Exemple @@ -570,33 +612,33 @@ format = "[$symbol$environment](dimmed green) " ## Crystal -Le module `crystal` affiche la version actuellement installée de [Crystal](https://crystal-lang.org/). Par défaut le module sera activé si au moins l'une des conditions suivantes est remplie: +The `crystal` module shows the currently installed version of [Crystal](https://crystal-lang.org/). Par défaut le module sera activé si au moins l'une des conditions suivantes est remplie: -- Le répertoire courant contient un fichier `shard.yml` -- Le répertoire courant contient un fichier `.cr` +- The current directory contains a `shard.yml` file +- The current directory contains a `.cr` file ### Options | Option | Défaut | Description | | ------------------- | ------------------------------------ | ------------------------------------------------------------------------------------------ | -| `symbol` | `"🔮 "` | Le symbole utilisé avant d'afficher la version de crystal. | +| `symbol` | `"🔮 "` | The symbol used before displaying the version of crystal. | | `format` | `"via [$symbol($version )]($style)"` | Format du module. | | `version_format` | `"v${raw}"` | Le format de la version. Les variables disponibles sont `raw`, `major`, `minor`, & `patch` | | `style` | `"bold green"` | Le style du module. | | `detect_extensions` | `["cr"]` | Quelles extensions devraient activer ce module. | | `detect_files` | `["shard.yml"]` | Quels fichiers devraient activer ce module. | | `detect_folders` | `[]` | Quels dossiers devraient activer ce module. | -| `disabled` | `false` | Désactive le module `crystal`. | +| `disabled` | `false` | Disables the `crystal` module. | ### Variables | Variable | Exemple | Description | | --------- | --------- | -------------------------------------- | -| version | `v0.32.1` | La version de `cristal` | +| version | `v0.32.1` | The version of `crystal` | | symbol | | Reflète la valeur de l'option `symbol` | | style\* | | Reflète la valeur de l'option `style` | -\* : Cette variable ne peut être utilisée que comme partie d'une chaîne de style +\*: This variable can only be used as a part of a style string ### Exemple @@ -609,11 +651,11 @@ format = "via [✨ $version](bold blue) " ## Dart -Le module `dart` affiche la version actuellement installée de [Dart](https://dart.dev/). Par défaut le module sera activé si au moins l'une des conditions suivantes est remplie: +The `dart` module shows the currently installed version of [Dart](https://dart.dev/). Par défaut le module sera activé si au moins l'une des conditions suivantes est remplie: -- Le répertoire courant contient un fichier `.dart` -- Le répertoire courant contient un répertoire `.dart_tool` -- Le répertoire courant contient un fichier `pubspec.yaml`, `pubspec.yml` ou `pubspec.lock` +- The current directory contains a file with `.dart` extension +- The current directory contains a `.dart_tool` directory +- The current directory contains a `pubspec.yaml`, `pubspec.yml` or `pubspec.lock` file ### Options @@ -621,22 +663,22 @@ Le module `dart` affiche la version actuellement installée de [Dart](https://da | ------------------- | ------------------------------------------------- | ------------------------------------------------------------------------------------------ | | `format` | `"via [$symbol($version )]($style)"` | Format du module. | | `version_format` | `"v${raw}"` | Le format de la version. Les variables disponibles sont `raw`, `major`, `minor`, & `patch` | -| `symbol` | `"🎯 "` | Une chaîne de caractères représentant le symbole de Dart | +| `symbol` | `"🎯 "` | A format string representing the symbol of Dart | | `detect_extensions` | `["dart"]` | Quelles extensions devraient activer ce module. | | `detect_files` | `["pubspec.yaml", "pubspec.yml", "pubspec.lock"]` | Quels fichiers devraient activer ce module. | | `detect_folders` | `[".dart_tool"]` | Quels dossiers devraient activer ce module. | | `style` | `"bold blue"` | Le style du module. | -| `disabled` | `false` | Désactive le module `dart`. | +| `disabled` | `false` | Disables the `dart` module. | ### Variables | Variable | Exemple | Description | | --------- | -------- | -------------------------------------- | -| version | `v2.8.4` | La version de `dart` | +| version | `v2.8.4` | The version of `dart` | | symbol | | Reflète la valeur de l'option `symbol` | | style\* | | Reflète la valeur de l'option `style` | -\* : Cette variable ne peut être utilisée que comme partie d'une chaîne de style +\*: This variable can only be used as a part of a style string ### Exemple @@ -649,8 +691,8 @@ format = "via [🔰 $version](bold red) " ## Deno -Le module `deno` affiche la version actuellement installée de [Deno](https://deno.land/). Par défaut le module sera activé si au moins l'une des conditions suivantes est remplie: -- Le répertoire courant contient un fichier `mod.ts`, `mod.js`, `deps.ts` ou `deps.ts` +The `deno` module shows you your currently installed version of [Deno](https://deno.land/). Par défaut le module sera activé si au moins l'une des conditions suivantes est remplie: +- The current directory contains a `mod.ts`, `mod.js`, `deps.ts` or `deps.js` file ### Options @@ -658,18 +700,18 @@ Le module `deno` affiche la version actuellement installée de [Deno](https://de | ------------------- | -------------------------------------------- | ------------------------------------------------------------------------------------------ | | `format` | `"via [$symbol($version )]($style)"` | Format du module. | | `version_format` | `"v${raw}"` | Le format de la version. Les variables disponibles sont `raw`, `major`, `minor`, & `patch` | -| `symbol` | `"🦕 "` | Une chaîne de caractères représentant le symbole de Deno | +| `symbol` | `"🦕 "` | A format string representing the symbol of Deno | | `detect_extensions` | `[]` | Quelles extensions devraient activer ce module. | | `detect_files` | `["mod.ts", "mod.js", "deps.ts", "deps.js"]` | Quels fichiers devraient activer ce module. | | `detect_folders` | `[]` | Quels dossiers devraient activer ce module. | | `style` | `"green bold"` | Le style du module. | -| `disabled` | `false` | Désactive le module `deno`. | +| `disabled` | `false` | Disables the `deno` module. | ### Variables | Variable | Exemple | Description | | --------- | -------- | -------------------------------------- | -| version | `v1.8.3` | La version de `deno` | +| version | `v1.8.3` | The version of `deno` | | symbol | | Reflète la valeur de l'option `symbol` | | style\* | | Reflète la valeur de l'option `style` | @@ -684,36 +726,36 @@ format = "via [🦕 $version](green bold) " ## Dossier -Le module `directory` montre le chemin vers votre répertoire courant, tronqué à trois dossiers parents. Votre répertoire sera également tronqué à la racine du repo git dans lequel vous vous trouvez actuellement. +The `directory` module shows the path to your current directory, truncated to three parent folders. Your directory will also be truncated to the root of the git repo that you're currently in. -Lorsque vous utilisez le style de pwd de fish, au lieu de cacher le chemin tronqué, vous verrez une abréviation du nom de chaque dossier, en fonction du nombre que vous avez utilisé comme valeur. +When using the fish style pwd option, instead of hiding the path that is truncated, you will see a shortened name of each directory based on the number you enable for the option. -Par exemple, `~/Dev/Nix/nixpkgs/pkgs` où `nixpkgs` est la racine du repo, et l'option définie à `1`. Vous verrez maintenant `~/D/N/nixpkgs/pkgs`, alors que vous auriez vu `nixpkgs/pkgs` avant. +For example, given `~/Dev/Nix/nixpkgs/pkgs` where `nixpkgs` is the repo root, and the option set to `1`. You will now see `~/D/N/nixpkgs/pkgs`, whereas before it would have been `nixpkgs/pkgs`. ### Options -| Option | Défaut | Description | -| ------------------- | -------------------------------------------------- | ------------------------------------------------------------------------------ | -| `truncation_length` | `3` | Le nombre de dossiers parents auquel tronquer le chemin du répertoire courant. | -| `truncate_to_repo` | `true` | Si oui ou non tronquer à la racine du repo git dans lequel vous vous trouvez. | -| `format` | `"[$path]($style)[$read_only]($read_only_style) "` | Format du module. | -| `style` | `"bold cyan"` | Le style du module. | -| `disabled` | `false` | Désactive le module `directory`. | -| `read_only` | `"🔒"` | Le symbole indiquant que le répertoire courant est en lecture seule. | -| `read_only_style` | `"red"` | Le style du symbole de lecture seule. | -| `truncation_symbol` | `""` | Le symbole pour préfixer les chemins tronqués. ex: "…/" | -| `home_symbol` | `"~"` | Le symbole indiquant le répertoire personnel. | +| Option | Défaut | Description | +| ------------------- | -------------------------------------------------- | -------------------------------------------------------------------------------- | +| `truncation_length` | `3` | The number of parent folders that the current directory should be truncated to. | +| `truncate_to_repo` | `true` | Whether or not to truncate to the root of the git repo that you're currently in. | +| `format` | `"[$path]($style)[$read_only]($read_only_style) "` | Format du module. | +| `style` | `"bold cyan"` | Le style du module. | +| `disabled` | `false` | Disables the `directory` module. | +| `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: "…/" | +| `home_symbol` | `"~"` | The symbol indicating home directory. |
-Ce module possède quelques options de configuration avancées qui contrôlent l'affichage du répertoire. +This module has a few advanced configuration options that control how the directory is displayed. -| Options avancées | Défaut | Description | -| --------------------------- | ------ | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -| `substitutions` | | Une table de substitutions à appliquer aux chemins. | -| `fish_style_pwd_dir_length` | `0` | Le nombre de caractères à utiliser lors de l'application de la logique de troncature du pwd de fish. | -| `use_logical_path` | `true` | Si `true` affiche le chemin logique issu du shell via `PWD` ou `--logical-path`. Si `false` renvoie plutôt le chemin du système de fichiers physique avec les liens symboliques résolus. | +| Advanced Option | Défaut | Description | +| --------------------------- | ------ | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------- | +| `substitutions` | | A table of substitutions to be made to the path. | +| `fish_style_pwd_dir_length` | `0` | The number of characters to use when applying fish shell pwd path logic. | +| `use_logical_path` | `true` | If `true` render the logical path sourced from the shell via `PWD` or `--logical-path`. If `false` instead render the physical filesystem path with symlinks resolved. | -`substitutions` vous permet de définir des remplacements arbitraires pour les chaînes littérales qui apparaissent dans le chemin, par exemple pour de longs préfixes de réseau ou des répertoires de développement (ex. Java). Notez que cela désactivera la PWD de style fish. +`substitutions` allows you to define arbitrary replacements for literal strings that occur in the path, for example long network prefixes or development directories (i.e. Java). Note that this will disable the fish style PWD. ```toml [directory.substitutions] @@ -721,7 +763,7 @@ Par exemple, `~/Dev/Nix/nixpkgs/pkgs` où `nixpkgs` est la racine du repo, et l' "src/com/long/java/path" = "mypath" ``` -`fish_style_pwd_dir_leng` interagit avec les options de troncature d'une manière qui peut être surprenante au début : si elle n'est pas nulle, les composantes du chemin qui seraient normalement tronquées sont affichées à la place avec autant de caractères. Par exemple, le chemin `/built/this/city/on/rock/and/roll`, qui devrait normalement être affiché comme `rock/and/roll`, sera affiché sous la forme de `/b/t/c/o/rock/and/roll` avec `fish_style_pwd_dir_length = 1`--les composants de chemin qui seraient normalement supprimés sont affichés avec un caractère unique. Pour `fish_style_pwd_dir_length = 2`, ce serait `/bu/th/ci/on/rock/and/roll`. +`fish_style_pwd_dir_length` interacts with the standard truncation options in a way that can be surprising at first: if it's non-zero, the components of the path that would normally be truncated are instead displayed with that many characters. For example, the path `/built/this/city/on/rock/and/roll`, which would normally be displayed as as `rock/and/roll`, would be displayed as `/b/t/c/o/rock/and/roll` with `fish_style_pwd_dir_length = 1`--the path components that would normally be removed are displayed with a single character. For `fish_style_pwd_dir_length = 2`, it would be `/bu/th/ci/on/rock/and/roll`.
@@ -729,10 +771,10 @@ Par exemple, `~/Dev/Nix/nixpkgs/pkgs` où `nixpkgs` est la racine du repo, et l' | Variable | Exemple | Description | | --------- | --------------------- | ------------------------------------- | -| path | `"D:/Projects"` | Le chemin du répertoire courant | +| path | `"D:/Projects"` | The current directory path | | style\* | `"black bold dimmed"` | Reflète la valeur de l'option `style` | -\* : Cette variable ne peut être utilisée que comme partie d'une chaîne de style +\*: This variable can only be used as a part of a style string ### Exemple @@ -744,32 +786,32 @@ truncation_length = 8 truncation_symbol = "…/" ``` -## Contexte Docker +## Docker Context The `docker_context` module shows the currently active [Docker context](https://docs.docker.com/engine/context/working-with-contexts/) if it's not set to `default` or if the `DOCKER_HOST` or `DOCKER_CONTEXT` environment variables are set (as they are meant to override the context in use). ### Options -| Option | Défaut | Description | -| ------------------- | ------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------ | -| `format` | `"via [$symbol$context]($style) "` | Format du module. | -| `symbol` | `"🐳 "` | Le symbole utilisé avant d'afficher le contexte Docker. | -| `only_with_files` | `true` | Afficher uniquement quand il y a une correspondance | -| `detect_extensions` | `[]` | Quelles extensions devraient activer ce module (il faut que `only_with_files` soit réglé sur true). | -| `detect_files` | `["docker-compose.yml", "docker-compose.yaml", "Dockerfile"]` | Quels noms de fichier devraient activer ce module (il faut que `only_with_files` soit réglé sur true). | -| `detect_folders` | `[]` | Quels dossiers devraient activer ce module (il faut que `only_with_files` soit réglé sur true). | -| `style` | `"blue bold"` | Le style du module. | -| `disabled` | `false` | Désactive le module `docker_context`. | +| Option | Défaut | Description | +| ------------------- | ------------------------------------------------------------- | --------------------------------------------------------------------------------- | +| `format` | `"via [$symbol$context]($style) "` | Format du module. | +| `symbol` | `"🐳 "` | The symbol used before displaying the Docker context. | +| `only_with_files` | `true` | Only show when there's a match | +| `detect_extensions` | `[]` | Which extensions should trigger this module (needs `only_with_files` to be true). | +| `detect_files` | `["docker-compose.yml", "docker-compose.yaml", "Dockerfile"]` | Which filenames should trigger this module (needs `only_with_files` to be true). | +| `detect_folders` | `[]` | Which folders should trigger this module (needs `only_with_files` to be true). | +| `style` | `"blue bold"` | Le style du module. | +| `disabled` | `false` | Disables the `docker_context` module. | ### Variables | Variable | Exemple | Description | | --------- | -------------- | -------------------------------------- | -| context | `test_context` | Le contexte actuel de Docker | +| context | `test_context` | The current docker context | | symbol | | Reflète la valeur de l'option `symbol` | | style\* | | Reflète la valeur de l'option `style` | -\* : Cette variable ne peut être utilisée que comme partie d'une chaîne de style +\*: This variable can only be used as a part of a style string ### Exemple @@ -782,9 +824,9 @@ format = "via [🐋 $context](blue bold)" ## Dotnet -Le module `dotnet` montre la version pertinente du [SDK .NET Core](https://dotnet.microsoft.com/) pour le répertoire courant. Si le SDK a été épinglé dans le répertoire courant, la version épinglée est affichée. Sinon, le module affiche la dernière version installée du SDK. +The `dotnet` module shows the relevant version of the [.NET Core SDK](https://dotnet.microsoft.com/) for the current directory. If the SDK has been pinned in the current directory, the pinned version is shown. Otherwise the module shows the latest installed version of the SDK. -Par défaut, ce module ne sera affiché dans votre invite que lorsqu'un ou plusieurs des fichiers suivants sont présents dans le répertoire courant : +By default this module will only be shown in your prompt when one or more of the following files are present in the current directory: - `global.json` - `project.json` @@ -795,9 +837,9 @@ Par défaut, ce module ne sera affiché dans votre invite que lorsqu'un ou plusi - `*.fsproj` - `*.xproj` -Vous aurez également besoin du SDK .NET Core pour pouvoir l'utiliser correctement. +You'll also need the .NET Core SDK installed in order to use it correctly. -En interne, ce module utilise son propre mécanisme de détection de version. Généralement, il est deux fois plus rapide que d'exécuter `dotnet --version`, mais il peut afficher une version incorrecte si votre projet .NET a une arborescence inhabituelle. Si la précision est plus importante que la vitesse, vous pouvez désactiver le mécanisme en définissant `heuristic = false` dans les options du module. +Internally, this module uses its own mechanism for version detection. Typically it is twice as fast as running `dotnet --version`, but it may show an incorrect version if your .NET project has an unusual directory layout. If accuracy is more important than speed, you can disable the mechanism by setting `heuristic = false` in the module options. The module will also show the Target Framework Moniker () when there is a csproj file in the current directory. @@ -807,24 +849,24 @@ The module will also show the Target Framework Moniker ([\\w-]+)" = "gke-$cluster" ``` -## Saut de ligne +## Line Break -Le module `line_break` sépare l'invite en deux lignes. +The `line_break` module separates the prompt into two lines. ### Options -| Option | Défaut | Description | -| ---------- | ------- | ----------------------------------------------------------------------- | -| `disabled` | `false` | Désactive le module `line_break` , faisant de l'invite une seule ligne. | +| Option | Défaut | Description | +| ---------- | ------- | ------------------------------------------------------------------ | +| `disabled` | `false` | Disables the `line_break` module, making the prompt a single line. | ### Exemple @@ -1708,11 +1780,11 @@ disabled = true ## Lua -Le module `lua` affiche la version actuellement installée de [Lua](http://www.lua.org/). Par défaut le module sera activé si au moins l'une des conditions suivantes est remplie: +The `lua` module shows the currently installed version of [Lua](http://www.lua.org/). Par défaut le module sera activé si au moins l'une des conditions suivantes est remplie: -- Le répertoire courant contient un fichier `.lua-version` -- Le répertoire courant contient un répertoire `lua` -- Le répertoire actuel contient un fichier avec l'extension `.lua` +- The current directory contains a `.lua-version` file +- The current directory contains a `lua` directory +- The current directory contains a file with the `.lua` extension ### Options @@ -1720,23 +1792,23 @@ Le module `lua` affiche la version actuellement installée de [Lua](http://www.l | ------------------- | ------------------------------------ | ------------------------------------------------------------------------------------------ | | `format` | `"via [$symbol($version )]($style)"` | Format du module. | | `version_format` | `"v${raw}"` | Le format de la version. Les variables disponibles sont `raw`, `major`, `minor`, & `patch` | -| `symbol` | `"🌙 "` | Une chaîne de caractères représentant le symbole de Lua. | +| `symbol` | `"🌙 "` | A format string representing the symbol of Lua. | | `detect_extensions` | `["lua"]` | Quelles extensions devraient activer ce module. | | `detect_files` | `[".lua-version"]` | Quels fichiers devraient activer ce module. | | `detect_folders` | `["lua"]` | Quels dossiers devraient activer ce module. | | `style` | `"bold blue"` | Le style du module. | -| `lua_binary` | `"lua"` | Configure le binaire lua que Starship exécute lors de l'obtention de la version. | -| `disabled` | `false` | Désactive le module `lua`. | +| `lua_binary` | `"lua"` | Configures the lua binary that Starship executes when getting the version. | +| `disabled` | `false` | Disables the `lua` module. | ### Variables | Variable | Exemple | Description | | --------- | -------- | -------------------------------------- | -| version | `v5.4.0` | La version de `lua` | +| version | `v5.4.0` | The version of `lua` | | symbol | | Reflète la valeur de l'option `symbol` | | style\* | | Reflète la valeur de l'option `style` | -\* : Cette variable ne peut être utilisée que comme partie d'une chaîne de style +\*: This variable can only be used as a part of a style string ### Exemple @@ -1747,40 +1819,40 @@ Le module `lua` affiche la version actuellement installée de [Lua](http://www.l format = "via [🌕 $version](bold blue) " ``` -## Utilisation mémoire +## Memory Usage -Le module `memory_usage` affiche la mémoire système actuelle et l'utilisation de swap. +The `memory_usage` module shows current system memory and swap usage. -Par défaut, l'utilisation du swap est affichée si le swap total du système n'est pas nul. +By default the swap usage is displayed if the total system swap is non-zero. ::: tip -Ce module est désactivé par défaut. Pour l'activer, configurez `disabled` sur `false` dans votre fichier de configuration. +This module is disabled by default. To enable it, set `disabled` to `false` in your configuration file. ::: ### Options -| Option | Défaut | Description | -| ----------- | ----------------------------------------------- | ------------------------------------------------------------------------------ | -| `threshold` | `75` | Masquer l'utilisation de la mémoire à moins qu'elle ne dépasse ce pourcentage. | -| `format` | `"via $symbol [${ram}( \| ${swap})]($style) "` | Format du module. | -| `symbol` | `"🐏"` | Le symbole utilisé avant d'afficher l'utilisation de la mémoire. | -| `style` | `"bold dimmed white"` | Le style du module. | -| `disabled` | `true` | Désactiver le module `memory_usage`. | +| Option | Défaut | Description | +| ----------- | ----------------------------------------------- | -------------------------------------------------------- | +| `threshold` | `75` | Hide the memory usage unless it exceeds this percentage. | +| `format` | `"via $symbol [${ram}( \| ${swap})]($style) "` | Format du module. | +| `symbol` | `"🐏"` | The symbol used before displaying the memory usage. | +| `style` | `"bold dimmed white"` | Le style du module. | +| `disabled` | `true` | Disables the `memory_usage` module. | ### Variables -| Variable | Exemple | Description | -| ---------------- | ------------- | ------------------------------------------------------------------------------- | -| ram | `31GiB/65GiB` | La mémoire système utilisée/totale . | -| ram_pct | `48%` | Le pourcentage de la mémoire du système actuel. | -| swap\*\* | `1GiB/4GiB` | La taille de la mémoire swap du fichier de mémoire swap du système courant. | -| swap_pct\*\* | `77%` | Le poucentage de la mémoire swap du fichier de mémoire swap du système courant. | -| symbol | `🐏` | Reflète la valeur de l'option `symbol` | -| style\* | | Reflète la valeur de l'option `style` | +| Variable | Exemple | Description | +| ---------------- | ------------- | ------------------------------------------------------------------ | +| ram | `31GiB/65GiB` | The usage/total RAM of the current system memory. | +| ram_pct | `48%` | The percentage of the current system memory. | +| swap\*\* | `1GiB/4GiB` | The swap memory size of the current system swap memory file. | +| swap_pct\*\* | `77%` | The swap memory percentage of the current system swap memory file. | +| symbol | `🐏` | Reflète la valeur de l'option `symbol` | +| style\* | | Reflète la valeur de l'option `style` | -\* : Cette variable ne peut être utilisée que comme partie d'une chaîne de style \*\* : Les informations sur le fichier SWAP ne sont affichées que si détectées sur le système actuel +\*: This variable can only be used as a part of a style string \*\*: The SWAP file information is only displayed if detected on the current system ### Exemple @@ -1794,30 +1866,30 @@ symbol = " " style = "bold dimmed green" ``` -## Branche Mercurial +## Mercurial Branch -Le module `hg_branch` affiche la branche active du dépôt dans votre répertoire courant. +The `hg_branch` module shows the active branch of the repo in your current directory. ### Options -| Option | Défaut | Description | -| ------------------- | -------------------------------- | ---------------------------------------------------------------------------------------------------------- | -| `symbol` | `" "` | Le symbole utilisé avant le marque-page hg ou le nom de la branche du dépôt dans votre répertoire courant. | -| `style` | `"bold purple"` | Le style du module. | -| `format` | `"on [$symbol$branch]($style) "` | Format du module. | -| `truncation_length` | `2^63 - 1` | Tronque le nom de la branche hg à `N` graphèmes | -| `truncation_symbol` | `"…"` | Le symbole utilisé pour indiquer qu'un nom de branche a été tronqué. | -| `disabled` | `true` | Désactive le module `hg_branch`. | +| Option | Défaut | Description | +| ------------------- | -------------------------------- | -------------------------------------------------------------------------------------------- | +| `symbol` | `" "` | The symbol used before the hg bookmark or branch name of the repo in your current directory. | +| `style` | `"bold purple"` | Le style du module. | +| `format` | `"on [$symbol$branch]($style) "` | Format du module. | +| `truncation_length` | `2^63 - 1` | Truncates the hg branch name to `N` graphemes | +| `truncation_symbol` | `"…"` | The symbol used to indicate a branch name was truncated. | +| `disabled` | `true` | Disables the `hg_branch` module. | ### Variables | Variable | Exemple | Description | | --------- | -------- | -------------------------------------- | -| branch | `master` | La branche mercuriale active | +| branch | `master` | The active mercurial branch | | symbol | | Reflète la valeur de l'option `symbol` | | style\* | | Reflète la valeur de l'option `style` | -\* : Cette variable ne peut être utilisée que comme partie d'une chaîne de style +\*: This variable can only be used as a part of a style string ### Exemple @@ -1832,35 +1904,35 @@ truncation_symbol = "" ## Nim -Le module `nim` affiche la version actuellement installée de [Nim](https://nim-lang.org/). Par défaut le module sera activé si au moins l'une des conditions suivantes est remplie: +The `nim` module shows the currently installed version of [Nim](https://nim-lang.org/). Par défaut le module sera activé si au moins l'une des conditions suivantes est remplie: -- Le répertoire courant contient un fichier `nim.cfg` -- Le répertoire actuel contient un fichier avec l'extension `.nim` -- Le répertoire actuel contient un fichier avec l'extension `.nims` -- Le répertoire actuel contient un fichier avec l'extension `.nimble` +- The current directory contains a `nim.cfg` file +- The current directory contains a file with the `.nim` extension +- The current directory contains a file with the `.nims` extension +- The current directory contains a file with the `.nimble` extension ### Options | Option | Défaut | Description | | ------------------- | ------------------------------------ | ------------------------------------------------------------------------------------------ | -| `format` | `"via [$symbol($version )]($style)"` | Format du module | +| `format` | `"via [$symbol($version )]($style)"` | The format for the module | | `version_format` | `"v${raw}"` | Le format de la version. Les variables disponibles sont `raw`, `major`, `minor`, & `patch` | -| `symbol` | `"👑 "` | Le symbole utilisé avant d'afficher la version de Nim. | +| `symbol` | `"👑 "` | The symbol used before displaying the version of Nim. | | `detect_extensions` | `["nim", "nims", "nimble"]` | Quelles extensions devraient activer ce module. | | `detect_files` | `["nim.cfg"]` | Quels fichiers devraient activer ce module. | | `detect_folders` | `[]` | Quels dossiers devraient activer ce module. | | `style` | `"bold yellow"` | Le style du module. | -| `disabled` | `false` | Désactive le module `nim`. | +| `disabled` | `false` | Disables the `nim` module. | ### Variables | Variable | Exemple | Description | | --------- | -------- | -------------------------------------- | -| version | `v1.2.0` | La version de `nim` | +| version | `v1.2.0` | The version of `nimc` | | symbol | | Reflète la valeur de l'option `symbol` | | style\* | | Reflète la valeur de l'option `style` | -\* : Cette variable ne peut être utilisée que comme partie d'une chaîne de style +\*: This variable can only be used as a part of a style string ### Exemple @@ -1878,14 +1950,14 @@ The `nix_shell` module shows the [nix-shell](https://nixos.org/guides/nix-pills/ ### Options -| Option | Défaut | Description | -| ------------ | ---------------------------------------------- | ---------------------------------------------------------- | -| `format` | `'via [$symbol$state( \($name\))]($style) '` | Format du module. | -| `symbol` | `"❄️ "` | Une chaîne de format représentant le symbole de nix-shell. | -| `style` | `"bold blue"` | Le style du module. | -| `impure_msg` | `"impure"` | Une chaîne de format affichée lorsque le shell est impur. | -| `pure_msg` | `"pure"` | Une chaîne de format affichée lorsque le shell est pur. | -| `disabled` | `false` | Désactive le module `nix_shell`. | +| Option | Défaut | Description | +| ------------ | ---------------------------------------------- | ----------------------------------------------------- | +| `format` | `'via [$symbol$state( \($name\))]($style) '` | Format du module. | +| `symbol` | `"❄️ "` | A format string representing the symbol of nix-shell. | +| `style` | `"bold blue"` | Le style du module. | +| `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` | Disables the `nix_shell` module. | ### Variables @@ -1896,7 +1968,7 @@ The `nix_shell` module shows the [nix-shell](https://nixos.org/guides/nix-pills/ | symbol | | Reflète la valeur de l'option `symbol` | | style\* | | Reflète la valeur de l'option `style` | -\* : Cette variable ne peut être utilisée que comme partie d'une chaîne de style +\*: This variable can only be used as a part of a style string ### Exemple @@ -1912,14 +1984,14 @@ format = 'via [☃️ $state( \($name\))](bold blue) ' ## Node.js -Le module `nodejs` affiche la version actuellement installée de [Node.js](https://nodejs.org/). Par défaut le module sera activé si au moins l'une des conditions suivantes est remplie: +The `nodejs` module shows the currently installed version of [Node.js](https://nodejs.org/). Par défaut le module sera activé si au moins l'une des conditions suivantes est remplie: -- Le répertoire courant contient un fichier `package.json` -- Le répertoire courant contient un fichier `.node-version` -- Le répertoire courant contient un fichier `.nvmrc` -- Le répertoire courant contient un répertoire `node_modules` -- Le répertoire actuel contient un fichier avec l'extension `.js`, `.mjs` ou `.cjs` -- Le répertoire actuel contient un fichier avec l'extension `.ts` +- The current directory contains a `package.json` file +- The current directory contains a `.node-version` file +- The current directory contains a `.nvmrc` file +- The current directory contains a `node_modules` directory +- The current directory contains a file with the `.js`, `.mjs` or `.cjs` extension +- The current directory contains a file with the `.ts` extension ### Options @@ -1927,23 +1999,23 @@ Le module `nodejs` affiche la version actuellement installée de [Node.js](https | ------------------- | ------------------------------------ | ----------------------------------------------------------------------------------------------------- | | `format` | `"via [$symbol($version )]($style)"` | Format du module. | | `version_format` | `"v${raw}"` | Le format de la version. Les variables disponibles sont `raw`, `major`, `minor`, & `patch` | -| `symbol` | `" "` | Une chaîne de caractères représentant le symbole de Node.js. | +| `symbol` | `" "` | A format string representing the symbol of Node.js. | | `detect_extensions` | `["js", "mjs", "cjs", "ts"]` | Quelles extensions devraient activer ce module. | | `detect_files` | `["package.json", ".node-version"]` | Quels fichiers devraient activer ce module. | | `detect_folders` | `["node_modules"]` | Quels dossiers devraient activer ce module. | | `style` | `"bold green"` | Le style du module. | -| `disabled` | `false` | Désactive le module `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 | Variable | Exemple | Description | | --------- | ---------- | -------------------------------------- | -| version | `v13.12.0` | La version de `node` | +| version | `v13.12.0` | The version of `node` | | symbol | | Reflète la valeur de l'option `symbol` | | style\* | | Reflète la valeur de l'option `style` | -\* : Cette variable ne peut être utilisée que comme partie d'une chaîne de style +\*: This variable can only be used as a part of a style string ### Exemple @@ -1956,41 +2028,41 @@ format = "via [🤖 $version](bold green) " ## OCaml -Le module `ocaml` affiche la version actuellement installée de [OCaml](https://ocaml.org/). Par défaut le module sera activé si au moins l'une des conditions suivantes est remplie: +The `ocaml` module shows the currently installed version of [OCaml](https://ocaml.org/). Par défaut le module sera activé si au moins l'une des conditions suivantes est remplie: -- Le répertoire courant contient un fichier avec l'extension `.opam` ou le répertoire `_opam` -- Le répertoire courant contient un répertoire `esy.lock` -- Le répertoire courant contient un fichier `dune` ou `dune-project` -- Le répertoire courant contient un fichier `jbuild` ou `jbuild-ignore` -- Le répertoire courant contient un fichier `.merlin` -- Le répertoire actuel contient un fichier avec l'extension `.ml`, `.mli`, `.re` ou `.rei` +- The current directory contains a file with `.opam` extension or `_opam` directory +- The current directory contains a `esy.lock` directory +- The current directory contains a `dune` or `dune-project` file +- The current directory contains a `jbuild` or `jbuild-ignore` file +- The current directory contains a `.merlin` file +- The current directory contains a file with `.ml`, `.mli`, `.re` or `.rei` extension ### Options | Option | Défaut | Description | | ------------------------- | -------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------ | -| `format` | `"via [$symbol($version )(\($switch_indicator$switch_name\) )]($style)"` | La chaîne de format pour le module. | +| `format` | `"via [$symbol($version )(\($switch_indicator$switch_name\) )]($style)"` | The format string for the module. | | `version_format` | `"v${raw}"` | Le format de la version. Les variables disponibles sont `raw`, `major`, `minor`, & `patch` | -| `symbol` | `"🐫 "` | Le symbole utilisé avant d'afficher la version de OCaml. | -| `global_switch_indicator` | `""` | La chaîne de caractères utilisée pour représenter le commutateur OPAM global. | -| `local_switch_indicator` | `"*"` | La chaîne de caractères utilisée pour représenter le commutateur OPAM local. | +| `symbol` | `"🐫 "` | The symbol used before displaying the version of OCaml. | +| `global_switch_indicator` | `""` | The format string used to represent global OPAM switch. | +| `local_switch_indicator` | `"*"` | The format string used to represent local OPAM switch. | | `detect_extensions` | `["opam", "ml", "mli", "re", "rei"]` | Quelles extensions devraient activer ce module. | | `detect_files` | `["dune", "dune-project", "jbuild", "jbuild-ignore", ".merlin"]` | Quels fichiers devraient activer ce module. | | `detect_folders` | `["_opam", "esy.lock"]` | Quels dossiers devraient activer ce module. | | `style` | `"bold yellow"` | Le style du module. | -| `disabled` | `false` | Désactive le module `ocaml`. | +| `disabled` | `false` | Disables the `ocaml` module. | ### Variables | Variable | Exemple | Description | | ---------------- | ------------ | ----------------------------------------------------------------- | -| version | `v4.10.0` | La version de `ocaml` | +| version | `v4.10.0` | The version of `ocaml` | | switch_name | `my-project` | The active OPAM switch | | switch_indicator | | Mirrors the value of `indicator` for currently active OPAM switch | | symbol | | Reflète la valeur de l'option `symbol` | | style\* | | Reflète la valeur de l'option `style` | -\* : Cette variable ne peut être utilisée que comme partie d'une chaîne de style +\*: This variable can only be used as a part of a style string ### Exemple @@ -2010,9 +2082,9 @@ The `openstack` module shows the current OpenStack cloud and project. The module | Option | Défaut | Description | | ---------- | --------------------------------------------------- | -------------------------------------------------------------- | | `format` | `"on [$symbol$cloud(\\($project\\))]($style) "` | Format du module. | -| `symbol` | `"☁️ "` | Le symbole utilisé avant d'afficher le cloud OpenStack actuel. | +| `symbol` | `"☁️ "` | The symbol used before displaying the current OpenStack cloud. | | `style` | `"bold yellow"` | Le style du module. | -| `disabled` | `false` | Désactive le module `openstack`. | +| `disabled` | `false` | Disables the `openstack` module. | ### Variables @@ -2023,7 +2095,7 @@ The `openstack` module shows the current OpenStack cloud and project. The module | symbol | | Reflète la valeur de l'option `symbol` | | style\* | | Reflète la valeur de l'option `style` | -\* : Cette variable ne peut être utilisée que comme partie d'une chaîne de style +\*: This variable can only be used as a part of a style string ### Exemple @@ -2036,23 +2108,23 @@ style = "bold yellow" symbol = "☁️ " ``` -## Version du package +## Package Version 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`, `composer`, `gradle`, `julia`, `mix` and `helm` 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 -- [**nimble**](https://github.com/nim-lang/nimble) - The `nimble` package version is extracted from the `*.nimble` file present in the current directory with the `nimble dump` command -- [**poetry**](https://python-poetry.org/) – The `poetry` package version is extracted from the `pyproject.toml` present in the current directory -- [**python**](https://www.python.org) - The `python` package version is extracted from the `setup.cfg` present in the current directory -- [**composer**](https://getcomposer.org/) – The `composer` package version is extracted from the `composer.json` present in the current directory -- [**gradle**](https://gradle.org/) – The `gradle` package version is extracted from the `build.gradle` present -- [**julia**](https://docs.julialang.org/en/v1/stdlib/Pkg/) - The package version is extracted from the `Project.toml` present -- [**mix**](https://hexdocs.pm/mix/) - The `mix` package version is extracted from the `mix.exs` present -- [**helm**](https://helm.sh/docs/helm/helm_package/) - The `helm` chart version is extracted from the `Chart.yaml` present -- [**maven**](https://maven.apache.org/) - The `maven` package version is extracted from the `pom.xml` present -- [**meson**](https://mesonbuild.com/) - The `meson` package version is extracted from the `meson.build` present -- [**vlang**](https://vlang.io) - The `vlang` package version is extracted from the `v.mod` present +- [**Cargo**](https://doc.rust-lang.org/cargo/) – The `cargo` package version is extracted from the `Cargo.toml` present in the current directory +- [**Nimble**](https://github.com/nim-lang/nimble) - The `nimble` package version is extracted from the `*.nimble` file present in the current directory with the `nimble dump` command +- [**Poetry**](https://python-poetry.org/) – The `poetry` package version is extracted from the `pyproject.toml` present in the current directory +- [**Python**](https://www.python.org) - The `python` package version is extracted from the `setup.cfg` present in the current directory +- [**Composer**](https://getcomposer.org/) – The `composer` package version is extracted from the `composer.json` present in the current directory +- [**Gradle**](https://gradle.org/) – The `gradle` package version is extracted from the `build.gradle` present +- [**Julia**](https://docs.julialang.org/en/v1/stdlib/Pkg/) - The package version is extracted from the `Project.toml` present +- [**Mix**](https://hexdocs.pm/mix/) - The `mix` package version is extracted from the `mix.exs` present +- [**Helm**](https://helm.sh/docs/helm/helm_package/) - The `helm` chart version is extracted from the `Chart.yaml` present +- [**Maven**](https://maven.apache.org/) - The `maven` package version is extracted from the `pom.xml` present +- [**Meson**](https://mesonbuild.com/) - The `meson` package version is extracted from the `meson.build` present +- [**V**](https://vlang.io) - The `vlang` package version is extracted from the `v.mod` present > ⚠️ The version being shown is that of the package whose source code is in your current directory, not your package manager. @@ -2061,21 +2133,21 @@ The `package` module is shown when the current directory is the repository for a | Option | Défaut | Description | | ----------------- | --------------------------------- | ------------------------------------------------------------------------------------------ | | `format` | `"is [$symbol$version]($style) "` | Format du module. | -| `symbol` | `"📦 "` | Le symbole utilisé avant d'afficher la version du paquet. | +| `symbol` | `"📦 "` | The symbol used before displaying the version the package. | | `version_format` | `"v${raw}"` | Le format de la version. Les variables disponibles sont `raw`, `major`, `minor`, & `patch` | | `style` | `"bold 208"` | Le style du module. | | `display_private` | `false` | Enable displaying version for packages marked as private. | -| `disabled` | `false` | Désactive le module `package`. | +| `disabled` | `false` | Disables the `package` module. | ### Variables | Variable | Exemple | Description | | --------- | -------- | -------------------------------------- | -| version | `v1.0.0` | La version de votre package | +| version | `v1.0.0` | The version of your package | | symbol | | Reflète la valeur de l'option `symbol` | | style\* | | Reflète la valeur de l'option `style` | -\* : Cette variable ne peut être utilisée que comme partie d'une chaîne de style +\*: This variable can only be used as a part of a style string ### Exemple @@ -2088,32 +2160,32 @@ format = "via [🎁 $version](208 bold) " ## Perl -Le module `perl` affiche la version actuellement installée de [Perl](https://www.perl.org/). Par défaut le module sera activé si au moins l'une des conditions suivantes est remplie: +The `perl` module shows the currently installed version of [Perl](https://www.perl.org/). Par défaut le module sera activé si au moins l'une des conditions suivantes est remplie: -- Le répertoire courant contient un fichier `Makefile.PL` ou `Build.PL` -- Le répertoire courant contient un fichier `cpanfile` ou `cpanfile.snapshot` -- Le répertoire courant contient un fichier `META.json` ou `META.yml` -- Le répertoire courant contient un fichier `.perl-version` -- Le répertoire courant contient un fichier `.pl`, `.pm` ou `.pod` +- The current directory contains a `Makefile.PL` or `Build.PL` file +- The current directory contains a `cpanfile` or `cpanfile.snapshot` file +- The current directory contains a `META.json` file or `META.yml` file +- The current directory contains a `.perl-version` file +- The current directory contains a `.pl`, `.pm` or `.pod` ### Options | Option | Défaut | Description | | ------------------- | -------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------ | -| `format` | `"via [$symbol($version )]($style)"` | La chaîne de format pour le module. | +| `format` | `"via [$symbol($version )]($style)"` | The format string for the module. | | `version_format` | `"v${raw}"` | Le format de la version. Les variables disponibles sont `raw`, `major`, `minor`, & `patch` | -| `symbol` | `"🐪 "` | Le symbole utilisé avant d'afficher la version de Perl | +| `symbol` | `"🐪 "` | The symbol used before displaying the version of Perl | | `detect_extensions` | `["pl", "pm", "pod"]` | Quelles extensions devraient activer ce module. | | `detect_files` | `["Makefile.PL", "Build.PL", "cpanfile", "cpanfile.snapshot", "META.json", "META.yml", ".perl-version"]` | Quels fichiers devraient activer ce module. | | `detect_folders` | `[]` | Quels dossiers devraient activer ce module. | | `style` | `"bold 149"` | Le style du module. | -| `disabled` | `false` | Désactive le module `perl`. | +| `disabled` | `false` | Disables the `perl` module. | ### Variables | Variable | Exemple | Description | | --------- | --------- | -------------------------------------- | -| version | `v5.26.1` | La version de `perl` | +| version | `v5.26.1` | The version of `perl` | | symbol | | Reflète la valeur de l'option `symbol` | | style\* | | Reflète la valeur de l'option `style` | @@ -2128,11 +2200,11 @@ format = "via [🦪 $version]($style) " ## PHP -Le module `php` affiche la version actuellement installée de [PHP](https://www.php.net/). Par défaut le module sera activé si au moins l'une des conditions suivantes est remplie: +The `php` module shows the currently installed version of [PHP](https://www.php.net/). Par défaut le module sera activé si au moins l'une des conditions suivantes est remplie: -- Le répertoire courant contient un fichier `composer.json` -- Le répertoire courant contient un fichier `.php-version` -- Le répertoire courant contient un fichier avec l'extension `.php` +- The current directory contains a `composer.json` file +- The current directory contains a `.php-version` file +- The current directory contains a `.php` extension ### Options @@ -2140,22 +2212,22 @@ Le module `php` affiche la version actuellement installée de [PHP](https://www. | ------------------- | ------------------------------------ | ------------------------------------------------------------------------------------------ | | `format` | `"via [$symbol($version )]($style)"` | Format du module. | | `version_format` | `"v${raw}"` | Le format de la version. Les variables disponibles sont `raw`, `major`, `minor`, & `patch` | -| `symbol` | `"🐘 "` | Le symbole utilisé avant d'afficher la version de PHP. | +| `symbol` | `"🐘 "` | The symbol used before displaying the version of PHP. | | `detect_extensions` | `["php"]` | Quelles extensions devraient activer ce module. | | `detect_files` | `["composer.json", ".php-version"]` | Quels fichiers devraient activer ce module. | | `detect_folders` | `[]` | Quels dossiers devraient activer ce module. | | `style` | `"147 bold"` | Le style du module. | -| `disabled` | `false` | Désactive le module `php`. | +| `disabled` | `false` | Disables the `php` module. | ### Variables | Variable | Exemple | Description | | --------- | -------- | -------------------------------------- | -| version | `v7.3.8` | La version de `php` | +| version | `v7.3.8` | The version of `php` | | symbol | | Reflète la valeur de l'option `symbol` | | style\* | | Reflète la valeur de l'option `style` | -\* : Cette variable ne peut être utilisée que comme partie d'une chaîne de style +\*: This variable can only be used as a part of a style string ### Exemple @@ -2168,10 +2240,10 @@ format = "via [🔹 $version](147 bold) " ## PureScript -Le module `purescript` affiche la version actuellement installée de [PureScript](https://www.purescript.org/). Par défaut le module sera activé si au moins l'une des conditions suivantes est remplie: +The `purescript` module shows the currently installed version of [PureScript](https://www.purescript.org/) version. Par défaut le module sera activé si au moins l'une des conditions suivantes est remplie: -- Le répertoire courant contient un fichier `spago.dhall` -- Le répertoire actuel contient un fichier avec l'extension `.purs` +- The current directory contains a `spago.dhall` file +- The current directory contains a file with the `.purs` extension ### Options @@ -2179,22 +2251,22 @@ Le module `purescript` affiche la version actuellement installée de [PureScript | ------------------- | ------------------------------------ | ------------------------------------------------------------------------------------------ | | `format` | `"via [$symbol($version )]($style)"` | Format du module. | | `version_format` | `"v${raw}"` | Le format de la version. Les variables disponibles sont `raw`, `major`, `minor`, & `patch` | -| `symbol` | `"<=> "` | Le symbole utilisé avant d'afficher la version de PureScript. | +| `symbol` | `"<=> "` | The symbol used before displaying the version of PureScript. | | `detect_extensions` | `["purs"]` | Quelles extensions devraient activer ce module. | | `detect_files` | `["spago.dhall"]` | Quels fichiers devraient activer ce module. | | `detect_folders` | `[]` | Quels dossiers devraient activer ce module. | | `style` | `"bold white"` | Le style du module. | -| `disabled` | `false` | Désactive le module `purescript`. | +| `disabled` | `false` | Disables the `purescript` module. | ### Variables | Variable | Exemple | Description | | --------- | -------- | -------------------------------------- | -| version | `0.13.5` | La version de `purescript` | +| version | `0.13.5` | The version of `purescript` | | symbol | | Reflète la valeur de l'option `symbol` | | style\* | | Reflète la valeur de l'option `style` | -\* : Cette variable ne peut être utilisée que comme partie d'une chaîne de style +\*: This variable can only be used as a part of a style string ### Exemple @@ -2207,21 +2279,21 @@ format = "via [$symbol$version](bold white)" ## Python -Le module `python` affiche la version actuellement installée de [Python](https://www.python.org/) ainsi que la version d'[environnement virtuel Python](https://docs.python.org/tutorial/venv.html) si il y en a un d'activé. +The `python` module shows the currently installed version of [Python](https://www.python.org/) and the current [Python virtual environment](https://docs.python.org/tutorial/venv.html) if one is activated. If `pyenv_version_name` is set to `true`, it will display the pyenv version name. Otherwise, it will display the version number from `python --version`. Par défaut le module sera activé si au moins l'une des conditions suivantes est remplie: -- Le répertoire courant contient un fichier `.python-version` -- Le répertoire courant contient un fichier `Pipfile` -- Le répertoire courant contient un fichier `__init__.py` -- Le répertoire courant contient un fichier `pyproject.toml` -- Le répertoire courant contient un fichier `requirements.txt` -- Le répertoire courant contient un fichier `setup.py` -- Le répertoire courant contient un fichier `tox.ini` -- Le répertoire actuel contient un fichier avec l'extension `.py`. -- Un environnement virtuel est actuellement activé +- The current directory contains a `.python-version` file +- The current directory contains a `Pipfile` file +- The current directory contains a `__init__.py` file +- The current directory contains a `pyproject.toml` file +- The current directory contains a `requirements.txt` file +- The current directory contains a `setup.py` file +- The current directory contains a `tox.ini` file +- The current directory contains a file with the `.py` extension. +- A virtual environment is currently activated ### Options @@ -2229,7 +2301,7 @@ Par défaut le module sera activé si au moins l'une des conditions suivantes es | -------------------- | ------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------ | | `format` | `'via [${symbol}${pyenv_prefix}(${version} )(\($virtualenv\) )]($style)'` | Format du module. | | `version_format` | `"v${raw}"` | Le format de la version. Les variables disponibles sont `raw`, `major`, `minor`, & `patch` | -| `symbol` | `"🐍 "` | Une chaîne de caractères représentant le symbole de Python | +| `symbol` | `"🐍 "` | A format string representing the symbol of Python | | `style` | `"yellow bold"` | Le style du module. | | `pyenv_version_name` | `false` | Use pyenv to get Python version | | `pyenv_prefix` | `pyenv` | Prefix before pyenv version display, only used if pyenv is used | @@ -2237,7 +2309,7 @@ Par défaut le module sera activé si au moins l'une des conditions suivantes es | `detect_extensions` | `["py"]` | Quelles extensions devraient activer ce module | | `detect_files` | `[".python-version", "Pipfile", "__init__.py", "pyproject.toml", "requirements.txt", "setup.py", "tox.ini"]` | Quels fichiers devraient activer ce module | | `detect_folders` | `[]` | Quels dossiers devraient activer ce module | -| `disabled` | `false` | Désactive le module `python`. | +| `disabled` | `false` | Disables the `python` module. | ::: tip @@ -2251,7 +2323,7 @@ The default values and order for `python_binary` was chosen to first identify th | Variable | Exemple | Description | | ------------ | --------------- | ------------------------------------------ | -| version | `"v3.8.1"` | La version de `python` | +| version | `"v3.8.1"` | The version of `python` | | symbol | `"🐍 "` | Reflète la valeur de l'option `symbol` | | style | `"yellow bold"` | Reflète la valeur de l'option `style` | | pyenv_prefix | `"pyenv "` | Mirrors the value of option `pyenv_prefix` | @@ -2271,7 +2343,7 @@ pyenv_version_name = true # ~/.config/starship.toml [python] -# N'utilisez que le binaire `python3` pour obtenir la version. +# Only use the `python3` binary to get the version. python_binary = "python3" ``` @@ -2279,7 +2351,7 @@ python_binary = "python3" # ~/.config/starship.toml [python] -# Ne pas déclencher pour les fichiers avec l'extension py +# Don't trigger for files with the py extension detect_extensions = [] ``` @@ -2287,25 +2359,24 @@ detect_extensions = [] # ~/.config/starship.toml [python] -# Affiche la version de python depuis l'intérieur d'un venv local. +# Display the version of python from inside a local venv. # -# Notez que cela ne fonctionnera que lorsque le venv est à l'intérieur du projet, -# et uniquement lorsque vous vous situez dans le répertoire contenant le dossier du venv -# mais peut-être que c'est suffisant? +# Note this will only work when the venv is inside the project and it will only +# work in the directory that contains the venv dir but maybe this is ok? python_binary = ["./venv/bin/python", "python", "python3", "python2"] ``` ## R -The `rlang` module shows the currently installed version of R. The module will be shown if any of the following conditions are met: +The `rlang` module shows the currently installed version of [R](https://www.r-project.org/). The module will be shown if any of the following conditions are met: -- Le répertoire actuel contient un fichier avec l'extension `.R`. -- Le répertoire actuel contient un fichier avec l'extension `.Rd`. -- Le répertoire actuel contient un fichier avec l'extension `.Rmd`. -- Le répertoire actuel contient un fichier avec l'extension `.Rproj`. -- Le répertoire actuel contient un fichier avec l'extension `.Rsx`. -- Le répertoire courant contient un fichier `.Rprofile` -- Le répertoire courant contient un dossier `.Rproj.user` +- The current directory contains a file with the `.R` extension. +- The current directory contains a file with the `.Rd` extension. +- The current directory contains a file with the `.Rmd` extension. +- The current directory contains a file with the `.Rproj` extension. +- The current directory contains a file with the `.Rsx` extension. +- The current directory contains a `.Rprofile` file +- The current directory contains a `.Rproj.user` folder ### Options @@ -2313,18 +2384,18 @@ The `rlang` module shows the currently installed version of R. The module will b | ------------------- | ------------------------------------ | ------------------------------------------------------------------------------------------ | | `format` | `"via [$symbol($version )]($style)"` | Format du module. | | `version_format` | `"v${raw}"` | Le format de la version. Les variables disponibles sont `raw`, `major`, `minor`, & `patch` | -| `symbol` | `"📐"` | Une chaîne de caractères représentant le symbole de R. | +| `symbol` | `"📐"` | A format string representing the symbol of R. | | `style` | `"blue bold"` | Le style du module. | | `detect_extensions` | `["R", "Rd", "Rmd", "Rproj", "Rsx"]` | Quelles extensions devraient activer ce module | | `detect_files` | `[".Rprofile"]` | Quels fichiers devraient activer ce module | | `detect_folders` | `[".Rproj.user"]` | Quels dossiers devraient activer ce module | -| `disabled` | `false` | Désactive le module `r`. | +| `disabled` | `false` | Disables the `r` module. | ### Variables | Variable | Exemple | Description | | -------- | ------------- | -------------------------------------- | -| version | `v4.0.5` | La version de `R` | +| version | `v4.0.5` | The version of `R` | | symbol | | Reflète la valeur de l'option `symbol` | | style | `"blue bold"` | Reflète la valeur de l'option `style` | @@ -2339,9 +2410,9 @@ format = "with [📐 $version](blue bold) " ## Red -Par défaut, le module `red` affiche la version actuellement installée de [Red](https://www.red-lang.org/). Le module est affiché si l'une de ces conditions est remplie : +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: -- Le répertoire actuel contient un fichier avec l'extension `.red` ou `.reds` +- The current directory contains a file with `.red` or `.reds` extension ### Options @@ -2349,22 +2420,22 @@ Par défaut, le module `red` affiche la version actuellement installée de [Red] | ------------------- | ------------------------------------ | ------------------------------------------------------------------------------------------ | | `format` | `"via [$symbol($version )]($style)"` | Format du module. | | `version_format` | `"v${raw}"` | Le format de la version. Les variables disponibles sont `raw`, `major`, `minor`, & `patch` | -| `symbol` | `"🔺 "` | Une chaîne de caractères représentant le symbole de Red. | +| `symbol` | `"🔺 "` | A format string representing the symbol of Red. | | `detect_extensions` | `["red"]` | Quelles extensions devraient activer ce module. | | `detect_files` | `[]` | Quels fichiers devraient activer ce module. | | `detect_folders` | `[]` | Quels dossiers devraient activer ce module. | | `style` | `"red bold"` | Le style du module. | -| `disabled` | `false` | Désactive le module `red`. | +| `disabled` | `false` | Disables the `red` module. | ### Variables | Variable | Exemple | Description | | --------- | -------- | -------------------------------------- | -| version | `v2.5.1` | La version de `red` | +| version | `v2.5.1` | The version of `red` | | symbol | | Reflète la valeur de l'option `symbol` | | style\* | | Reflète la valeur de l'option `style` | -\* : Cette variable ne peut être utilisée que comme partie d'une chaîne de style +\*: This variable can only be used as a part of a style string ### Exemple @@ -2377,11 +2448,11 @@ symbol = "🔴 " ## Ruby -Par défaut, le module `ruby` affiche la version actuellement installée de [Ruby](https://www.ruby-lang.org/). Le module est affiché si l'une de ces conditions est remplie : +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: -- Le répertoire courant contient un fichier `Gemfile` -- Le répertoire courant contient un fichier `.ruby-version` -- Le répertoire courant contient un fichier `.rb` +- The current directory contains a `Gemfile` file +- The current directory contains a `.ruby-version` file +- The current directory contains a `.rb` file ### Options @@ -2389,22 +2460,22 @@ Par défaut, le module `ruby` affiche la version actuellement installée de [Rub | ------------------- | ------------------------------------ | ------------------------------------------------------------------------------------------ | | `format` | `"via [$symbol($version )]($style)"` | Format du module. | | `version_format` | `"v${raw}"` | Le format de la version. Les variables disponibles sont `raw`, `major`, `minor`, & `patch` | -| `symbol` | `"💎 "` | Une chaîne de caractères représentant le symbole de Ruby. | +| `symbol` | `"💎 "` | A format string representing the symbol of Ruby. | | `detect_extensions` | `["rb"]` | Quelles extensions devraient activer ce module. | | `detect_files` | `["Gemfile", ".ruby-version"]` | Quels fichiers devraient activer ce module. | | `detect_folders` | `[]` | Quels dossiers devraient activer ce module. | | `style` | `"bold green"` | Le style du module. | -| `disabled` | `false` | Désactive le module `ruby`. | +| `disabled` | `false` | Disables the `ruby` module. | ### Variables | Variable | Exemple | Description | | --------- | -------- | -------------------------------------- | -| version | `v2.5.1` | La version de `ruby` | +| version | `v2.5.1` | The version of `ruby` | | symbol | | Reflète la valeur de l'option `symbol` | | style\* | | Reflète la valeur de l'option `style` | -\* : Cette variable ne peut être utilisée que comme partie d'une chaîne de style +\*: This variable can only be used as a part of a style string ### Exemple @@ -2417,10 +2488,10 @@ symbol = "🔺 " ## Rust -Par défaut, le module `rust` affiche la version actuellement installée de [Rust](https://www.rust-lang.org/). Le module est affiché si l'une de ces conditions est remplie : +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: -- Le répertoire courant contient un fichier `Cargo.toml` -- Le répertoire actuel contient un fichier avec l'extension `.rs` +- The current directory contains a `Cargo.toml` file +- The current directory contains a file with the `.rs` extension ### Options @@ -2428,22 +2499,22 @@ Par défaut, le module `rust` affiche la version actuellement installée de [Rus | ------------------- | ------------------------------------ | ------------------------------------------------------------------------------------------ | | `format` | `"via [$symbol($version )]($style)"` | Format du module. | | `version_format` | `"v${raw}"` | Le format de la version. Les variables disponibles sont `raw`, `major`, `minor`, & `patch` | -| `symbol` | `"🦀 "` | Une chaîne de caractères représentant le symbole de Rust | +| `symbol` | `"🦀 "` | A format string representing the symbol of Rust | | `detect_extensions` | `["rs"]` | Quelles extensions devraient activer ce module. | | `detect_files` | `["Cargo.toml"]` | Quels fichiers devraient activer ce module. | | `detect_folders` | `[]` | Quels dossiers devraient activer ce module. | | `style` | `"bold green"` | Le style du module. | -| `disabled` | `false` | Désactive le module `rust`. | +| `disabled` | `false` | Disables the `rust` module. | ### Variables | Variable | Exemple | Description | | --------- | ----------------- | -------------------------------------- | -| version | `v1.43.0-nightly` | La version de `rustc` | +| version | `v1.43.0-nightly` | The version of `rustc` | | symbol | | Reflète la valeur de l'option `symbol` | | style\* | | Reflète la valeur de l'option `style` | -\* : Cette variable ne peut être utilisée que comme partie d'une chaîne de style +\*: This variable can only be used as a part of a style string ### Exemple @@ -2456,11 +2527,11 @@ format = "via [⚙️ $version](red bold)" ## Scala -Le module `scala` affiche la version actuellement installée de [Scala](https://www.scala-lang.org/). Par défaut le module sera activé si au moins l'une des conditions suivantes est remplie: +The `scala` module shows the currently installed version of [Scala](https://www.scala-lang.org/). Par défaut le module sera activé si au moins l'une des conditions suivantes est remplie: -- Le répertoire courant contient un fichier `build.sbt`, `.scalaenv` ou `.sbtenv` -- Le répertoire actuel contient un fichier avec l'extension `.scala` ou `.sbt` -- Le répertoire courant contient un répertoire nommé `.metals` +- The current directory contains a `build.sbt`, `.scalaenv` or `.sbtenv` file +- The current directory contains a file with the `.scala` or `.sbt` extension +- The current directory contains a directory named `.metals` ### Options @@ -2471,19 +2542,19 @@ Le module `scala` affiche la version actuellement installée de [Scala](https:// | `detect_extensions` | `["sbt", "scala"]` | Quelles extensions devraient activer ce module. | | `detect_files` | `[".scalaenv", ".sbtenv", "build.sbt"]` | Quels fichiers devraient activer ce module. | | `detect_folders` | `[".metals"]` | Quels dossiers devraient activer ce module. | -| `symbol` | `"🆂 "` | Une chaîne de caractères représentant le symbole de Scala. | +| `symbol` | `"🆂 "` | A format string representing the symbol of Scala. | | `style` | `"red dimmed"` | Le style du module. | -| `disabled` | `false` | Désactive le module `scala`. | +| `disabled` | `false` | Disables the `scala` module. | ### Variables | Variable | Exemple | Description | | --------- | -------- | -------------------------------------- | -| version | `2.13.5` | La version de `scala` | +| version | `2.13.5` | The version of `scala` | | symbol | | Reflète la valeur de l'option `symbol` | | style\* | | Reflète la valeur de l'option `style` | -\* : Cette variable ne peut être utilisée que comme partie d'une chaîne de style +\*: This variable can only be used as a part of a style string ### Exemple @@ -2500,7 +2571,7 @@ The `shell` module shows an indicator for currently used shell. ::: tip -Ce module est désactivé par défaut. Pour l'activer, configurez `disabled` sur `false` dans votre fichier de configuration. +This module is disabled by default. To enable it, set `disabled` to `false` in your configuration file. ::: @@ -2508,17 +2579,17 @@ Ce module est désactivé par défaut. Pour l'activer, configurez `disabled` sur | Option | Défaut | Description | | ---------------------- | ------------ | ------------------------------------------------------------ | -| `bash_indicator` | `bsh` | Une chaîne de format utilisée pour représenter bash. | -| `fish_indicator` | `fsh` | Une chaîne de format utilisée pour représenter fish. | -| `zsh_indicator` | `zsh` | Une chaîne de format utilisée pour représenter zsh. | -| `powershell_indicator` | `psh` | Une chaîne de format utilisée pour représenter powershell. | -| `ion_indicator` | `ion` | Une chaîne de format utilisée pour représenter ion. | -| `elvish_indicator` | `esh` | Une chaîne de format utilisée pour représenter elvish. | -| `tcsh_indicator` | `tsh` | Une chaîne de format utilisée pour représenter tcsh. | +| `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. | | `unknown_indicator` | | The default value to be displayed when the shell is unknown. | | `format` | `$indicator` | Format du module. | -| `disabled` | `true` | Désactive le module `shell`. | +| `disabled` | `true` | Disables the `shell` module. | ### Variables @@ -2540,7 +2611,7 @@ disabled = false ## SHLVL -The `shlvl` module shows the current `SHLVL` ("shell level") environment variable, if it is set to a number and meets or exceeds the specified threshold. +The `shlvl` module shows the current [`SHLVL`](https://tldp.org/LDP/abs/html/internalvariables.html#SHLVLREF) ("shell level") environment variable, if it is set to a number and meets or exceeds the specified threshold. ### Options @@ -2551,7 +2622,7 @@ The `shlvl` module shows the current `SHLVL` ("shell level") environment variabl | `symbol` | `"↕️ "` | The symbol used to represent the `SHLVL`. | | `repeat` | `false` | Causes `symbol` to be repeated by the current `SHLVL` amount. | | `style` | `"bold yellow"` | Le style du module. | -| `disabled` | `true` | Désactive le module `shlvl`. | +| `disabled` | `true` | Disables the `shlvl` module. | ### Variables @@ -2561,7 +2632,7 @@ The `shlvl` module shows the current `SHLVL` ("shell level") environment variabl | symbol | | Reflète la valeur de l'option `symbol` | | style\* | | Reflète la valeur de l'option `style` | -\* : Cette variable ne peut être utilisée que comme partie d'une chaîne de style +\*: This variable can only be used as a part of a style string ### Exemple @@ -2580,12 +2651,12 @@ The `singularity` module shows the current [Singularity](https://sylabs.io/singu ### Options -| Option | Défaut | Description | -| ---------- | -------------------------------- | ------------------------------------------------------ | -| `format` | `'[$symbol\[$env\]]($style) '` | Format du module. | -| `symbol` | `""` | Une chaîne de format affichée avant le nom de l'image. | -| `style` | `"bold dimmed blue"` | Le style du module. | -| `disabled` | `false` | Désactive le module `singularity`. | +| Option | Défaut | Description | +| ---------- | -------------------------------- | ------------------------------------------------ | +| `format` | `'[$symbol\[$env\]]($style) '` | Format du module. | +| `symbol` | `""` | A format string displayed before the image name. | +| `style` | `"bold dimmed blue"` | Le style du module. | +| `disabled` | `false` | Disables the `singularity` module. | ### Variables @@ -2595,7 +2666,7 @@ The `singularity` module shows the current [Singularity](https://sylabs.io/singu | symbol | | Reflète la valeur de l'option `symbol` | | style\* | | Reflète la valeur de l'option `style` | -\* : Cette variable ne peut être utilisée que comme partie d'une chaîne de style +\*: This variable can only be used as a part of a style string ### Exemple @@ -2612,7 +2683,7 @@ The `status` module displays the exit code of the previous command. The module w ::: tip -Ce module est désactivé par défaut. Pour l'activer, configurez `disabled` sur `false` dans votre fichier de configuration. +This module is disabled by default. To enable it, set `disabled` to `false` in your configuration file. ::: @@ -2635,7 +2706,7 @@ Ce module est désactivé par défaut. Pour l'activer, configurez `disabled` sur | `pipestatus` | `false` | Enable pipestatus reporting | | `pipestatus_separator` | `|` | The symbol that separate in pipe program exit codes | | `pipestatus_format` | `\\[$pipestatus\\] => [$symbol$common_meaning$signal_name$maybe_int]($style)` | The format of the module when the command is a pipeline | -| `disabled` | `true` | Désactiver le module `status`. | +| `disabled` | `true` | Disables the `status` module. | ### Variables @@ -2651,7 +2722,7 @@ Ce module est désactivé par défaut. Pour l'activer, configurez `disabled` sur | symbol | | Reflète la valeur de l'option `symbol` | | style\* | | Reflète la valeur de l'option `style` | -\* : Cette variable ne peut être utilisée que comme partie d'une chaîne de style +\*: This variable can only be used as a part of a style string ### Exemple @@ -2670,10 +2741,10 @@ disabled = false ## Swift -Par défaut, le module `swift` affiche la version actuellement installée de [Swift](https://swift.org/). Le module est affiché si l'une de ces conditions est remplie : +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: -- Le répertoire courant contient un fichier `Package.swift` -- Le répertoire actuel contient un fichier avec l'extension `.swift` +- The current directory contains a `Package.swift` file +- The current directory contains a file with the `.swift` extension ### Options @@ -2681,22 +2752,22 @@ Par défaut, le module `swift` affiche la version actuellement installée de [Sw | ------------------- | ------------------------------------ | ------------------------------------------------------------------------------------------ | | `format` | `"via [$symbol($version )]($style)"` | Format du module. | | `version_format` | `"v${raw}"` | Le format de la version. Les variables disponibles sont `raw`, `major`, `minor`, & `patch` | -| `symbol` | `"🐦 "` | Une chaîne de caractères représentant le symbole de Swift | +| `symbol` | `"🐦 "` | A format string representing the symbol of Swift | | `detect_extensions` | `["swift"]` | Quelles extensions devraient activer ce module. | | `detect_files` | `["Package.swift"]` | Quels fichiers devraient activer ce module. | | `detect_folders` | `[]` | Quels dossiers devraient activer ce module. | | `style` | `"bold 202"` | Le style du module. | -| `disabled` | `false` | Désactiver le module `swift`. | +| `disabled` | `false` | Disables the `swift` module. | ### Variables | Variable | Exemple | Description | | --------- | -------- | -------------------------------------- | -| version | `v5.2.4` | La version de `swift` | +| version | `v5.2.4` | The version of `swift` | | symbol | | Reflète la valeur de l'option `symbol` | | style\* | | Reflète la valeur de l'option `style` | -\* : Cette variable ne peut être utilisée que comme partie d'une chaîne de style +\*: This variable can only be used as a part of a style string ### Exemple @@ -2719,32 +2790,32 @@ By default the Terraform version is not shown, since this is slow for current ve Par défaut le module sera activé si au moins l'une des conditions suivantes est remplie: -- Le répertoire courant contient un dossier `.terraform` -- Le répertoire actuel contient un fichier avec l'extension `.tf` ou `.hcl` +- The current directory contains a `.terraform` folder +- Current directory contains a file with the `.tf` or `.hcl` extensions ### Options | Option | Défaut | Description | | ------------------- | ------------------------------------ | ------------------------------------------------------------------------------------------ | -| `format` | `"via [$symbol$workspace]($style) "` | La chaîne de format pour le module. | +| `format` | `"via [$symbol$workspace]($style) "` | The format string for the module. | | `version_format` | `"v${raw}"` | Le format de la version. Les variables disponibles sont `raw`, `major`, `minor`, & `patch` | -| `symbol` | `"💠"` | Une chaîne de format montrée avant l'espace de travail terraform. | +| `symbol` | `"💠"` | A format string shown before the terraform workspace. | | `detect_extensions` | `["tf", "hcl"]` | Quelles extensions devraient activer ce module. | | `detect_files` | `[]` | Quels fichiers devraient activer ce module. | | `detect_folders` | `[".terraform"]` | Quels dossiers devraient activer ce module. | | `style` | `"bold 105"` | Le style du module. | -| `disabled` | `false` | Désactive le module `terraform`. | +| `disabled` | `false` | Disables the `terraform` module. | ### Variables | Variable | Exemple | Description | | --------- | ---------- | -------------------------------------- | -| version | `v0.12.24` | La version de `terraform` | +| version | `v0.12.24` | The version of `terraform` | | workspace | `default` | The current Terraform workspace | | symbol | | Reflète la valeur de l'option `symbol` | | style\* | | Reflète la valeur de l'option `style` | -\* : Cette variable ne peut être utilisée que comme partie d'une chaîne de style +\*: This variable can only be used as a part of a style string ### Exemple @@ -2768,27 +2839,27 @@ format = "[🏎💨 $workspace]($style) " ## Date et Heure -Le module `time` affiche l'heure actuelle **localement**. La valeur de `format` est utilisée par le package [`chrono`](https://crates.io/crates/chrono) pour contrôler la façon dont l'heure est affichée. Consultez la [doc de chrono strftime](https://docs.rs/chrono/0.4.7/chrono/format/strftime/index.html) pour découvrir les options disponibles. +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 -Ce module est désactivé par défaut. Pour l'activer, configurez `disabled` sur `false` dans votre fichier de configuration. +This module is disabled by default. To enable it, set `disabled` to `false` in your configuration file. ::: ### Options -| Option | Défaut | Description | -| ----------------- | ----------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------ | -| `format` | `"at [$time]($style) "` | La chaîne de format pour le module. | -| `use_12hr` | `false` | Activer le format 12h | -| `time_format` | voir plus bas | Le [format chrono](https://docs.rs/chrono/0.4.7/chrono/format/strftime/index.html) utilisé pour formater l'heure. | -| `style` | `"bold yellow"` | Le style utilisé par le module | -| `utc_time_offset` | `"local"` | Définir le décalage horaire UTC à utiliser. Range from -24 < x < 24. Accepte des nombres décimaux pour s'adapter aux décalages de 30/45 minutes. | -| `disabled` | `true` | Désactiver le module `time`. | -| `time_range` | `"-"` | Sets the time range during which the module will be shown. Times must be specified in 24-hours format | +| Option | Défaut | Description | +| ----------------- | ----------------------- | ---------------------------------------------------------------------------------------------------------------------------------- | +| `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"`. Sinon, il est défini comme `"%T"`. Manually setting `time_format` will override the `use_12hr` setting. +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. ### Variables @@ -2797,7 +2868,7 @@ If `use_12hr` is `true`, then `time_format` defaults to `"%r"`. Sinon, il est d | time | `13:08:10` | The current time. | | style\* | | Reflète la valeur de l'option `style` | -\* : Cette variable ne peut être utilisée que comme partie d'une chaîne de style +\*: This variable can only be used as a part of a style string ### Exemple @@ -2812,14 +2883,14 @@ utc_time_offset = "-5" time_range = "10:00:00-14:00:00" ``` -## Nom d'utilisateur +## Username -Le module `username` affiche le nom d'utilisateur de l'utilisateur actif. Le module est affiché si l'une de ces conditions est remplie : +The `username` module shows active user's username. The module will be shown if any of the following conditions are met: -- L'utilisateur courant est root -- L'utilisateur courant est différent de celui connecté -- L'utilisateur est actuellement connecté à une session SSH -- La variable `show_always` a comme valeur true +- The current user is root +- The current user isn't the same as the one that is logged in +- The user is currently connected as an SSH session +- The variable `show_always` is set to true ::: tip @@ -2829,13 +2900,13 @@ SSH connection is detected by checking environment variables `SSH_CONNECTION`, ` ### Options -| Option | Défaut | Description | -| ------------- | ----------------------- | ------------------------------------------------ | -| `style_root` | `"bold green"` | Le style utilisé quand l'utilisateur est root. | -| `style_user` | `"bold yellow"` | Le style utilisé pour les utilisateurs non-root. | -| `format` | `"[$user]($style) in "` | Format du module. | -| `show_always` | `false` | Toujours afficher le module `username`. | -| `disabled` | `false` | Désactiver le module `username`. | +| Option | Défaut | Description | +| ------------- | ----------------------- | ------------------------------------- | +| `style_root` | `"bold green"` | The style used when the user is root. | +| `style_user` | `"bold yellow"` | The style used for non-root users. | +| `format` | `"[$user]($style) in "` | Format du module. | +| `show_always` | `false` | Always shows the `username` module. | +| `disabled` | `false` | Disables the `username` module. | ### Variables @@ -2859,9 +2930,9 @@ show_always = true ## Vagrant -Le module `vagrant` affiche la version actuellement installée de [Vagrant](https://www.vagrantup.com/). Par défaut le module sera activé si au moins l'une des conditions suivantes est remplie: +The `vagrant` module shows the currently installed version of [Vagrant](https://www.vagrantup.com/). Par défaut le module sera activé si au moins l'une des conditions suivantes est remplie: -- Le répertoire courant contient un fichier `Vagrantfile` +- The current directory contains a `Vagrantfile` file ### Options @@ -2869,22 +2940,22 @@ Le module `vagrant` affiche la version actuellement installée de [Vagrant](http | ------------------- | ------------------------------------ | ------------------------------------------------------------------------------------------ | | `format` | `"via [$symbol($version )]($style)"` | Format du module. | | `version_format` | `"v${raw}"` | Le format de la version. Les variables disponibles sont `raw`, `major`, `minor`, & `patch` | -| `symbol` | `"⍱ "` | Une chaîne de caractères représentant le symbole de Vagrant. | +| `symbol` | `"⍱ "` | A format string representing the symbol of Vagrant. | | `detect_extensions` | `[]` | Quelles extensions devraient activer ce module. | | `detect_files` | `["Vagrantfile"]` | Quels fichiers devraient activer ce module. | | `detect_folders` | `[]` | Quels dossiers devraient activer ce module. | | `style` | `"cyan bold"` | Le style du module. | -| `disabled` | `false` | Désactive le module `vagrant`. | +| `disabled` | `false` | Disables the `vagrant` module. | ### Variables | Variable | Exemple | Description | | --------- | ---------------- | -------------------------------------- | -| version | `Vagrant 2.2.10` | La version de `Vagrant` | +| version | `Vagrant 2.2.10` | The version of `Vagrant` | | symbol | | Reflète la valeur de l'option `symbol` | | style\* | | Reflète la valeur de l'option `style` | -\* : Cette variable ne peut être utilisée que comme partie d'une chaîne de style +\*: This variable can only be used as a part of a style string ### Exemple @@ -2895,11 +2966,11 @@ Le module `vagrant` affiche la version actuellement installée de [Vagrant](http format = "via [⍱ $version](bold white) " ``` -## VLang +## V -Le module `vlang` vous montre votre version de V actuellement installée. Par défaut, le module sera affiché si l'une des conditions suivantes est remplie : -- Le répertoire courant contient un fichier avec l'extension `.v` -- Le répertoire courant contient un fichier `v.mod`, `vpkg.json` ou `.vpkg-lock.json` +The `vlang` module shows you your currently installed version of [V](https://vlang.io/). Par défaut le module sera activé si au moins l'une des conditions suivantes est remplie: +- The current directory contains a file with `.v` extension +- The current directory contains a `v.mod`, `vpkg.json` or `.vpkg-lock.json` file ### Options @@ -2907,18 +2978,18 @@ Le module `vlang` vous montre votre version de V actuellement installée. Par d | ------------------- | -------------------------------------------- | ------------------------------------------------------------------------------------------ | | `format` | `"via [$symbol($version )]($style)"` | Format du module. | | `version_format` | `"v${raw}"` | Le format de la version. Les variables disponibles sont `raw`, `major`, `minor`, & `patch` | -| `symbol` | `"V "` | Une chaîne de caractères représentant le symbole de V | +| `symbol` | `"V "` | A format string representing the symbol of V | | `detect_extensions` | `["v"]` | Quelles extensions devraient activer ce module. | | `detect_files` | `["v.mod", "vpkg.json", ".vpkg-lock.json" ]` | Quels fichiers devraient activer ce module. | | `detect_folders` | `[]` | Quels dossiers devraient activer ce module. | | `style` | `"blue bold"` | Le style du module. | -| `disabled` | `false` | Désactive le module `vlang`. | +| `disabled` | `false` | Disables the `vlang` module. | ### Variables | Variable | Exemple | Description | | --------- | ------- | -------------------------------------- | -| version | `v0.2` | La version de `v` | +| version | `v0.2` | The version of `v` | | symbol | | Reflète la valeur de l'option `symbol` | | style\* | | Reflète la valeur de l'option `style` | @@ -2926,7 +2997,7 @@ Le module `vlang` vous montre votre version de V actuellement installée. Par d ```toml # ~/.config/starship.toml -[v] +[vlang] format = "via [V $version](blue bold) " ``` @@ -2936,22 +3007,22 @@ The `vcsh` module displays the current active [VCSH](https://github.com/RichiH/v ### Options -| Option | Défaut | Description | -| ---------- | -------------------------------- | ---------------------------------------------------- | -| `symbol` | | Le symbole utilisé avant d'afficher le nom du dépôt. | -| `style` | `"bold yellow"` | Le style du module. | -| `format` | `"vcsh [$symbol$repo]($style) "` | Format du module. | -| `disabled` | `false` | Désactive le module `vcsh`. | +| Option | Défaut | Description | +| ---------- | -------------------------------- | ------------------------------------------------------ | +| `symbol` | | The symbol used before displaying the repository name. | +| `style` | `"bold yellow"` | Le style du module. | +| `format` | `"vcsh [$symbol$repo]($style) "` | Format du module. | +| `disabled` | `false` | Disables the `vcsh` module. | ### Variables -| Variable | Exemple | Description | -| --------- | ----------------------------------------------- | -------------------------------------- | -| repo | `dotfiles` si dans un dépôt VCSH nommé dotfiles | The active repository name | -| symbol | | Reflète la valeur de l'option `symbol` | -| style\* | `black bold dimmed` | Reflète la valeur de l'option `style` | +| Variable | Exemple | Description | +| --------- | ------------------------------------------- | -------------------------------------- | +| repo | `dotfiles` if in a VCSH repo named dotfiles | The active repository name | +| symbol | | Reflète la valeur de l'option `symbol` | +| style\* | `black bold dimmed` | Reflète la valeur de l'option `style` | -\* : Cette variable ne peut être utilisée que comme partie d'une chaîne de style +\*: This variable can only be used as a part of a style string ### Exemple @@ -2964,9 +3035,9 @@ format = "[🆅 $repo](bold blue) " ## Zig -Par défaut, le module `zig` affiche la version actuellement installée de [Zig](https://ziglang.org/). Le module est affiché si l'une de ces conditions est remplie : +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: -- Le répertoire courant contient un fichier `.zig` +- The current directory contains a `.zig` file ### Options @@ -2974,9 +3045,9 @@ Par défaut, le module `zig` affiche la version actuellement installée de [Zig] | ------------------- | ------------------------------------ | ------------------------------------------------------------------------------------------ | | `format` | `"via [$symbol($version )]($style)"` | Format du module. | | `version_format` | `"v${raw}"` | Le format de la version. Les variables disponibles sont `raw`, `major`, `minor`, & `patch` | -| `symbol` | `"↯ "` | Le symbole utilisé avant d'afficher la version de Zig. | +| `symbol` | `"↯ "` | The symbol used before displaying the version of Zig. | | `style` | `"bold yellow"` | Le style du module. | -| `disabled` | `false` | Désactive le module `zig`. | +| `disabled` | `false` | Disables the `zig` module. | | `detect_extensions` | `["zig"]` | Quelles extensions devraient activer ce module. | | `detect_files` | `[]` | Quels fichiers devraient activer ce module. | | `detect_folders` | `[]` | Quels dossiers devraient activer ce module. | @@ -2985,11 +3056,11 @@ Par défaut, le module `zig` affiche la version actuellement installée de [Zig] | Variable | Exemple | Description | | --------- | -------- | -------------------------------------- | -| version | `v0.6.0` | La version de `zig` | +| version | `v0.6.0` | The version of `zig` | | symbol | | Reflète la valeur de l'option `symbol` | | style\* | | Reflète la valeur de l'option `style` | -\* : Cette variable ne peut être utilisée que comme partie d'une chaîne de style +\*: This variable can only be used as a part of a style string ### Exemple @@ -3041,10 +3112,10 @@ The order in which custom modules are shown can be individually set by including | `files` | `[]` | The files that will be searched in the working directory for a match. | | `directories` | `[]` | The directories that will be searched in the working directory for a match. | | `extensions` | `[]` | The extensions that will be searched in the working directory for a match. | -| `symbol` | `""` | Le symbole utilisé avant d'afficher la sortie de la commande. | +| `symbol` | `""` | The symbol used before displaying the command output. | | `style` | `"bold green"` | Le style du module. | | `format` | `"[$symbol($output )]($style)"` | Format du module. | -| `disabled` | `false` | Désactive le module `custom`. | +| `disabled` | `false` | Disables this `custom` module. | | `os` | | Operating System name on which the module will be shown (unix, linux, macos, windows, ... ) [See possible values](https://doc.rust-lang.org/std/env/consts/constant.OS.html). | ### Variables @@ -3055,13 +3126,13 @@ The order in which custom modules are shown can be individually set by including | symbol | Reflète la valeur de l'option `symbol` | | style\* | Reflète la valeur de l'option `style` | -\* : Cette variable ne peut être utilisée que comme partie d'une chaîne de style +\*: This variable can only be used as a part of a style string #### Commandes shell personnalisées -`shell` accepte une liste de chaînes non vide, où: +`shell` accepts a non-empty list of strings, where: -- La première chaîne est le chemin vers le shell à utiliser pour exécuter la commande. +- The first string is the path to the shell to use to execute the command. - Other following arguments are passed to the shell. If unset, it will fallback to STARSHIP_SHELL and then to "sh" on Linux, and "cmd /C" on Windows. @@ -3092,8 +3163,8 @@ Automatic detection of shells and proper parameters addition are currently imple # ~/.config/starship.toml [custom.foo] -command = "echo foo" # affiche la sortie de la commande -files = ["foo"] # ajoute un filtre +command = "echo foo" # shows output of command +files = ["foo"] # can specify filters when = """ test "$HOME" == "$PWD" """ format = " transcending [$output]($style)" diff --git a/docs/fr-FR/guide/README.md b/docs/fr-FR/guide/README.md index fb6783b5..1b9ab93e 100644 --- a/docs/fr-FR/guide/README.md +++ b/docs/fr-FR/guide/README.md @@ -48,30 +48,6 @@ height="20" src="https://raw.githubusercontent.com/starship/starship/master/media/flag-us.png" alt="English" - /> -   - 日本語 -   - 繁體中文 -   - Русский   -   - 简体中文   Espagnol   +   + 日本語 +   + Português do Brasil +   + Русский   +   + 简体中文 +   + 繁體中文

@@ -160,8 +168,8 @@ ```sh sh -c "$(curl -fsSL https://starship.rs/install.sh)" ``` - Pour mettre à jour Starship, relancez le script ci-dessus. Cela remplacera la version actuelle sans toucher à la configuration de Starship. + Pour mettre à jour Starship, relancez le script ci-dessus. Cela remplacera la version actuelle sans toucher à la configuration de Starship. **Note** - Les valeurs par défaut du script d'installation peuvent être remplacées, voir l'aide intégrée. diff --git a/docs/fr-FR/presets/README.md b/docs/fr-FR/presets/README.md index 457e4f7d..18bd527d 100644 --- a/docs/fr-FR/presets/README.md +++ b/docs/fr-FR/presets/README.md @@ -112,6 +112,9 @@ format = '\[[$symbol($version)]($style)\]' [cmd_duration] format = '\[[⏱ $duration ]($style)\]' +[cobol] +format = '\[[$symbol($version)]($style)\]' + [conda] format = '\[[$symbol$environment]($style)\]' @@ -272,6 +275,9 @@ deleted = "x" [aws] symbol = "aws " +[cobol] +symbol = "cobol " + [conda] symbol = "conda " @@ -375,6 +381,9 @@ This preset hides the version of language runtimes. If you work in containers or [cmake] format = "via [$symbol]($style)" +[cobol] +format = "via [$symbol]($style)" + [crystal] format = "via [$symbol]($style)" diff --git a/docs/id-ID/README.md b/docs/id-ID/README.md index dbd00c05..79d6cd3a 100644 --- a/docs/id-ID/README.md +++ b/docs/id-ID/README.md @@ -3,22 +3,22 @@ home: true heroImage: /logo.svg heroText: tagline: Prompt yang minimal, super cepat, dan dapat disesuaikan tanpa batas untuk shell apa pun! -actionText: Mulai +actionText: Mari Mulai → actionLink: ./guide/ features: - - title: Kompabilitas Yang Utama + title: Mengutamakan Kompabilitas details: Dapat bekerja di shells yang paling biasa dengan sistem operasi yang paling biasa. Bisa digunakan di mana saja! - title: Dibuat Dengan Rust - details: Menggunakan kecepatan dan keamaan dari Rust, untuk membuat prompt anda bekerja secepat mungkin dan dapat diandalkan. + details: Menggunakan kecepatan dan keamanan dari Rust, untuk membuat prompt kamu bekerja secepat dan seandal mungkin. - - title: Dapat Diatur - details: Semua detail kecil yang ada dapat kamu atur sesukamu, mungkin untuk membuat prompt yang seminimal mungkin atau kaya fitur seperti yang kamu inginkan. + title: Dapat Dikustomisasi + details: Semua detail kecil yang ada dapat kamu atur sesukamu, entah untuk membuatnya sebagai prompt yang seminimal mungkin atau mungkin kaya akan fitur sesuai keinginanmu. footer: Berlisensi ISC | Hak Cipta © 2019-sekarang Kontributor Starship #Used for the description meta tag, for SEO metaTitle: "Starship: Prompt Lintas Shell" -description: Starship merupakan prompt yang minimal, super cepat, dan sangat bisa diatur untuk semua shell! Menampilkan info yang dibutuhkan, namun tetap bisa tampil ramping dan minimal. Instalasi sederhana tersedia untuk Bash, Fish, ZSH, Ion, Tcsh, Elvish, Nu, Xonsh, dan PowerShell. +description: Starship merupakan sebuah prompt yang minimal, super cepat, dan sangat bisa untuk dikustomisasi untuk shell apapun! Bisa menampilkan informasi yang kamu butuhkan, namun tetap bisa tampil dengan ramping dan minimal. Instalasi sederhana tersedia untuk Bash, Fish, ZSH, Ion, Tcsh, Elvish, Nu, Xonsh, dan PowerShell. ---
@@ -30,7 +30,7 @@ description: Starship merupakan prompt yang minimal, super cepat, dan sangat bis ### Prasyarat -- [Nerd Font](https://www.nerdfonts.com/) yang telah terinstalasi dan telah diaktifkan di terminal. +- [Nerd Font](https://www.nerdfonts.com/) yang telah terinstalasi dan telah diaktifkan di dalam terminal. ### Instalasi Sederhana @@ -44,7 +44,7 @@ description: Starship merupakan prompt yang minimal, super cepat, dan sangat bis ```sh sh -c "$(curl -fsSL https://starship.rs/install.sh)" ``` - Untuk memperbarui Starship, jalankan kembali skrip di atas. Hal ini dapat memperbarui versi yang terpasang tanpa menyentuh konfigurasi Starship. + Untuk memperbarui Starship, jalankan kembali skrip di atas. Hal ini dapat memperbarui versi yang terpasang tanpa mengubah konfigurasi Starship. #### Pasang Melalui Package Manager @@ -61,7 +61,7 @@ description: Starship merupakan prompt yang minimal, super cepat, dan sangat bis scoop install starship ``` -1. Tambahkan skrip init ke file konfigurasi Shell: +1. Tambahkan skrip init ke dalam file konfigurasi Shell: #### Bash @@ -119,7 +119,7 @@ description: Starship merupakan prompt yang minimal, super cepat, dan sangat bis #### Elvish - ::: warning Cuma elvish v0.15 atau yang lebih baru yang tengah didukung. ::: + ::: warning Hanya elvish v0.15 atau versi yang lebih baru yang mendapat dukungan pengembangan. ::: Tambahkan skrip berikut pada baris akhir `~/.elvish/rc.elv`: @@ -143,7 +143,7 @@ description: Starship merupakan prompt yang minimal, super cepat, dan sangat bis #### Nushell - ::: peringatan Hal ini dapat berubah di kemudian hari. Hanya nu versi v0.33 atau lebih baru yang tengah didukung. ::: Tambahkan skrip berikut ke dalam file konfigurasi nu. Lokasi dari file ini dapat dicek dengan menjalankan `config path` pada nu. + ::: peringatan Hal ini dapat berubah di kemudian hari. Hanya nu versi v0.33 atau versi terbaru yang mendapat dukungan pengembangan. ::: Tambahkan skrip berikut ke dalam file konfigurasi nu. Lokasi dari file ini dapat dicek dengan menjalankan `config path` pada nu. ```toml startup = [ diff --git a/docs/id-ID/advanced-config/README.md b/docs/id-ID/advanced-config/README.md index 6abf856e..08ffd880 100644 --- a/docs/id-ID/advanced-config/README.md +++ b/docs/id-ID/advanced-config/README.md @@ -8,7 +8,7 @@ Konfigurasi pada bagian ini dapat berubah saat pembaruan Starship rilis di kemud ::: -## Kostumisasi Perintah pre-prompt dan pre-execution Pada Bash +## Kustomisasi Perintah pre-prompt dan pre-execution Pada Bash Bash tidak memiliki framework preexec/precmd yang tetap seperti kebanyakan shell pada umumnya. Oleh karena itu, sulit halnya untuk membuat hook yang dapat dikustomisasi sepenuhnya di dalam `bash`. Namun, Starship memberikan beberapa cara supaya kamu bisa memasukkan fungsimu sendiri ke dalam prosedur prompt-rendering: @@ -21,7 +21,7 @@ function blastoff(){ starship_precmd_user_func="blastoff" ``` -- Untuk menjalankan fungsi buatan tepat sebelum commands berjalan, kamu bisa menggunakan [`DEBUG` trap mechanism](https://jichu4n.com/posts/debug-trap-and-prompt_command-in-bash/). Akan tetapi, kamu **harus** melakukan proses trap pada DEBUG signal *sebelum* menjalankan Starship! Starship bisa menyimpan nilai dari DEBUG trap, tapi jika trap diganti setelah starship berjalan, beberapa fungsi akan rusak. +- Untuk menjalankan fungsi yang dikustomisasi tepat sebelum commands berjalan, kamu bisa menggunakan [`DEBUG` trap mechanism](https://jichu4n.com/posts/debug-trap-and-prompt_command-in-bash/). Akan tetapi, kamu **harus** melakukan proses trap pada DEBUG signal *sebelum* menjalankan Starship! Starship bisa menyimpan nilai dari DEBUG trap, tapi jika trap diganti setelah starship berjalan, beberapa fungsi akan rusak. ```bash function blastoff(){ @@ -33,7 +33,7 @@ eval $(starship init bash) ## Mengubah Judul Window -Beberapa prompts shell dengan otomatis akan mengubah judul window-nya untukmu (mis. untuk merefleksikan direktori kerjamu). Fish bahkan mengaturnya sebagai bawaan. Starship tidak, tapi mudah saja untuk menambahkan fungsi tersebut ke dalam `bash` ataupun `zsh`. +Beberapa prompt shell dengan otomatis akan mengubah judul window-nya untukmu (mis. untuk merefleksikan direktori kerjamu). Fish bahkan mengaturnya sebagai bawaan. Starship tidak, tapi mudah saja untuk menambahkan fungsi tersebut ke dalam `bash` ataupun `zsh`. Pertama, buatlah fungsi untuk mengubah judul window (bekerja pada bash dan zsh): @@ -57,9 +57,9 @@ Dalam `zsh`, pada array `precmd_functions`, tambahkan: precmd_functions+=(set_win_title) ``` -Kalau kamu suka hasilnya, tambahkan baris (`~/.bashrc` or `~/.zshrc`) ke dalam file konfigurasi shell-mu untuk membuatnya permanen. +Kalau kamu suka hasilnya, tambahkan baris (`~/.bashrc` or `~/.zshrc`) ke dalam file konfigurasi shell milikmu untuk membuatnya permanen. -Sebagai contoh, kalau kamu mau menampilkan lokasi direktori pada judul label terminalmu, tambahkan snippet berikut ke dalam `~/.bashrc` atau `~/.zshrc`: +Sebagai contoh, kalau kamu mau menampilkan lokasi direktori pada judul label terminalmu, tambahkan bagian berikut ke dalam `~/.bashrc` atau `~/.zshrc`: ```bash function set_win_title(){ @@ -68,9 +68,36 @@ function set_win_title(){ starship_precmd_user_func="set_win_title" ``` +## Enable Right Prompt + +Some shells support a right prompt which renders on the same line as the input. Starship can set the content of the right prompt using the `right_format` option. Any module that can be used in `format` is also supported in `right_format`. The `$all` variable will only contain modules not explicitly used in either `format` or `right_format`. + +Note: The right prompt is a single line following the input location. To right align modules above the input line in a multi-line prompt, see the [fill module](/config/#fill). + +`right_format` saat ini hanya tersedia pada shell: elvish, fish, zsh. + +### Contoh + +```toml +# ~/.config/starship.toml + +# A minimal left prompt +format = """$character""" + +# move the rest of the prompt to the right +right_format = """$all""" +``` + +Menghasilkan prompt seperti berikut: + +``` +▶ starship on  rprompt [!] is 📦 v0.57.0 via 🦀 v1.54.0 took 17s +``` + + ## Menata String -Tataan pada strings merupakan sebuah kumpulan kata yang dipisahkan dengan spasi kosong. Kata-katanya tidak bersifat case sensitive (mis. `tebal` dan `TeBaL` dianggap sebagai string yang sama). Tiap-tiap kata berikut adalah opsinya: +Style strings are a list of words, separated by whitespace. Kumpulan katanya tidak bersifat case sensitive (mis. `tebal` dan `TeBaL` dianggap sebagai string yang sama). Tiap-tiap kata berikut adalah opsinya: - `bold` - `italic` diff --git a/docs/id-ID/config/README.md b/docs/id-ID/config/README.md index 3930bb64..1ece2bf5 100644 --- a/docs/id-ID/config/README.md +++ b/docs/id-ID/config/README.md @@ -16,7 +16,7 @@ add_newline = true [character] # Nama modul yang dikonfigurasi adalah "character" success_symbol = "[➜](bold green)" # Segmen "success_symbol" diganti menjadi "➜" dengan warna "bold green" -# Mengnonaktifkan paket modul, menyembunyikannya dari prompt secara utuh +# Menonaktifkan paket modul, menyembunyikannya dari prompt seutuhnya [package] disabled = true ``` @@ -51,7 +51,7 @@ $ENV:STARSHIP_CACHE = "$HOME\AppData\Local\Temp" **Modul**: Sebuah komponen pada prompt yang memberikan informasi berdasarkan info kontekstual sistem operasimu. Sebagai contoh, modul "nodejs" menampilkan versi Node.js yang tengah terpasang pada komputermu, jika direktorimu sedang berada pada proyek Node.js. -**Variabel**: Sub-komponen yang terdiri dari informasi yang disediakan oleh modul. Sebagai contoh, variabel "version" dalam modul "nodejs" memuat versi Node.js saat ini. +**Variabel**: Sub-komponen yang terdiri dari informasi yang disediakan oleh modul. Sebagai contoh, variabel "version" dalam modul "nodejs" memuat versi terikini dari Node.js. Secara konvensi, sebagian modul memiliki prefiks bawaan pada warna terminal (mis. `via` pada "nodejs") dan juga sebuah ruang kosong sebagai sufiks. @@ -75,7 +75,7 @@ Grup teks dibuat dengan dua bagian yang berbeda. Bagian pertama, yang mana diapit dalam sebuah `[]`, merupakan sebuah [format string](#format-strings). Kamu bisa menambahkan teks, variabel, atau bahkan grup teks bercabang di dalamnya. -Pada bagian kedua, yang mana diapit dalam sebuah `()`, merupakan sebuah [penataan string](#style-strings). Bagian ini dapat digunakan untuk menata bagian pertama. +Pada bagian kedua, yang mana diapit dalam sebuah `()`, merupakan sebuah [penataan string](#style-strings). This can be used to style the first part. Sebagai contoh: @@ -98,7 +98,7 @@ Perhatikan bagaimana nantinya penataanmu akan terlihat pada emulator terminalmu. #### Format String Bersyarat (Conditional) -String dengan format bersyarat dibungkus dengan `(` dan `)` tidak akan dijalankan jika variabel di dalamnya kosong. +Sebuah string dengan format bersyarat dibungkus dengan `(` dan `)` tidak akan dijalankan jika variabel di dalamnya kosong. Sebagai contoh: @@ -106,9 +106,9 @@ Sebagai contoh: - `(sembarang)` akan selalu tidak menampilkan apapun karena tidak ada variabel yang dibungkus dalam kurung kurawal. - Tatkala `$all` digunakan sebagai shortcut untuk `\[$a$b\]`, `($all)` tidak akan menampilkan apapun jika nilai `$a` dan `$b` adalah `None`. Berlaku juga dengan `(\[$a$b\] )`. -#### Karakter Yang Bisa Dihindari (Escapable) +#### Pembebasan Karakter -Simbol-simbol berikut mempunyai kegunaan yang spesial dalam format srting. Jika kamu ingin menampilkan simbol-simbol berikut, kamu harus mengikatnya (escape) dengan garis miring terbalik (`\`). +Simbol-simbol berikut mempunyai kegunaan yang spesial dalam format srting. Jika kamu ingin menampilkan simbol-simbol berikut, kamu harus membebaskannya (escape) dengan garis miring terbalik (`\`). - \$ - \\ @@ -117,9 +117,9 @@ Simbol-simbol berikut mempunyai kegunaan yang spesial dalam format srting. Jika - ( - ) -Perhatikan bahwa `toml` memiliki [sintaksi bebasnya sendiri](https://github.com/toml-lang/toml#user-content-string). Disarankan halnya untukmu menggunakan string literal (`''`) dalam konfigurasimu. Jika kamu mau memakai string standar (`""`), ingatlah untuk mengikat garis miring terbalik `\`. +Perhatikan bahwa `toml` memiliki [sintaksi bebasnya sendiri](https://github.com/toml-lang/toml#user-content-string). Disarankan halnya untukmu menggunakan string literal (`''`) dalam konfigurasimu. Jika kamu mau memakai string standar (`""`), ingatlah untuk membebaskan garis miring terbalik `\`. -Sebagai contoh, ketika kamu ingin menampilkan simbol `$` pada baris baru, konfigurasi berikut untuk `format` bersifat ekuivalen: +Sebagai contoh, ketika kamu ingin menampilkan simbol `$` pada sebuah baris baru, konfigurasi berikut sama halnya pada `format`: ```toml # dengan string standar @@ -142,12 +142,14 @@ Berikut adalah opsi konfigurasi dari list yang bersifat prompt-wide. ### Opsi -| Opsi | Bawaan | Deskripsi | -| ----------------- | ------------------------------ | ---------------------------------------------------------------------------- | -| `fromat` | [link](#default-prompt-format) | Mengkonfigurasi format pada prompt. | -| `scan_timeout` | `30` | Batas waktu starpship untuk memindai file (dalam milidetik). | -| `command_timeout` | `500` | Batas waktu untuk perintah yang dieksekusi oleh starship (dalam militdetik). | -| `add_newline` | `true` | Memasukkan baris kosong antara prompt shell. | +| Opsi | Bawaan | Deskripsi | +| ----------------- | ------------------------------ | ---------------------------------------------------------------- | +| `fromat` | [link](#default-prompt-format) | Mengkonfigurasi format pada prompt. | +| `right_format` | `""` | See [Enable Right Prompt](/advanced-config/#enable-right-prompt) | +| `scan_timeout` | `30` | Timeout for starship to scan files (in milliseconds). | +| `command_timeout` | `500` | Timeout for commands executed by starship (in milliseconds). | +| `add_newline` | `true` | Inserts blank line between shell prompts. | + ### Contoh @@ -174,11 +176,12 @@ Aturan `format` bawaan digunakan untuk mendefinisikan format pada prompt, apabil ```toml format = "$all" -# yang mana ekuivalen dengan +# Which is equivalent to format = """ $username\ $hostname\ $shlvl\ +$singularity\ $kubernetes\ $directory\ $vcsh\ @@ -191,6 +194,7 @@ $hg_branch\ $docker_context\ $package\ $cmake\ +$cobol\ $dart\ $deno\ $dotnet\ @@ -202,6 +206,7 @@ $helm\ $java\ $julia\ $kotlin\ +$lua\ $nim\ $nodejs\ $ocaml\ @@ -209,6 +214,7 @@ $perl\ $php\ $purescript\ $python\ +$rlang\ $red\ $ruby\ $rust\ @@ -229,7 +235,6 @@ $crystal\ $custom\ $cmd_duration\ $line_break\ -$lua\ $jobs\ $battery\ $time\ @@ -238,15 +243,22 @@ $shell\ $character""" ``` +If you just want to extend the default format, you can use `$all`; modules you explicitly add to the format will not be duplicated. Eg. + +```toml +# Move the directory to the second line +format="$all$directory$character" +``` + ## AWS -Module `aws` menampilkan region dan profil AWS terkini. Diperoleh dari variabel environment `AWS_REGION`, `AWS_DEFAULT_REGION`, dan `AWS_PROFILE` pada file `~/.aws/config`. Modul ini juga menampilkan penghitung waktu mundur kedaluwarsa ketika menggunakan temporer kredensial. +The `aws` module shows the current AWS region and profile. This is based on `AWS_REGION`, `AWS_DEFAULT_REGION`, and `AWS_PROFILE` env var with `~/.aws/config` file. This module also shows an expiration timer when using temporary credentials. -Ketika menggunakan [aws-vault](https://github.com/99designs/aws-vault), profil dibaca dari variabel environment `AWS_VAULT` dan tanggal kedaluwarsanya dibaca dari variabel environment `AWS_SESSION_EXPIRATION`. +When using [aws-vault](https://github.com/99designs/aws-vault) the profile is read from the `AWS_VAULT` env var and the credentials expiration date is read from the `AWS_SESSION_EXPIRATION` env var. -Ketika menggunakan [awsu](https://github.com/kreuzwerker/awsu) profil dibaca dari variabel environment `AWSU_PROFILE`. +When using [awsu](https://github.com/kreuzwerker/awsu) the profile is read from the `AWSU_PROFILE` env var. -Ketika menggunakan [AWSume](https://awsu.me) profil dibaca dari variabel environment `AWSUME_PROFILE` dan tanggal kedaluwarsanya dibaca dari variabel environment `AWSUME_EXPIRATION`. +When using [AWSume](https://awsu.me) the profile is read from the `AWSUME_PROFILE` env var and the credentials expiration date is read from the `AWSUME_EXPIRATION` env var. ### Opsi @@ -269,7 +281,7 @@ Ketika menggunakan [AWSume](https://awsu.me) profil dibaca dari variabel environ | symbol | | Menyalin nilai dari opsi `symbol` | | style\* | | Menyalin nilai dari opsi `style` | -\*: Variabel tersebut hanya dapat digunakan sebagai bagian dari penataan string +\*: This variable can only be used as a part of a style string ### Contoh @@ -314,7 +326,7 @@ symbol = "🅰 " ## Baterai -Modul `battery` menampilkan seberapa penuh baterai piranti terisi dan status pengisiannya. Modulnya hanya dapat terlihat ketika baterai dari pirantinya di bawah 10%. +The `battery` module shows how charged the device's battery is and its current charging status. The module is only visible when the device's battery is below 10%. ### Opsi @@ -342,7 +354,7 @@ discharging_symbol = "💀 " ### Tampilan Baterai -Opsi konfigurasi `display` digunakan untuk menentukan kapan indikator baterai harus ditampilkan (threshold), simbol mana yang akan digunakan (symbol), dan bagaimana seharusnya itu terlihat (style). Jika tidak ada `display` yang diberikan. Aturannya seperti yang ditunjukkan: +The `display` configuration option is used to define when the battery indicator should be shown (threshold), which symbol would be used (symbol), and what it would like (style). If no `display` is provided. Aturannya seperti yang ditunjukkan: ```toml [[battery.display]] @@ -350,11 +362,11 @@ threshold = 10 style = "bold red" ``` -Nilai bawaan untuk opsi `charging_symbol` dan `discharging_symbol` adalah nilai dari masing-masing opsi `charging_symbol` dan `discharging_symbol` dari nilai `battery`. +The default value for the `charging_symbol` and `discharging_symbol` option is respectively the value of `battery`'s `charging_symbol` and `discharging_symbol` option. #### Opsi -Opsi dari `display` merupakan sebuah array dari tabel berikut. +The `display` option is an array of the following table. | Opsi | Bawaan | Deskripsi | | -------------------- | ---------- | -------------------------------------------------------------------------------------------------------------------- | @@ -366,39 +378,39 @@ Opsi dari `display` merupakan sebuah array dari tabel berikut. #### Contoh ```toml -[[battery.display]] # "bold red" untuk corak gaya dan discharging_symbol ketika kapasitasnya berada di antara 0% dan 10% +[[battery.display]] # "bold red" style and discharging_symbol when capacity is between 0% and 10% threshold = 10 style = "bold red" -[[battery.display]] # "bold yellow" untuk corak gaya dan simbol 💦 ketika kapasitasnya berada di antara 10% dan 30% +[[battery.display]] # "bold yellow" style and 💦 symbol when capacity is between 10% and 30% threshold = 30 style = "bold yellow" discharging_symbol = 💦 -# ketika kapasitasnya di atas 30%, indikator baterai tidak akan ditampilkan +# when capacity is over 30%, the battery indicator will not be displayed ``` ## Karakter -Modul `character` menampilkan sebuah karakter (biasanya anak panah) di samping teks pada terminalmu. +The `character` module shows a character (usually an arrow) beside where the text is entered in your terminal. -Karakter dapat memberitahu kamu apakah perintah terakhir berhasil atau tidak. Karakter dapat memberitahumu dengan dua cara ini: +The character will tell you whether the last command was successful or not. It can do this in two ways: - mengganti warna (`red`/`green`) - mengganti bentuk (`❯`/`✖`) -Secara bawaan karakter hanya dapat mengganti warna. Jika kamu juga ingin mengganti bentuknya, perhatikan [contoh](#with-custom-error-shape) berikut. +By default it only changes color. If you also want to change its shape take a look at [this example](#with-custom-error-shape). ::: peringatan -`error_symbol` tidak didukung pada elvish dan nu shell. +`error_symbol` is not supported on elvish and nu shell. ::: ::: peringatan -`vicmd_symbol` hanya didukung pada fish dan zsh. +`vicmd_symbol` is only supported in fish and zsh. ::: @@ -451,10 +463,10 @@ vicmd_symbol = "[V](bold green) " ## CMake -Modul `cmake` menampilkan versi terkini dari [CMake](https://cmake.org/) yang terpasang. Secara bawaan, modul akan aktif jika beberapa syarat berikut telah terpenuhi: +The `cmake` module shows the currently installed version of [CMake](https://cmake.org/). By default the module will be activated if any of the following conditions are met: -- Direktori terkini berisikan sebuah file `CMakeLists.txt` -- Direktori terkini berisikan sebuah file `CMakeCache.txt` +- Direktori terkini yang berisikan sebuah file `CMakeLists.txt` +- Direktori terkini yang berisikan sebuah file `CMakeCache.txt` ### Opsi @@ -477,46 +489,76 @@ Modul `cmake` menampilkan versi terkini dari [CMake](https://cmake.org/) yang te | symbol | | Menyalin nilai dari opsi `symbol` | | style\* | | Menyalin nilai dari opsi `style` | -\*: Variabel tersebut hanya dapat digunakan sebagai bagian dari penataan string +\*: This variable can only be used as a part of a style string -## Command Duration +## COBOL / GNUCOBOL -Modul `cmd_duration` menampilkan seberapa lama perintah sebelumnya membutuhkan waktu untuk dilaksanakan. Modulnya hanya akan ditampilkan jika perintahnya membutuhkan waktu lebih dari dua detik, atau ada nilai dari konfigurasi `min_time`. +The `cobol` module shows the currently installed version of COBOL. By default, the module will be shown if any of the following conditions are met: -::: jangan lakukan hook DEBUG trap dalam Bash - -Jia kamu menjalankan Starship di `bash`, jangan lakukan hook DEBUG trap setelah menjalankan `eval $(starship init $0)`, atau modulnya **akan** rusak. - -::: - -Pengguna Bash yang membutuhkan fungsi seperti preexec dapat menggunakan [kerangka kerja bash_preexec dari rcaloras](https://github.com/rcaloras/bash-preexec). Cukup dengan membuat array `preexec_functions` dan `precmd_functions` sebelum menjalankan `eval $(starship init $0)`, lalu lanjutkan seperti biasa. +- The current directory contains any files ending in `.cob` or `.COB` +- The current directory contains any files ending in `.cbl` or `.CBL` ### Opsi -| Opsi | Bawaan | Deskripsi | -| -------------------- | ----------------------------- | ---------------------------------------------------------------- | -| `min_tim` | `2_000` | Durasi terpendek untuk menampilkan waktu (dalam milidetik). | -| `show_milliseconds` | `false` | Tampilkan milidetik sebagai ganti detik untuk durasinya. | -| `format` | `"took [$duration]($style) "` | Format dari modul. | -| `style` | `"bold yellow"` | Gaya penataan untuk modul. | -| `disabled` | `false` | Menonaktifkan modul `cmd_duration`. | -| `show_notifications` | `false` | Menampilkan notifikasi layar ketika perintah selesai. | -| `min_time_to_notify` | `45_000` | Durasi terpendek untuk menampilkan notifikasi (dalam milidetik). | +| Opsi | Bawaan | Deskripsi | +| ------------------- | ------------------------------------ | ----------------------------------------------------------------------------------- | +| `symbol` | `"⚙️ "` | The symbol used before displaying the version of COBOL. | +| `format` | `"via [$symbol($version )]($style)"` | Format dari modul. | +| `version_format` | `"v${raw}"` | Format dari versi. Variabel yang tersedia adalah `raw`, `major`, `minor`, & `patch` | +| `style` | `"bold blue"` | Gaya penataan untuk modul. | +| `detect_extensions` | `["cbl", "cob", "CBL", "COB"]` | Ekstensi mana yang sebaiknya memicu modul ini. | +| `detect_files` | `[]` | filenames mana yang sebaiknya memicu modul ini. | +| `detect_folders` | `[]` | Folder mana yang sebaiknya memicul modul ini. | +| `disabled` | `false` | Disables the `cobol` module. | -::: saran +### Variabel -Menampilkan notifikasi layar memerlukan starship dikembangkan dengan dukungan dari `rust-notify`. Periksa apakah starship kamu mendukung notifikasi dengan menjalankan `STARSHIP_LOG=debug starship module cmd_duration -d 60000` ketika `show_notifications` diatur menjadi `true`. +| Variabel | Contoh | Deskripsi | +| --------- | ---------- | --------------------------------- | +| version | `v3.1.2.0` | The version of `cobol` | +| symbol | | Menyalin nilai dari opsi `symbol` | +| style\* | | Menyalin nilai dari opsi `style` | + +\*: This variable can only be used as a part of a style string + +## Durasi Perintah + +The `cmd_duration` module shows how long the last command took to execute. The module will be shown only if the command took longer than two seconds, or the `min_time` config value, if it exists. + +::: warning Do not hook the DEBUG trap in Bash + +If you are running Starship in `bash`, do not hook the `DEBUG` trap after running `eval $(starship init $0)`, or this module **will** break. + +::: + +Bash users who need preexec-like functionality can use [rcaloras's bash_preexec framework](https://github.com/rcaloras/bash-preexec). Simply define the arrays `preexec_functions` and `precmd_functions` before running `eval $(starship init $0)`, and then proceed as normal. + +### Opsi + +| Opsi | Bawaan | Deskripsi | +| -------------------- | ----------------------------- | ---------------------------------------------------------- | +| `min_time` | `2_000` | Shortest duration to show time for (in milliseconds). | +| `show_milliseconds` | `false` | Show milliseconds in addition to seconds for the duration. | +| `format` | `"took [$duration]($style) "` | Format dari modul. | +| `style` | `"bold yellow"` | Gaya penataan untuk modul. | +| `disabled` | `false` | Disables the `cmd_duration` module. | +| `show_notifications` | `false` | Show desktop notifications when command completes. | +| `min_time_to_notify` | `45_000` | Shortest duration for notification (in milliseconds). | + +::: tip + +Showing desktop notifications requires starship to be built with `rust-notify` support. You check if your starship supports notifications by running `STARSHIP_LOG=debug starship module cmd_duration -d 60000` when `show_notifications` is set to `true`. ::: ### Variabel -| Variabel | Contoh | Deskripsi | -| --------- | -------- | -------------------------------------------------- | -| duration | `16m40s` | Waktu yang dibutuhkan untuk menyelesaikan perintah | -| style\* | | Menyalin nilai dari opsi `style` | +| Variabel | Contoh | Deskripsi | +| --------- | -------- | --------------------------------------- | +| duration | `16m40s` | The time it took to execute the command | +| style\* | | Menyalin nilai dari opsi `style` | -\*: Variabel tersebut hanya dapat digunakan sebagai bagian dari penataan string +\*: This variable can only be used as a part of a style string ### Contoh @@ -530,11 +572,11 @@ format = "underwent [$duration](bold yellow)" ## Conda -Modul `conda` menampilkan environment conda terkini, jika `$CONDA_DEFAULT_ENV` telah diatur. +The `conda` module shows the current [Conda](https://docs.conda.io/en/latest/) environment, if `$CONDA_DEFAULT_ENV` is set. -::: saran +::: tip -Hal ini tidak menahan pengubah (modifier) prompt dari conda sendiri, kamu mungkin bisa menjalankan `conda config --set changeps1 False`. +This does not suppress conda's own prompt modifier, you may want to run `conda config --set changeps1 False`. ::: @@ -557,7 +599,7 @@ Hal ini tidak menahan pengubah (modifier) prompt dari conda sendiri, kamu mungki | symbol | | Menyalin nilai dari opsi `symbol` | | style\* | | Menyalin nilai dari opsi `style` | -\*: Variabel tersebut hanya dapat digunakan sebagai bagian dari penataan string +\*: This variable can only be used as a part of a style string ### Contoh @@ -570,7 +612,7 @@ format = "[$symbol$environment](dimmed green) " ## Crystal -The `crystal` module shows the currently installed version of [Crystal](https://crystal-lang.org/). By default the module will be shown if any of the following conditions are met: +The `crystal` module shows the currently installed version of [Crystal](https://crystal-lang.org/). Secara bawaan, modul akan aktif jika beberapa syarat berikut telah terpenuhi: - The current directory contains a `shard.yml` file - The current directory contains a `.cr` file @@ -596,7 +638,7 @@ The `crystal` module shows the currently installed version of [Crystal](https:// | symbol | | Menyalin nilai dari opsi `symbol` | | style\* | | Menyalin nilai dari opsi `style` | -\*: Variabel tersebut hanya dapat digunakan sebagai bagian dari penataan string +\*: This variable can only be used as a part of a style string ### Contoh @@ -609,7 +651,7 @@ format = "via [✨ $version](bold blue) " ## Dart -The `dart` module shows the currently installed version of [Dart](https://dart.dev/). By default the module will be shown if any of the following conditions are met: +The `dart` module shows the currently installed version of [Dart](https://dart.dev/). Secara bawaan, modul akan aktif jika beberapa syarat berikut telah terpenuhi: - The current directory contains a file with `.dart` extension - The current directory contains a `.dart_tool` directory @@ -636,7 +678,7 @@ The `dart` module shows the currently installed version of [Dart](https://dart.d | symbol | | Menyalin nilai dari opsi `symbol` | | style\* | | Menyalin nilai dari opsi `style` | -\*: Variabel tersebut hanya dapat digunakan sebagai bagian dari penataan string +\*: This variable can only be used as a part of a style string ### Contoh @@ -649,7 +691,7 @@ format = "via [🔰 $version](bold red) " ## Deno -The `deno` module shows you your currently installed version of [Deno](https://deno.land/). By default the module will be shown if any of the following conditions are met: +The `deno` module shows you your currently installed version of [Deno](https://deno.land/). Secara bawaan, modul akan aktif jika beberapa syarat berikut telah terpenuhi: - The current directory contains a `mod.ts`, `mod.js`, `deps.ts` or `deps.js` file ### Opsi @@ -682,7 +724,7 @@ The `deno` module shows you your currently installed version of [Deno](https://d format = "via [🦕 $version](green bold) " ``` -## Directory +## Direktori The `directory` module shows the path to your current directory, truncated to three parent folders. Your directory will also be truncated to the root of the git repo that you're currently in. @@ -732,7 +774,7 @@ For example, given `~/Dev/Nix/nixpkgs/pkgs` where `nixpkgs` is the repo root, an | path | `"D:/Projects"` | The current directory path | | style\* | `"black bold dimmed"` | Menyalin nilai dari opsi `style` | -\*: Variabel tersebut hanya dapat digunakan sebagai bagian dari penataan string +\*: This variable can only be used as a part of a style string ### Contoh @@ -769,7 +811,7 @@ The `docker_context` module shows the currently active [Docker context](https:// | symbol | | Menyalin nilai dari opsi `symbol` | | style\* | | Menyalin nilai dari opsi `style` | -\*: Variabel tersebut hanya dapat digunakan sebagai bagian dari penataan string +\*: This variable can only be used as a part of a style string ### Contoh @@ -811,7 +853,7 @@ The module will also show the Target Framework Moniker ( ⚠️ The version being shown is that of the package whose source code is in your current directory, not your package manager. @@ -2075,7 +2147,7 @@ The `package` module is shown when the current directory is the repository for a | symbol | | Menyalin nilai dari opsi `symbol` | | style\* | | Menyalin nilai dari opsi `style` | -\*: Variabel tersebut hanya dapat digunakan sebagai bagian dari penataan string +\*: This variable can only be used as a part of a style string ### Contoh @@ -2088,7 +2160,7 @@ format = "via [🎁 $version](208 bold) " ## Perl -The `perl` module shows the currently installed version of [Perl](https://www.perl.org/). By default the module will be shown if any of the following conditions are met: +The `perl` module shows the currently installed version of [Perl](https://www.perl.org/). Secara bawaan, modul akan aktif jika beberapa syarat berikut telah terpenuhi: - The current directory contains a `Makefile.PL` or `Build.PL` file - The current directory contains a `cpanfile` or `cpanfile.snapshot` file @@ -2128,7 +2200,7 @@ format = "via [🦪 $version]($style) " ## PHP -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 `php` module shows the currently installed version of [PHP](https://www.php.net/). Secara bawaan, modul akan aktif jika beberapa syarat berikut telah terpenuhi: - The current directory contains a `composer.json` file - The current directory contains a `.php-version` file @@ -2155,7 +2227,7 @@ The `php` module shows the currently installed version of [PHP](https://www.php. | symbol | | Menyalin nilai dari opsi `symbol` | | style\* | | Menyalin nilai dari opsi `style` | -\*: Variabel tersebut hanya dapat digunakan sebagai bagian dari penataan string +\*: This variable can only be used as a part of a style string ### Contoh @@ -2168,7 +2240,7 @@ format = "via [🔹 $version](147 bold) " ## PureScript -The `purescript` module shows the currently installed version of [PureScript](https://www.purescript.org/) version. By default the module will be shown if any of the following conditions are met: +The `purescript` module shows the currently installed version of [PureScript](https://www.purescript.org/) version. Secara bawaan, modul akan aktif jika beberapa syarat berikut telah terpenuhi: - The current directory contains a `spago.dhall` file - The current directory contains a file with the `.purs` extension @@ -2194,7 +2266,7 @@ The `purescript` module shows the currently installed version of [PureScript](ht | symbol | | Menyalin nilai dari opsi `symbol` | | style\* | | Menyalin nilai dari opsi `style` | -\*: Variabel tersebut hanya dapat digunakan sebagai bagian dari penataan string +\*: This variable can only be used as a part of a style string ### Contoh @@ -2211,7 +2283,7 @@ The `python` module shows the currently installed version of [Python](https://ww If `pyenv_version_name` is set to `true`, it will display the pyenv version name. Otherwise, it will display the version number from `python --version`. -By default the module will be shown if any of the following conditions are met: +Secara bawaan, modul akan aktif jika beberapa syarat berikut telah terpenuhi: - The current directory contains a `.python-version` file - The current directory contains a `Pipfile` file @@ -2239,7 +2311,7 @@ By default the module will be shown if any of the following conditions are met: | `detect_folders` | `[]` | Folder mana yang sebaiknya memicul modul ini | | `disabled` | `false` | Disables the `python` module. | -::: saran +::: tip The `python_binary` variable accepts either a string or a list of strings. Starship will try executing each binary until it gets a result. Note you can only change the binary that Starship executes to get the version of Python not the arguments that are used. @@ -2296,7 +2368,7 @@ python_binary = ["./venv/bin/python", "python", "python3", "python2"] ## R -The `rlang` module shows the currently installed version of R. The module will be shown if any of the following conditions are met: +The `rlang` module shows the currently installed version of [R](https://www.r-project.org/). The module will be shown if any of the following conditions are met: - The current directory contains a file with the `.R` extension. - The current directory contains a file with the `.Rd` extension. @@ -2363,7 +2435,7 @@ By default the `red` module shows the currently installed version of [Red](https | symbol | | Menyalin nilai dari opsi `symbol` | | style\* | | Menyalin nilai dari opsi `style` | -\*: Variabel tersebut hanya dapat digunakan sebagai bagian dari penataan string +\*: This variable can only be used as a part of a style string ### Contoh @@ -2403,7 +2475,7 @@ By default the `ruby` module shows the currently installed version of [Ruby](htt | symbol | | Menyalin nilai dari opsi `symbol` | | style\* | | Menyalin nilai dari opsi `style` | -\*: Variabel tersebut hanya dapat digunakan sebagai bagian dari penataan string +\*: This variable can only be used as a part of a style string ### Contoh @@ -2442,7 +2514,7 @@ By default the `rust` module shows the currently installed version of [Rust](htt | symbol | | Menyalin nilai dari opsi `symbol` | | style\* | | Menyalin nilai dari opsi `style` | -\*: Variabel tersebut hanya dapat digunakan sebagai bagian dari penataan string +\*: This variable can only be used as a part of a style string ### Contoh @@ -2455,7 +2527,7 @@ format = "via [⚙️ $version](red bold)" ## Scala -The `scala` module shows the currently installed version of [Scala](https://www.scala-lang.org/). By default the module will be shown if any of the following conditions are met: +The `scala` module shows the currently installed version of [Scala](https://www.scala-lang.org/). Secara bawaan, modul akan aktif jika beberapa syarat berikut telah terpenuhi: - The current directory contains a `build.sbt`, `.scalaenv` or `.sbtenv` file - The current directory contains a file with the `.scala` or `.sbt` extension @@ -2469,7 +2541,7 @@ The `scala` module shows the currently installed version of [Scala](https://www. | `version_format` | `"v${raw}"` | Format dari versi. Variabel yang tersedia adalah `raw`, `major`, `minor`, & `patch` | | `detect_extensions` | `["sbt", "scala"]` | Ekstensi mana yang sebaiknya memicu modul ini. | | `detect_files` | `[".scalaenv", ".sbtenv", "build.sbt"]` | filenames mana yang sebaiknya memicu modul ini. | -| `detect_folders` | `[".metals"]` | Which folders should trigger this modules. | +| `detect_folders` | `[".metals"]` | Folder mana yang sebaiknya memicul modul ini. | | `symbol` | `"🆂 "` | A format string representing the symbol of Scala. | | `style` | `"red dimmed"` | Gaya penataan untuk modul. | | `disabled` | `false` | Disables the `scala` module. | @@ -2482,7 +2554,7 @@ The `scala` module shows the currently installed version of [Scala](https://www. | symbol | | Menyalin nilai dari opsi `symbol` | | style\* | | Menyalin nilai dari opsi `style` | -\*: Variabel tersebut hanya dapat digunakan sebagai bagian dari penataan string +\*: This variable can only be used as a part of a style string ### Contoh @@ -2497,7 +2569,7 @@ symbol = "🌟 " The `shell` module shows an indicator for currently used shell. -::: saran +::: tip This module is disabled by default. To enable it, set `disabled` to `false` in your configuration file. @@ -2539,7 +2611,7 @@ disabled = false ## SHLVL -The `shlvl` module shows the current `SHLVL` ("shell level") environment variable, if it is set to a number and meets or exceeds the specified threshold. +The `shlvl` module shows the current [`SHLVL`](https://tldp.org/LDP/abs/html/internalvariables.html#SHLVLREF) ("shell level") environment variable, if it is set to a number and meets or exceeds the specified threshold. ### Opsi @@ -2560,7 +2632,7 @@ The `shlvl` module shows the current `SHLVL` ("shell level") environment variabl | symbol | | Menyalin nilai dari opsi `symbol` | | style\* | | Menyalin nilai dari opsi `style` | -\*: Variabel tersebut hanya dapat digunakan sebagai bagian dari penataan string +\*: This variable can only be used as a part of a style string ### Contoh @@ -2594,7 +2666,7 @@ The `singularity` module shows the current [Singularity](https://sylabs.io/singu | symbol | | Menyalin nilai dari opsi `symbol` | | style\* | | Menyalin nilai dari opsi `style` | -\*: Variabel tersebut hanya dapat digunakan sebagai bagian dari penataan string +\*: This variable can only be used as a part of a style string ### Contoh @@ -2609,7 +2681,7 @@ format = '[📦 \[$env\]]($style) ' The `status` module displays the exit code of the previous command. The module will be shown only if the exit code is not `0`. -::: saran +::: tip This module is disabled by default. To enable it, set `disabled` to `false` in your configuration file. @@ -2650,7 +2722,7 @@ This module is disabled by default. To enable it, set `disabled` to `false` in y | symbol | | Menyalin nilai dari opsi `symbol` | | style\* | | Menyalin nilai dari opsi `style` | -\*: Variabel tersebut hanya dapat digunakan sebagai bagian dari penataan string +\*: This variable can only be used as a part of a style string ### Contoh @@ -2695,7 +2767,7 @@ By default the `swift` module shows the currently installed version of [Swift](h | symbol | | Menyalin nilai dari opsi `symbol` | | style\* | | Menyalin nilai dari opsi `style` | -\*: Variabel tersebut hanya dapat digunakan sebagai bagian dari penataan string +\*: This variable can only be used as a part of a style string ### Contoh @@ -2710,13 +2782,13 @@ format = "via [🏎 $version](red bold)" The `terraform` module shows the currently selected [Terraform workspace](https://www.terraform.io/docs/language/state/workspaces.html) and version. -::: saran +::: tip By default the Terraform version is not shown, since this is slow for current versions of Terraform when a lot of plugins are in use. If you still want to enable it, [follow the example shown below](#with-terraform-version). ::: -By default the module will be shown if any of the following conditions are met: +Secara bawaan, modul akan aktif jika beberapa syarat berikut telah terpenuhi: - The current directory contains a `.terraform` folder - Current directory contains a file with the `.tf` or `.hcl` extensions @@ -2739,11 +2811,11 @@ By default the module will be shown if any of the following conditions are met: | Variabel | Contoh | Deskripsi | | --------- | ---------- | --------------------------------- | | version | `v0.12.24` | The version of `terraform` | -| workspace | `bawaan` | The current Terraform workspace | +| workspace | `default` | The current Terraform workspace | | symbol | | Menyalin nilai dari opsi `symbol` | | style\* | | Menyalin nilai dari opsi `style` | -\*: Variabel tersebut hanya dapat digunakan sebagai bagian dari penataan string +\*: This variable can only be used as a part of a style string ### Contoh @@ -2765,11 +2837,11 @@ format = "[🏎💨 $version$workspace]($style) " format = "[🏎💨 $workspace]($style) " ``` -## Time +## Waktu 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. -::: saran +::: tip This module is disabled by default. To enable it, set `disabled` to `false` in your configuration file. @@ -2796,7 +2868,7 @@ If `use_12hr` is `true`, then `time_format` defaults to `"%r"`. Otherwise, it de | time | `13:08:10` | The current time. | | style\* | | Menyalin nilai dari opsi `style` | -\*: Variabel tersebut hanya dapat digunakan sebagai bagian dari penataan string +\*: This variable can only be used as a part of a style string ### Contoh @@ -2820,7 +2892,7 @@ The `username` module shows active user's username. The module will be shown if - The user is currently connected as an SSH session - The variable `show_always` is set to true -::: saran +::: tip SSH connection is detected by checking environment variables `SSH_CONNECTION`, `SSH_CLIENT`, and `SSH_TTY`. If your SSH host does not set up these variables, one workaround is to set one of them with a dummy value. @@ -2858,7 +2930,7 @@ show_always = true ## Vagrant -The `vagrant` module shows the currently installed version of [Vagrant](https://www.vagrantup.com/). By default the module will be shown if any of the following conditions are met: +The `vagrant` module shows the currently installed version of [Vagrant](https://www.vagrantup.com/). Secara bawaan, modul akan aktif jika beberapa syarat berikut telah terpenuhi: - The current directory contains a `Vagrantfile` file @@ -2883,7 +2955,7 @@ The `vagrant` module shows the currently installed version of [Vagrant](https:// | symbol | | Menyalin nilai dari opsi `symbol` | | style\* | | Menyalin nilai dari opsi `style` | -\*: Variabel tersebut hanya dapat digunakan sebagai bagian dari penataan string +\*: This variable can only be used as a part of a style string ### Contoh @@ -2894,9 +2966,9 @@ The `vagrant` module shows the currently installed version of [Vagrant](https:// format = "via [⍱ $version](bold white) " ``` -## VLang +## V -The `vlang` module shows you your currently installed version of V. By default the module will be shown if any of the following conditions are met: +The `vlang` module shows you your currently installed version of [V](https://vlang.io/). Secara bawaan, modul akan aktif jika beberapa syarat berikut telah terpenuhi: - The current directory contains a file with `.v` extension - The current directory contains a `v.mod`, `vpkg.json` or `.vpkg-lock.json` file @@ -2925,7 +2997,7 @@ The `vlang` module shows you your currently installed version of V. By default t ```toml # ~/.config/starship.toml -[v] +[vlang] format = "via [V $version](blue bold) " ``` @@ -2950,7 +3022,7 @@ The `vcsh` module displays the current active [VCSH](https://github.com/RichiH/v | symbol | | Menyalin nilai dari opsi `symbol` | | style\* | `black bold dimmed` | Menyalin nilai dari opsi `style` | -\*: Variabel tersebut hanya dapat digunakan sebagai bagian dari penataan string +\*: This variable can only be used as a part of a style string ### Contoh @@ -2988,7 +3060,7 @@ By default the the `zig` module shows the currently installed version of [Zig](h | symbol | | Menyalin nilai dari opsi `symbol` | | style\* | | Menyalin nilai dari opsi `style` | -\*: Variabel tersebut hanya dapat digunakan sebagai bagian dari penataan string +\*: This variable can only be used as a part of a style string ### Contoh @@ -3011,19 +3083,19 @@ These modules will be shown if any of the following conditions are met: - The `when` command returns 0 - The current Operating System (std::env::consts::OS) matchs with `os` field if defined. -::: saran +::: tip Multiple custom modules can be defined by using a `.`. ::: -::: saran +::: tip The order in which custom modules are shown can be individually set by including `${custom.foo}` in the top level `format` (as it includes a dot, you need to use `${...}`). By default, the `custom` module will simply show all custom modules in the order they were defined. ::: -::: saran +::: tip [Issue #1252](https://github.com/starship/starship/discussions/1252) contains examples of custom modules. If you have an interesting example not covered there, feel free to share it there! @@ -3036,7 +3108,7 @@ The order in which custom modules are shown can be individually set by including | `command` | | The command whose output should be printed. The command will be passed on stdin to the shell. | | `when` | | A shell command used as a condition to show the module. The module will be shown if the command returns a `0` status code. | | `shell` | | [See below](#custom-command-shell) | -| `deskripsi` | `""` | The description of the module that is shown when running `starship explain`. | +| `description` | `""` | The description of the module that is shown when running `starship explain`. | | `files` | `[]` | The files that will be searched in the working directory for a match. | | `directories` | `[]` | The directories that will be searched in the working directory for a match. | | `extensions` | `[]` | The extensions that will be searched in the working directory for a match. | @@ -3054,7 +3126,7 @@ The order in which custom modules are shown can be individually set by including | symbol | Menyalin nilai dari opsi `symbol` | | style\* | Menyalin nilai dari opsi `style` | -\*: Variabel tersebut hanya dapat digunakan sebagai bagian dari penataan string +\*: This variable can only be used as a part of a style string #### Custom command shell diff --git a/docs/id-ID/guide/README.md b/docs/id-ID/guide/README.md index ba84fedb..a4101378 100644 --- a/docs/id-ID/guide/README.md +++ b/docs/id-ID/guide/README.md @@ -48,30 +48,6 @@ height="20" src="https://raw.githubusercontent.com/starship/starship/master/media/flag-us.png" alt="English" - /> -   - 日本語 -   - 繁體中文 -   - Русский   -   - 简体中文   +   + 日本語 +   + Português do Brasil +   + Русский   +   + 简体中文 +   + 繁體中文

@@ -160,8 +168,8 @@ ```sh sh -c "$(curl -fsSL https://starship.rs/install.sh)" ``` - Untuk memperbarui Starship, jalankan kembali skrip di atas. Hal ini dapat memperbarui versi yang terpasang tanpa menyentuh konfigurasi Starship. + Untuk memperbarui Starship, jalankan kembali skrip di atas. Hal ini dapat memperbarui versi yang terpasang tanpa menyentuh konfigurasi Starship. **Note** - The defaults of the install script can be overridden see the built-in help. @@ -277,7 +285,7 @@ #### Nushell - **Warning** This will change in the future. Hanya nu versi v0.33 atau lebih baru yang tengah didukung. Add the following to your nu config file. Lokasi dari file ini dapat dicek dengan menjalankan `config path` pada nu. + **Warning** This will change in the future. Hanya nu versi v0.33 atau versi terbaru yang mendapat dukungan pengembangan. Add the following to your nu config file. Lokasi dari file ini dapat dicek dengan menjalankan `config path` pada nu. ```toml startup = [ diff --git a/docs/id-ID/migrating-to-0.45.0/README.md b/docs/id-ID/migrating-to-0.45.0/README.md index 9ae7a6ea..89589729 100644 --- a/docs/id-ID/migrating-to-0.45.0/README.md +++ b/docs/id-ID/migrating-to-0.45.0/README.md @@ -1,16 +1,16 @@ -# Migrating to v0.45.0 +# Migrasi ke v0.45.0 -Starship v0.45.0 is a release containing breaking changes, in preparation for the big v1.0.0. We have made some major changes around how configuration is done on the prompt, to allow for a greater degree of customization. +Starship v0.45.0 merupakan rilisan dengan perubahan yang signifikan, untuk persiapan v1.0.0 yang besar. Kami membuat beberapa perubahan besar tentang bagaimana konfigurasi dilakukan pada prompt, hingga bagaimana kami mengizinkan tingkat kustomisasi yang lebih luas. -This guide is intended to walk you through the breaking changes. +Petunjuk berikut memandu kamu ke perubahan besar kami. -## `prompt_order` has been replaced by a root-level `format` +## `prompt_order` kini digantikan dengan sebuah `format` root-level -Previously to v0.45.0, `prompt_order` would accept an array of module names in the order which they should be rendered by Starship. +Sebelum v0.45.0, `prompt_order` dapat menerima sebuah nama modul dengan urutan yang harusya di-render oleh Starship. -Starship v0.45.0 instead accepts a `format` value, allowing for customization of the prompt outside of the modules themselves. +Starship v0.45.0 kini menerima nilai dari `format`, memungkinkan kustomisasi prompt di luar modul itu sendiri. -**Example pre-v0.45.0 configuration** +**Contoh konfigurasi pra-v0.45.0** ```toml prompt_order = [ @@ -31,7 +31,7 @@ prompt_order = [ ] ``` -**Example v0.45.0 configuration** +**Contoh konfigurasi v0.45.0** ```toml format = """\ @@ -52,20 +52,20 @@ format = """\ """ ``` -## Module `prefix` and `suffix` have been replaced by `format` +## Modul `prefix` dan `suffix` kini digantikan dengan `format` -Previously to v0.45.0, some modules would accept `prefix` and/or `suffix` in order to stylize the way that modules are rendered. +Sebelum v0.45.0, beberapa modul bisa menerima `prefix` dan/atau `suffix` untuk menata gayanya sesuai yang di-render modul. -Starship v0.45.0 instead accepts a `format` value, allowing for further customization of how modules are rendered. Instead of defining a prefix and suffix for the context-based variables, the variables can now be substituted from within a format string, which represents the module's output. +Starship v0.45.0 menerima nilai `format` sebagai gantinya, memungkinkan bagaimana modul di-render untuk kustomisasi yang lebih jauh. Ketimbang membuat prefix dan suffix untuk varibel berbasis konteks, kini variabel dapat disubtitusikan dari sebuah format string, yang mana merepresantikan keluaran dari sebuah modul. -**Example pre-v0.45.0 configuration** +**Contoh konfigurasi pra-v0.45.0** ```toml [cmd_duration] prefix = "took " ``` -**Example v0.45.0 configuration** +**Contoh konfigurasi v0.45.0** ```toml [cmd_duration] @@ -78,14 +78,14 @@ format = "took [$duration]($style) " #### Karakter -| Removed Property | Replacement | -| ----------------------- | ---------------- | -| `symbol` | `success_symbol` | -| `use_symbol_for_status` | `error_symbol` | -| `style_success` | `success_symbol` | -| `style_failure` | `error_symbol` | +| Properti Yang Digantikan | Penggantinya | +| ------------------------ | ---------------- | +| `symbol` | `success_symbol` | +| `use_symbol_for_status` | `error_symbol` | +| `style_success` | `success_symbol` | +| `style_failure` | `error_symbol` | -**Changes to the Default Configuration** +**Perubahan pada konfigurasi bawaan** ```diff [character] @@ -98,26 +98,26 @@ format = "took [$duration]($style) " ++ vicmd_symbol = "[❮](bold green)" ``` -Previously, the `use_symbol_for_status` property was used to configure the prompt to show the `error_symbol` when the last command resulted in a non-zero status code. +Sebelumnya, properti `use_symbol_for_status` digunakan untuk mengkonfigurasi prompt untuk menampilkan `error_symbol` saat perintah terakhir berakhir dengan nilai code status yang bukan nol. -With the release of v0.45.0, we now always use `error_symbol` after non-zero status codes, unifying `use_symbol_for_status` and `error_symbol` properties. +Dengan rilisnya v0.45.0, kini kita selalu menggunakan `error_symbol` setelah nilai code status yang bukan nol, menggabungkan properti `use_symbol_for_status` dan `error_symbol`. -To configure the prompt to use the older `use_symbol_for_status = true` configuration, add the following to your config file: +Untuk mengkonfigurasi prompt agar menggunakan konfigurasi `use_symbol_for_status = true`, tambahkan baris berikut ke dalam file config: ```toml [character] error_symbol = "[✖](bold red)" ``` -*Note:* The `character` element automatically adds a space after, so unlike the other `format` strings, we specifically do not add one in the above examples. +*Catatan:* Element `character` secara otomatis menambahkan sebuah spasi setelahnya, jadi tidak seperti `format` string yang lain, kami secara spesifik tidak menambahkannya pada contoh di atas. -#### Command Duration +#### Durasi Perintah -| Removed Property | Replacement | -| ---------------- | ----------- | -| `prefix` | `format` | +| Properti Yang Digantikan | Penggantinya | +| ------------------------ | ------------ | +| `prefix` | `format` | -**Changes to the Default Configuration** +**Perubahan pada konfigurasi bawaan** ```diff [cmd_duration] @@ -125,13 +125,13 @@ error_symbol = "[✖](bold red)" ++ format = "took [$duration]($style) " ``` -#### Directory +#### Direktori -| Removed Property | Replacement | -| ---------------- | ----------- | -| `prefix` | `format` | +| Properti Yang Digantikan | Penggantinya | +| ------------------------ | ------------ | +| `prefix` | `format` | -**Changes to the Default Configuration** +**Perubahan pada konfigurasi bawaan** ```diff [directory] @@ -139,14 +139,14 @@ error_symbol = "[✖](bold red)" ++ format = "[$path]($style)[$read_only]($read_only_style) " ``` -#### Environment Variable +#### Variabel Environment -| Removed Property | Replacement | -| ---------------- | ----------- | -| `prefix` | `format` | -| `suffix` | `format` | +| Properti Yang Digantikan | Penggantinya | +| ------------------------ | ------------ | +| `prefix` | `format` | +| `suffix` | `format` | -**Changes to the Default Configuration** +**Perubahan pada konfigurasi bawaan** ```diff [env_var] @@ -157,12 +157,12 @@ error_symbol = "[✖](bold red)" #### Git Commit -| Removed Property | Replacement | -| ---------------- | ----------- | -| `prefix` | `format` | -| `suffix` | `format` | +| Properti Yang Digantikan | Penggantinya | +| ------------------------ | ------------ | +| `prefix` | `format` | +| `suffix` | `format` | -**Changes to the Default Configuration** +**Perubahan pada konfigurasi bawaan** ```diff [git_commit] @@ -173,13 +173,13 @@ error_symbol = "[✖](bold red)" #### Git Status -| Removed Property | Replacement | -| ----------------- | ----------- | -| `prefix` | `format` | -| `suffix` | `format` | -| `show_sync_count` | `format` | +| Properti Yang Digantikan | Penggantinya | +| ------------------------ | ------------ | +| `prefix` | `format` | +| `suffix` | `format` | +| `show_sync_count` | `format` | -**Changes to the Default Configuration** +**Perubahan pada konfigurasi bawaan** ```diff [git_status] @@ -189,11 +189,11 @@ error_symbol = "[✖](bold red)" ++ format = '([\[$all_status$ahead_behind\]]($style) )' ``` -Previously, the `show_sync_count` property was used to configure the prompt to show the number of commits the branch was ahead or behind the remote branch. +Sebelumnya, properti `show_sync_count` digunakan untuk mengkonfigurasi prompt untuk menampilkan jumlah commits dari branch yang terdepan atau terbelakang dari remote branch. -With the release of v0.45.0, this has been replaced with three separate properties, `ahead`, `behind`, and `diverged`. +Dengan rilisnya v0.45.0, hal ini kini digantikan dengan tiga properti terpisah, `ahead`, `behind`, dan `diverged`. -To configure the prompt to use the older `show_sync_count = true` configuration, set the following to your config file: +Untuk mengkonfigurasi prompt agar menggunakan konfigurasi `show_sync_count = true`, tambahkan baris berikut ke dalam file config: ```toml [git_status] @@ -204,12 +204,12 @@ behind = "⇣${count}" #### Hostname -| Removed Property | Replacement | -| ---------------- | ----------- | -| `prefix` | `format` | -| `suffix` | `format` | +| Properti Yang Digantikan | Penggantinya | +| ------------------------ | ------------ | +| `prefix` | `format` | +| `suffix` | `format` | -**Changes to the Default Configuration** +**Perubahan pada konfigurasi bawaan** ```diff [hostname] @@ -220,13 +220,13 @@ behind = "⇣${count}" #### Singularity -| Removed Property | Replacement | -| ---------------- | ----------- | -| `label` | `format` | -| `prefix` | `format` | -| `suffix` | `format` | +| Properti Yang Digantikan | Penggantinya | +| ------------------------ | ------------ | +| `label` | `format` | +| `prefix` | `format` | +| `suffix` | `format` | -**Changes to the Default Configuration** +**Perubahan pada konfigurasi bawaan** ```diff [singularity] @@ -235,13 +235,13 @@ behind = "⇣${count}" ++ format = '[$symbol\[$env\]]($style) ' ``` -#### Time +#### Waktu -| Removed Property | Replacement | -| ---------------- | ------------- | -| `format` | `time_format` | +| Properti Yang Digantikan | Penggantinya | +| ------------------------ | ------------- | +| `format` | `time_format` | -**Changes to the Default Configuration** +**Perubahan pada konfigurasi bawaan** ```diff [time] @@ -252,12 +252,12 @@ behind = "⇣${count}" #### Custom Commands -| Removed Property | Replacement | -| ---------------- | ----------- | -| `prefix` | `format` | -| `suffix` | `format` | +| Properti Yang Digantikan | Penggantinya | +| ------------------------ | ------------ | +| `prefix` | `format` | +| `suffix` | `format` | -**Changes to the Default Configuration** +**Perubahan pada konfigurasi bawaan** ```diff [custom.example] diff --git a/docs/id-ID/presets/README.md b/docs/id-ID/presets/README.md index cb485127..446504b8 100644 --- a/docs/id-ID/presets/README.md +++ b/docs/id-ID/presets/README.md @@ -1,16 +1,16 @@ -# Presets +# Prasetel (Presets) -Here is a collection of community-submitted configuration presets for Starship. If you have a preset to share, please [submit a PR](https://github.com/starship/starship/edit/master/docs/presets/README.md) updating this file! 😊 +Berikut ini adalah koleksi konfigurasi prasetel dari kumpulan komunita Starship. Jika kamu punya konfigurasi prasetel untuk dibagikan, silakan [kirim PR](https://github.com/starship/starship/edit/master/docs/presets/README.md) untuk memperbarui file ini! 😊 -## Nerd Font Symbols +## Simbol Nerd Font -This preset doesn't change anything except for the symbols used for each module. If emojis aren't your thing, this might catch your eye! +Konfigurasi prasetel berikut tidak mengubah apapun selain simbol yang digunakan untuk masing-masing modulnya. Kalau kamu enggak suka dengan emoji, hal ini mungkin bisa menarik perhatianmu! -![Screenshot of Nerd Font Symbols preset](/presets/nerd-font-symbols.png) +![Tangkapan Layar dari preset simbol Nerd Font](/presets/nerd-font-symbols.png) ### Prasyarat -- A [Nerd Font](https://www.nerdfonts.com/) installed and enabled in your terminal (the example uses Fira Code Nerd Font) +- Nerd Font yang terpasang dan telah diaktifkan di dalam terminal (contoh berikut menggunakan Nerd Font Fira Code) ### Konfigurasi @@ -88,17 +88,17 @@ symbol = " " symbol = "ﯣ " ``` -## Bracketed Segments +## Segmen Berkurung -This preset changes the format of all the built-in modules to show their segment in brackets instead of using the default Starship wording ("via", "on", etc.). +Konfigurasi prasetel berikut mengubah format dari seluruh modul bawaan untuk menampilkan segmennya di dalam tanda kurung daripada menggunakan susunan kata bawaan Starship ("via", "on", dll.). -Before: +Sebelum: -![Screenshot of default Starship configuration](/presets/bracketed-segments-before.png) +![Tangkapan Layar dari konfigurasi bawaan Starship](/presets/bracketed-segments-before.png) -After: +Sesudah: -![Screenshot of Bracketed Segments preset](/presets/bracketed-segments-after.png) +![Tangkapan Layar dari Segmen Berkurung](/presets/bracketed-segments-after.png) ### Konfigurasi @@ -112,6 +112,9 @@ format = '\[[$symbol($version)]($style)\]' [cmd_duration] format = '\[[⏱ $duration ]($style)\]' +[cobol] +format = '\[[$symbol($version)]($style)\]' + [conda] format = '\[[$symbol$environment]($style)\]' @@ -239,17 +242,17 @@ format = '\[[$symbol($version)]($style)\]' format = '\[[$symbol($version)]($style)\]' ``` -## Plain Text Symbols +## Simbol Teks Sederhana -This preset changes the symbols into plain text. If your terminal/font could not render the NerdFonts/emojis, maybe you could try this preset! +Konfigurasi prasetel berikut mengubah simbol menjadi teks sederhana. Jika terminal atau font kamu tidak mampu me-render Nerd Font atau emoji, mungkin kamu bisa mencoba konfigurasi prasetel berikut! -Before (default setting with Fixedsys font): +Sebelum (aturan bawaan dengan menggunakan font Fixedys): -![Screenshot of default Starship configuration with Fixedsys font](/presets/plain-text-symbols-before.png) +![Tangkapan Layar dari konfigurasi bawaan Starship dengan Font Fixedsys](/presets/plain-text-symbols-before.png) -After (Plain Text Symbols): +Sesudah (Simbol Teks Sederhana): -![Screenshot of Plain Text Symbols preset](/presets/plain-text-symbols-after.png) +![Tangkapan Layar dari preset Simbol Teks Sederhana](/presets/plain-text-symbols-after.png) ### Konfigurasi @@ -272,6 +275,9 @@ deleted = "x" [aws] symbol = "aws " +[cobol] +symbol = "cobol " + [conda] symbol = "conda " @@ -363,11 +369,11 @@ symbol = "scala " symbol = "swift " ``` -## Hide Runtime Versions +## Penyembunyian Versi Runtime -This preset hides the version of language runtimes. If you work in containers or virtualized environments, this one is for you! +Konfigurasi prasetel berikut menyembunyikan versi language runtimes. Jika kamu bekerja di dalam kontainer atau environments virtual, preset berikut cocok untukmu! -![Screenshot of Hide Runtime Versions preset](/presets/hide-runtime-versions.png) +![Tangkapan Layar dari preset Penyembunyian Versi Runtime](/presets/hide-runtime-versions.png) ### Konfigurasi @@ -375,6 +381,9 @@ This preset hides the version of language runtimes. If you work in containers or [cmake] format = "via [$symbol]($style)" +[cobol] +format = "via [$symbol]($style)" + [crystal] format = "via [$symbol]($style)" diff --git a/docs/it-IT/README.md b/docs/it-IT/README.md index 3c3fc90b..5c074175 100644 --- a/docs/it-IT/README.md +++ b/docs/it-IT/README.md @@ -18,7 +18,7 @@ features: footer: Licenza ISC | Copyright © 2019-present Starship Collaboratori #Used for the description meta tag, for SEO metaTitle: "Starship: Cross-Shell Prompt" -description: Starship è il prompt minimalista, super veloce ed estremamente personalizzabile per qualsiasi shell! Mostra le informazioni di cui hai bisogno, rimanendo elegante e minimale. Quick installation available for Bash, Fish, ZSH, Ion, Tcsh, Elvish, Nu, Xonsh, and PowerShell. +description: Starship è il prompt minimalista, super veloce ed estremamente personalizzabile per qualsiasi shell! Mostra le informazioni di cui hai bisogno, rimanendo elegante e minimale. Installazione rapida disponibile per Bash, Fish, ZSH, Ion, Tcsh, Elvish, Nu, Xonsh e PowerShell. ---
@@ -143,7 +143,7 @@ description: Starship è il prompt minimalista, super veloce ed estremamente per #### Nushell - ::: warning This will change in the future. Only nu version v0.33 or higher is supported. ::: Add the following to your nu config file. You can check the location of this file by running `config path` in nu. + ::: warning Questo cambierà in futuro. È supportata solo la versione v0.33 o superiore. ::: Aggiungi quanto segue al tuo file di configurazione nu. Puoi controllare la posizione di questo file eseguendo `percorso di configurazione` in nu. ```toml startup = [ @@ -157,7 +157,7 @@ description: Starship è il prompt minimalista, super veloce ed estremamente per #### Xonsh - Add the following to the end of `~/.xonshrc`: + Aggiungi quanto segue alla fine di `~/.xonshrc`: ```sh # ~/.xonshrc diff --git a/docs/it-IT/advanced-config/README.md b/docs/it-IT/advanced-config/README.md index 6e74418c..9da84da9 100644 --- a/docs/it-IT/advanced-config/README.md +++ b/docs/it-IT/advanced-config/README.md @@ -68,9 +68,36 @@ function set_win_title(){ starship_precmd_user_func="set_win_title" ``` -## Stringhe di stile +## Enable Right Prompt -Le stringhe di stile sono un elenco di parole, separate da spazi bianchi. Le parole non sono sensibili alle maiuscole (cioè `grassetto` e `BoLd` sono considerate la stessa stringa). Ogni parola può essere una delle seguenti: +Some shells support a right prompt which renders on the same line as the input. Starship can set the content of the right prompt using the `right_format` option. Any module that can be used in `format` is also supported in `right_format`. The `$all` variable will only contain modules not explicitly used in either `format` or `right_format`. + +Note: The right prompt is a single line following the input location. To right align modules above the input line in a multi-line prompt, see the [fill module](/config/#fill). + +`right_format` is currently supported for the following shells: elvish, fish, zsh. + +### Example + +```toml +# ~/.config/starship.toml + +# A minimal left prompt +format = """$character""" + +# move the rest of the prompt to the right +right_format = """$all""" +``` + +Produces a prompt like the following: + +``` +▶ starship on  rprompt [!] is 📦 v0.57.0 via 🦀 v1.54.0 took 17s +``` + + +## Stile delle Stringhe + +Style strings are a list of words, separated by whitespace. The words are not case sensitive (i.e. `bold` and `BoLd` are considered the same string). Each word can be one of the following: - `bold` - `italic` @@ -82,14 +109,14 @@ Le stringhe di stile sono un elenco di parole, separate da spazi bianchi. Le par - `` - `none` -dove `` è un colore specifico (discusso in seguito). `fg:` e `` attualmente fanno la stessa cosa, anche se questo potrebbe cambiare in futuro. `inverted` scambia lo sfondo e i colori in primo piano. L'ordine delle parole nella stringa non conta. +where `` is a color specifier (discussed below). `fg:` and `` currently do the same thing, though this may change in the future. `inverted` swaps the background and foreground colors. The order of words in the string does not matter. -Il token `none` sovrascrive tutti gli altri token in una stringa se non fa parte di uno specificatore `bg:`, così ad esempio `fg:red none fg:blue` creerà una stringa senza stile. `bg:none` imposta come colore di sfondo quello predefinito così `fg:red bg:none` è equivalente a `red` o `fg:red` e `bg:green fg:red bg:none` è equivalente a `fg:red` o `red`. Potrà diventare un errore usare `none` in combinazione con altri token in futuro. +The `none` token overrides all other tokens in a string if it is not part of a `bg:` specifier, so that e.g. `fg:red none fg:blue` will still create a string with no styling. `bg:none` sets the background to the default color so `fg:red bg:none` is equivalent to `red` or `fg:red` and `bg:green fg:red bg:none` is also equivalent to `fg:red` or `red`. It may become an error to use `none` in conjunction with other tokens in the future. -Uno colore specifico può essere uno di questi: +A color specifier can be one of the following: - Uno dei colori standard del terminale: `nero`, `rosso`, `verde`, `blu`, `giallo`, `viola`, `ciano`, `bianco`. Puoi eventualmente utilizzare il prefisso `bright-` per ottenere la versione luminosa (es. `bright-white`). - Un `#` seguito da un valore esadecimale a sei cifre. Questo specifica un [colore esagesimale in RGB](https://www.w3schools.com/colors/colors_hexadecimal.asp). - Un numero compreso tra 0-255. Specifica un [codice colore ANSI a 8 bit](https://i.stack.imgur.com/KTSQa.png). -Se sono specificati più colori per il primo piano/sfondo, l'ultimo nella stringa avrà la priorità. +If multiple colors are specified for foreground/background, the last one in the string will take priority. diff --git a/docs/it-IT/config/README.md b/docs/it-IT/config/README.md index 7885b026..5963aac8 100644 --- a/docs/it-IT/config/README.md +++ b/docs/it-IT/config/README.md @@ -65,9 +65,9 @@ Una variabile contiene un simbolo `$` seguito dal nome della variabile. Il nome Per esempio: -- `$version` is a format string with a variable named `version`. -- `$git_branch$git_commit` is a format string with two variables named `git_branch` and `git_commit`. -- `$git_branch $git_commit` has the two variables separated with a space. +- `$version` è una stringa di formato con una variabile chiamata `version`. +- `$git_branch$git_commit` è una stringa di formato con due variabili denominate `git_branch` e `git_commit`. +- `$git_branch $git_commit` ha le due variabili separate con uno spazio. #### Gruppo Testo @@ -75,30 +75,30 @@ Un gruppo di testo è composto da due parti diverse. La prima parte, che è racchiusa tra `[]`, è una [format string](#format-strings). È possibile aggiungere testi, variabili o anche gruppi annidati di testo. -Nella seconda parte, che è racchiusa tra `()`, è un [style string](#style-strings). Questo può essere usato stile la prima parte. +Nella seconda parte, che è racchiusa tra `()`, è un [style string](#style-strings). This can be used to style the first part. Per esempio: -- `[on](red bold)` will print a string `on` with bold text colored red. -- `[⌘ $version](bold green)` will print a symbol `⌘` followed by the content of variable `version`, with bold text colored green. -- `[a [b](red) c](green)` will print `a b c` with `b` red, and `a` and `c` green. +- `[on](rosso grassetto)` stamperà una stringa `on` con testo in grassetto di colore rosso. +- `[⌘ $version](grassetto verde)` stamperà un simbolo `⌘` seguito dal contenuto della variabile `version`, con testo grassetto di colore verde. +- `[a [b](rosso) c](verde)` stamperà `a b c` con `b` rosso, e `a` e `c` verde. -#### Stringhe di stile +#### Stile delle Stringhe -Most modules in starship allow you to configure their display styles. This is done with an entry (usually called `style`) which is a string specifying the configuration. Here are some examples of style strings along with what they do. For details on the full syntax, consult the [advanced config guide](/advanced-config/). +La maggior parte dei moduli in starship ti permettono di configurare i loro stili di visualizzazione. Questo viene fatto con una voce (solitamente chiamata `style`) che è una stringa che specifica la configurazione. Ecco alcuni esempi di stringhe di stile per quello che fanno. Per maggiori dettagli sulla sintassi completa, consulta la [guida di configurazione avanzata](/advanced-config/). -- `"fg:green bg:blue"` sets green text on a blue background -- `"bg:blue fg:bright-green"` sets bright green text on a blue background -- `"bold fg:27"` sets bold text with [ANSI color](https://i.stack.imgur.com/KTSQa.png) 27 -- `"underline bg:#bf5700"` sets underlined text on a burnt orange background -- `"bold italic fg:purple"` sets bold italic purple text -- `""` explicitly disables all styling +- `"fg:green bg:blue"` imposta il testo verde su uno sfondo blu +- `"bg:blue fg:bright-green"` imposta un testo verde brillante su uno sfondo blu +- `"bold fg:27"` imposta il testo in grassetto con [ANSI color](https://i.stack.imgur.com/KTSQa.png) 27 +- `"underline bg:#bf5700"` imposta il testo sottolineato su uno sfondo arancione scuro +- `"bold italic fg:purple"` imposta il testo viola in corsivo e grassetto +- `""` disabilita esplicitamente tutti gli stili -Note that what styling looks like will be controlled by your terminal emulator. For example, some terminal emulators will brighten the colors instead of bolding text, and some color themes use the same values for the normal and bright colors. Also, to get italic text, your terminal must support italics. +Nota che quello che assomiglia allo stile sarà controllato dal tuo emulatore terminale. Ad esempio, alcuni emulatori di terminale renderanno luminosi i colori invece del testo in grassetto, e alcuni temi colorati useranno gli stessi valori per i colori normali e luminosi. Inoltre, per ottenere il testo in corsivo, il tuo terminale deve supportare il corsivo. -#### Conditional Format Strings +#### Formattazione condizionale delle stringhe -A conditional format string wrapped in `(` and `)` will not render if all variables inside are empty. +Una stringa di formato condizionale inserita in `(` e `)` non verrà presentata se tutte le variabili interne sono vuote. Per esempio: @@ -108,7 +108,7 @@ Per esempio: #### Escapable characters -The following symbols have special usage in a format string. If you want to print the following symbols, you have to escape them with a backslash (`\`). +I seguenti simboli hanno un uso speciale in una stringa di formato. If you want to print the following symbols, you have to escape them with a backslash (`\`). - \$ - \\ @@ -140,16 +140,18 @@ format = ''' This is the list of prompt-wide configuration options. -### Options +### Opzioni -| Option | Default | Description | -| ----------------- | ------------------------------ | ------------------------------------------------------------ | -| `format` | [link](#default-prompt-format) | Configure the format of the prompt. | -| `scan_timeout` | `30` | Timeout for starship to scan files (in milliseconds). | -| `command_timeout` | `500` | Timeout for commands executed by starship (in milliseconds). | -| `add_newline` | `true` | Inserts blank line between shell prompts. | +| Opzione | Default | Descrizione | +| ----------------- | ------------------------------ | ---------------------------------------------------------------- | +| `format` | [link](#default-prompt-format) | Configura il formato del prompt. | +| `right_format` | `""` | See [Enable Right Prompt](/advanced-config/#enable-right-prompt) | +| `scan_timeout` | `30` | Timeout for starship to scan files (in milliseconds). | +| `command_timeout` | `500` | Timeout for commands executed by starship (in milliseconds). | +| `add_newline` | `true` | Inserts blank line between shell prompts. | -### Example + +### Esempio ```toml # ~/.config/starship.toml @@ -179,6 +181,7 @@ format = """ $username\ $hostname\ $shlvl\ +$singularity\ $kubernetes\ $directory\ $vcsh\ @@ -191,6 +194,7 @@ $hg_branch\ $docker_context\ $package\ $cmake\ +$cobol\ $dart\ $deno\ $dotnet\ @@ -202,6 +206,7 @@ $helm\ $java\ $julia\ $kotlin\ +$lua\ $nim\ $nodejs\ $ocaml\ @@ -209,6 +214,7 @@ $perl\ $php\ $purescript\ $python\ +$rlang\ $red\ $ruby\ $rust\ @@ -229,7 +235,6 @@ $crystal\ $custom\ $cmd_duration\ $line_break\ -$lua\ $jobs\ $battery\ $time\ @@ -238,6 +243,13 @@ $shell\ $character""" ``` +If you just want to extend the default format, you can use `$all`; modules you explicitly add to the format will not be duplicated. Eg. + +```toml +# Move the directory to the second line +format="$all$directory$character" +``` + ## AWS The `aws` module shows the current AWS region and profile. This is based on `AWS_REGION`, `AWS_DEFAULT_REGION`, and `AWS_PROFILE` env var with `~/.aws/config` file. This module also shows an expiration timer when using temporary credentials. @@ -250,7 +262,7 @@ When using [AWSume](https://awsu.me) the profile is read from the `AWSUME_PROFIL ### Options -| Option | Default | Description | +| Opzione | Default | Descrizione | | ------------------- | -------------------------------------------------------------------- | ----------------------------------------------------------------- | | `format` | `'on [$symbol($profile )(\($region\) )(\[$duration\])]($style)'` | The format for the module. | | `symbol` | `"☁️ "` | The symbol used before displaying the current AWS profile. | @@ -261,7 +273,7 @@ When using [AWSume](https://awsu.me) the profile is read from the `AWSUME_PROFIL ### Variables -| Variable | Example | Description | +| Variable | Example | Descrizione | | --------- | ---------------- | ------------------------------------------- | | region | `ap-northeast-1` | The current AWS region | | profile | `astronauts` | The current AWS profile | @@ -318,7 +330,7 @@ The `battery` module shows how charged the device's battery is and its current c ### Options -| Option | Default | Description | +| Opzione | Default | Descrizione | | -------------------- | --------------------------------- | --------------------------------------------------- | | `full_symbol` | `" "` | The symbol shown when the battery is full. | | `charging_symbol` | `" "` | The symbol shown when the battery is charging. | @@ -356,7 +368,7 @@ 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 | +| Opzione | Default | Descrizione | | -------------------- | ---------- | --------------------------------------------------------------------------------------------------------- | | `threshold` | `10` | The upper bound for the display option. | | `style` | `bold red` | The style used if the display option is in use. | @@ -404,7 +416,7 @@ By default it only changes color. If you also want to change its shape take a lo ### Options -| Option | Default | Description | +| Opzione | Default | Descrizione | | ---------------- | ------------------- | -------------------------------------------------------------------------------- | | `format` | `"$symbol "` | The format string used before the text input. | | `success_symbol` | `"[❯](bold green)"` | The format string used before the text input if the previous command succeeded. | @@ -414,7 +426,7 @@ By default it only changes color. If you also want to change its shape take a lo ### Variables -| Variable | Example | Description | +| Variable | Example | Descrizione | | -------- | ------- | --------------------------------------------------------------------- | | symbol | | A mirror of either `success_symbol`, `error_symbol` or `vicmd_symbol` | @@ -458,7 +470,7 @@ The `cmake` module shows the currently installed version of [CMake](https://cmak ### Options -| Option | Default | Description | +| Opzione | Default | Descrizione | | ------------------- | -------------------------------------- | ------------------------------------------------------------------------- | | `format` | `"via [$symbol($version )]($style)"` | The format for the module. | | `version_format` | `"v${raw}"` | The version format. Available vars are `raw`, `major`, `minor`, & `patch` | @@ -471,7 +483,7 @@ The `cmake` module shows the currently installed version of [CMake](https://cmak ### Variables -| Variable | Example | Description | +| Variable | Example | Descrizione | | --------- | --------- | ------------------------------------ | | version | `v3.17.3` | The version of cmake | | symbol | | Mirrors the value of option `symbol` | @@ -479,6 +491,36 @@ The `cmake` module shows the currently installed version of [CMake](https://cmak \*: This variable can only be used as a part of a style string +## COBOL / GNUCOBOL + +The `cobol` module shows the currently installed version of COBOL. By default, the module will be shown if any of the following conditions are met: + +- The current directory contains any files ending in `.cob` or `.COB` +- The current directory contains any files ending in `.cbl` or `.CBL` + +### Options + +| Opzione | Default | Descrizione | +| ------------------- | ------------------------------------ | ------------------------------------------------------------------------- | +| `symbol` | `"⚙️ "` | The symbol used before displaying the version of COBOL. | +| `format` | `"via [$symbol($version )]($style)"` | The format for the module. | +| `version_format` | `"v${raw}"` | The version format. Available vars are `raw`, `major`, `minor`, & `patch` | +| `style` | `"bold blue"` | The style for the module. | +| `detect_extensions` | `["cbl", "cob", "CBL", "COB"]` | Which extensions should trigger this module. | +| `detect_files` | `[]` | Which filenames should trigger this module. | +| `detect_folders` | `[]` | Which folders should trigger this module. | +| `disabled` | `false` | Disables the `cobol` module. | + +### Variables + +| Variable | Example | Descrizione | +| --------- | ---------- | ------------------------------------ | +| version | `v3.1.2.0` | The version of `cobol` | +| 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 + ## Durata del comando The `cmd_duration` module shows how long the last command took to execute. The module will be shown only if the command took longer than two seconds, or the `min_time` config value, if it exists. @@ -493,7 +535,7 @@ Bash users who need preexec-like functionality can use [rcaloras's bash_preexec ### Options -| Option | Default | Description | +| Opzione | Default | Descrizione | | -------------------- | ----------------------------- | ---------------------------------------------------------- | | `min_time` | `2_000` | Shortest duration to show time for (in milliseconds). | | `show_milliseconds` | `false` | Show milliseconds in addition to seconds for the duration. | @@ -511,7 +553,7 @@ Showing desktop notifications requires starship to be built with `rust-notify` s ### Variables -| Variable | Example | Description | +| Variable | Example | Descrizione | | --------- | -------- | --------------------------------------- | | duration | `16m40s` | The time it took to execute the command | | style\* | | Mirrors the value of option `style` | @@ -530,7 +572,7 @@ format = "underwent [$duration](bold yellow)" ## Conda -The `conda` module shows the current conda environment, if `$CONDA_DEFAULT_ENV` is set. +The `conda` module shows the current [Conda](https://docs.conda.io/en/latest/) environment, if `$CONDA_DEFAULT_ENV` is set. ::: tip @@ -540,7 +582,7 @@ This does not suppress conda's own prompt modifier, you may want to run `conda c ### Options -| Option | Default | Description | +| Opzione | Default | Descrizione | | ------------------- | -------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | | `truncation_length` | `1` | The number of directories the environment path should be truncated to, if the environment was created via `conda create -p [path]`. `0` means no truncation. Also see the [`directory`](#directory) module. | | `symbol` | `"🅒 "` | The symbol used before the environment name. | @@ -551,7 +593,7 @@ This does not suppress conda's own prompt modifier, you may want to run `conda c ### Variables -| Variable | Example | Description | +| Variable | Example | Descrizione | | ----------- | ------------ | ------------------------------------ | | environment | `astronauts` | The current conda environment | | symbol | | Mirrors the value of option `symbol` | @@ -577,7 +619,7 @@ The `crystal` module shows the currently installed version of [Crystal](https:// ### Options -| Option | Default | Description | +| Opzione | Default | Descrizione | | ------------------- | ------------------------------------ | ------------------------------------------------------------------------- | | `symbol` | `"🔮 "` | The symbol used before displaying the version of crystal. | | `format` | `"via [$symbol($version )]($style)"` | The format for the module. | @@ -590,7 +632,7 @@ The `crystal` module shows the currently installed version of [Crystal](https:// ### Variables -| Variable | Example | Description | +| Variable | Example | Descrizione | | --------- | --------- | ------------------------------------ | | version | `v0.32.1` | The version of `crystal` | | symbol | | Mirrors the value of option `symbol` | @@ -617,7 +659,7 @@ The `dart` module shows the currently installed version of [Dart](https://dart.d ### Options -| Option | Default | Description | +| Opzione | Default | Descrizione | | ------------------- | ------------------------------------------------- | ------------------------------------------------------------------------- | | `format` | `"via [$symbol($version )]($style)"` | The format for the module. | | `version_format` | `"v${raw}"` | The version format. Available vars are `raw`, `major`, `minor`, & `patch` | @@ -630,7 +672,7 @@ The `dart` module shows the currently installed version of [Dart](https://dart.d ### Variables -| Variable | Example | Description | +| Variable | Example | Descrizione | | --------- | -------- | ------------------------------------ | | version | `v2.8.4` | The version of `dart` | | symbol | | Mirrors the value of option `symbol` | @@ -654,7 +696,7 @@ The `deno` module shows you your currently installed version of [Deno](https://d ### Options -| Option | Default | Description | +| Opzione | Default | Descrizione | | ------------------- | -------------------------------------------- | ------------------------------------------------------------------------- | | `format` | `"via [$symbol($version )]($style)"` | The format for the module. | | `version_format` | `"v${raw}"` | The version format. Available vars are `raw`, `major`, `minor`, & `patch` | @@ -667,7 +709,7 @@ The `deno` module shows you your currently installed version of [Deno](https://d ### Variables -| Variable | Example | Description | +| Variable | Example | Descrizione | | --------- | -------- | ------------------------------------ | | version | `v1.8.3` | The version of `deno` | | symbol | | Mirrors the value of option `symbol` | @@ -692,7 +734,7 @@ For example, given `~/Dev/Nix/nixpkgs/pkgs` where `nixpkgs` is the repo root, an ### Options -| Option | Default | Description | +| Opzione | Default | Descrizione | | ------------------- | -------------------------------------------------- | -------------------------------------------------------------------------------- | | `truncation_length` | `3` | The number of parent folders that the current directory should be truncated to. | | `truncate_to_repo` | `true` | Whether or not to truncate to the root of the git repo that you're currently in. | @@ -707,7 +749,7 @@ For example, given `~/Dev/Nix/nixpkgs/pkgs` where `nixpkgs` is the repo root, an
This module has a few advanced configuration options that control how the directory is displayed. -| Advanced Option | Default | Description | +| Advanced Option | Default | Descrizione | | --------------------------- | ------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------- | | `substitutions` | | A table of substitutions to be made to the path. | | `fish_style_pwd_dir_length` | `0` | The number of characters to use when applying fish shell pwd path logic. | @@ -727,7 +769,7 @@ For example, given `~/Dev/Nix/nixpkgs/pkgs` where `nixpkgs` is the repo root, an ### Variables -| Variable | Example | Description | +| Variable | Example | Descrizione | | --------- | --------------------- | ----------------------------------- | | path | `"D:/Projects"` | The current directory path | | style\* | `"black bold dimmed"` | Mirrors the value of option `style` | @@ -750,7 +792,7 @@ The `docker_context` module shows the currently active [Docker context](https:// ### Options -| Option | Default | Description | +| Opzione | Default | Descrizione | | ------------------- | ------------------------------------------------------------- | --------------------------------------------------------------------------------- | | `format` | `"via [$symbol$context]($style) "` | The format for the module. | | `symbol` | `"🐳 "` | The symbol used before displaying the Docker context. | @@ -763,7 +805,7 @@ The `docker_context` module shows the currently active [Docker context](https:// ### Variables -| Variable | Example | Description | +| Variable | Example | Descrizione | | --------- | -------------- | ------------------------------------ | | context | `test_context` | The current docker context | | symbol | | Mirrors the value of option `symbol` | @@ -803,7 +845,7 @@ The module will also show the Target Framework Moniker ( ⚠️ The version being shown is that of the package whose source code is in your current directory, not your package manager. ### Options -| Option | Default | Description | +| Opzione | Default | Descrizione | | ----------------- | --------------------------------- | ------------------------------------------------------------------------- | | `format` | `"is [$symbol$version]($style) "` | The format for the module. | | `symbol` | `"📦 "` | The symbol used before displaying the version the package. | @@ -2069,7 +2141,7 @@ The `package` module is shown when the current directory is the repository for a ### Variables -| Variable | Example | Description | +| Variable | Example | Descrizione | | --------- | -------- | ------------------------------------ | | version | `v1.0.0` | The version of your package | | symbol | | Mirrors the value of option `symbol` | @@ -2098,7 +2170,7 @@ The `perl` module shows the currently installed version of [Perl](https://www.pe ### Options -| Option | Default | Description | +| Opzione | Default | Descrizione | | ------------------- | -------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------- | | `format` | `"via [$symbol($version )]($style)"` | The format string for the module. | | `version_format` | `"v${raw}"` | The version format. Available vars are `raw`, `major`, `minor`, & `patch` | @@ -2111,7 +2183,7 @@ The `perl` module shows the currently installed version of [Perl](https://www.pe ### Variables -| Variable | Example | Description | +| Variable | Example | Descrizione | | --------- | --------- | ------------------------------------ | | version | `v5.26.1` | The version of `perl` | | symbol | | Mirrors the value of option `symbol` | @@ -2136,7 +2208,7 @@ The `php` module shows the currently installed version of [PHP](https://www.php. ### Options -| Option | Default | Description | +| Opzione | Default | Descrizione | | ------------------- | ------------------------------------ | ------------------------------------------------------------------------- | | `format` | `"via [$symbol($version )]($style)"` | The format for the module. | | `version_format` | `"v${raw}"` | The version format. Available vars are `raw`, `major`, `minor`, & `patch` | @@ -2149,7 +2221,7 @@ The `php` module shows the currently installed version of [PHP](https://www.php. ### Variables -| Variable | Example | Description | +| Variable | Example | Descrizione | | --------- | -------- | ------------------------------------ | | version | `v7.3.8` | The version of `php` | | symbol | | Mirrors the value of option `symbol` | @@ -2175,7 +2247,7 @@ The `purescript` module shows the currently installed version of [PureScript](ht ### Options -| Option | Default | Description | +| Opzione | Default | Descrizione | | ------------------- | ------------------------------------ | ------------------------------------------------------------------------- | | `format` | `"via [$symbol($version )]($style)"` | The format for the module. | | `version_format` | `"v${raw}"` | The version format. Available vars are `raw`, `major`, `minor`, & `patch` | @@ -2188,7 +2260,7 @@ The `purescript` module shows the currently installed version of [PureScript](ht ### Variables -| Variable | Example | Description | +| Variable | Example | Descrizione | | --------- | -------- | ------------------------------------ | | version | `0.13.5` | The version of `purescript` | | symbol | | Mirrors the value of option `symbol` | @@ -2225,7 +2297,7 @@ By default the module will be shown if any of the following conditions are met: ### Options -| Option | Default | Description | +| Opzione | Default | Descrizione | | -------------------- | ------------------------------------------------------------------------------------------------------------ | -------------------------------------------------------------------------------------- | | `format` | `'via [${symbol}${pyenv_prefix}(${version} )(\($virtualenv\) )]($style)'` | The format for the module. | | `version_format` | `"v${raw}"` | The version format. Available vars are `raw`, `major`, `minor`, & `patch` | @@ -2249,7 +2321,7 @@ The default values and order for `python_binary` was chosen to first identify th ### Variables -| Variable | Example | Description | +| Variable | Example | Descrizione | | ------------ | --------------- | ------------------------------------------ | | version | `"v3.8.1"` | The version of `python` | | symbol | `"🐍 "` | Mirrors the value of option `symbol` | @@ -2296,7 +2368,7 @@ python_binary = ["./venv/bin/python", "python", "python3", "python2"] ## R -The `rlang` module shows the currently installed version of R. The module will be shown if any of the following conditions are met: +The `rlang` module shows the currently installed version of [R](https://www.r-project.org/). The module will be shown if any of the following conditions are met: - The current directory contains a file with the `.R` extension. - The current directory contains a file with the `.Rd` extension. @@ -2308,7 +2380,7 @@ The `rlang` module shows the currently installed version of R. The module will b ### Options -| Option | Default | Description | +| Opzione | Default | Descrizione | | ------------------- | ------------------------------------ | ------------------------------------------------------------------------- | | `format` | `"via [$symbol($version )]($style)"` | The format for the module. | | `version_format` | `"v${raw}"` | The version format. Available vars are `raw`, `major`, `minor`, & `patch` | @@ -2321,7 +2393,7 @@ The `rlang` module shows the currently installed version of R. The module will b ### Variables -| Variable | Example | Description | +| Variable | Example | Descrizione | | -------- | ------------- | ------------------------------------ | | version | `v4.0.5` | The version of `R` | | symbol | | Mirrors the value of option `symbol` | @@ -2344,7 +2416,7 @@ By default the `red` module shows the currently installed version of [Red](https ### Options -| Option | Default | Description | +| Opzione | Default | Descrizione | | ------------------- | ------------------------------------ | ------------------------------------------------------------------------- | | `format` | `"via [$symbol($version )]($style)"` | The format for the module. | | `version_format` | `"v${raw}"` | The version format. Available vars are `raw`, `major`, `minor`, & `patch` | @@ -2357,7 +2429,7 @@ By default the `red` module shows the currently installed version of [Red](https ### Variables -| Variable | Example | Description | +| Variable | Example | Descrizione | | --------- | -------- | ------------------------------------ | | version | `v2.5.1` | The version of `red` | | symbol | | Mirrors the value of option `symbol` | @@ -2384,7 +2456,7 @@ By default the `ruby` module shows the currently installed version of [Ruby](htt ### Options -| Option | Default | Description | +| Opzione | Default | Descrizione | | ------------------- | ------------------------------------ | ------------------------------------------------------------------------- | | `format` | `"via [$symbol($version )]($style)"` | The format for the module. | | `version_format` | `"v${raw}"` | The version format. Available vars are `raw`, `major`, `minor`, & `patch` | @@ -2397,7 +2469,7 @@ By default the `ruby` module shows the currently installed version of [Ruby](htt ### Variables -| Variable | Example | Description | +| Variable | Example | Descrizione | | --------- | -------- | ------------------------------------ | | version | `v2.5.1` | The version of `ruby` | | symbol | | Mirrors the value of option `symbol` | @@ -2423,7 +2495,7 @@ By default the `rust` module shows the currently installed version of [Rust](htt ### Options -| Option | Default | Description | +| Opzione | Default | Descrizione | | ------------------- | ------------------------------------ | ------------------------------------------------------------------------- | | `format` | `"via [$symbol($version )]($style)"` | The format for the module. | | `version_format` | `"v${raw}"` | The version format. Available vars are `raw`, `major`, `minor`, & `patch` | @@ -2436,7 +2508,7 @@ By default the `rust` module shows the currently installed version of [Rust](htt ### Variables -| Variable | Example | Description | +| Variable | Example | Descrizione | | --------- | ----------------- | ------------------------------------ | | version | `v1.43.0-nightly` | The version of `rustc` | | symbol | | Mirrors the value of option `symbol` | @@ -2463,7 +2535,7 @@ The `scala` module shows the currently installed version of [Scala](https://www. ### Options -| Option | Default | Description | +| Opzione | Default | Descrizione | | ------------------- | ---------------------------------------- | ------------------------------------------------------------------------- | | `format` | `"via [${symbol}(${version} )]($style)"` | The format for the module. | | `version_format` | `"v${raw}"` | The version format. Available vars are `raw`, `major`, `minor`, & `patch` | @@ -2476,7 +2548,7 @@ The `scala` module shows the currently installed version of [Scala](https://www. ### Variables -| Variable | Example | Description | +| Variable | Example | Descrizione | | --------- | -------- | ------------------------------------ | | version | `2.13.5` | The version of `scala` | | symbol | | Mirrors the value of option `symbol` | @@ -2505,7 +2577,7 @@ This module is disabled by default. To enable it, set `disabled` to `false` in y ### Options -| Option | Default | Description | +| Opzione | Default | Descrizione | | ---------------------- | ------------ | ------------------------------------------------------------ | | `bash_indicator` | `bsh` | A format string used to represent bash. | | `fish_indicator` | `fsh` | A format string used to represent fish. | @@ -2521,7 +2593,7 @@ This module is disabled by default. To enable it, set `disabled` to `false` in y ### Variables -| Variable | Default | Description | +| Variable | Default | Descrizione | | --------- | ------- | ---------------------------------------------------------- | | indicator | | Mirrors the value of `indicator` for currently used shell. | @@ -2539,11 +2611,11 @@ disabled = false ## SHLVL -The `shlvl` module shows the current `SHLVL` ("shell level") environment variable, if it is set to a number and meets or exceeds the specified threshold. +The `shlvl` module shows the current [`SHLVL`](https://tldp.org/LDP/abs/html/internalvariables.html#SHLVLREF) ("shell level") environment variable, if it is set to a number and meets or exceeds the specified threshold. ### Options -| Option | Default | Description | +| Opzione | Default | Descrizione | | ----------- | ---------------------------- | ------------------------------------------------------------- | | `threshold` | `2` | Display threshold. | | `format` | `"[$symbol$shlvl]($style) "` | The format for the module. | @@ -2554,7 +2626,7 @@ The `shlvl` module shows the current `SHLVL` ("shell level") environment variabl ### Variables -| Variable | Example | Description | +| Variable | Example | Descrizione | | --------- | ------- | ------------------------------------ | | shlvl | `3` | The current value of `SHLVL` | | symbol | | Mirrors the value of option `symbol` | @@ -2579,7 +2651,7 @@ The `singularity` module shows the current [Singularity](https://sylabs.io/singu ### Options -| Option | Default | Description | +| Opzione | Default | Descrizione | | ---------- | -------------------------------- | ------------------------------------------------ | | `format` | `'[$symbol\[$env\]]($style) '` | The format for the module. | | `symbol` | `""` | A format string displayed before the image name. | @@ -2588,7 +2660,7 @@ The `singularity` module shows the current [Singularity](https://sylabs.io/singu ### Variables -| Variable | Example | Description | +| Variable | Example | Descrizione | | --------- | ------------ | ------------------------------------ | | env | `centos.img` | The current Singularity image | | symbol | | Mirrors the value of option `symbol` | @@ -2619,7 +2691,7 @@ This module is disabled by default. To enable it, set `disabled` to `false` in y ### Options -| Option | Default | Description | +| Opzione | Default | Descrizione | | ----------------------- | ------------------------------------------------------------------------------------ | ------------------------------------------------------- | | `format` | `"[$symbol$status]($style) "` | The format of the module | | `symbol` | `"✖"` | The symbol displayed on program error | @@ -2638,7 +2710,7 @@ This module is disabled by default. To enable it, set `disabled` to `false` in y ### Variables -| Variable | Example | Description | +| Variable | Example | Descrizione | | -------------- | ------- | ------------------------------------------------------------------------------------------- | | status | `127` | The exit code of the last command | | int | `127` | The exit code of the last command | @@ -2676,7 +2748,7 @@ By default the `swift` module shows the currently installed version of [Swift](h ### Options -| Option | Default | Description | +| Opzione | Default | Descrizione | | ------------------- | ------------------------------------ | ------------------------------------------------------------------------- | | `format` | `"via [$symbol($version )]($style)"` | The format for the module. | | `version_format` | `"v${raw}"` | The version format. Available vars are `raw`, `major`, `minor`, & `patch` | @@ -2689,7 +2761,7 @@ By default the `swift` module shows the currently installed version of [Swift](h ### Variables -| Variable | Example | Description | +| Variable | Example | Descrizione | | --------- | -------- | ------------------------------------ | | version | `v5.2.4` | The version of `swift` | | symbol | | Mirrors the value of option `symbol` | @@ -2723,7 +2795,7 @@ By default the module will be shown if any of the following conditions are met: ### Options -| Option | Default | Description | +| Opzione | Default | Descrizione | | ------------------- | ------------------------------------ | ------------------------------------------------------------------------- | | `format` | `"via [$symbol$workspace]($style) "` | The format string for the module. | | `version_format` | `"v${raw}"` | The version format. Available vars are `raw`, `major`, `minor`, & `patch` | @@ -2736,7 +2808,7 @@ By default the module will be shown if any of the following conditions are met: ### Variables -| Variable | Example | Description | +| Variable | Example | Descrizione | | --------- | ---------- | ------------------------------------ | | version | `v0.12.24` | The version of `terraform` | | workspace | `default` | The current Terraform workspace | @@ -2777,7 +2849,7 @@ This module is disabled by default. To enable it, set `disabled` to `false` in y ### Options -| Option | Default | Description | +| Opzione | Default | Descrizione | | ----------------- | ----------------------- | ---------------------------------------------------------------------------------------------------------------------------------- | | `format` | `"at [$time]($style) "` | The format string for the module. | | `use_12hr` | `false` | Enables 12 hour formatting | @@ -2791,9 +2863,9 @@ If `use_12hr` is `true`, then `time_format` defaults to `"%r"`. Otherwise, it de ### Variables -| Variable | Example | Description | +| Variable | Example | Descrizione | | --------- | ---------- | ----------------------------------- | -| ora | `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 @@ -2828,7 +2900,7 @@ SSH connection is detected by checking environment variables `SSH_CONNECTION`, ` ### Options -| Option | Default | Description | +| Opzione | Default | Descrizione | | ------------- | ----------------------- | ------------------------------------- | | `style_root` | `"bold red"` | The style used when the user is root. | | `style_user` | `"bold yellow"` | The style used for non-root users. | @@ -2838,7 +2910,7 @@ SSH connection is detected by checking environment variables `SSH_CONNECTION`, ` ### Variables -| Variable | Example | Description | +| Variable | Example | Descrizione | | -------- | ------------ | ------------------------------------------------------------------------------------------- | | `style` | `"red bold"` | Mirrors the value of option `style_root` when root is logged in and `style_user` otherwise. | | `user` | `"matchai"` | The currently logged-in user ID. | @@ -2864,7 +2936,7 @@ The `vagrant` module shows the currently installed version of [Vagrant](https:// ### Options -| Option | Default | Description | +| Opzione | Default | Descrizione | | ------------------- | ------------------------------------ | ------------------------------------------------------------------------- | | `format` | `"via [$symbol($version )]($style)"` | The format for the module. | | `version_format` | `"v${raw}"` | The version format. Available vars are `raw`, `major`, `minor`, & `patch` | @@ -2877,7 +2949,7 @@ The `vagrant` module shows the currently installed version of [Vagrant](https:// ### Variables -| Variable | Example | Description | +| Variable | Example | Descrizione | | --------- | ---------------- | ------------------------------------ | | version | `Vagrant 2.2.10` | The version of `Vagrant` | | symbol | | Mirrors the value of option `symbol` | @@ -2894,15 +2966,15 @@ The `vagrant` module shows the currently installed version of [Vagrant](https:// format = "via [⍱ $version](bold white) " ``` -## VLang +## V -The `vlang` module shows you your currently installed version of V. By default the module will be shown if any of the following conditions are met: +The `vlang` module shows you your currently installed version of [V](https://vlang.io/). By default the module will be shown if any of the following conditions are met: - The current directory contains a file with `.v` extension - The current directory contains a `v.mod`, `vpkg.json` or `.vpkg-lock.json` file ### Options -| Option | Default | Description | +| Opzione | Default | Descrizione | | ------------------- | -------------------------------------------- | ------------------------------------------------------------------------- | | `format` | `"via [$symbol($version )]($style)"` | The format for the module. | | `version_format` | `"v${raw}"` | The version format. Available vars are `raw`, `major`, `minor`, & `patch` | @@ -2915,7 +2987,7 @@ The `vlang` module shows you your currently installed version of V. By default t ### Variables -| Variable | Example | Description | +| Variable | Example | Descrizione | | --------- | ------- | ------------------------------------ | | version | `v0.2` | The version of `v` | | symbol | | Mirrors the value of option `symbol` | @@ -2925,7 +2997,7 @@ The `vlang` module shows you your currently installed version of V. By default t ```toml # ~/.config/starship.toml -[v] +[vlang] format = "via [V $version](blue bold) " ``` @@ -2935,7 +3007,7 @@ The `vcsh` module displays the current active [VCSH](https://github.com/RichiH/v ### Options -| Option | Default | Description | +| Opzione | Default | Descrizione | | ---------- | -------------------------------- | ------------------------------------------------------ | | `symbol` | | The symbol used before displaying the repository name. | | `style` | `"bold yellow"` | The style for the module. | @@ -2944,7 +3016,7 @@ The `vcsh` module displays the current active [VCSH](https://github.com/RichiH/v ### Variables -| Variable | Example | Description | +| Variable | Example | Descrizione | | --------- | ------------------------------------------- | ------------------------------------ | | repo | `dotfiles` if in a VCSH repo named dotfiles | The active repository name | | symbol | | Mirrors the value of option `symbol` | @@ -2969,7 +3041,7 @@ By default the the `zig` module shows the currently installed version of [Zig](h ### Options -| Option | Default | Description | +| Opzione | Default | Descrizione | | ------------------- | ------------------------------------ | ------------------------------------------------------------------------- | | `format` | `"via [$symbol($version )]($style)"` | The format for the module. | | `version_format` | `"v${raw}"` | The version format. Available vars are `raw`, `major`, `minor`, & `patch` | @@ -2982,7 +3054,7 @@ By default the the `zig` module shows the currently installed version of [Zig](h ### Variables -| Variable | Example | Description | +| Variable | Example | Descrizione | | --------- | -------- | ------------------------------------ | | version | `v0.6.0` | The version of `zig` | | symbol | | Mirrors the value of option `symbol` | @@ -3031,7 +3103,7 @@ The order in which custom modules are shown can be individually set by including ### Options -| Option | Default | Description | +| Opzione | Default | Descrizione | | ------------- | ------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | | `command` | | The command whose output should be printed. The command will be passed on stdin to the shell. | | `when` | | A shell command used as a condition to show the module. The module will be shown if the command returns a `0` status code. | @@ -3048,7 +3120,7 @@ The order in which custom modules are shown can be individually set by including ### Variables -| Variable | Description | +| Variable | Descrizione | | --------- | -------------------------------------- | | output | The output of shell command in `shell` | | symbol | Mirrors the value of option `symbol` | diff --git a/docs/it-IT/guide/README.md b/docs/it-IT/guide/README.md index 28a8172e..36041279 100644 --- a/docs/it-IT/guide/README.md +++ b/docs/it-IT/guide/README.md @@ -48,30 +48,6 @@ height="20" src="https://raw.githubusercontent.com/starship/starship/master/media/flag-us.png" alt="Inglese" - /> -   - 日本語 -   - 繁體中文 -   - Russo   -   - 简体中文   +   + Giapponese +   + Portoghese del Brasile +   + Russo   Tiếng Việt +   + Cinese semplificato +   + Cinese tradizionale

@@ -160,8 +168,8 @@ ```sh sh -c "$(curl -fsSL https://starship.rs/install.sh)" ``` - Per aggiornare Starship stesso, riavviare lo script sopra. Sostituirà la versione corrente senza toccare la configurazione di Starship. + Per aggiornare Starship stesso, riavviare lo script sopra. Sostituirà la versione corrente senza toccare la configurazione di Starship. **Nota** - I valori predefiniti dello script di installazione possono essere sovrascritti, vedi la guida integrata. @@ -266,7 +274,7 @@ #### Xonsh - Add the following to the end of `~/.xonshrc`: + Aggiungi quanto segue alla fine di `~/.xonshrc`: ```sh # ~/.xonshrc @@ -277,7 +285,7 @@ #### Nushell - **Warning** This will change in the future. Only nu version v0.33 or higher is supported. Add the following to your nu config file. You can check the location of this file by running `config path` in nu. + **Warning** This will change in the future. È supportata solo la versione v0.33 o superiore. Add the following to your nu config file. Puoi controllare la posizione di questo file eseguendo `percorso di configurazione` in nu. ```toml startup = [ diff --git a/docs/it-IT/installing/README.md b/docs/it-IT/installing/README.md index a1bcb0dd..ebd18d9a 100644 --- a/docs/it-IT/installing/README.md +++ b/docs/it-IT/installing/README.md @@ -1,21 +1,21 @@ -# 🚀 Advanced Installation +# 🚀 Installazione Avanzata -To install starship, you need to do two things: +Per installare starship, è necessario fare due cose: -1. Get the **starship** binary onto your computer -1. Tell your shell to use the starship binary as its prompt by modifying its init scripts +1. Ottieni il binario **starship** sul tuo computer +1. Indica alla tua shell di usare il binario starship come prompt modificando i suoi script in init -For most users, the instructions on [the main page](/guide/#🚀-installation) will work great. However, for some more specialized platforms, different instructions are needed. +Per la maggior parte degli utenti, le istruzioni nella [pagina principale](/guide/#🚀-installation) funzioneranno bene. Tuttavia, per alcune piattaforme più specializzate, sono necessarie istruzioni diverse. -There are so many platforms out there that they didn't fit into the main README.md file, so here are some installation instructions for other platforms from the community. Is yours not here? Please do add it here if you figure it out! +Ci sono così tante piattaforme là fuori che non sono tutte inserite nel README.md principale, così ecco alcune istruzioni di installazione per altre piattaforme della community. La tua non c'è? Per favore, aggiungilo qui se capisci che manca! ## [Chocolatey](https://chocolatey.org) ### Prerequisiti -Head over to the [Chocolatey installation page](https://chocolatey.org/install) and follow the instructions to install Chocolatey. +Vai alla pagina di installazione [Chocolatey](https://chocolatey.org/install) e segui le istruzioni per installare Chocolatey. -### Installation +### Installazione ```powershell choco install starship @@ -29,7 +29,7 @@ choco install starship pkg install getconf ``` -### Installation +### Installazione ```sh sh -c "$(curl -fsSL https://starship.rs/install.sh)" -- --bin-dir /data/data/com.termux/files/usr/bin @@ -37,17 +37,17 @@ sh -c "$(curl -fsSL https://starship.rs/install.sh)" -- --bin-dir /data/data/com ## [Nix](https://nixos.wiki/wiki/Nix) -### Getting the Binary +### Ottenere il Binario -#### Imperatively +#### Imperativo ```sh nix-env -iA nixos.starship ``` -#### Declarative, single user, via [home-manager](https://github.com/nix-community/home-manager) +#### Dichiarativo, singolo utente, tramite [home-manager](https://github.com/nix-community/home-manager) -Enable the `programs.starship` module in your `home.nix` file, and add your settings +Abilita il modulo `programs.starship` nel tuo file `home.nix` e aggiungi le tue impostazioni ```nix { @@ -69,15 +69,15 @@ Enable the `programs.starship` module in your `home.nix` file, and add your sett } ``` -then run +poi eseguire ```sh home-manager switch ``` -#### Declarative, system-wide, with NixOS +#### Dichiarativa, di sistema, con NixOS -Add `pkgs.starship` to `environment.systemPackages` in your `configuration.nix`, then run +Aggiungi `pkgs.starship` a `environment.systemPackages` in `configuration.nix`, poi esegui ```sh sudo nixos-rebuild switch diff --git a/docs/it-IT/presets/README.md b/docs/it-IT/presets/README.md index 21a8d714..ca8e990c 100644 --- a/docs/it-IT/presets/README.md +++ b/docs/it-IT/presets/README.md @@ -112,6 +112,9 @@ format = '\[[$symbol($version)]($style)\]' [cmd_duration] format = '\[[⏱ $duration ]($style)\]' +[cobol] +format = '\[[$symbol($version)]($style)\]' + [conda] format = '\[[$symbol$environment]($style)\]' @@ -272,6 +275,9 @@ deleted = "x" [aws] symbol = "aws " +[cobol] +symbol = "cobol " + [conda] symbol = "conda " @@ -375,6 +381,9 @@ This preset hides the version of language runtimes. If you work in containers or [cmake] format = "via [$symbol]($style)" +[cobol] +format = "via [$symbol]($style)" + [crystal] format = "via [$symbol]($style)" diff --git a/docs/ja-JP/advanced-config/README.md b/docs/ja-JP/advanced-config/README.md index cb6ea0c5..d84175d4 100644 --- a/docs/ja-JP/advanced-config/README.md +++ b/docs/ja-JP/advanced-config/README.md @@ -68,9 +68,36 @@ function set_win_title(){ starship_precmd_user_func="set_win_title" ``` +## Enable Right Prompt + +Some shells support a right prompt which renders on the same line as the input. Starship can set the content of the right prompt using the `right_format` option. Any module that can be used in `format` is also supported in `right_format`. The `$all` variable will only contain modules not explicitly used in either `format` or `right_format`. + +Note: The right prompt is a single line following the input location. To right align modules above the input line in a multi-line prompt, see the [fill module](/config/#fill). + +`right_format` is currently supported for the following shells: elvish, fish, zsh. + +### 設定例 + +```toml +# ~/.config/starship.toml + +# A minimal left prompt +format = """$character""" + +# move the rest of the prompt to the right +right_format = """$all""" +``` + +Produces a prompt like the following: + +``` +▶ starship on  rprompt [!] is 📦 v0.57.0 via 🦀 v1.54.0 took 17s +``` + + ## スタイルの設定 -スタイル文字列は空白で区切られた単語のリストです。 大文字小文字を区別しません(例えば、 `bold` と`BoLd` は同じだとみなされます)。 それぞれ以下のいずれか一つが該当します。 +Style strings are a list of words, separated by whitespace. The words are not case sensitive (i.e. `bold` and `BoLd` are considered the same string). Each word can be one of the following: - `bold` - `italic` @@ -82,14 +109,14 @@ starship_precmd_user_func="set_win_title" - `` - `none` -ここで、 `` は色を指定します(以下で述べます)。 現在 `fg:` と `` は同様の動作ですが、将来変更される可能性があります。 `inverted` は背景と前景の色を交換します。 文字列中の単語の順序は関係ありません。 +where `` is a color specifier (discussed below). `fg:` and `` currently do the same thing, though this may change in the future. `inverted` swaps the background and foreground colors. The order of words in the string does not matter. -`none` トークンは、文字列中の`bg:` 指定子の一部でない場合、他のすべてのトークンをオーバーライドします。そのため、たとえば、`fg:red none fg:blue` と指定した場合、スタイルなしの文字列が作られます。 `bg:none` は背景色をデフォルトの色にセットするので、`fg:red bg:none` は `red` や `fg:red` と同じ意味になり、`bg:green fg:red bg:none` も `fg:red` や `red` と同じ意味になります。 将来 `none` を他の単語と一緒に使用することはエラーになるかもしれません。 +The `none` token overrides all other tokens in a string if it is not part of a `bg:` specifier, so that e.g. `fg:red none fg:blue` will still create a string with no styling. `bg:none` sets the background to the default color so `fg:red bg:none` is equivalent to `red` or `fg:red` and `bg:green fg:red bg:none` is also equivalent to `fg:red` or `red`. It may become an error to use `none` in conjunction with other tokens in the future. -色は以下のいずれか1つを指定できます。 +A color specifier can be one of the following: - 標準的なターミナルカラーの `black`、 `red`、 `green`、 `blue`、 `yellow`、 `purple`、 `cyan`、 `white`。 必要に応じて、より明るい色を得るために `bright-` を前につけることができます。(例えば、 `bright-white` ) - `#` に続く16進数。 [RGB の16進数カラーコード](https://www.w3schools.com/colors/colors_hexadecimal.asp)を表します。 - 0-255 までの間の数字。 [8-bit ANSI カラーコード](https://i.stack.imgur.com/KTSQa.png) を表します。 -複数の色が文字色/背景色に指定された際には、最後の指定が優先して選ばれます。 +If multiple colors are specified for foreground/background, the last one in the string will take priority. diff --git a/docs/ja-JP/config/README.md b/docs/ja-JP/config/README.md index 6bc97ec4..a1de5607 100644 --- a/docs/ja-JP/config/README.md +++ b/docs/ja-JP/config/README.md @@ -75,7 +75,7 @@ $ENV:STARSHIP_CACHE = "$HOME\AppData\Local\Temp" `[]`で囲まれている最初の部分は、 [フォーマット文字列](#format-strings) です。 テキスト、変数、または入れ子になったテキストグループを追加できます。 -2 番目の部分では、 `()`で囲まれている [スタイル文字列](#style-strings) です。 これは最初のパートのスタイルを使用することができます。 +2 番目の部分では、 `()`で囲まれている [スタイル文字列](#style-strings) です。 This can be used to style the first part. 例: @@ -142,12 +142,14 @@ format = ''' ### オプション -| オプション | デフォルト | 説明 | -| ----------------- | ------------------------------ | ------------------------------------------------- | -| `format` | [link](#default-prompt-format) | プロンプトの形式を設定します。 | -| `scan_timeout` | `30` | ファイルをスキャンする際のタイムアウト時間 (milliseconds) です。 | -| `command_timeout` | `500` | Starshipによって実行されたコマンドのタイムアウト時間 (milliseconds) です。 | -| `add_newline` | `true` | シェルプロンプトの間に空行を挿入します。 | +| オプション | デフォルト | 説明 | +| ----------------- | ------------------------------ | ---------------------------------------------------------------- | +| `format` | [link](#default-prompt-format) | プロンプトの形式を設定します。 | +| `right_format` | `""` | See [Enable Right Prompt](/advanced-config/#enable-right-prompt) | +| `scan_timeout` | `30` | Timeout for starship to scan files (in milliseconds). | +| `command_timeout` | `500` | Timeout for commands executed by starship (in milliseconds). | +| `add_newline` | `true` | Inserts blank line between shell prompts. | + ### 設定例 @@ -180,6 +182,7 @@ format = """ $username\ $hostname\ $shlvl\ +$singularity\ $kubernetes\ $directory\ $vcsh\ @@ -192,6 +195,7 @@ $hg_branch\ $docker_context\ $package\ $cmake\ +$cobol\ $dart\ $deno\ $dotnet\ @@ -203,6 +207,7 @@ $helm\ $java\ $julia\ $kotlin\ +$lua\ $nim\ $nodejs\ $ocaml\ @@ -210,6 +215,7 @@ $perl\ $php\ $purescript\ $python\ +$rlang\ $red\ $ruby\ $rust\ @@ -230,7 +236,6 @@ $crystal\ $custom\ $cmd_duration\ $line_break\ -$lua\ $jobs\ $battery\ $time\ @@ -239,13 +244,20 @@ $shell\ $character""" ``` +If you just want to extend the default format, you can use `$all`; modules you explicitly add to the format will not be duplicated. Eg. + +```toml +# Move the directory to the second line +format="$all$directory$character" +``` + ## AWS -`aws` モジュールは現在のAWSプロファイルが表示されます。 これは `~/.aws/config` に記述されている `AWS_REGION`, `AWS_DEFAULT_REGION`, and `AWS_PROFILE` 環境変数に基づいています。 This module also shows an expiration timer when using temporary credentials. +The `aws` module shows the current AWS region and profile. This is based on `AWS_REGION`, `AWS_DEFAULT_REGION`, and `AWS_PROFILE` env var with `~/.aws/config` file. This module also shows an expiration timer when using temporary credentials. When using [aws-vault](https://github.com/99designs/aws-vault) the profile is read from the `AWS_VAULT` env var and the credentials expiration date is read from the `AWS_SESSION_EXPIRATION` env var. -[awsu](https://github.com/kreuzwerker/awsu) を使う場合、そのプロファイルは環境変数 `AWSU_PROFILE` から読まれます。 +When using [awsu](https://github.com/kreuzwerker/awsu) the profile is read from the `AWSU_PROFILE` env var. When using [AWSume](https://awsu.me) the profile is read from the `AWSUME_PROFILE` env var and the credentials expiration date is read from the `AWSUME_EXPIRATION` env var. @@ -270,7 +282,7 @@ When using [AWSume](https://awsu.me) the profile is read from the `AWSUME_PROFIL | symbol | | オプション `記号` の値をミラーする | | style\* | | オプション `style` の値をミラーする | -\*: この変数はスタイル文字列の一部としてのみ使用できます +\*: This variable can only be used as a part of a style string ### 設定例 @@ -315,7 +327,7 @@ symbol = "🅰 " ## バッテリー -`battery`モジュールは、デバイスのバッテリー残量と現在の充電状態を示します。 モジュールは、デバイスのバッテリー残量が10%未満の場合にのみ表示されます。 +The `battery` module shows how charged the device's battery is and its current charging status. The module is only visible when the device's battery is below 10%. ### オプション @@ -343,7 +355,7 @@ discharging_symbol = "💀 " ### バッテリーの表示 -`display`オプションを使用して、バッテリーインジケーターを表示するタイミング(threshold)、どのシンボルが使われるか(symbol) と外観(style)を定義します。 `display` が提供されない場合、 デフォルトは次のとおりです。 +The `display` configuration option is used to define when the battery indicator should be shown (threshold), which symbol would be used (symbol), and what it would like (style). If no `display` is provided. デフォルトは次のとおりです。 ```toml [[battery.display]] @@ -351,11 +363,11 @@ threshold = 10 style = "bold red" ``` -`charging_symbol`と`discharging_symbol`オプションのデフォルト値はそれぞれ`battery`の `charging_symbol`と`discharging_symbol`になります。 +The default value for the `charging_symbol` and `discharging_symbol` option is respectively the value of `battery`'s `charging_symbol` and `discharging_symbol` option. #### オプション -`display`オプションは、次の表の通りです。 +The `display` option is an array of the following table. | オプション | デフォルト | 説明 | | -------------------- | ---------- | -------------------------------------------------------------------------------------- | @@ -367,29 +379,29 @@ style = "bold red" #### 設定例 ```toml -[[battery.display]] # "bold red"のスタイルとバッテリー残量が0%~10%の放電時のシンボル +[[battery.display]] # "bold red" style and discharging_symbol when capacity is between 0% and 10% threshold = 10 style = "bold red" -[[battery.display]] # "bold yellow"のスタイルとバッテリー残量が10%~30%の放電時の💦シンボル +[[battery.display]] # "bold yellow" style and 💦 symbol when capacity is between 10% and 30% threshold = 30 style = "bold yellow" discharging_symbol = 💦 -# 残量が30%以上の場合バッテリーインジケータは表示されません +# when capacity is over 30%, the battery indicator will not be displayed ``` ## 文字 -`character`モジュールは、端末でテキストが入力される場所の横に文字(通常は矢印)を表示します。 +The `character` module shows a character (usually an arrow) beside where the text is entered in your terminal. -文字は、最後のコマンドが成功したかどうかを示します。 表し方は下記の2つです。 +The character will tell you whether the last command was successful or not. It can do this in two ways: - 色の変更 (`赤`/`緑`) - プロンプトの表示の変更 (`❯`/`✖`) -デフォルトでは、色だけが変更されます。 形も変えてみたい場合は[このサンプル](#with-custom-error-shape)も参考にしてください。 +By default it only changes color. If you also want to change its shape take a look at [this example](#with-custom-error-shape). ::: warning @@ -399,7 +411,7 @@ discharging_symbol = 💦 ::: warning -`vicmd_symbol`はfishとzshのみでサポートされています。 +`vicmd_symbol` is only supported in fish and zsh. ::: @@ -452,7 +464,7 @@ vicmd_symbol = "[V](bold green) " ## CMake -`cmake`モジュールは、現在インストールされている[Cmake](https://cmake.org/)のバージョンを表示します。 デフォルトでは次のいずれかの条件が満たされると、モジュールがアクティブになります。 +The `cmake` module shows the currently installed version of [CMake](https://cmake.org/). By default the module will be activated if any of the following conditions are met: - カレントディレクトリに `CMakeLists.txt` ファイルが含まれている - カレントディレクトリに `CMakeCache.txt` ファイルが含まれている @@ -478,46 +490,76 @@ vicmd_symbol = "[V](bold green) " | symbol | | オプション `記号` の値をミラーする | | style\* | | オプション `style` の値をミラーする | -\*: この変数はスタイル文字列の一部としてのみ使用できます +\*: This variable can only be used as a part of a style string -## コマンド実行時間 +## COBOL / GNUCOBOL -`cmd_duration`モジュールは、最後のコマンドの実行にかかった時間を示します。 モジュールが表示されるのは、コマンドが2秒以上かかった場合、または`min_time`値が存在する場合のみです。 +The `cobol` module shows the currently installed version of COBOL. By default, the module will be shown if any of the following conditions are met: -::: warning BashでDEBUGトラップをhookしない - -`bash`でStarshipを実行している場合、 `eval $(starship init $0)`実行した後に`DEBUG`トラップをフックしないでください。そうしないと、このモジュールが**おそらくですが**壊れます。 - -::: - -preexecのような機能を必要とするBashユーザーは、 [rcalorasのbash_preexecフレームワーク](https://github.com/rcaloras/bash-preexec)を使用できます。 `eval $(starship init $0)` を実行する前に、`preexec_functions`、および`precmd_functions`定義するだけで、通常どおり続行します。 +- The current directory contains any files ending in `.cob` or `.COB` +- The current directory contains any files ending in `.cbl` or `.CBL` ### オプション -| オプション | デフォルト | 説明 | -| -------------------- | ----------------------------- | --------------------------- | -| `min_time` | `2_000` | 実行時間を表示する最短期間(ミリ秒単位)です。 | -| `show_milliseconds` | `false` | 実行時間の秒に加えてミリ秒を表示します。 | -| `format` | `"took [$duration]($style) "` | moduleのフォーマットです。 | -| `style` | `"bold yellow"` | モジュールのスタイルです。 | -| `disabled` | `false` | `cmd_duration`モジュールを無効にします。 | -| `show_notifications` | `false` | コマンドが完了したらデスクトップ通知を表示します。 | -| `min_time_to_notify` | `45_000` | 通知を持続する最短期間(ミリ秒単位) | +| オプション | デフォルト | 説明 | +| ------------------- | ------------------------------------ | ------------------------------------------------------- | +| `symbol` | `"⚙️ "` | The symbol used before displaying the version of COBOL. | +| `format` | `"via [$symbol($version )]($style)"` | moduleのフォーマットです。 | +| `version_format` | `"v${raw}"` | バージョンのフォーマット。 使用可能な変数は`raw`、`major`、`minor`と`patch`です。 | +| `style` | `"bold blue"` | モジュールのスタイルです。 | +| `detect_extensions` | `["cbl", "cob", "CBL", "COB"]` | どの拡張子がこのモジュールをアクティブにするか | +| `detect_files` | `[]` | どのファイル名がこのモジュールをアクティブにするか | +| `detect_folders` | `[]` | どのフォルダーがこのモジュールをアクティブにするか | +| `disabled` | `false` | Disables the `cobol` module. | + +### 変数 + +| 変数 | 設定例 | 説明 | +| --------- | ---------- | ---------------------- | +| version | `v3.1.2.0` | The version of `cobol` | +| symbol | | オプション `記号` の値をミラーする | +| style\* | | オプション `style` の値をミラーする | + +\*: This variable can only be used as a part of a style string + +## Command Duration + +The `cmd_duration` module shows how long the last command took to execute. The module will be shown only if the command took longer than two seconds, or the `min_time` config value, if it exists. + +::: warning Do not hook the DEBUG trap in Bash + +If you are running Starship in `bash`, do not hook the `DEBUG` trap after running `eval $(starship init $0)`, or this module **will** break. + +::: + +Bash users who need preexec-like functionality can use [rcaloras's bash_preexec framework](https://github.com/rcaloras/bash-preexec). Simply define the arrays `preexec_functions` and `precmd_functions` before running `eval $(starship init $0)`, and then proceed as normal. + +### オプション + +| オプション | デフォルト | 説明 | +| -------------------- | ----------------------------- | ---------------------------------------------------------- | +| `min_time` | `2_000` | Shortest duration to show time for (in milliseconds). | +| `show_milliseconds` | `false` | Show milliseconds in addition to seconds for the duration. | +| `format` | `"took [$duration]($style) "` | moduleのフォーマットです。 | +| `style` | `"bold yellow"` | モジュールのスタイルです。 | +| `disabled` | `false` | Disables the `cmd_duration` module. | +| `show_notifications` | `false` | Show desktop notifications when command completes. | +| `min_time_to_notify` | `45_000` | Shortest duration for notification (in milliseconds). | ::: tip -デスクトップ通知を表示するには、 `rust-notify` をサポートしているstarshipをビルドする必要があります。 `show_notifications` が `true` となっている状態で `STARSHIP_LOG=debug starship module cmd_duration -d 60000` を実行することにより、starshipが通知をサポートしているかを確認することができます。 +Showing desktop notifications requires starship to be built with `rust-notify` support. You check if your starship supports notifications by running `STARSHIP_LOG=debug starship module cmd_duration -d 60000` when `show_notifications` is set to `true`. ::: ### 変数 -| 変数 | 設定例 | 説明 | -| --------- | -------- | ---------------------- | -| duration | `16m40s` | コマンドの実行時間 | -| style\* | | オプション `style` の値をミラーする | +| 変数 | 設定例 | 説明 | +| --------- | -------- | --------------------------------------- | +| duration | `16m40s` | The time it took to execute the command | +| style\* | | オプション `style` の値をミラーする | -\*: この変数はスタイル文字列の一部としてのみ使用できます +\*: This variable can only be used as a part of a style string ### 設定例 @@ -531,34 +573,34 @@ format = "underwent [$duration](bold yellow)" ## Conda -`$CONDA_DEFAULT_ENV`が設定されている場合、`conda`モジュールは現在のcondaの環境を表示します。 +The `conda` module shows the current [Conda](https://docs.conda.io/en/latest/) environment, if `$CONDA_DEFAULT_ENV` is set. ::: tip -Note: これはconda自身の プロンプト修飾子 を抑制しません。`conda config --set changeps1 False` で実行することができます。 +This does not suppress conda's own prompt modifier, you may want to run `conda config --set changeps1 False`. ::: ### オプション -| オプション | デフォルト | 説明 | -| ------------------- | -------------------------------------- | ---------------------------------------------------------------------------------------------------------------- | -| `truncation_length` | `1` | 環境が`conda create -p [path]`で作成された場合、環境パスが切り捨てられるディレクトリ数。 `0`は切り捨てがないことを意味します。 [`directory`](#directory)もご覧ください。 | -| `symbol` | `"🅒 "` | 環境名の直前に使用されるシンボルです。 | -| `style` | `"bold green"` | モジュールのスタイルです。 | -| `format` | `"via [$symbol$environment]($style) "` | moduleのフォーマットです。 | -| `ignore_base` | `true` | アクティブになった時、環境`base`を無視します。 | -| `disabled` | `false` | `conda`モジュールを無効にします。 | +| オプション | デフォルト | 説明 | +| ------------------- | -------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | +| `truncation_length` | `1` | The number of directories the environment path should be truncated to, if the environment was created via `conda create -p [path]`. `0` means no truncation. Also see the [`directory`](#directory) module. | +| `symbol` | `"🅒 "` | The symbol used before the environment name. | +| `style` | `"bold green"` | モジュールのスタイルです。 | +| `format` | `"via [$symbol$environment]($style) "` | moduleのフォーマットです。 | +| `ignore_base` | `true` | Ignores `base` environment when activated. | +| `disabled` | `false` | Disables the `conda` module. | ### 変数 -| 変数 | 設定例 | 説明 | -| ----------- | ------------ | ---------------------- | -| environment | `astronauts` | 現在の conda 環境 | -| symbol | | オプション `記号` の値をミラーする | -| style\* | | オプション `style` の値をミラーする | +| 変数 | 設定例 | 説明 | +| ----------- | ------------ | ----------------------------- | +| environment | `astronauts` | The current conda environment | +| symbol | | オプション `記号` の値をミラーする | +| style\* | | オプション `style` の値をミラーする | -\*: この変数はスタイル文字列の一部としてのみ使用できます +\*: This variable can only be used as a part of a style string ### 設定例 @@ -571,33 +613,33 @@ format = "[$symbol$environment](dimmed green) " ## Crystal -`crystal`モジュールは、現在インストールされている[Crystal](https://crystal-lang.org/)のバージョンを表示します。 デフォルトでは次の条件のいずれかが満たされると、モジュールが表示されます。 +The `crystal` module shows the currently installed version of [Crystal](https://crystal-lang.org/). デフォルトでは次の条件のいずれかが満たされると、モジュールが表示されます。 -- カレントディレクトリに`shard.yml`ファイルが含まれている -- カレントディレクトリに`.cr`の拡張子のファイルが含まれている +- The current directory contains a `shard.yml` file +- The current directory contains a `.cr` file ### オプション -| オプション | デフォルト | 説明 | -| ------------------- | ------------------------------------ | ------------------------------------------------------ | -| `symbol` | `"🔮 "` | Crystalのバージョンを表示する前に使用される記号です。 | -| `format` | `"via [$symbol($version )]($style)"` | moduleのフォーマットです。 | -| `version_format` | `"v${raw}"` | バージョンのフォーマット。 使用可能な変数は`raw`、`major`、`minor`と`patch`です。 | -| `style` | `"bold red"` | モジュールのスタイルです。 | -| `detect_extensions` | `["cr"]` | どの拡張子がこのモジュールをアクティブにするか | -| `detect_files` | `["shard.yml"]` | どのファイル名がこのモジュールをアクティブにするか | -| `detect_folders` | `[]` | どのフォルダーがこのモジュールをアクティブにするか | -| `disabled` | `false` | `crystal`モジュールを無効にします。 | +| オプション | デフォルト | 説明 | +| ------------------- | ------------------------------------ | --------------------------------------------------------- | +| `symbol` | `"🔮 "` | The symbol used before displaying the version of crystal. | +| `format` | `"via [$symbol($version )]($style)"` | moduleのフォーマットです。 | +| `version_format` | `"v${raw}"` | バージョンのフォーマット。 使用可能な変数は`raw`、`major`、`minor`と`patch`です。 | +| `style` | `"bold red"` | モジュールのスタイルです。 | +| `detect_extensions` | `["cr"]` | どの拡張子がこのモジュールをアクティブにするか | +| `detect_files` | `["shard.yml"]` | どのファイル名がこのモジュールをアクティブにするか | +| `detect_folders` | `[]` | どのフォルダーがこのモジュールをアクティブにするか | +| `disabled` | `false` | Disables the `crystal` module. | ### 変数 -| 変数 | 設定例 | 説明 | -| --------- | --------- | ---------------------- | -| version | `v0.32.1` | `crystal` のバージョン | -| symbol | | オプション `記号` の値をミラーする | -| style\* | | オプション `style` の値をミラーする | +| 変数 | 設定例 | 説明 | +| --------- | --------- | ------------------------ | +| version | `v0.32.1` | The version of `crystal` | +| symbol | | オプション `記号` の値をミラーする | +| style\* | | オプション `style` の値をミラーする | -\*: この変数はスタイル文字列の一部としてのみ使用できます +\*: This variable can only be used as a part of a style string ### 設定例 @@ -610,34 +652,34 @@ format = "via [✨ $version](bold blue) " ## Dart -`dart`モジュールは、現在インストールされている[Dart](https://dart.dev/)のバージョンを表示します。 デフォルトでは次の条件のいずれかが満たされると、モジュールが表示されます。 +The `dart` module shows the currently installed version of [Dart](https://dart.dev/). デフォルトでは次の条件のいずれかが満たされると、モジュールが表示されます。 -- カレントディレクトリに`.dart`の拡張子のファイルが含まれている -- カレントディレクトリに`.dart_tool`ディレクトリが含まれている -- カレントディレクトリに`pubspec.yaml`, `pubspec.yml`,もしくは`pubspec.lock`が含まれている +- The current directory contains a file with `.dart` extension +- The current directory contains a `.dart_tool` directory +- The current directory contains a `pubspec.yaml`, `pubspec.yml` or `pubspec.lock` file ### オプション | オプション | デフォルト | 説明 | | ------------------- | ------------------------------------------------- | ------------------------------------------------------ | -| `format` | `"via [$symbol($version )]($style)"` | moduleのフォーマットです。 | +| `format` | `"via [$symbol($version )]($style)"` | module のフォーマットです。 | | `version_format` | `"v${raw}"` | バージョンのフォーマット。 使用可能な変数は`raw`、`major`、`minor`と`patch`です。 | -| `symbol` | `"🎯 "` | Dartのシンボルを表すフォーマット文字列 | +| `symbol` | `"🎯 "` | A format string representing the symbol of Dart | | `detect_extensions` | `["dart"]` | どの拡張子がこのモジュールをアクティブにするか | | `detect_files` | `["pubspec.yaml", "pubspec.yml", "pubspec.lock"]` | どのファイル名がこのモジュールをアクティブにするか | | `detect_folders` | `[".dart_tool"]` | どのフォルダーがこのモジュールをアクティブにするか | | `style` | `"bold blue"` | モジュールのスタイルです。 | -| `disabled` | `false` | `dart`モジュールを無効にします。 | +| `disabled` | `false` | Disables the `dart` module. | ### 変数 | 変数 | 設定例 | 説明 | | --------- | -------- | ---------------------- | -| version | `v2.8.4` | `dart` のバージョン | +| version | `v2.8.4` | The version of `dart` | | symbol | | オプション `記号` の値をミラーする | | style\* | | オプション `style` の値をミラーする | -\*: この変数はスタイル文字列の一部としてのみ使用できます +\*: This variable can only be used as a part of a style string ### 設定例 @@ -650,27 +692,27 @@ format = "via [🔰 $version](bold red) " ## Deno -`deno`モジュールは、現在インストールされている[Deno](https://deno.land/)のバージョンを表示します。 デフォルトでは次の条件のいずれかが満たされると、モジュールが表示されます。 -- カレントディレクトリに`mod.ts`、`mod.js`、`deps.ts`か`deps.js`が含まれている +The `deno` module shows you your currently installed version of [Deno](https://deno.land/). デフォルトでは次の条件のいずれかが満たされると、モジュールが表示されます。 +- The current directory contains a `mod.ts`, `mod.js`, `deps.ts` or `deps.js` file ### オプション | オプション | デフォルト | 説明 | | ------------------- | -------------------------------------------- | ------------------------------------------------------ | -| `format` | `"via [$symbol($version )]($style)"` | module のフォーマットです。 | +| `format` | `"via [$symbol($version )]($style)"` | moduleのフォーマットです。 | | `version_format` | `"v${raw}"` | バージョンのフォーマット。 使用可能な変数は`raw`、`major`、`minor`と`patch`です。 | -| `symbol` | `"🦕 "` | Dart のシンボルを表すフォーマット文字列 | +| `symbol` | `"🦕 "` | A format string representing the symbol of Deno | | `detect_extensions` | `[]` | どの拡張子がこのモジュールをアクティブにするか | | `detect_files` | `["mod.ts", "mod.js", "deps.ts", "deps.js"]` | どのファイル名がこのモジュールをアクティブにするか | | `detect_folders` | `[]` | どのフォルダーがこのモジュールをアクティブにするか | | `style` | `"green bold"` | モジュールのスタイルです。 | -| `disabled` | `false` | `deno`モジュールを無効化します。 | +| `disabled` | `false` | Disables the `deno` module. | ### 変数 | 変数 | 設定例 | 説明 | | --------- | -------- | ---------------------- | -| version | `v1.8.3` | `deno`のバージョン | +| version | `v1.8.3` | The version of `deno` | | symbol | | オプション `記号` の値をミラーする | | style\* | | オプション `style` の値をミラーする | @@ -685,33 +727,33 @@ format = "via [🦕 $version](green bold) " ## Directory -`directory`モジュールには、現在のディレクトリへのパスが表示され、3つの親フォルダは切り捨てられます。 ディレクトリは、現在のgitリポジトリであるとルートとなります。 +The `directory` module shows the path to your current directory, truncated to three parent folders. Your directory will also be truncated to the root of the git repo that you're currently in. -fishスタイルのpwdオプションを使用すると、切り捨てられたパスを非表示にする代わりに、オプションで有効にした番号に基づいて各ディレクトリの短縮名が表示されます。 +When using the fish style pwd option, instead of hiding the path that is truncated, you will see a shortened name of each directory based on the number you enable for the option. -例として、`~/Dev/Nix/nixpkgs/pkgs`で、`nixpkgs`がリポジトリルートであり、オプションが`1`に設定されている場合を挙げます。 以前は`nixpkgs/pkgs`でしたが、`~/D/N/nixpkgs/pkgs`が表示されます。 +For example, given `~/Dev/Nix/nixpkgs/pkgs` where `nixpkgs` is the repo root, and the option set to `1`. You will now see `~/D/N/nixpkgs/pkgs`, whereas before it would have been `nixpkgs/pkgs`. ### オプション -| オプション | デフォルト | 説明 | -| ------------------- | -------------------------------------------------- | ----------------------------------------------------- | -| `truncation_length` | `3` | 現在のディレクトリを切り捨てる親フォルダーの数です。 | -| `truncate_to_repo` | `true` | 現在いるgitリポジトリのルートに切り捨てるかどうかです。 | -| `format` | `"[$path]($style)[$read_only]($read_only_style) "` | moduleのフォーマットです。 | -| `style` | `"bold cyan"` | モジュールのスタイルです。 | -| `disabled` | `false` | `directory`モジュールを無効にします。 | -| `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: "…/" | -| `home_symbol` | `"~"` | The symbol indicating home directory. | +| オプション | デフォルト | 説明 | +| ------------------- | -------------------------------------------------- | -------------------------------------------------------------------------------- | +| `truncation_length` | `3` | The number of parent folders that the current directory should be truncated to. | +| `truncate_to_repo` | `true` | Whether or not to truncate to the root of the git repo that you're currently in. | +| `format` | `"[$path]($style)[$read_only]($read_only_style) "` | moduleのフォーマットです。 | +| `style` | `"bold cyan"` | モジュールのスタイルです。 | +| `disabled` | `false` | Disables the `directory` module. | +| `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: "…/" | +| `home_symbol` | `"~"` | The symbol indicating home directory. |
-このモジュールは、どのようにディレクトリを表示するかについての高度なオプションをいくつか持っています。 +This module has a few advanced configuration options that control how the directory is displayed. | Advanced Option | デフォルト | 説明 | | --------------------------- | ------ | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------- | | `substitutions` | | A table of substitutions to be made to the path. | -| `fish_style_pwd_dir_length` | `0` | fish shellのpwdパスロジックを適用するときに使用する文字数です。 | +| `fish_style_pwd_dir_length` | `0` | The number of characters to use when applying fish shell pwd path logic. | | `use_logical_path` | `true` | If `true` render the logical path sourced from the shell via `PWD` or `--logical-path`. If `false` instead render the physical filesystem path with symlinks resolved. | `substitutions` allows you to define arbitrary replacements for literal strings that occur in the path, for example long network prefixes or development directories (i.e. Java). Note that this will disable the fish style PWD. @@ -728,12 +770,12 @@ fishスタイルのpwdオプションを使用すると、切り捨てられた ### 変数 -| 変数 | 設定例 | 説明 | -| --------- | --------------------- | ---------------------- | -| path | `"D:/Projects"` | カレントディレクトリのパス | -| style\* | `"black bold dimmed"` | オプション `style` の値をミラーする | +| 変数 | 設定例 | 説明 | +| --------- | --------------------- | -------------------------- | +| path | `"D:/Projects"` | The current directory path | +| style\* | `"black bold dimmed"` | オプション `style` の値をミラーする | -\*: この変数はスタイル文字列の一部としてのみ使用できます +\*: This variable can only be used as a part of a style string ### 設定例 @@ -751,26 +793,26 @@ The `docker_context` module shows the currently active [Docker context](https:// ### オプション -| オプション | デフォルト | 説明 | -| ------------------- | ---------------------------------- | -------------------------------------------------------------- | -| `format` | `"via [$symbol$context]($style) "` | moduleのフォーマットです。 | -| `symbol` | `"🐳 "` | Dockerコンテキストを表示する前に使用される記号です。 | -| `only_with_files` | `true` | ファイルに一致する場合にのみ表示 | -| `detect_extensions` | `[]` | どの拡張子がこのモジュールをトリガーするか(`only_with_files`がtrueになっている必要があります)。 | -| `detect_files` | `The format for the module.` | どんなファイル名がこのモジュールをトリガーするか(`only_with_files`がtrueになっている必要があります)。 | -| `detect_folders` | `[]` | どんなフォルダがこのモジュールをトリガーするか(`only_with_files`がtrueになっている必要があります)。 | -| `style` | `"blue bold"` | モジュールのスタイルです。 | -| `disabled` | `false` | `docker_context`モジュールを無効にします。 | +| オプション | デフォルト | 説明 | +| ------------------- | ------------------------------------------------------------- | --------------------------------------------------------------------------------- | +| `format` | `"via [$symbol$context]($style) "` | moduleのフォーマットです。 | +| `symbol` | `"🐳 "` | The symbol used before displaying the Docker context. | +| `only_with_files` | `true` | Only show when there's a match | +| `detect_extensions` | `[]` | Which extensions should trigger this module (needs `only_with_files` to be true). | +| `detect_files` | `["docker-compose.yml", "docker-compose.yaml", "Dockerfile"]` | Which filenames should trigger this module (needs `only_with_files` to be true). | +| `detect_folders` | `[]` | Which folders should trigger this module (needs `only_with_files` to be true). | +| `style` | `"blue bold"` | モジュールのスタイルです。 | +| `disabled` | `false` | Disables the `docker_context` module. | ### 変数 -| 変数 | 設定例 | 説明 | -| --------- | -------------- | ---------------------- | -| context | `test_context` | 現在の Docker コンテキスト | -| symbol | | オプション `記号` の値をミラーする | -| style\* | | オプション `style` の値をミラーする | +| 変数 | 設定例 | 説明 | +| --------- | -------------- | -------------------------- | +| context | `test_context` | The current docker context | +| symbol | | オプション `記号` の値をミラーする | +| style\* | | オプション `style` の値をミラーする | -\*: この変数はスタイル文字列の一部としてのみ使用できます +\*: This variable can only be used as a part of a style string ### 設定例 @@ -783,7 +825,7 @@ format = "via [🐋 $context](blue bold)" ## Dotnet -`dotnet`モジュールはカレントディレクトリに関係する[.NET Core SDK](https://dotnet.microsoft.com/)のバージョンを表示します。 もし SDKは現在のディレクトリに固定されているのであれば、その固定されたバージョンが表示されます。 それ以外の場合、モジュール SDKの最新のインストールバージョンを示します。 +The `dotnet` module shows the relevant version of the [.NET Core SDK](https://dotnet.microsoft.com/) for the current directory. If the SDK has been pinned in the current directory, the pinned version is shown. Otherwise the module shows the latest installed version of the SDK. By default this module will only be shown in your prompt when one or more of the following files are present in the current directory: @@ -798,23 +840,23 @@ By default this module will only be shown in your prompt when one or more of the You'll also need the .NET Core SDK installed in order to use it correctly. -内部的に、このモジュールは自身のバージョン検知のメカニズムを利用します。 `dotnet --version` を実行するより2倍速く実行できますが、.NET project一般的でないディレクトリlayoutの場合は間違ったバージョンが示されてしまうことがあります。 速度よりも精度が重要な場合は、次の方法でメカニズムを無効にできます。 モジュールオプションで`heuristic = false `を設定します。 +Internally, this module uses its own mechanism for version detection. Typically it is twice as fast as running `dotnet --version`, but it may show an incorrect version if your .NET project has an unusual directory layout. If accuracy is more important than speed, you can disable the mechanism by setting `heuristic = false` in the module options. The module will also show the Target Framework Moniker () when there is a csproj file in the current directory. ### オプション -| オプション | デフォルト | 説明 | -| ------------------- | ------------------------------------------------------------------------------------------------------- | ------------------------------------------------------ | -| `format` | `"via [$symbol($version )(🎯 $tfm )]($style)"` | moduleのフォーマットです。 | -| `version_format` | `"v${raw}"` | バージョンのフォーマット。 使用可能な変数は`raw`、`major`、`minor`と`patch`です。 | -| `symbol` | `".NET "` | dotnetのバージョンを表示する前に使用される記号です。 | -| `heuristic` | `true` | より高速なバージョン検出を使用して、starshipの動作を維持します。 | -| `detect_extensions` | `["csproj", "fsproj", "xproj"]` | どの拡張子がこのモジュールをアクティブにするか | -| `detect_files` | `["global.json", "project.json", "Directory.Build.props", "Directory.Build.targets", "Packages.props"]` | どのファイル名がこのモジュールをアクティブにするか | -| `detect_folders` | `[]` | どのフォルダーがこのモジュールをアクティブにするか | -| `style` | `"bold blue"` | モジュールのスタイルです。 | -| `disabled` | `false` | `dotnet`モジュールを無効にします。 | +| オプション | デフォルト | 説明 | +| ------------------- | ------------------------------------------------------------------------------------------------------- | -------------------------------------------------------- | +| `format` | `"via [$symbol($version )(🎯 $tfm )]($style)"` | moduleのフォーマットです。 | +| `version_format` | `"v${raw}"` | バージョンのフォーマット。 使用可能な変数は`raw`、`major`、`minor`と`patch`です。 | +| `symbol` | `".NET "` | The symbol used before displaying the version of dotnet. | +| `heuristic` | `true` | Use faster version detection to keep starship snappy. | +| `detect_extensions` | `["csproj", "fsproj", "xproj"]` | どの拡張子がこのモジュールをアクティブにするか | +| `detect_files` | `["global.json", "project.json", "Directory.Build.props", "Directory.Build.targets", "Packages.props"]` | どのファイル名がこのモジュールをアクティブにするか | +| `detect_folders` | `[]` | どのフォルダーがこのモジュールをアクティブにするか | +| `style` | `"bold blue"` | モジュールのスタイルです。 | +| `disabled` | `false` | Disables the `dotnet` module. | ### 変数 @@ -825,7 +867,7 @@ The module will also show the Target Framework Moniker ( ⚠️ 表示されるバージョンは、パッケージマネージャーではなく、ソースコードが現在のディレクトリにあるパッケージのバージョンです。 ### オプション -| オプション | デフォルト | 説明 | -| ----------------- | --------------------------------- | --------------------------------------------------------- | -| `format` | `"is [$symbol$version]($style) "` | moduleのフォーマットです。 | -| `symbol` | `"📦 "` | パッケージのバージョンを表示する前に使用される記号です。 | -| `version_format` | `"v${raw}"` | バージョンのフォーマット。 使用可能な変数は`raw`、`major`、`minor`と`patch`です。 | -| `style` | `"bold 208"` | モジュールのスタイルです。 | -| `display_private` | `false` | Enable displaying version for packages marked as private. | -| `disabled` | `false` | `package`モジュールを無効にします。 | +| オプション | デフォルト | 説明 | +| ----------------- | --------------------------------- | ---------------------------------------------------------- | +| `format` | `"is [$symbol$version]($style) "` | moduleのフォーマットです。 | +| `symbol` | `"📦 "` | The symbol used before displaying the version the package. | +| `version_format` | `"v${raw}"` | バージョンのフォーマット。 使用可能な変数は`raw`、`major`、`minor`と`patch`です。 | +| `style` | `"bold 208"` | モジュールのスタイルです。 | +| `display_private` | `false` | Enable displaying version for packages marked as private. | +| `disabled` | `false` | Disables the `package` module. | ### 変数 @@ -2076,7 +2148,7 @@ symbol = "☁️ " | symbol | | オプション `記号` の値をミラーする | | style\* | | オプション `style` の値をミラーする | -\*: この変数はスタイル文字列の一部としてのみ使用できます +\*: This variable can only be used as a part of a style string ### 設定例 @@ -2131,7 +2203,7 @@ format = "via [🦪 $version]($style) " The `php` module shows the currently installed version of [PHP](https://www.php.net/). デフォルトでは次の条件のいずれかが満たされると、モジュールが表示されます。 -- カレントディレクトリに`composer.json`ファイルが含まれている +- The current directory contains a `composer.json` file - The current directory contains a `.php-version` file - The current directory contains a `.php` extension @@ -2141,12 +2213,12 @@ The `php` module shows the currently installed version of [PHP](https://www.php. | ------------------- | ------------------------------------ | ------------------------------------------------------ | | `format` | `"via [$symbol($version )]($style)"` | moduleのフォーマットです。 | | `version_format` | `"v${raw}"` | バージョンのフォーマット。 使用可能な変数は`raw`、`major`、`minor`と`patch`です。 | -| `symbol` | `"🐘 "` | PHPのバージョンを表示する前に使用される記号です。 | +| `symbol` | `"🐘 "` | The symbol used before displaying the version of PHP. | | `detect_extensions` | `["php"]` | どの拡張子がこのモジュールをアクティブにするか | | `detect_files` | `["composer.json", ".php-version"]` | どのファイル名がこのモジュールをアクティブにするか | | `detect_folders` | `[]` | どのフォルダーがこのモジュールをアクティブにするか | | `style` | `"147 bold"` | モジュールのスタイルです。 | -| `disabled` | `false` | `php`モジュールを無効にします。 | +| `disabled` | `false` | Disables the `php` module. | ### 変数 @@ -2156,7 +2228,7 @@ The `php` module shows the currently installed version of [PHP](https://www.php. | symbol | | オプション `記号` の値をミラーする | | style\* | | オプション `style` の値をミラーする | -\*: この変数はスタイル文字列の一部としてのみ使用できます +\*: This variable can only be used as a part of a style string ### 設定例 @@ -2171,7 +2243,7 @@ format = "via [🔹 $version](147 bold) " The `purescript` module shows the currently installed version of [PureScript](https://www.purescript.org/) version. デフォルトでは次の条件のいずれかが満たされると、モジュールが表示されます。 -- カレントディレクトリに`spago.dhall`ファイルが含まれている +- The current directory contains a `spago.dhall` file - The current directory contains a file with the `.purs` extension ### オプション @@ -2195,7 +2267,7 @@ The `purescript` module shows the currently installed version of [PureScript](ht | symbol | | オプション `記号` の値をミラーする | | style\* | | オプション `style` の値をミラーする | -\*: この変数はスタイル文字列の一部としてのみ使用できます +\*: This variable can only be used as a part of a style string ### 設定例 @@ -2210,19 +2282,19 @@ format = "via [$symbol$version](bold white)" The `python` module shows the currently installed version of [Python](https://www.python.org/) and the current [Python virtual environment](https://docs.python.org/tutorial/venv.html) if one is activated. -`pyenvversionname` が `true` に設定されている場合 、pyenv でのバージョン名が表示されます 。 そうでなければ、`python --version` を元にバージョン番号を表示します。 +If `pyenv_version_name` is set to `true`, it will display the pyenv version name. Otherwise, it will display the version number from `python --version`. デフォルトでは次の条件のいずれかが満たされると、モジュールが表示されます。 -- カレントディレクトリに`.python-version`ファイルが含まれている -- カレントディレクトリに`Pipfile`ファイルが含まれている +- The current directory contains a `.python-version` file +- The current directory contains a `Pipfile` file - The current directory contains a `__init__.py` file -- カレントディレクトリに`pyproject.toml`ファイルが含まれている -- カレントディレクトリに`requirements.txt`ファイルが含まれている -- カレントディレクトリに`setup.py`ファイルが含まれている -- カレントディレクトリに`tox.ini`ファイルが含まれている -- カレントディレクトリに`.py`の拡張子のファイルが含まれている. -- 仮想環境がアクティブである +- The current directory contains a `pyproject.toml` file +- The current directory contains a `requirements.txt` file +- The current directory contains a `setup.py` file +- The current directory contains a `tox.ini` file +- The current directory contains a file with the `.py` extension. +- A virtual environment is currently activated ### オプション @@ -2232,13 +2304,13 @@ The `python` module shows the currently installed version of [Python](https://ww | `version_format` | `"v${raw}"` | バージョンのフォーマット。 使用可能な変数は`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"]` | どの拡張子がこのモジュールをアクティブにするか | | `detect_files` | `[".python-version", "Pipfile", "__init__.py", "pyproject.toml", "requirements.txt", "setup.py", "tox.ini"]` | どのファイル名がこのモジュールをアクティブにするか | | `detect_folders` | `[]` | どのフォルダーがこのモジュールをアクティブにするか | -| `disabled` | `false` | `python`モジュールを無効にします。 | +| `disabled` | `false` | Disables the `python` module. | ::: tip @@ -2297,7 +2369,7 @@ python_binary = ["./venv/bin/python", "python", "python3", "python2"] ## R -The `rlang` module shows the currently installed version of R. The module will be shown if any of the following conditions are met: +The `rlang` module shows the currently installed version of [R](https://www.r-project.org/). The module will be shown if any of the following conditions are met: - The current directory contains a file with the `.R` extension. - The current directory contains a file with the `.Rd` extension. @@ -2339,7 +2411,7 @@ format = "with [📐 $version](blue bold) " ## 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 @@ -2364,7 +2436,7 @@ By default the `red` module shows the currently installed version of [Red](https | symbol | | オプション `記号` の値をミラーする | | style\* | | オプション `style` の値をミラーする | -\*: この変数はスタイル文字列の一部としてのみ使用できます +\*: This variable can only be used as a part of a style string ### 設定例 @@ -2377,11 +2449,11 @@ 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 `Gemfile` file - The current directory contains a `.ruby-version` file -- カレントディレクトリに`.rb`の拡張子のファイルが含まれている +- The current directory contains a `.rb` file ### オプション @@ -2394,7 +2466,7 @@ By default the `ruby` module shows the currently installed version of [Ruby](htt | `detect_files` | `["Gemfile", ".ruby-version"]` | どのファイル名がこのモジュールをアクティブにするか | | `detect_folders` | `[]` | どのフォルダーがこのモジュールをアクティブにするか | | `style` | `"bold red"` | モジュールのスタイルです。 | -| `disabled` | `false` | `ruby`モジュールを無効にします。 | +| `disabled` | `false` | Disables the `ruby` module. | ### 変数 @@ -2404,7 +2476,7 @@ By default the `ruby` module shows the currently installed version of [Ruby](htt | symbol | | オプション `記号` の値をミラーする | | style\* | | オプション `style` の値をミラーする | -\*: この変数はスタイル文字列の一部としてのみ使用できます +\*: This variable can only be used as a part of a style string ### 設定例 @@ -2417,10 +2489,10 @@ symbol = "🔺 " ## Rust -デフォルトでは`rust`モジュールは現在インストールされている[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`の拡張子のファイルが含まれている +- The current directory contains a `Cargo.toml` file +- The current directory contains a file with the `.rs` extension ### オプション @@ -2428,22 +2500,22 @@ symbol = "🔺 " | ------------------- | ------------------------------------ | ------------------------------------------------------ | | `format` | `"via [$symbol($version )]($style)"` | moduleのフォーマットです。 | | `version_format` | `"v${raw}"` | バージョンのフォーマット。 使用可能な変数は`raw`、`major`、`minor`と`patch`です。 | -| `symbol` | `"🦀 "` | Rustのシンボルを表すフォーマット文字列 | +| `symbol` | `"🦀 "` | A format string representing the symbol of Rust | | `detect_extensions` | `["rs"]` | どの拡張子がこのモジュールをアクティブにするか | | `detect_files` | `["Cargo.toml"]` | どのファイル名がこのモジュールをアクティブにするか | | `detect_folders` | `[]` | どのフォルダーがこのモジュールをアクティブにするか | | `style` | `"bold red"` | モジュールのスタイルです。 | -| `disabled` | `false` | `rust`モジュールを無効にします。 | +| `disabled` | `false` | Disables the `rust` module. | ### 変数 | 変数 | 設定例 | 説明 | | --------- | ----------------- | ---------------------- | -| version | `v1.43.0-nightly` | `rustc`のバージョン | +| version | `v1.43.0-nightly` | The version of `rustc` | | symbol | | オプション `記号` の値をミラーする | | style\* | | オプション `style` の値をミラーする | -\*: この変数はスタイル文字列の一部としてのみ使用できます +\*: This variable can only be used as a part of a style string ### 設定例 @@ -2483,7 +2555,7 @@ The `scala` module shows the currently installed version of [Scala](https://www. | symbol | | オプション `記号` の値をミラーする | | style\* | | オプション `style` の値をミラーする | -\*: この変数はスタイル文字列の一部としてのみ使用できます +\*: This variable can only be used as a part of a style string ### 設定例 @@ -2500,7 +2572,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. ::: @@ -2540,7 +2612,7 @@ disabled = false ## SHLVL -The `shlvl` module shows the current `SHLVL` ("shell level") environment variable, if it is set to a number and meets or exceeds the specified threshold. +The `shlvl` module shows the current [`SHLVL`](https://tldp.org/LDP/abs/html/internalvariables.html#SHLVLREF) ("shell level") environment variable, if it is set to a number and meets or exceeds the specified threshold. ### オプション @@ -2561,7 +2633,7 @@ The `shlvl` module shows the current `SHLVL` ("shell level") environment variabl | symbol | | オプション `記号` の値をミラーする | | style\* | | オプション `style` の値をミラーする | -\*: この変数はスタイル文字列の一部としてのみ使用できます +\*: This variable can only be used as a part of a style string ### 設定例 @@ -2595,7 +2667,7 @@ The `singularity` module shows the current [Singularity](https://sylabs.io/singu | symbol | | オプション `記号` の値をミラーする | | style\* | | オプション `style` の値をミラーする | -\*: この変数はスタイル文字列の一部としてのみ使用できます +\*: This variable can only be used as a part of a style string ### 設定例 @@ -2612,7 +2684,7 @@ The `status` module displays the exit code of the previous command. The module w ::: tip -このモジュールはデフォルトで無効になっています。 有効にするには、設定ファイルで`disabled`を`false`に設定します。 +This module is disabled by default. To enable it, set `disabled` to `false` in your configuration file. ::: @@ -2651,7 +2723,7 @@ The `status` module displays the exit code of the previous command. The module w | symbol | | オプション `記号` の値をミラーする | | style\* | | オプション `style` の値をミラーする | -\*: この変数はスタイル文字列の一部としてのみ使用できます +\*: This variable can only be used as a part of a style string ### 設定例 @@ -2670,7 +2742,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 @@ -2696,7 +2768,7 @@ By default the `swift` module shows the currently installed version of [Swift](h | symbol | | オプション `記号` の値をミラーする | | style\* | | オプション `style` の値をミラーする | -\*: この変数はスタイル文字列の一部としてのみ使用できます +\*: This variable can only be used as a part of a style string ### 設定例 @@ -2719,7 +2791,7 @@ By default the Terraform version is not shown, since this is slow for current ve デフォルトでは次の条件のいずれかが満たされると、モジュールが表示されます。 -- カレントディレクトリに`.terraform`フォルダが含まれている +- The current directory contains a `.terraform` folder - Current directory contains a file with the `.tf` or `.hcl` extensions ### オプション @@ -2733,7 +2805,7 @@ By default the Terraform version is not shown, since this is slow for current ve | `detect_files` | `[]` | どのファイル名がこのモジュールをアクティブにするか | | `detect_folders` | `[".terraform"]` | どのフォルダーがこのモジュールをアクティブにするか | | `style` | `"bold 105"` | モジュールのスタイルです。 | -| `disabled` | `false` | `terraform`モジュールを無効にします。 | +| `disabled` | `false` | Disables the `terraform` module. | ### 変数 @@ -2744,7 +2816,7 @@ By default the Terraform version is not shown, since this is slow for current ve | symbol | | オプション `記号` の値をミラーする | | style\* | | オプション `style` の値をミラーする | -\*: この変数はスタイル文字列の一部としてのみ使用できます +\*: This variable can only be used as a part of a style string ### 設定例 @@ -2768,36 +2840,36 @@ format = "[🏎💨 $workspace]($style) " ## Time -`time`モジュールは、現在の**現地**時間を示します。 `format`設定は、時間の表示方法を制御するために[`chrono`](https://crates.io/crates/chrono)クレートによって使用されます。 使用可能なオプションを確認するには、[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. ::: ### オプション -| オプション | デフォルト | 説明 | -| ----------------- | ----------------------- | ----------------------------------------------------------------------------------------------------- | -| `format` | `"at [$time]($style) "` | The format string for the module. | -| `use_12hr` | `false` | 12時間のフォーマットを有効にします。 | -| `time_format` | この表の下を参照してください | 時刻のフォーマットに使用される[クロノフォーマット文字列](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 | +| オプション | デフォルト | 説明 | +| ----------------- | ----------------------- | ---------------------------------------------------------------------------------------------------------------------------------- | +| `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"`. それ以外の場合、デフォルトは`"%T"`です。 Manually setting `time_format` will override the `use_12hr` setting. +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. ### 変数 | 変数 | 設定例 | 説明 | | --------- | ---------- | ---------------------- | -| 時刻 | `13:08:10` | The current time. | +| time | `13:08:10` | The current time. | | style\* | | オプション `style` の値をミラーする | -\*: この変数はスタイル文字列の一部としてのみ使用できます +\*: This variable can only be used as a part of a style string ### 設定例 @@ -2812,14 +2884,14 @@ 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: -- カレントユーザーがroot -- カレントユーザーが、ログインしているユーザーとは異なる -- ユーザーがSSHセッションとして接続されている -- `show_always`変数がtrueに設定されている +- The current user is root +- The current user isn't the same as the one that is logged in +- The user is currently connected as an SSH session +- The variable `show_always` is set to true ::: tip @@ -2829,13 +2901,13 @@ SSH connection is detected by checking environment variables `SSH_CONNECTION`, ` ### オプション -| オプション | デフォルト | 説明 | -| ------------- | ----------------------- | ------------------------- | -| `style_root` | `"bold red"` | ユーザーがrootのときに使用されるスタイルです。 | -| `style_user` | `"bold yellow"` | 非rootユーザーに使用されるスタイルです。 | -| `format` | `"[$user]($style) in "` | moduleのフォーマットです。 | -| `show_always` | `false` | `username`モジュールを常に表示します。 | -| `disabled` | `false` | `username`モジュールを無効にします。 | +| オプション | デフォルト | 説明 | +| ------------- | ----------------------- | ------------------------------------- | +| `style_root` | `"bold red"` | The style used when the user is root. | +| `style_user` | `"bold yellow"` | The style used for non-root users. | +| `format` | `"[$user]($style) in "` | moduleのフォーマットです。 | +| `show_always` | `false` | Always shows the `username` module. | +| `disabled` | `false` | Disables the `username` module. | ### 変数 @@ -2884,7 +2956,7 @@ The `vagrant` module shows the currently installed version of [Vagrant](https:// | symbol | | オプション `記号` の値をミラーする | | style\* | | オプション `style` の値をミラーする | -\*: この変数はスタイル文字列の一部としてのみ使用できます +\*: This variable can only be used as a part of a style string ### 設定例 @@ -2895,9 +2967,9 @@ The `vagrant` module shows the currently installed version of [Vagrant](https:// format = "via [⍱ $version](bold white) " ``` -## VLang +## V -The `vlang` module shows you your currently installed version of V. By default the module will be shown if any of the following conditions are met: +The `vlang` module shows you your currently installed version of [V](https://vlang.io/). デフォルトでは次の条件のいずれかが満たされると、モジュールが表示されます。 - The current directory contains a file with `.v` extension - The current directory contains a `v.mod`, `vpkg.json` or `.vpkg-lock.json` file @@ -2926,7 +2998,7 @@ The `vlang` module shows you your currently installed version of V. By default t ```toml # ~/.config/starship.toml -[v] +[vlang] format = "via [V $version](blue bold) " ``` @@ -2951,7 +3023,7 @@ The `vcsh` module displays the current active [VCSH](https://github.com/RichiH/v | symbol | | オプション `記号` の値をミラーする | | style\* | `black bold dimmed` | オプション `style` の値をミラーする | -\*: この変数はスタイル文字列の一部としてのみ使用できます +\*: This variable can only be used as a part of a style string ### 設定例 @@ -2964,7 +3036,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 @@ -2989,7 +3061,7 @@ By default the the `zig` module shows the currently installed version of [Zig](h | symbol | | オプション `記号` の値をミラーする | | style\* | | オプション `style` の値をミラーする | -\*: この変数はスタイル文字列の一部としてのみ使用できます +\*: This variable can only be used as a part of a style string ### 設定例 @@ -3036,8 +3108,8 @@ The order in which custom modules are shown can be individually set by including | ------------- | ------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | | `command` | | The command whose output should be printed. The command will be passed on stdin to the shell. | | `when` | | A shell command used as a condition to show the module. The module will be shown if the command returns a `0` status code. | -| `shell` | | [この表の下を参照してください](#custom-command-shell) | -| `説明` | `""` | The description of the module that is shown when running `starship explain`. | +| `shell` | | [See below](#custom-command-shell) | +| `description` | `""` | The description of the module that is shown when running `starship explain`. | | `files` | `[]` | The files that will be searched in the working directory for a match. | | `directories` | `[]` | The directories that will be searched in the working directory for a match. | | `extensions` | `[]` | The extensions that will be searched in the working directory for a match. | @@ -3055,7 +3127,7 @@ The order in which custom modules are shown can be individually set by including | symbol | オプション `記号` の値をミラーする | | style\* | オプション `style` の値をミラーする | -\*: この変数はスタイル文字列の一部としてのみ使用できます +\*: This variable can only be used as a part of a style string #### Custom command shell diff --git a/docs/ja-JP/guide/README.md b/docs/ja-JP/guide/README.md index ce701531..ead0b726 100644 --- a/docs/ja-JP/guide/README.md +++ b/docs/ja-JP/guide/README.md @@ -48,30 +48,6 @@ height="20" src="https://raw.githubusercontent.com/starship/starship/master/media/flag-us.png" alt="English" - /> -   - 日本語 -   - 繁體中文 -   - Русский   -   - 简体中文   +   + 日本語 +   + Português do Brasil +   + Русский   +   + 简体中文 +   + 繁體中文

@@ -160,8 +168,8 @@ ```sh sh -c "$(curl -fsSL https://starship.rs/install.sh)" ``` - Starship自体を更新するには、上記のスクリプトを再度実行してください。 最新のバージョンに置き換わり、設定ファイルには変更を加えません。 + Starship自体を更新するには、上記のスクリプトを再度実行してください。 最新のバージョンに置き換わり、設定ファイルには変更を加えません。 **※**インストールスクリプトのデフォルト値は上書きすることができます。詳しくはヘルプを参照してください。 @@ -266,7 +274,7 @@ #### Xonsh - Add the following to the end of `~/.xonshrc`: + `~/.xonshrc` の最後に以下を追加してください: ```sh # ~/.xonshrc @@ -277,7 +285,7 @@ #### Nushell - **Warning** This will change in the future. Only nu version v0.33 or higher is supported. Add the following to your nu config file. You can check the location of this file by running `config path` in nu. + **警告** これは将来的に変更されます。 nu バージョン 0.33 以降のみサポートされます。 nu 設定ファイルに以下を追加してください。 nu で`config path`を実行することで、設定ファイルの場所を確認できます。 ```toml startup = [ diff --git a/docs/ja-JP/presets/README.md b/docs/ja-JP/presets/README.md index 6c3c4590..0d8c8ab7 100644 --- a/docs/ja-JP/presets/README.md +++ b/docs/ja-JP/presets/README.md @@ -112,6 +112,9 @@ format = '\[[$symbol($version)]($style)\]' [cmd_duration] format = '\[[⏱ $duration ]($style)\]' +[cobol] +format = '\[[$symbol($version)]($style)\]' + [conda] format = '\[[$symbol$environment]($style)\]' @@ -272,6 +275,9 @@ deleted = "x" [aws] symbol = "aws " +[cobol] +symbol = "cobol " + [conda] symbol = "conda " @@ -375,6 +381,9 @@ This preset hides the version of language runtimes. If you work in containers or [cmake] format = "via [$symbol]($style)" +[cobol] +format = "via [$symbol]($style)" + [crystal] format = "via [$symbol]($style)" diff --git a/docs/ko-KR/advanced-config/README.md b/docs/ko-KR/advanced-config/README.md index 0d59c601..d7b9ec4d 100644 --- a/docs/ko-KR/advanced-config/README.md +++ b/docs/ko-KR/advanced-config/README.md @@ -68,6 +68,33 @@ function set_win_title(){ starship_precmd_user_func="set_win_title" ``` +## Enable Right Prompt + +Some shells support a right prompt which renders on the same line as the input. Starship can set the content of the right prompt using the `right_format` option. Any module that can be used in `format` is also supported in `right_format`. The `$all` variable will only contain modules not explicitly used in either `format` or `right_format`. + +Note: The right prompt is a single line following the input location. To right align modules above the input line in a multi-line prompt, see the [fill module](/config/#fill). + +`right_format` is currently supported for the following shells: elvish, fish, zsh. + +### Example + +```toml +# ~/.config/starship.toml + +# A minimal left prompt +format = """$character""" + +# move the rest of the prompt to the right +right_format = """$all""" +``` + +Produces a prompt like the following: + +``` +▶ starship on  rprompt [!] is 📦 v0.57.0 via 🦀 v1.54.0 took 17s +``` + + ## Style Strings Style strings are a list of words, separated by whitespace. The words are not case sensitive (i.e. `bold` and `BoLd` are considered the same string). Each word can be one of the following: diff --git a/docs/ko-KR/config/README.md b/docs/ko-KR/config/README.md index 61f8fcfd..2fb31aa1 100644 --- a/docs/ko-KR/config/README.md +++ b/docs/ko-KR/config/README.md @@ -75,7 +75,7 @@ A text group is made up of two different parts. The first part, which is enclosed in a `[]`, is a [format string](#format-strings). You can add texts, variables, or even nested text groups in it. -In the second part, which is enclosed in a `()`, is a [style string](#style-strings). This can be used style the first part. +In the second part, which is enclosed in a `()`, is a [style string](#style-strings). This can be used to style the first part. For example: @@ -142,12 +142,14 @@ This is the list of prompt-wide configuration options. ### Options -| Option | Default | Description | -| ----------------- | ------------------------------ | ------------------------------------------------------------ | -| `format` | [link](#default-prompt-format) | Configure the format of the prompt. | -| `scan_timeout` | `30` | Timeout for starship to scan files (in milliseconds). | -| `command_timeout` | `500` | Timeout for commands executed by starship (in milliseconds). | -| `add_newline` | `true` | Inserts blank line between shell prompts. | +| Option | Default | Description | +| ----------------- | ------------------------------ | ---------------------------------------------------------------- | +| `format` | [link](#default-prompt-format) | Configure the format of the prompt. | +| `right_format` | `""` | See [Enable Right Prompt](/advanced-config/#enable-right-prompt) | +| `scan_timeout` | `30` | Timeout for starship to scan files (in milliseconds). | +| `command_timeout` | `500` | Timeout for commands executed by starship (in milliseconds). | +| `add_newline` | `true` | Inserts blank line between shell prompts. | + ### Example @@ -179,6 +181,7 @@ format = """ $username\ $hostname\ $shlvl\ +$singularity\ $kubernetes\ $directory\ $vcsh\ @@ -191,6 +194,7 @@ $hg_branch\ $docker_context\ $package\ $cmake\ +$cobol\ $dart\ $deno\ $dotnet\ @@ -202,6 +206,7 @@ $helm\ $java\ $julia\ $kotlin\ +$lua\ $nim\ $nodejs\ $ocaml\ @@ -209,6 +214,7 @@ $perl\ $php\ $purescript\ $python\ +$rlang\ $red\ $ruby\ $rust\ @@ -229,7 +235,6 @@ $crystal\ $custom\ $cmd_duration\ $line_break\ -$lua\ $jobs\ $battery\ $time\ @@ -238,6 +243,13 @@ $shell\ $character""" ``` +If you just want to extend the default format, you can use `$all`; modules you explicitly add to the format will not be duplicated. Eg. + +```toml +# Move the directory to the second line +format="$all$directory$character" +``` + ## AWS The `aws` module shows the current AWS region and profile. This is based on `AWS_REGION`, `AWS_DEFAULT_REGION`, and `AWS_PROFILE` env var with `~/.aws/config` file. This module also shows an expiration timer when using temporary credentials. @@ -479,6 +491,36 @@ The `cmake` module shows the currently installed version of [CMake](https://cmak \*: This variable can only be used as a part of a style string +## COBOL / GNUCOBOL + +The `cobol` module shows the currently installed version of COBOL. By default, the module will be shown if any of the following conditions are met: + +- The current directory contains any files ending in `.cob` or `.COB` +- The current directory contains any files ending in `.cbl` or `.CBL` + +### Options + +| Option | Default | Description | +| ------------------- | ------------------------------------ | ------------------------------------------------------------------------- | +| `symbol` | `"⚙️ "` | The symbol used before displaying the version of COBOL. | +| `format` | `"via [$symbol($version )]($style)"` | The format for the module. | +| `version_format` | `"v${raw}"` | The version format. Available vars are `raw`, `major`, `minor`, & `patch` | +| `style` | `"bold blue"` | The style for the module. | +| `detect_extensions` | `["cbl", "cob", "CBL", "COB"]` | Which extensions should trigger this module. | +| `detect_files` | `[]` | Which filenames should trigger this module. | +| `detect_folders` | `[]` | Which folders should trigger this module. | +| `disabled` | `false` | Disables the `cobol` module. | + +### Variables + +| Variable | Example | Description | +| --------- | ---------- | ------------------------------------ | +| version | `v3.1.2.0` | The version of `cobol` | +| 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 + ## Command Duration The `cmd_duration` module shows how long the last command took to execute. The module will be shown only if the command took longer than two seconds, or the `min_time` config value, if it exists. @@ -530,7 +572,7 @@ format = "underwent [$duration](bold yellow)" ## Conda -The `conda` module shows the current conda environment, if `$CONDA_DEFAULT_ENV` is set. +The `conda` module shows the current [Conda](https://docs.conda.io/en/latest/) environment, if `$CONDA_DEFAULT_ENV` is set. ::: tip @@ -1017,6 +1059,35 @@ The `erlang` module shows the currently installed version of [Erlang/OTP](https: format = "via [e $version](bold red) " ``` +## 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. + +### Options + +| Option | Default | Description | +| -------- | -------------- | --------------------------------- | +| `symbol` | `"."` | The symbol used to fill the line. | +| `style` | `"bold black"` | The style for the module. | + +### Example + +```toml +# ~/.config/starship.toml +format="AA $fill BB $fill CC" + +[fill] +symbol = "-" +style = "bold green" +``` + +Produces a prompt that looks like: + +``` +AA -------------------------------------------- BB -------------------------------------------- CC + +``` + ## 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. @@ -1205,12 +1276,13 @@ This module is disabled by default. To enable it, set `disabled` to `false` in y ### Options -| Option | Default | Description | -| --------------- | -------------------------------------------------------- | ---------------------------------- | -| `added_style` | `"bold green"` | The style for the added count. | -| `deleted_style` | `"bold red"` | The style for the deleted count. | -| `format` | `'[+$added]($added_style) [-$deleted]($deleted_style) '` | The format for the module. | -| `disabled` | `true` | Disables the `git_metrics` module. | +| Option | Default | Description | +| -------------------- | ------------------------------------------------------------ | ------------------------------------- | +| `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. | +| `disabled` | `true` | Disables the `git_metrics` module. | ### Variables @@ -1318,9 +1390,9 @@ diverged = "⇕⇡${ahead_count}⇣${behind_count}" behind = "⇣${count}" ``` -## Golang +## Go -The `golang` module shows the currently installed version of [Golang](https://golang.org/). By default the module will be shown if any of the following conditions are met: +The `golang` module shows the currently installed version of [Go](https://golang.org/). By default the module will be shown if any of the following conditions are met: - The current directory contains a `go.mod` file - The current directory contains a `go.sum` file @@ -2041,18 +2113,18 @@ symbol = "☁️ " 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`, `composer`, `gradle`, `julia`, `mix` and `helm` 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 -- [**nimble**](https://github.com/nim-lang/nimble) - The `nimble` package version is extracted from the `*.nimble` file present in the current directory with the `nimble dump` command -- [**poetry**](https://python-poetry.org/) – The `poetry` package version is extracted from the `pyproject.toml` present in the current directory -- [**python**](https://www.python.org) - The `python` package version is extracted from the `setup.cfg` present in the current directory -- [**composer**](https://getcomposer.org/) – The `composer` package version is extracted from the `composer.json` present in the current directory -- [**gradle**](https://gradle.org/) – The `gradle` package version is extracted from the `build.gradle` present -- [**julia**](https://docs.julialang.org/en/v1/stdlib/Pkg/) - The package version is extracted from the `Project.toml` present -- [**mix**](https://hexdocs.pm/mix/) - The `mix` package version is extracted from the `mix.exs` present -- [**helm**](https://helm.sh/docs/helm/helm_package/) - The `helm` chart version is extracted from the `Chart.yaml` present -- [**maven**](https://maven.apache.org/) - The `maven` package version is extracted from the `pom.xml` present -- [**meson**](https://mesonbuild.com/) - The `meson` package version is extracted from the `meson.build` present -- [**vlang**](https://vlang.io) - The `vlang` package version is extracted from the `v.mod` present +- [**Cargo**](https://doc.rust-lang.org/cargo/) – The `cargo` package version is extracted from the `Cargo.toml` present in the current directory +- [**Nimble**](https://github.com/nim-lang/nimble) - The `nimble` package version is extracted from the `*.nimble` file present in the current directory with the `nimble dump` command +- [**Poetry**](https://python-poetry.org/) – The `poetry` package version is extracted from the `pyproject.toml` present in the current directory +- [**Python**](https://www.python.org) - The `python` package version is extracted from the `setup.cfg` present in the current directory +- [**Composer**](https://getcomposer.org/) – The `composer` package version is extracted from the `composer.json` present in the current directory +- [**Gradle**](https://gradle.org/) – The `gradle` package version is extracted from the `build.gradle` present +- [**Julia**](https://docs.julialang.org/en/v1/stdlib/Pkg/) - The package version is extracted from the `Project.toml` present +- [**Mix**](https://hexdocs.pm/mix/) - The `mix` package version is extracted from the `mix.exs` present +- [**Helm**](https://helm.sh/docs/helm/helm_package/) - The `helm` chart version is extracted from the `Chart.yaml` present +- [**Maven**](https://maven.apache.org/) - The `maven` package version is extracted from the `pom.xml` present +- [**Meson**](https://mesonbuild.com/) - The `meson` package version is extracted from the `meson.build` present +- [**V**](https://vlang.io) - The `vlang` package version is extracted from the `v.mod` present > ⚠️ The version being shown is that of the package whose source code is in your current directory, not your package manager. @@ -2296,7 +2368,7 @@ python_binary = ["./venv/bin/python", "python", "python3", "python2"] ## R -The `rlang` module shows the currently installed version of R. The module will be shown if any of the following conditions are met: +The `rlang` module shows the currently installed version of [R](https://www.r-project.org/). The module will be shown if any of the following conditions are met: - The current directory contains a file with the `.R` extension. - The current directory contains a file with the `.Rd` extension. @@ -2539,7 +2611,7 @@ disabled = false ## SHLVL -The `shlvl` module shows the current `SHLVL` ("shell level") environment variable, if it is set to a number and meets or exceeds the specified threshold. +The `shlvl` module shows the current [`SHLVL`](https://tldp.org/LDP/abs/html/internalvariables.html#SHLVLREF) ("shell level") environment variable, if it is set to a number and meets or exceeds the specified threshold. ### Options @@ -2894,9 +2966,9 @@ The `vagrant` module shows the currently installed version of [Vagrant](https:// format = "via [⍱ $version](bold white) " ``` -## VLang +## V -The `vlang` module shows you your currently installed version of V. By default the module will be shown if any of the following conditions are met: +The `vlang` module shows you your currently installed version of [V](https://vlang.io/). By default the module will be shown if any of the following conditions are met: - The current directory contains a file with `.v` extension - The current directory contains a `v.mod`, `vpkg.json` or `.vpkg-lock.json` file @@ -2925,7 +2997,7 @@ The `vlang` module shows you your currently installed version of V. By default t ```toml # ~/.config/starship.toml -[v] +[vlang] format = "via [V $version](blue bold) " ``` diff --git a/docs/ko-KR/guide/README.md b/docs/ko-KR/guide/README.md index 64eab34f..a4d6f685 100644 --- a/docs/ko-KR/guide/README.md +++ b/docs/ko-KR/guide/README.md @@ -48,30 +48,6 @@ height="20" src="https://raw.githubusercontent.com/starship/starship/master/media/flag-us.png" alt="English" - /> -   - 日本語 -   - 繁體中文 -   - Русский   -   - 简体中文   +   + 日本語 +   + Português do Brasil +   + Русский   +   + 简体中文 +   + 繁體中文

@@ -160,8 +168,8 @@ ```sh sh -c "$(curl -fsSL https://starship.rs/install.sh)" ``` - To update the Starship itself, rerun the above script. It will replace the current version without touching Starship's configuration. + To update the Starship itself, rerun the above script. It will replace the current version without touching Starship's configuration. **Note** - The defaults of the install script can be overridden see the built-in help. diff --git a/docs/ko-KR/presets/README.md b/docs/ko-KR/presets/README.md index c6cc6f60..61165f5b 100644 --- a/docs/ko-KR/presets/README.md +++ b/docs/ko-KR/presets/README.md @@ -112,6 +112,9 @@ format = '\[[$symbol($version)]($style)\]' [cmd_duration] format = '\[[⏱ $duration ]($style)\]' +[cobol] +format = '\[[$symbol($version)]($style)\]' + [conda] format = '\[[$symbol$environment]($style)\]' @@ -272,6 +275,9 @@ deleted = "x" [aws] symbol = "aws " +[cobol] +symbol = "cobol " + [conda] symbol = "conda " @@ -375,6 +381,9 @@ This preset hides the version of language runtimes. If you work in containers or [cmake] format = "via [$symbol]($style)" +[cobol] +format = "via [$symbol]($style)" + [crystal] format = "via [$symbol]($style)" diff --git a/docs/nl-NL/advanced-config/README.md b/docs/nl-NL/advanced-config/README.md index 0d59c601..d7b9ec4d 100644 --- a/docs/nl-NL/advanced-config/README.md +++ b/docs/nl-NL/advanced-config/README.md @@ -68,6 +68,33 @@ function set_win_title(){ starship_precmd_user_func="set_win_title" ``` +## Enable Right Prompt + +Some shells support a right prompt which renders on the same line as the input. Starship can set the content of the right prompt using the `right_format` option. Any module that can be used in `format` is also supported in `right_format`. The `$all` variable will only contain modules not explicitly used in either `format` or `right_format`. + +Note: The right prompt is a single line following the input location. To right align modules above the input line in a multi-line prompt, see the [fill module](/config/#fill). + +`right_format` is currently supported for the following shells: elvish, fish, zsh. + +### Example + +```toml +# ~/.config/starship.toml + +# A minimal left prompt +format = """$character""" + +# move the rest of the prompt to the right +right_format = """$all""" +``` + +Produces a prompt like the following: + +``` +▶ starship on  rprompt [!] is 📦 v0.57.0 via 🦀 v1.54.0 took 17s +``` + + ## Style Strings Style strings are a list of words, separated by whitespace. The words are not case sensitive (i.e. `bold` and `BoLd` are considered the same string). Each word can be one of the following: diff --git a/docs/nl-NL/config/README.md b/docs/nl-NL/config/README.md index 61f8fcfd..2fb31aa1 100644 --- a/docs/nl-NL/config/README.md +++ b/docs/nl-NL/config/README.md @@ -75,7 +75,7 @@ A text group is made up of two different parts. The first part, which is enclosed in a `[]`, is a [format string](#format-strings). You can add texts, variables, or even nested text groups in it. -In the second part, which is enclosed in a `()`, is a [style string](#style-strings). This can be used style the first part. +In the second part, which is enclosed in a `()`, is a [style string](#style-strings). This can be used to style the first part. For example: @@ -142,12 +142,14 @@ This is the list of prompt-wide configuration options. ### Options -| Option | Default | Description | -| ----------------- | ------------------------------ | ------------------------------------------------------------ | -| `format` | [link](#default-prompt-format) | Configure the format of the prompt. | -| `scan_timeout` | `30` | Timeout for starship to scan files (in milliseconds). | -| `command_timeout` | `500` | Timeout for commands executed by starship (in milliseconds). | -| `add_newline` | `true` | Inserts blank line between shell prompts. | +| Option | Default | Description | +| ----------------- | ------------------------------ | ---------------------------------------------------------------- | +| `format` | [link](#default-prompt-format) | Configure the format of the prompt. | +| `right_format` | `""` | See [Enable Right Prompt](/advanced-config/#enable-right-prompt) | +| `scan_timeout` | `30` | Timeout for starship to scan files (in milliseconds). | +| `command_timeout` | `500` | Timeout for commands executed by starship (in milliseconds). | +| `add_newline` | `true` | Inserts blank line between shell prompts. | + ### Example @@ -179,6 +181,7 @@ format = """ $username\ $hostname\ $shlvl\ +$singularity\ $kubernetes\ $directory\ $vcsh\ @@ -191,6 +194,7 @@ $hg_branch\ $docker_context\ $package\ $cmake\ +$cobol\ $dart\ $deno\ $dotnet\ @@ -202,6 +206,7 @@ $helm\ $java\ $julia\ $kotlin\ +$lua\ $nim\ $nodejs\ $ocaml\ @@ -209,6 +214,7 @@ $perl\ $php\ $purescript\ $python\ +$rlang\ $red\ $ruby\ $rust\ @@ -229,7 +235,6 @@ $crystal\ $custom\ $cmd_duration\ $line_break\ -$lua\ $jobs\ $battery\ $time\ @@ -238,6 +243,13 @@ $shell\ $character""" ``` +If you just want to extend the default format, you can use `$all`; modules you explicitly add to the format will not be duplicated. Eg. + +```toml +# Move the directory to the second line +format="$all$directory$character" +``` + ## AWS The `aws` module shows the current AWS region and profile. This is based on `AWS_REGION`, `AWS_DEFAULT_REGION`, and `AWS_PROFILE` env var with `~/.aws/config` file. This module also shows an expiration timer when using temporary credentials. @@ -479,6 +491,36 @@ The `cmake` module shows the currently installed version of [CMake](https://cmak \*: This variable can only be used as a part of a style string +## COBOL / GNUCOBOL + +The `cobol` module shows the currently installed version of COBOL. By default, the module will be shown if any of the following conditions are met: + +- The current directory contains any files ending in `.cob` or `.COB` +- The current directory contains any files ending in `.cbl` or `.CBL` + +### Options + +| Option | Default | Description | +| ------------------- | ------------------------------------ | ------------------------------------------------------------------------- | +| `symbol` | `"⚙️ "` | The symbol used before displaying the version of COBOL. | +| `format` | `"via [$symbol($version )]($style)"` | The format for the module. | +| `version_format` | `"v${raw}"` | The version format. Available vars are `raw`, `major`, `minor`, & `patch` | +| `style` | `"bold blue"` | The style for the module. | +| `detect_extensions` | `["cbl", "cob", "CBL", "COB"]` | Which extensions should trigger this module. | +| `detect_files` | `[]` | Which filenames should trigger this module. | +| `detect_folders` | `[]` | Which folders should trigger this module. | +| `disabled` | `false` | Disables the `cobol` module. | + +### Variables + +| Variable | Example | Description | +| --------- | ---------- | ------------------------------------ | +| version | `v3.1.2.0` | The version of `cobol` | +| 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 + ## Command Duration The `cmd_duration` module shows how long the last command took to execute. The module will be shown only if the command took longer than two seconds, or the `min_time` config value, if it exists. @@ -530,7 +572,7 @@ format = "underwent [$duration](bold yellow)" ## Conda -The `conda` module shows the current conda environment, if `$CONDA_DEFAULT_ENV` is set. +The `conda` module shows the current [Conda](https://docs.conda.io/en/latest/) environment, if `$CONDA_DEFAULT_ENV` is set. ::: tip @@ -1017,6 +1059,35 @@ The `erlang` module shows the currently installed version of [Erlang/OTP](https: format = "via [e $version](bold red) " ``` +## 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. + +### Options + +| Option | Default | Description | +| -------- | -------------- | --------------------------------- | +| `symbol` | `"."` | The symbol used to fill the line. | +| `style` | `"bold black"` | The style for the module. | + +### Example + +```toml +# ~/.config/starship.toml +format="AA $fill BB $fill CC" + +[fill] +symbol = "-" +style = "bold green" +``` + +Produces a prompt that looks like: + +``` +AA -------------------------------------------- BB -------------------------------------------- CC + +``` + ## 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. @@ -1205,12 +1276,13 @@ This module is disabled by default. To enable it, set `disabled` to `false` in y ### Options -| Option | Default | Description | -| --------------- | -------------------------------------------------------- | ---------------------------------- | -| `added_style` | `"bold green"` | The style for the added count. | -| `deleted_style` | `"bold red"` | The style for the deleted count. | -| `format` | `'[+$added]($added_style) [-$deleted]($deleted_style) '` | The format for the module. | -| `disabled` | `true` | Disables the `git_metrics` module. | +| Option | Default | Description | +| -------------------- | ------------------------------------------------------------ | ------------------------------------- | +| `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. | +| `disabled` | `true` | Disables the `git_metrics` module. | ### Variables @@ -1318,9 +1390,9 @@ diverged = "⇕⇡${ahead_count}⇣${behind_count}" behind = "⇣${count}" ``` -## Golang +## Go -The `golang` module shows the currently installed version of [Golang](https://golang.org/). By default the module will be shown if any of the following conditions are met: +The `golang` module shows the currently installed version of [Go](https://golang.org/). By default the module will be shown if any of the following conditions are met: - The current directory contains a `go.mod` file - The current directory contains a `go.sum` file @@ -2041,18 +2113,18 @@ symbol = "☁️ " 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`, `composer`, `gradle`, `julia`, `mix` and `helm` 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 -- [**nimble**](https://github.com/nim-lang/nimble) - The `nimble` package version is extracted from the `*.nimble` file present in the current directory with the `nimble dump` command -- [**poetry**](https://python-poetry.org/) – The `poetry` package version is extracted from the `pyproject.toml` present in the current directory -- [**python**](https://www.python.org) - The `python` package version is extracted from the `setup.cfg` present in the current directory -- [**composer**](https://getcomposer.org/) – The `composer` package version is extracted from the `composer.json` present in the current directory -- [**gradle**](https://gradle.org/) – The `gradle` package version is extracted from the `build.gradle` present -- [**julia**](https://docs.julialang.org/en/v1/stdlib/Pkg/) - The package version is extracted from the `Project.toml` present -- [**mix**](https://hexdocs.pm/mix/) - The `mix` package version is extracted from the `mix.exs` present -- [**helm**](https://helm.sh/docs/helm/helm_package/) - The `helm` chart version is extracted from the `Chart.yaml` present -- [**maven**](https://maven.apache.org/) - The `maven` package version is extracted from the `pom.xml` present -- [**meson**](https://mesonbuild.com/) - The `meson` package version is extracted from the `meson.build` present -- [**vlang**](https://vlang.io) - The `vlang` package version is extracted from the `v.mod` present +- [**Cargo**](https://doc.rust-lang.org/cargo/) – The `cargo` package version is extracted from the `Cargo.toml` present in the current directory +- [**Nimble**](https://github.com/nim-lang/nimble) - The `nimble` package version is extracted from the `*.nimble` file present in the current directory with the `nimble dump` command +- [**Poetry**](https://python-poetry.org/) – The `poetry` package version is extracted from the `pyproject.toml` present in the current directory +- [**Python**](https://www.python.org) - The `python` package version is extracted from the `setup.cfg` present in the current directory +- [**Composer**](https://getcomposer.org/) – The `composer` package version is extracted from the `composer.json` present in the current directory +- [**Gradle**](https://gradle.org/) – The `gradle` package version is extracted from the `build.gradle` present +- [**Julia**](https://docs.julialang.org/en/v1/stdlib/Pkg/) - The package version is extracted from the `Project.toml` present +- [**Mix**](https://hexdocs.pm/mix/) - The `mix` package version is extracted from the `mix.exs` present +- [**Helm**](https://helm.sh/docs/helm/helm_package/) - The `helm` chart version is extracted from the `Chart.yaml` present +- [**Maven**](https://maven.apache.org/) - The `maven` package version is extracted from the `pom.xml` present +- [**Meson**](https://mesonbuild.com/) - The `meson` package version is extracted from the `meson.build` present +- [**V**](https://vlang.io) - The `vlang` package version is extracted from the `v.mod` present > ⚠️ The version being shown is that of the package whose source code is in your current directory, not your package manager. @@ -2296,7 +2368,7 @@ python_binary = ["./venv/bin/python", "python", "python3", "python2"] ## R -The `rlang` module shows the currently installed version of R. The module will be shown if any of the following conditions are met: +The `rlang` module shows the currently installed version of [R](https://www.r-project.org/). The module will be shown if any of the following conditions are met: - The current directory contains a file with the `.R` extension. - The current directory contains a file with the `.Rd` extension. @@ -2539,7 +2611,7 @@ disabled = false ## SHLVL -The `shlvl` module shows the current `SHLVL` ("shell level") environment variable, if it is set to a number and meets or exceeds the specified threshold. +The `shlvl` module shows the current [`SHLVL`](https://tldp.org/LDP/abs/html/internalvariables.html#SHLVLREF) ("shell level") environment variable, if it is set to a number and meets or exceeds the specified threshold. ### Options @@ -2894,9 +2966,9 @@ The `vagrant` module shows the currently installed version of [Vagrant](https:// format = "via [⍱ $version](bold white) " ``` -## VLang +## V -The `vlang` module shows you your currently installed version of V. By default the module will be shown if any of the following conditions are met: +The `vlang` module shows you your currently installed version of [V](https://vlang.io/). By default the module will be shown if any of the following conditions are met: - The current directory contains a file with `.v` extension - The current directory contains a `v.mod`, `vpkg.json` or `.vpkg-lock.json` file @@ -2925,7 +2997,7 @@ The `vlang` module shows you your currently installed version of V. By default t ```toml # ~/.config/starship.toml -[v] +[vlang] format = "via [V $version](blue bold) " ``` diff --git a/docs/nl-NL/guide/README.md b/docs/nl-NL/guide/README.md index f9d9916b..69f505cf 100644 --- a/docs/nl-NL/guide/README.md +++ b/docs/nl-NL/guide/README.md @@ -46,30 +46,6 @@ height="20" src="https://raw.githubusercontent.com/starship/starship/master/media/flag-us.png" alt="English" - /> -   - 日本語 -   - 繁體中文 -   - Русский   -   - 简体中文   +   + 日本語 +   + Português do Brasil +   + Русский   +   + 简体中文 +   + 繁體中文

@@ -145,7 +153,7 @@ ### Aan de slag -**Opmerking:**: als gevolg van de groei van verschillende platforms, worden slechts bepaalde ondersteunde platforms hieronder weergegeven. Staat de jouwe er niet tussen? Neem een kijkje in de [extra platforminstructies](https://starship.rs/installing/). +**Opmerking:** als gevolg van de groei van verschillende platforms, worden slechts bepaalde ondersteunde platforms hieronder weergegeven. Staat de jouwe er niet tussen? Neem een kijkje in de [extra platforminstructies](https://starship.rs/installing/). 1. Installeer de **Starship** binary: @@ -158,8 +166,8 @@ ```sh sh -c "$(curl -fsSL https://starship.rs/install.sh)" ``` - Om Starship zelf bij te werken, voer je het bovenstaande script opnieuw uit. Deze vervangt de huidige versie zonder de configuratie van Starship aan te passen. + Om Starship zelf bij te werken, voer je het bovenstaande script opnieuw uit. Deze vervangt de huidige versie zonder de configuratie van Starship aan te passen. **Opmerking** - De standaardinstellingen van het installatiescript kunnen overschreven worden; zie de ingebouwde hulp. @@ -275,7 +283,7 @@ #### Nushell - **Warning** This will change in the future. Only nu version v0.33 or higher is supported. Add the following to your nu config file. You can check the location of this file by running `config path` in nu. + **Warning** This will change in the future. Add the following to your nu config file. De locatie van hiervan kunt u vinden door `config path` uit te voeren in nushell. ```toml startup = [ diff --git a/docs/nl-NL/presets/README.md b/docs/nl-NL/presets/README.md index ae5d0176..c7e62c43 100644 --- a/docs/nl-NL/presets/README.md +++ b/docs/nl-NL/presets/README.md @@ -112,6 +112,9 @@ format = '\[[$symbol($version)]($style)\]' [cmd_duration] format = '\[[⏱ $duration ]($style)\]' +[cobol] +format = '\[[$symbol($version)]($style)\]' + [conda] format = '\[[$symbol$environment]($style)\]' @@ -272,6 +275,9 @@ deleted = "x" [aws] symbol = "aws " +[cobol] +symbol = "cobol " + [conda] symbol = "conda " @@ -375,6 +381,9 @@ This preset hides the version of language runtimes. If you work in containers or [cmake] format = "via [$symbol]($style)" +[cobol] +format = "via [$symbol]($style)" + [crystal] format = "via [$symbol]($style)" diff --git a/docs/pl-PL/README.md b/docs/pl-PL/README.md index 6b4bbaef..3146ab42 100644 --- a/docs/pl-PL/README.md +++ b/docs/pl-PL/README.md @@ -2,18 +2,18 @@ home: true heroImage: /logo.svg heroText: -tagline: The minimal, blazing-fast, and infinitely customizable prompt for any shell! +tagline: Minimalny, szybki i nieskończenie konfigurowalny wiersz poleceń dla dowolnej powłoki! actionText: Get Started → actionLink: ./guide/ features: - - title: Compatibility First + title: Kompatybilność przede wszystkim details: Works on the most common shells on the most common operating systems. Use it everywhere! - - title: Rust-Powered + title: Napędzany językiem Rust details: Brings the best-in-class speed and safety of Rust, to make your prompt as quick and reliable as possible. - - title: Customizable + title: Konfigurowalny details: Every little detail is customizable to your liking, to make this prompt as minimal or feature-rich as you'd like it to be. footer: ISC Licensed | Copyright © 2019-present Starship Contributors #Used for the description meta tag, for SEO @@ -28,26 +28,26 @@ description: Starship is the minimal, blazing fast, and extremely customizable p
-### Prerequisites +### Wymagania wstępne - A [Nerd Font](https://www.nerdfonts.com/) installed and enabled in your terminal. ### Quick Install -1. Install the **starship** binary: +1. Zainstaluj plik programu **starship**: - #### Install Latest Version + #### Instalacja najnowszej wersji With Shell: ```sh sh -c "$(curl -fsSL https://starship.rs/install.sh)" ``` - To update the Starship itself, rerun the above script. It will replace the current version without touching Starship's configuration. + Aby zaktualizować Starship, uruchom ponownie powyższy skrypt. Obecna wersja zostanie zastąpiona nową, bez modyfikowania konfiguracji Starship. - #### Install via Package Manager + #### Instalacja za pomocą menedżera pakietów With [Homebrew](https://brew.sh/): @@ -55,18 +55,18 @@ description: Starship is the minimal, blazing fast, and extremely customizable p brew install starship ``` - With [Scoop](https://scoop.sh): + Za pomocą [Scoop](https://scoop.sh): ```powershell scoop install starship ``` -1. Add the init script to your shell's config file: +1. Dodaj skrypt inicjalizacyjny do konfiguracji twojej powłoki: #### Bash - Add the following to the end of `~/.bashrc`: + Dodaj na koniec pliku `~/.bashrc`: ```sh # ~/.bashrc @@ -77,7 +77,7 @@ description: Starship is the minimal, blazing fast, and extremely customizable p #### Fish - Add the following to the end of `~/.config/fish/config.fish`: + Dodaj na koniec pliku `~/.config/fish/config.fish`: ```sh # ~/.config/fish/config.fish @@ -88,7 +88,7 @@ description: Starship is the minimal, blazing fast, and extremely customizable p #### Zsh - Add the following to the end of `~/.zshrc`: + Dodaj na koniec pliku `~/.zshrc`: ```sh # ~/.zshrc @@ -99,7 +99,7 @@ description: Starship is the minimal, blazing fast, and extremely customizable p #### Powershell - Add the following to the end of `Microsoft.PowerShell_profile.ps1`. You can check the location of this file by querying the `$PROFILE` variable in PowerShell. Typically the path is `~\Documents\PowerShell\Microsoft.PowerShell_profile.ps1` or `~/.config/powershell/Microsoft.PowerShell_profile.ps1` on -Nix. + Add the following to the end of `Microsoft.PowerShell_profile.ps1`. You can check the location of this file by querying the `$PROFILE` variable in PowerShell. Zazwyczaj jest to `~\Documents\PowerShell\Microsoft.PowerShell_profile.ps1` lub `~/.config/powershell/Microsoft.PowerShell_profile.ps1` na -Nixie. ```sh Invoke-Expression (&starship init powershell) @@ -108,7 +108,7 @@ description: Starship is the minimal, blazing fast, and extremely customizable p #### Ion - Add the following to the end of `~/.config/ion/initrc`: + Dodaj na koniec pliku `~/.config/ion/initrc`: ```sh # ~/.config/ion/initrc @@ -121,7 +121,7 @@ description: Starship is the minimal, blazing fast, and extremely customizable p ::: warning Only elvish v0.15 or higher is supported. ::: - Add the following to the end of `~/.elvish/rc.elv`: + Dodaj na koniec pliku `~/.elvish/rc.elv`: ```sh # ~/.elvish/rc.elv @@ -132,7 +132,7 @@ description: Starship is the minimal, blazing fast, and extremely customizable p #### Tcsh - Add the following to the end of `~/.tcshrc`: + Dodaj na koniec pliku `~/.tcshrc`: ```sh # ~/.tcshrc diff --git a/docs/pl-PL/advanced-config/README.md b/docs/pl-PL/advanced-config/README.md index 0d59c601..d5e0c6be 100644 --- a/docs/pl-PL/advanced-config/README.md +++ b/docs/pl-PL/advanced-config/README.md @@ -1,10 +1,10 @@ -# Advanced Configuration +# Zaawansowana konfiguracja -While Starship is a versatile shell, sometimes you need to do more than edit `starship.toml` to get it to do certain things. This page details some of the more advanced configuration techniques used in starship. +Mimo że Starship jest wszechstronny, czasem nie wystarczy modyfikacja pliku `starship.toml` żeby uzyskać pewne rzeczy. Na tej stronie opisano bardziej zaawansowane sposoby konfigurowania używane w Starship. ::: warning -The configurations in this section are subject to change in future releases of Starship. +Konfiguracja opisana w tej sekcji może ulec zmianie w przyszłych wydaniach Starship. ::: @@ -68,6 +68,33 @@ function set_win_title(){ starship_precmd_user_func="set_win_title" ``` +## Enable Right Prompt + +Some shells support a right prompt which renders on the same line as the input. Starship can set the content of the right prompt using the `right_format` option. Any module that can be used in `format` is also supported in `right_format`. The `$all` variable will only contain modules not explicitly used in either `format` or `right_format`. + +Note: The right prompt is a single line following the input location. To right align modules above the input line in a multi-line prompt, see the [fill module](/config/#fill). + +`right_format` is currently supported for the following shells: elvish, fish, zsh. + +### Example + +```toml +# ~/.config/starship.toml + +# A minimal left prompt +format = """$character""" + +# move the rest of the prompt to the right +right_format = """$all""" +``` + +Produces a prompt like the following: + +``` +▶ starship on  rprompt [!] is 📦 v0.57.0 via 🦀 v1.54.0 took 17s +``` + + ## Style Strings Style strings are a list of words, separated by whitespace. The words are not case sensitive (i.e. `bold` and `BoLd` are considered the same string). Each word can be one of the following: diff --git a/docs/pl-PL/config/README.md b/docs/pl-PL/config/README.md index 61f8fcfd..73cf743d 100644 --- a/docs/pl-PL/config/README.md +++ b/docs/pl-PL/config/README.md @@ -1,4 +1,4 @@ -# Configuration +# Konfiguracja To get started configuring starship, create the following file: `~/.config/starship.toml`. @@ -6,7 +6,7 @@ To get started configuring starship, create the following file: `~/.config/stars mkdir -p ~/.config && touch ~/.config/starship.toml ``` -All configuration for starship is done in this [TOML](https://github.com/toml-lang/toml) file: +Cała konfiguracja starship jest wykonywana w tym pliku [TOML](https://github.com/toml-lang/toml): ```toml # Inserts a blank line between shell prompts @@ -21,63 +21,63 @@ success_symbol = "[➜](bold green)" # The "success_symbol" segment is being disabled = true ``` -You can change default configuration file location with `STARSHIP_CONFIG` environment variable: +Możesz zmienić domyślną lokalizację pliku konfiguracyjnego za pomocą zmiennej środowiskowej `STARSHIP_CONFIG`: ```sh export STARSHIP_CONFIG=~/.starship/config.toml ``` -Equivalently in PowerShell (Windows) would be adding this line to your `$PROFILE`: +Odpowiednikiem dla PowerShell (Windows) jest dodanie następującej linii w twoim `$PROFILE`: ```powershell $ENV:STARSHIP_CONFIG = "$HOME\.starship\config.toml" ``` -### Logging +### Logi -By default starship logs warnings and errors into a file named `~/.cache/starship/session_${STARSHIP_SESSION_KEY}.log`, where the session key is corresponding to a instance of your terminal. This, however can be changed using the `STARSHIP_CACHE` environment variable: +Starship domyślnie loguje ostrzeżenia i błędy do pliku o nazwie`~/.cache/starship/session_${STARSHIP_SESSION_KEY}.log`, gdzie klucz sesji odpowiada twojej instancji terminala. Można to zmienić za pomocą zmiennej środowiskowej `STARSHIP_CACHE`: ```sh export STARSHIP_CACHE=~/.starship/cache ``` -Equivalently in PowerShell (Windows) would be adding this line to your `$PROFILE`: +Odpowiednikiem dla PowerShell (Windows) jest dodanie następującej linii w twoim `$PROFILE`: ```powershell $ENV:STARSHIP_CACHE = "$HOME\AppData\Local\Temp" ``` -### Terminology +### Glosariusz -**Module**: A component in the prompt giving information based on contextual information from your OS. For example, the "nodejs" module shows the version of Node.js that is currently installed on your computer, if your current directory is a Node.js project. +**Moduł**: Komponent wiersza poleceń, który dostarcza informacji opartych na kontekście twojego systemu operacyjnego. Przykładowo, moduł "nodejs" pokazuje wersję Node.js, która jest obecnie zainstalowana na twoim komputerze, jeżeli znajdujesz się w folderze zawierającym projekt Node.js. -**Variable**: Smaller sub-components that contain information provided by the module. For example, the "version" variable in the "nodejs" module contains the current version of Node.js. +**Zmienna**: Mniejszy podkomponent zawierający informacje dostarczane przez moduł. Przykładowo, zmienna "version" w module "nodejs" zawiera obecną wersję Node.js. -By convention, most modules have a prefix of default terminal color (e.g. `via` in "nodejs") and an empty space as a suffix. +W ramach konwencji większość modułów posiada przedrostek w domyślnym kolorze terminala (n.p. `via` w "nodejs") oraz pojedynczy odstęp za treścią modułu. -### Format Strings +### Formatowanie -Format strings are the format that a module prints all its variables with. Most modules have an entry called `format` that configures the display format of the module. You can use texts, variables and text groups in a format string. +Moduły wypisują swoje zmienne przy użyciu ciągów formatujących. Większość modułów posiada wpis o nazwie `format`, który konfiguruje format wyświetlania modułu. W ciągach formatujących można używać tekstu, zmiennych oraz grup tekstowych. -#### Variable +#### Zmienne -A variable contains a `$` symbol followed by the name of the variable. The name of a variable only contains letters, numbers and `_`. +Zmienna zawiera symbol `$`, po którym następuje nazwa zmiennej. Nazwa zmiennej zawiera tylko litery, cyfry i `_`. -For example: +Na przykład: -- `$version` is a format string with a variable named `version`. -- `$git_branch$git_commit` is a format string with two variables named `git_branch` and `git_commit`. -- `$git_branch $git_commit` has the two variables separated with a space. +- `$version` to ciąg formatujący ze zmienną o nazwie `version`. +- `$git_branch$git_commit` zawiera dwie zmienne: `git_branch` i `git_commit`. +- `$git_branch $git_commit` zawiera te dwie zmienne rozdzielone spacją. -#### Text Group +#### Grupy tekstowe -A text group is made up of two different parts. +Grupa tekstowa składa się z dwóch oddzielnych części. -The first part, which is enclosed in a `[]`, is a [format string](#format-strings). You can add texts, variables, or even nested text groups in it. +Pierwsza część, otoczona `[]`, to [ciąg formatujący](#format-strings). You can add texts, variables, or even nested text groups in it. -In the second part, which is enclosed in a `()`, is a [style string](#style-strings). This can be used style the first part. +In the second part, which is enclosed in a `()`, is a [style string](#style-strings). This can be used to style the first part. -For example: +Na przykład: - `[on](red bold)` will print a string `on` with bold text colored red. - `[⌘ $version](bold green)` will print a symbol `⌘` followed by the content of variable `version`, with bold text colored green. @@ -100,7 +100,7 @@ Note that what styling looks like will be controlled by your terminal emulator. A conditional format string wrapped in `(` and `)` will not render if all variables inside are empty. -For example: +Na przykład: - `(@$region)` will show nothing if the variable `region` is `None` or empty string, otherwise `@` followed by the value of region. - `(some text)` will always show nothing since there are no variables wrapped in the braces. @@ -142,12 +142,14 @@ This is the list of prompt-wide configuration options. ### Options -| Option | Default | Description | -| ----------------- | ------------------------------ | ------------------------------------------------------------ | -| `format` | [link](#default-prompt-format) | Configure the format of the prompt. | -| `scan_timeout` | `30` | Timeout for starship to scan files (in milliseconds). | -| `command_timeout` | `500` | Timeout for commands executed by starship (in milliseconds). | -| `add_newline` | `true` | Inserts blank line between shell prompts. | +| Option | Default | Description | +| ----------------- | ------------------------------ | ---------------------------------------------------------------- | +| `format` | [link](#default-prompt-format) | Configure the format of the prompt. | +| `right_format` | `""` | See [Enable Right Prompt](/advanced-config/#enable-right-prompt) | +| `scan_timeout` | `30` | Timeout for starship to scan files (in milliseconds). | +| `command_timeout` | `500` | Timeout for commands executed by starship (in milliseconds). | +| `add_newline` | `true` | Inserts blank line between shell prompts. | + ### Example @@ -179,6 +181,7 @@ format = """ $username\ $hostname\ $shlvl\ +$singularity\ $kubernetes\ $directory\ $vcsh\ @@ -191,6 +194,7 @@ $hg_branch\ $docker_context\ $package\ $cmake\ +$cobol\ $dart\ $deno\ $dotnet\ @@ -202,6 +206,7 @@ $helm\ $java\ $julia\ $kotlin\ +$lua\ $nim\ $nodejs\ $ocaml\ @@ -209,6 +214,7 @@ $perl\ $php\ $purescript\ $python\ +$rlang\ $red\ $ruby\ $rust\ @@ -229,7 +235,6 @@ $crystal\ $custom\ $cmd_duration\ $line_break\ -$lua\ $jobs\ $battery\ $time\ @@ -238,6 +243,13 @@ $shell\ $character""" ``` +If you just want to extend the default format, you can use `$all`; modules you explicitly add to the format will not be duplicated. Eg. + +```toml +# Move the directory to the second line +format="$all$directory$character" +``` + ## AWS The `aws` module shows the current AWS region and profile. This is based on `AWS_REGION`, `AWS_DEFAULT_REGION`, and `AWS_PROFILE` env var with `~/.aws/config` file. This module also shows an expiration timer when using temporary credentials. @@ -479,6 +491,36 @@ The `cmake` module shows the currently installed version of [CMake](https://cmak \*: This variable can only be used as a part of a style string +## COBOL / GNUCOBOL + +The `cobol` module shows the currently installed version of COBOL. By default, the module will be shown if any of the following conditions are met: + +- The current directory contains any files ending in `.cob` or `.COB` +- The current directory contains any files ending in `.cbl` or `.CBL` + +### Options + +| Option | Default | Description | +| ------------------- | ------------------------------------ | ------------------------------------------------------------------------- | +| `symbol` | `"⚙️ "` | The symbol used before displaying the version of COBOL. | +| `format` | `"via [$symbol($version )]($style)"` | The format for the module. | +| `version_format` | `"v${raw}"` | The version format. Available vars are `raw`, `major`, `minor`, & `patch` | +| `style` | `"bold blue"` | The style for the module. | +| `detect_extensions` | `["cbl", "cob", "CBL", "COB"]` | Which extensions should trigger this module. | +| `detect_files` | `[]` | Which filenames should trigger this module. | +| `detect_folders` | `[]` | Which folders should trigger this module. | +| `disabled` | `false` | Disables the `cobol` module. | + +### Variables + +| Variable | Example | Description | +| --------- | ---------- | ------------------------------------ | +| version | `v3.1.2.0` | The version of `cobol` | +| 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 + ## Command Duration The `cmd_duration` module shows how long the last command took to execute. The module will be shown only if the command took longer than two seconds, or the `min_time` config value, if it exists. @@ -530,7 +572,7 @@ format = "underwent [$duration](bold yellow)" ## Conda -The `conda` module shows the current conda environment, if `$CONDA_DEFAULT_ENV` is set. +The `conda` module shows the current [Conda](https://docs.conda.io/en/latest/) environment, if `$CONDA_DEFAULT_ENV` is set. ::: tip @@ -1017,6 +1059,35 @@ The `erlang` module shows the currently installed version of [Erlang/OTP](https: format = "via [e $version](bold red) " ``` +## 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. + +### Options + +| Option | Default | Description | +| -------- | -------------- | --------------------------------- | +| `symbol` | `"."` | The symbol used to fill the line. | +| `style` | `"bold black"` | The style for the module. | + +### Example + +```toml +# ~/.config/starship.toml +format="AA $fill BB $fill CC" + +[fill] +symbol = "-" +style = "bold green" +``` + +Produces a prompt that looks like: + +``` +AA -------------------------------------------- BB -------------------------------------------- CC + +``` + ## 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. @@ -1205,12 +1276,13 @@ This module is disabled by default. To enable it, set `disabled` to `false` in y ### Options -| Option | Default | Description | -| --------------- | -------------------------------------------------------- | ---------------------------------- | -| `added_style` | `"bold green"` | The style for the added count. | -| `deleted_style` | `"bold red"` | The style for the deleted count. | -| `format` | `'[+$added]($added_style) [-$deleted]($deleted_style) '` | The format for the module. | -| `disabled` | `true` | Disables the `git_metrics` module. | +| Option | Default | Description | +| -------------------- | ------------------------------------------------------------ | ------------------------------------- | +| `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. | +| `disabled` | `true` | Disables the `git_metrics` module. | ### Variables @@ -1318,9 +1390,9 @@ diverged = "⇕⇡${ahead_count}⇣${behind_count}" behind = "⇣${count}" ``` -## Golang +## Go -The `golang` module shows the currently installed version of [Golang](https://golang.org/). By default the module will be shown if any of the following conditions are met: +The `golang` module shows the currently installed version of [Go](https://golang.org/). By default the module will be shown if any of the following conditions are met: - The current directory contains a `go.mod` file - The current directory contains a `go.sum` file @@ -2041,18 +2113,18 @@ symbol = "☁️ " 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`, `composer`, `gradle`, `julia`, `mix` and `helm` 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 -- [**nimble**](https://github.com/nim-lang/nimble) - The `nimble` package version is extracted from the `*.nimble` file present in the current directory with the `nimble dump` command -- [**poetry**](https://python-poetry.org/) – The `poetry` package version is extracted from the `pyproject.toml` present in the current directory -- [**python**](https://www.python.org) - The `python` package version is extracted from the `setup.cfg` present in the current directory -- [**composer**](https://getcomposer.org/) – The `composer` package version is extracted from the `composer.json` present in the current directory -- [**gradle**](https://gradle.org/) – The `gradle` package version is extracted from the `build.gradle` present -- [**julia**](https://docs.julialang.org/en/v1/stdlib/Pkg/) - The package version is extracted from the `Project.toml` present -- [**mix**](https://hexdocs.pm/mix/) - The `mix` package version is extracted from the `mix.exs` present -- [**helm**](https://helm.sh/docs/helm/helm_package/) - The `helm` chart version is extracted from the `Chart.yaml` present -- [**maven**](https://maven.apache.org/) - The `maven` package version is extracted from the `pom.xml` present -- [**meson**](https://mesonbuild.com/) - The `meson` package version is extracted from the `meson.build` present -- [**vlang**](https://vlang.io) - The `vlang` package version is extracted from the `v.mod` present +- [**Cargo**](https://doc.rust-lang.org/cargo/) – The `cargo` package version is extracted from the `Cargo.toml` present in the current directory +- [**Nimble**](https://github.com/nim-lang/nimble) - The `nimble` package version is extracted from the `*.nimble` file present in the current directory with the `nimble dump` command +- [**Poetry**](https://python-poetry.org/) – The `poetry` package version is extracted from the `pyproject.toml` present in the current directory +- [**Python**](https://www.python.org) - The `python` package version is extracted from the `setup.cfg` present in the current directory +- [**Composer**](https://getcomposer.org/) – The `composer` package version is extracted from the `composer.json` present in the current directory +- [**Gradle**](https://gradle.org/) – The `gradle` package version is extracted from the `build.gradle` present +- [**Julia**](https://docs.julialang.org/en/v1/stdlib/Pkg/) - The package version is extracted from the `Project.toml` present +- [**Mix**](https://hexdocs.pm/mix/) - The `mix` package version is extracted from the `mix.exs` present +- [**Helm**](https://helm.sh/docs/helm/helm_package/) - The `helm` chart version is extracted from the `Chart.yaml` present +- [**Maven**](https://maven.apache.org/) - The `maven` package version is extracted from the `pom.xml` present +- [**Meson**](https://mesonbuild.com/) - The `meson` package version is extracted from the `meson.build` present +- [**V**](https://vlang.io) - The `vlang` package version is extracted from the `v.mod` present > ⚠️ The version being shown is that of the package whose source code is in your current directory, not your package manager. @@ -2296,7 +2368,7 @@ python_binary = ["./venv/bin/python", "python", "python3", "python2"] ## R -The `rlang` module shows the currently installed version of R. The module will be shown if any of the following conditions are met: +The `rlang` module shows the currently installed version of [R](https://www.r-project.org/). The module will be shown if any of the following conditions are met: - The current directory contains a file with the `.R` extension. - The current directory contains a file with the `.Rd` extension. @@ -2539,7 +2611,7 @@ disabled = false ## SHLVL -The `shlvl` module shows the current `SHLVL` ("shell level") environment variable, if it is set to a number and meets or exceeds the specified threshold. +The `shlvl` module shows the current [`SHLVL`](https://tldp.org/LDP/abs/html/internalvariables.html#SHLVLREF) ("shell level") environment variable, if it is set to a number and meets or exceeds the specified threshold. ### Options @@ -2894,9 +2966,9 @@ The `vagrant` module shows the currently installed version of [Vagrant](https:// format = "via [⍱ $version](bold white) " ``` -## VLang +## V -The `vlang` module shows you your currently installed version of V. By default the module will be shown if any of the following conditions are met: +The `vlang` module shows you your currently installed version of [V](https://vlang.io/). By default the module will be shown if any of the following conditions are met: - The current directory contains a file with `.v` extension - The current directory contains a `v.mod`, `vpkg.json` or `.vpkg-lock.json` file @@ -2925,7 +2997,7 @@ The `vlang` module shows you your currently installed version of V. By default t ```toml # ~/.config/starship.toml -[v] +[vlang] format = "via [V $version](blue bold) " ``` diff --git a/docs/pl-PL/faq/README.md b/docs/pl-PL/faq/README.md index 2b3096c1..9fe9b676 100644 --- a/docs/pl-PL/faq/README.md +++ b/docs/pl-PL/faq/README.md @@ -1,18 +1,18 @@ -# FAQ +# Najczęściej zadawane pytania (FAQ) -## What is the configuration used in the demo GIF? +## Jakiej konfiguracji użyto w GIFie demonstracyjnym? -- **Terminal Emulator**: [iTerm2](https://iterm2.com/) - - **Theme**: Minimal - - **Color Scheme**: [Snazzy](https://github.com/sindresorhus/iterm2-snazzy) - - **Font**: [FiraCode Nerd Font](https://www.nerdfonts.com/font-downloads) -- **Shell**: [Fish Shell](https://fishshell.com/) - - **Configuration**: [matchai's Dotfiles](https://github.com/matchai/dotfiles/blob/b6c6a701d0af8d145a8370288c00bb9f0648b5c2/.config/fish/config.fish) - - **Prompt**: [Starship](https://starship.rs/) +- **Emulator terminala**: [iTerm2](https://iterm2.com/) + - **Motyw**: Minimal + - **Schemat kolorów**: [Snazzy](https://github.com/sindresorhus/iterm2-snazzy) + - **Czcionka**: [FiraCode Nerd Font](https://www.nerdfonts.com/font-downloads) +- **Powłoka**: [Fish Shell](https://fishshell.com/) + - **Konfiguracja**: [Pliki Dotfile użytkownika matchai](https://github.com/matchai/dotfiles/blob/b6c6a701d0af8d145a8370288c00bb9f0648b5c2/.config/fish/config.fish) + - **Wiersz poleceń**: [Starship](https://starship.rs/) -## How do I get command completion as shown in the demo GIF? +## Jak uzyskać uzupełniania poleceń pokazane na GIFie demonstracyjnym? -Completion support, or autocomplete, is provided by your shell of choice. In the case of the demo, the demo was done with [Fish Shell](https://fishshell.com/), which provides completions by default. If you use Z Shell (zsh), I'd suggest taking a look at [zsh-autosuggestions](https://github.com/zsh-users/zsh-autosuggestions). +Uzupełnianie, znane też jako autouzupełnianie, jest dostarczane przez używaną przez ciebie powłokę. W przypadku demo, jest to powłoka [Fish Shell](https://fishshell.com/), która domyślnie zapewnia uzupełnianie. Jeśli używasz Z Shell (zsh), zalecamy zapoznać się z [zsh-autosuggestions](https://github.com/zsh-users/zsh-autosuggestions). ## Do top level `format` and `.disabled` do the same thing? @@ -21,7 +21,7 @@ Yes, they can both be used to disable modules in the prompt. If all you plan to - Disabling modules is more explicit than omitting them from the top level `format` - Newly created modules will be added to the prompt as Starship is updated -## The docs say Starship is cross-shell. Why isn't my preferred shell supported? +## Dokumentacja stwierdza że Starship jest wieloplatformowy. Dlaczego moja preferowana powłoka nie jest obsługiwana? The way Starship is built, it should be possible to add support for virtually any shell. The starship binary is stateless and shell agnostic, so as long as your shell supports prompt customization and shell expansion, Starship can be used. @@ -48,17 +48,17 @@ starship prompt --help The prompt will use as much context as is provided, but no flags are "required". -## How do I run Starship on Linux distributions with older versions of glibc? +## Jak uruchomić Starship na dystrybucjach systemu Linux ze starszymi wersjami glibc? -If you get an error like "_version 'GLIBC_2.18' not found (required by starship)_" when using the prebuilt binary (for example, on CentOS 6 or 7), you can use a binary compiled with `musl` instead of `glibc`: +Jeżeli podczas używania gotowych instalacji (np. na CentOS 6 lub 7) pojawia się błąd w stylu "_version 'GLIBC_2.18' not found (required by starship)_", możesz użyć instalacji zbudowanej za pomocą `musl` zamiast `glibc`: ```sh sh -c "$(curl -fsSL https://starship.rs/install.sh)" -- --platform unknown-linux-musl ``` -## I see symbols I don't understand or expect, what do they mean? +## W wierszu poleceń zauważyłem symbole których się nie spodziewałem bądź nie rozumiem. Co one oznaczają? -If you see symbols that you don't recognise you can use `starship explain` to explain the currently showing modules. +Jeśli zauważyłeś symbole których nie rozpoznajesz, możesz użyć `starship explain` aby uzyskać szczegółowy opis obecnie wyświetlanych modułów. ## Why don't I see a glyph symbol in my prompt? @@ -79,12 +79,12 @@ The first line should produce a [snake emoji](https://emojipedia.org/snake/), wh If either symbol fails to display correctly, your system is still misconfigured. Unfortunately, getting font configuration correct is sometimes difficult. Users on the Discord may be able to help. If both symbols display correctly, but you still don't see them in starship, [file a bug report!](https://github.com/starship/starship/issues/new/choose) -## How do I uninstall Starship? +## Jak odinstalować Starship? -Starship is just as easy to uninstall as it is to install in the first place. +Starship można odinstalować równie łatwo jak przebiega proces instalacji. -1. Remove any lines in your shell config (e.g. `~/.bashrc`) used to initialize Starship. -1. Delete the Starship binary. +1. Usuń zawartość konfiguracji powłoki (np. `~/.bashrc`) służącą do zainicjalizowania Starship. +1. Usuń plik wykonywalny programu Starship. If Starship was installed using a package manager, please refer to their docs for uninstallation instructions. diff --git a/docs/pl-PL/guide/README.md b/docs/pl-PL/guide/README.md index 5641182f..e5f014bc 100644 --- a/docs/pl-PL/guide/README.md +++ b/docs/pl-PL/guide/README.md @@ -10,36 +10,36 @@ GitHub Actions workflow status Crates.io version Packaging status
Chat on Discord Follow @StarshipPrompt on Twitter

- Website + Strona internetowa · - Installation + Instalacja · - Configuration + Konfiguracja

@@ -48,30 +48,6 @@ height="20" src="https://raw.githubusercontent.com/starship/starship/master/media/flag-us.png" alt="English" - /> -   - 日本語 -   - 繁體中文 -   - Русский   -   - 简体中文   +   + 日本語 +   + Português do Brasil +   + Русский   +   + 简体中文 +   + 繁體中文

Starship with iTerm2 and the Snazzy theme -**The minimal, blazing-fast, and infinitely customizable prompt for any shell!** +**Minimalny, szybki i nieskończenie konfigurowalny wiersz poleceń dla dowolnej powłoki!** -- **Fast:** it's fast – _really really_ fast! 🚀 -- **Customizable:** configure every aspect of your prompt. -- **Universal:** works on any shell, on any operating system. -- **Intelligent:** shows relevant information at a glance. -- **Feature rich:** support for all your favorite tools. -- **Easy:** quick to install – start using it in minutes. +- **Szybkość:** jest szybki - _naprawdę_ szybki! 🚀 +- **Konfigurowalny:** dostosowuj swój wiersz poleceń w każdym aspekcie. +- **Uniwersalny:** działa na każdej powłoce, na każdym systemie operacyjnym. +- **Inteligentny:** pokazuje istotne informacje na pierwszy rzut oka. +- **Bogata funkcjonalność:** wspiera wszystkie twoje ulubione narzędzia. +- **Łatwy w obsłudze:** szybka instalacja - zacznij korzystać w kilka minut.

-Explore the Starship docs  ▶ +Przeglądaj dokumentację Starship  ▶

-## 🚀 Installation +## 🚀Instalacja -### Prerequisites +### Wymagania wstępne -- A [Nerd Font](https://www.nerdfonts.com/) installed and enabled in your terminal (for example, try the [Fira Code Nerd Font](https://www.nerdfonts.com/font-downloads)). +- Czcionka typu [Nerd Font](https://www.nerdfonts.com/) zainstalowana i ustawiona w twoim terminalu (wypróbuj na przykład [Fira Code Nerd Font](https://www.nerdfonts.com/font-downloads)). -### Getting Started +### Pierwsze kroki -**Note**: due to the proliferation of different platforms, only a subset of supported platforms are shown below. Can't see yours? Have a look at the [extra platform instructions](https://starship.rs/installing/). +**Uwaga**: z powodu szybko rosnącej liczby platform poniżej pokazano wybrane platformy spośród obecnie obsługiwanych. Nie widzisz swojej? Sprawdź w [dodatkowych instrukcjach dla platform](https://starship.rs/installing/). -1. Install the **starship** binary: +1. Zainstaluj plik programu **starship**: - #### Install Latest Version + #### Instalacja najnowszej wersji - ##### From prebuilt binary, with Shell: + ##### Z wstępnie zbudowanego pliku wykonywalnego, za pomocą powłoki Shell: ```sh sh -c "$(curl -fsSL https://starship.rs/install.sh)" ``` - To update the Starship itself, rerun the above script. It will replace the current version without touching Starship's configuration. + Aby zaktualizować Starship, uruchom ponownie powyższy skrypt. Obecna wersja zostanie zastąpiona nową, bez modyfikowania konfiguracji Starship. - **Note** - The defaults of the install script can be overridden see the built-in help. + **Uwaga** - Domyślne ustawienia skryptu instalacyjnego można zmienić - szczegóły znajdziesz we wbudowanym poleceniu pomocy. ```sh sh -c "$(curl -fsSL https://starship.rs/install.sh)" -- --help ``` - #### Install via Package Manager + #### Instalacja za pomocą menedżera pakietów - ##### Example: [Homebrew](https://brew.sh/): + ##### Przykład: [Homebrew](https://brew.sh/): ```sh brew install starship ``` - ##### With [Scoop](https://scoop.sh): + ##### Za pomocą [Scoop](https://scoop.sh): ```powershell scoop install starship ``` -2. Add the init script to your shell's config file: +2. Dodaj skrypt inicjalizacyjny do konfiguracji twojej powłoki: #### Bash - Add the following to the end of `~/.bashrc`: + Dodaj na koniec pliku `~/.bashrc`: ```sh # ~/.bashrc @@ -202,7 +210,7 @@ #### Fish - Add the following to the end of `~/.config/fish/config.fish`: + Dodaj na koniec pliku `~/.config/fish/config.fish`: ```sh # ~/.config/fish/config.fish @@ -213,7 +221,7 @@ #### Zsh - Add the following to the end of `~/.zshrc`: + Dodaj na koniec pliku `~/.zshrc`: ```sh # ~/.zshrc @@ -224,7 +232,7 @@ #### PowerShell - Add the following to the end of `Microsoft.PowerShell_profile.ps1`. You can check the location of this file by querying the `$PROFILE` variable in PowerShell. Typically the path is `~\Documents\PowerShell\Microsoft.PowerShell_profile.ps1` or `~/.config/powershell/Microsoft.PowerShell_profile.ps1` on -Nix. + Dodaj na koniec pliku `Microsoft.PowerShell_profile.ps1`. Możesz sprawdzić lokalizację tego pliku odczytując zmienną środowiskową `$PROFILE` w PowerShell. Zazwyczaj jest to `~\Documents\PowerShell\Microsoft.PowerShell_profile.ps1` lub `~/.config/powershell/Microsoft.PowerShell_profile.ps1` na -Nixie. ```powershell Invoke-Expression (&starship init powershell) @@ -233,7 +241,7 @@ #### Ion - Add the following to the end of `~/.config/ion/initrc`: + Dodaj na koniec pliku `~/.config/ion/initrc`: ```sh # ~/.config/ion/initrc @@ -244,7 +252,7 @@ #### Elvish - **Warning** Only elvish v0.15 or higher is supported. Add the following to the end of `~/.elvish/rc.elv`: + **Uwaga** Działa tylko dla wersji powłoki elvish v0.15 lub wyższej. Dodaj na koniec pliku `~/.elvish/rc.elv`: ```sh # ~/.elvish/rc.elv @@ -255,7 +263,7 @@ #### Tcsh - Add the following to the end of `~/.tcshrc`: + Dodaj na koniec pliku `~/.tcshrc`: ```sh # ~/.tcshrc @@ -266,7 +274,7 @@ #### Xonsh - Add the following to the end of `~/.xonshrc`: + Dodaj na koniec pliku `~/.xonshrc`: ```sh # ~/.xonshrc @@ -277,7 +285,7 @@ #### Nushell - **Warning** This will change in the future. Only nu version v0.33 or higher is supported. Add the following to your nu config file. You can check the location of this file by running `config path` in nu. + **Uwaga** Może ulec zmianie w przyszłości. Działa tylko dla wersji powłoki nu v0.33 lub wyższej. Dodaj do pliku konfiguracyjnego nu. Możesz sprawdzić lokalizację tego pliku wywołując polecenie `config path` w powłoce nu. ```toml startup = [ @@ -288,30 +296,30 @@ prompt = "starship_prompt" ``` -## 🤝 Contributing +## 🤝Wspomóż nas -We are always looking for contributors of **all skill levels**! If you're looking to ease your way into the project, try out a [good first issue](https://github.com/starship/starship/labels/🌱%20good%20first%20issue). +Zawsze szukamy pomocy od osób **na każdym poziomie zaawansowania**! Jeśli potrzebujesz łatwiejszego wdrożenia w projekt, wypróbuj [good first issue](https://github.com/starship/starship/labels/🌱%20good%20first%20issue). -If you are fluent in a non-English language, we greatly appreciate any help keeping our docs translated and up-to-date in other languages. If you would like to help, translations can be contributed on the [Starship Crowdin](https://translate.starship.rs/). +Jeśli płynnie władasz językiem innym niż angielski, bardzo doceniamy każdą pomoc w tłumaczeniu dokumentacji. Jeśli chcesz pomóc, tłumaczenia można dodawać na [Starship Crowdin](https://translate.starship.rs/). -If you are interested in helping contribute to starship, please take a look at our [Contributing Guide](https://github.com/starship/starship/blob/master/CONTRIBUTING.md). Also, feel free to drop into our [Discord server](https://discord.gg/8Jzqu3T) and say hi. 👋 +Jeżeli chcesz wspomóc tworzenie starship, zapoznaj się z naszym [Poradnikiem Współpracy](https://github.com/starship/starship/blob/master/CONTRIBUTING.md). Ponadto możesz wejść na nasz [serwer Discord](https://discord.gg/8Jzqu3T) i się przywitać. 👋 -### Code Contributors +### Współtwórcy kodu -This project exists thanks to all the people who contribute. [[Contribute](https://github.com/starship/starship/blob/master/CONTRIBUTING.md)]. +Ten projekt istnieje dzięki pomocy wszystkich zaangażowanych osób. [[Wspomóż nas](https://github.com/starship/starship/blob/master/CONTRIBUTING.md)]. -### Financial Contributors +### Wsparcie finansowe -Become a financial contributor and help us sustain our community. [[Contribute](https://opencollective.com/starship/contribute)] +Udziel wsparcia finansowego i pomóż nam utrzymywać społeczność. [[Wspomóż nas](https://opencollective.com/starship/contribute)] -#### Individuals +#### Osoby prywatne -#### Organizations +#### Organizacje -Support this project with your organization. Your logo will show up here with a link to your website. [[Contribute](https://opencollective.com/starship/contribute)] +Wspieraj ten projekt za pomocą swojej organizacji. Twoje logo pojawi się tutaj z linkiem do Twojej witryny. [[Wspomóż nas](https://opencollective.com/starship/contribute)] @@ -324,21 +332,21 @@ Support this project with your organization. Your logo will show up here with a -## 💭 Inspired By +## 💭Inspiracje -Please check out these previous works that helped inspire the creation of starship. 🙏 +Zapoznaj się z wcześniejszymi projektami które zainspirowały nas do stworzenia starship. 🙏 -- **[denysdovhan/spaceship-prompt](https://github.com/denysdovhan/spaceship-prompt)** - A ZSH prompt for astronauts. +- **[denysdovhan/spaceship-prompt](https://github.com/denysdovhan/spaceship-prompt)** - Wiersz poleceń ZSH dla astronautów. -- **[denysdovhan/robbyrussell-node](https://github.com/denysdovhan/robbyrussell-node)** - Cross-shell robbyrussell theme written in JavaScript. +- **[denysdovhan/robbyrussell-node](https://github.com/denysdovhan/robbyrussell-node)** - Motyw robyrussell dla wielu powłok, napisany w JavaScript. -- **[reujab/silver](https://github.com/reujab/silver)** - A cross-shell customizable powerline-like prompt with icons. +- **[reujab/silver](https://github.com/reujab/silver)** - Wiersz polecenia typu Powerline z ikonami, działa na wielu różnych powłokach.


Starship rocket icon

-## 📝 License +## 📝 Licencja Copyright © 2019-present, [Starship Contributors](https://github.com/starship/starship/graphs/contributors).
This project is [ISC](https://github.com/starship/starship/blob/master/LICENSE) licensed. diff --git a/docs/pl-PL/installing/README.md b/docs/pl-PL/installing/README.md index 6bb76850..7675d70a 100644 --- a/docs/pl-PL/installing/README.md +++ b/docs/pl-PL/installing/README.md @@ -1,21 +1,21 @@ -# 🚀 Advanced Installation +# 🚀 Zaawansowana Instalacja -To install starship, you need to do two things: +Aby zainstalować starship, musisz zrobić dwie rzeczy: -1. Get the **starship** binary onto your computer -1. Tell your shell to use the starship binary as its prompt by modifying its init scripts +1. Pobrać plik wykonywalny **starship** na swój komputer +1. Skonfigurować swoją powłokę żeby używała pliku wykonywalnego starship jako wiersza poleceń poprzez modyfikację skryptów inicjalizacyjnych -For most users, the instructions on [the main page](/guide/#🚀-installation) will work great. However, for some more specialized platforms, different instructions are needed. +Dla większości użytkowników instrukcje na [stronie głównej](/guide/#🚀-installation) są wystarczające. However, for some more specialized platforms, different instructions are needed. There are so many platforms out there that they didn't fit into the main README.md file, so here are some installation instructions for other platforms from the community. Is yours not here? Please do add it here if you figure it out! ## [Chocolatey](https://chocolatey.org) -### Prerequisites +### Wymagania wstępne Head over to the [Chocolatey installation page](https://chocolatey.org/install) and follow the instructions to install Chocolatey. -### Installation +### Instalacja ```powershell choco install starship @@ -23,13 +23,13 @@ choco install starship ## [termux](https://termux.com) -### Prerequisites +### Wymagania wstępne ```sh pkg install getconf ``` -### Installation +### Instalacja ```sh sh -c "$(curl -fsSL https://starship.rs/install.sh)" -- --bin-dir /data/data/com.termux/files/usr/bin diff --git a/docs/pl-PL/migrating-to-0.45.0/README.md b/docs/pl-PL/migrating-to-0.45.0/README.md index 95a847bf..1f64546a 100644 --- a/docs/pl-PL/migrating-to-0.45.0/README.md +++ b/docs/pl-PL/migrating-to-0.45.0/README.md @@ -1,4 +1,4 @@ -# Migrating to v0.45.0 +# Migracja do wersji v0.45.0 Starship v0.45.0 is a release containing breaking changes, in preparation for the big v1.0.0. We have made some major changes around how configuration is done on the prompt, to allow for a greater degree of customization. diff --git a/docs/pl-PL/presets/README.md b/docs/pl-PL/presets/README.md index c6cc6f60..8bb7b266 100644 --- a/docs/pl-PL/presets/README.md +++ b/docs/pl-PL/presets/README.md @@ -1,18 +1,18 @@ -# Presets +# Gotowe konfiguracje -Here is a collection of community-submitted configuration presets for Starship. If you have a preset to share, please [submit a PR](https://github.com/starship/starship/edit/master/docs/presets/README.md) updating this file! 😊 +Poniżej zamieszczono zestaw gotowych konfiguracji Starship stworzonych przez społeczność. Jeżeli chcesz zamieścić własną konfigurację, [złóż PR](https://github.com/starship/starship/edit/master/docs/presets/README.md) z modyfikacją tego pliku! 😊 -## Nerd Font Symbols +## Symbole Nerd Font -This preset doesn't change anything except for the symbols used for each module. If emojis aren't your thing, this might catch your eye! +Poniższa konfiguracja nie zmienia nic poza znaczkami użytymi do oznaczenia poszczególnych modułów. Jeżeli nie jesteś fanem emoji, to może ci się spodobać! ![Screenshot of Nerd Font Symbols preset](/presets/nerd-font-symbols.png) -### Prerequisites +### Wymagania wstępne -- A [Nerd Font](https://www.nerdfonts.com/) installed and enabled in your terminal (the example uses Fira Code Nerd Font) +- Czcionka [Nerd Font](https://www.nerdfonts.com/) zainstalowana i ustawiona w twoim terminalu (w przykładzie użyto Fira Code Nerd Font) -### Configuration +### Konfiguracja ```toml [aws] @@ -88,19 +88,19 @@ symbol = " " symbol = "ﯣ " ``` -## Bracketed Segments +## Moduły w nawiasach kwadratowych -This preset changes the format of all the built-in modules to show their segment in brackets instead of using the default Starship wording ("via", "on", etc.). +Ta konfiguracja zmienia format wyświetlania wbudowanych modułów - zamiast domyślnych wyrazów ("via", "on", itp.) są wypisywane w nawiasach kwadratowych. -Before: +Przed: ![Screenshot of default Starship configuration](/presets/bracketed-segments-before.png) -After: +Po: ![Screenshot of Bracketed Segments preset](/presets/bracketed-segments-after.png) -### Configuration +### Konfiguracja ```toml [aws] @@ -112,6 +112,9 @@ format = '\[[$symbol($version)]($style)\]' [cmd_duration] format = '\[[⏱ $duration ]($style)\]' +[cobol] +format = '\[[$symbol($version)]($style)\]' + [conda] format = '\[[$symbol$environment]($style)\]' @@ -239,7 +242,7 @@ format = '\[[$symbol($version)]($style)\]' format = '\[[$symbol($version)]($style)\]' ``` -## Plain Text Symbols +## Symbole "plain text" This preset changes the symbols into plain text. If your terminal/font could not render the NerdFonts/emojis, maybe you could try this preset! @@ -251,7 +254,7 @@ After (Plain Text Symbols): ![Screenshot of Plain Text Symbols preset](/presets/plain-text-symbols-after.png) -### Configuration +### Konfiguracja ```toml [character] @@ -272,6 +275,9 @@ deleted = "x" [aws] symbol = "aws " +[cobol] +symbol = "cobol " + [conda] symbol = "conda " @@ -369,12 +375,15 @@ This preset hides the version of language runtimes. If you work in containers or ![Screenshot of Hide Runtime Versions preset](/presets/hide-runtime-versions.png) -### Configuration +### Konfiguracja ```toml [cmake] format = "via [$symbol]($style)" +[cobol] +format = "via [$symbol]($style)" + [crystal] format = "via [$symbol]($style)" diff --git a/docs/pt-BR/advanced-config/README.md b/docs/pt-BR/advanced-config/README.md index b1df7aca..cf90c06e 100644 --- a/docs/pt-BR/advanced-config/README.md +++ b/docs/pt-BR/advanced-config/README.md @@ -68,9 +68,36 @@ function set_win_title(){ starship_precmd_user_func="set_win_title" ``` +## Ativando o Prompt Direito + +Alguns shells suportam um prompt no lado direito que renderiza na mesma linha do input. Starship consegue definir o conteúdo do prompt direito usando a opção `right_format`. Qualquer módulo pode ser usado no `format` é suportado o `right_format`. A variável `$all` só irá alterar os módulos que não usaram de forma explicita o `format` ou `right_format`. + +Note: The right prompt is a single line following the input location. To right align modules above the input line in a multi-line prompt, see the [fill module](/config/#fill). + +`right_format` is currently supported for the following shells: elvish, fish, zsh. + +### Exemplo + +```toml +# ~/.config/starship.toml + +# Um prompt esquerdo minimo +format = """$character""" + +# Move o resto do prompt para direita +right_format = """$all""" +``` + +Gera um prompt parecido com o seguinte: + +``` +▶ starship on  rprompt [!] is 📦 v0.57.0 via 🦀 v1.54.0 took 17s +``` + + ## Estilo dos textos -Estilo de strings são uma lista de palavras, separadas por espaço. As palavras não são case sensitive (ou seja `bold` e `BoLd` são consideradas iguais). Cada palavra pode ser uma das seguintes: +Style strings are a list of words, separated by whitespace. The words are not case sensitive (i.e. `bold` and `BoLd` are considered the same string). Each word can be one of the following: - `bold` - `italic` @@ -82,14 +109,14 @@ Estilo de strings são uma lista de palavras, separadas por espaço. As palavras - `` - `none` -onde `` é uma especialista de cores (discutido abaixo). `fg:` e `` atualmente fazem a mesma coisa, isto deve mudar no futuro. `inverted` troca as cores de background e foreground. A ordem de palavras na string não importa. +where `` is a color specifier (discussed below). `fg:` and `` currently do the same thing, though this may change in the future. `inverted` swaps the background and foreground colors. The order of words in the string does not matter. -O token `none` substitui todos os outros tokens na string se ele não fizer parte de um `bg:` especificado que seja, por exemplo `fg:red none fg:blue` ainda criará uma string sem estilo. `bg:none` define a cor padrão de background então `fg:red bg:none` é equivalente a `red` ou `fg:red` e `bg:green fg:red bg:none` é equivalente a `fg:red` ou`red`. Pode se transformar em um erro ao usar `none` em um conjunto de outros tokens no futuro. +The `none` token overrides all other tokens in a string if it is not part of a `bg:` specifier, so that e.g. `fg:red none fg:blue` will still create a string with no styling. `bg:none` sets the background to the default color so `fg:red bg:none` is equivalent to `red` or `fg:red` and `bg:green fg:red bg:none` is also equivalent to `fg:red` or `red`. It may become an error to use `none` in conjunction with other tokens in the future. -Um especialista em cores pode ser um dos seguintes: +A color specifier can be one of the following: - Um dos padrões de cores no terminal: `black`, `red`, `green`, `blue`, `yellow`, `purple`, `cyan`, `white`. Você pode de forma opcional prefixar com `bright-` para obter uma versão mais brilhante/clara (ex `bright-white`). - Um `#` seguido por um número de seis dígitos hexadecimais. Isto especifica um [Código RGB em formato hexadecimal](https://www.w3schools.com/colors/colors_hexadecimal.asp). - Um número entre 0-255. Este especifica um [Código de Cor ANSI 8 bits](https://i.stack.imgur.com/KTSQa.png). -Se múltiplas cores forem especificadas para foreground/background, a ultima da string que terá prioridade. +If multiple colors are specified for foreground/background, the last one in the string will take priority. diff --git a/docs/pt-BR/config/README.md b/docs/pt-BR/config/README.md index 3d1809ad..60afc3a1 100644 --- a/docs/pt-BR/config/README.md +++ b/docs/pt-BR/config/README.md @@ -75,7 +75,7 @@ Um grupo de texto é composto por duas partes diferentes. A primeira parte, é contida em um `[]`, é uma [formatação de string](#format-strings). Você pode adicionar textos, variáveis ou até mesmos grupo de textos aninhados. -Na segunda parte, é composta por um `()`, é uma [estilização de string](#style-strings). Este pode ser usado para estilizar a primeira parte. +Na segunda parte, é composta por um `()`, é uma [estilização de string](#style-strings). This can be used to style the first part. Por exemplo: @@ -142,12 +142,14 @@ Está é a lista de opções de configuração de prompt. ### Opções -| Opções | Padrão | Descrição | -| ----------------- | ------------------------------ | ---------------------------------------------------------------------- | -| `format` | [link](#default-prompt-format) | Configura o formato do prompt. | -| `scan_timeout` | `30` | Tempo limite para escanear arquivos (em milissegundos). | -| `command_timeout` | `500` | Tempo limite de execução de comandos pelo starship (em milissegundos). | -| `add_newline` | `true` | Insere linha vazia entre os prompts do shell. | +| Opções | Padrão | Descrição | +| ----------------- | ------------------------------ | ---------------------------------------------------------------- | +| `format` | [link](#default-prompt-format) | Configura o formato do prompt. | +| `right_format` | `""` | See [Enable Right Prompt](/advanced-config/#enable-right-prompt) | +| `scan_timeout` | `30` | Timeout for starship to scan files (in milliseconds). | +| `command_timeout` | `500` | Timeout for commands executed by starship (in milliseconds). | +| `add_newline` | `true` | Inserts blank line between shell prompts. | + ### Exemplo @@ -174,11 +176,12 @@ O `formato` padrão é usado para definir o formato do prompt, se um valor vazio ```toml format = "$all" -# Que é equivalente a +# Which is equivalent to format = """ $username\ $hostname\ $shlvl\ +$singularity\ $kubernetes\ $directory\ $vcsh\ @@ -191,6 +194,7 @@ $hg_branch\ $docker_context\ $package\ $cmake\ +$cobol\ $dart\ $deno\ $dotnet\ @@ -202,6 +206,7 @@ $helm\ $java\ $julia\ $kotlin\ +$lua\ $nim\ $nodejs\ $ocaml\ @@ -209,6 +214,7 @@ $perl\ $php\ $purescript\ $python\ +$rlang\ $red\ $ruby\ $rust\ @@ -229,7 +235,6 @@ $crystal\ $custom\ $cmd_duration\ $line_break\ -$lua\ $jobs\ $battery\ $time\ @@ -238,15 +243,22 @@ $shell\ $character""" ``` +If you just want to extend the default format, you can use `$all`; modules you explicitly add to the format will not be duplicated. Eg. + +```toml +# Move the directory to the second line +format="$all$directory$character" +``` + ## AWS -O módulo `aws` exibi a região e perfil atual do AWS. Isto é baseado nas variáveis de env `AWS_REGION`, `AWS_DEFAULT_REGION`, and `AWS_PROFILE` contidas no arquivo `~/.aws/config`. Este modulo exibi também tempo de expiração de credenciais temporarias. +The `aws` module shows the current AWS region and profile. This is based on `AWS_REGION`, `AWS_DEFAULT_REGION`, and `AWS_PROFILE` env var with `~/.aws/config` file. This module also shows an expiration timer when using temporary credentials. -Quando usar [aws-vault](https://github.com/99designs/aws-vault) o perfil é lido da variável `AWS_VAULT` e o tempo de expiração de credenciais é lida da variável de env `AWS_SESSION_EXPIRATION`. +When using [aws-vault](https://github.com/99designs/aws-vault) the profile is read from the `AWS_VAULT` env var and the credentials expiration date is read from the `AWS_SESSION_EXPIRATION` env var. -Quando usar [awsu](https://github.com/kreuzwerker/awsu) o perfil é lido da varável de env `AWSU_PROFILE`. +When using [awsu](https://github.com/kreuzwerker/awsu) the profile is read from the `AWSU_PROFILE` env var. -Quando usar [AWSume](https://awsu.me) o perfil é lido da variável `AWSUME_PROFILE` e o tempo de expiração de credenciais é lida da variável de env `AWSUME_EXPIRATION`. +When using [AWSume](https://awsu.me) the profile is read from the `AWSUME_PROFILE` env var and the credentials expiration date is read from the `AWSUME_EXPIRATION` env var. ### Opções @@ -269,7 +281,7 @@ Quando usar [AWSume](https://awsu.me) o perfil é lido da variável `AWSUME_PROF | symbol | | Espelha o valor da opção `símbolo` | | style\* | | Espelha o valor da opção `style` | -\*: Essa variável só pode ser usada como parte de uma string de estilo +\*: This variable can only be used as a part of a style string ### Exemplos @@ -314,7 +326,7 @@ symbol = "🅰 " ## Bateria -O módulo `battery` exibe o quanto a bateria do dispositivo está carregada e o estado atual de carregamento. O módulo é visível somente quando a bateria está abaixo de 10%. +The `battery` module shows how charged the device's battery is and its current charging status. The module is only visible when the device's battery is below 10%. ### Opções @@ -342,7 +354,7 @@ discharging_symbol = "💀 " ### Indicador de bateria -A configuração `display` é usada para definir quando o indicador de bateria deve ser exibido (threshold), qual deve ser o simbolo(symbol) e como você gostaria de exibir (style). Se nenhum `display` for fornecido. Os valores padrão são os seguintes: +The `display` configuration option is used to define when the battery indicator should be shown (threshold), which symbol would be used (symbol), and what it would like (style). If no `display` is provided. Os valores padrão são os seguintes: ```toml [[battery.display]] @@ -350,11 +362,11 @@ threshold = 10 style = "bold red" ``` -O valor padrão das opções `charging_symbol` e `discharging_symbol`é respectivamente o valor das opções `battery`'s `charging_symbol` e `discharging_symbol`. +The default value for the `charging_symbol` and `discharging_symbol` option is respectively the value of `battery`'s `charging_symbol` and `discharging_symbol` option. #### Opções -A opção `display` é um array da seguinte tabela. +The `display` option is an array of the following table. | Opções | Padrão | Descrição | | -------------------- | ---------- | -------------------------------------------------------------------------------------------------- | @@ -366,39 +378,39 @@ A opção `display` é um array da seguinte tabela. #### Exemplo ```toml -[[battery.display]] # "bold red" é estilo e o simbolo discharging_symbol serão usados quando a capacidade estiver entre 0% e 10% +[[battery.display]] # "bold red" style and discharging_symbol when capacity is between 0% and 10% threshold = 10 style = "bold red" -[[battery.display]] # "bold yellow" é estilo e o simbolo 💦 serão usados quando a capacidade estiver entre 10% e 30% +[[battery.display]] # "bold yellow" style and 💦 symbol when capacity is between 10% and 30% threshold = 30 style = "bold yellow" discharging_symbol = 💦 -# Quando a capcidade for maior que 30%, o indicador de bateria não sera mostrado +# when capacity is over 30%, the battery indicator will not be displayed ``` ## Caractere -O módulo `character` exibe um caracter (normalmente uma seta) ao lado de onde o texto começa a ser inserido no terminal. +The `character` module shows a character (usually an arrow) beside where the text is entered in your terminal. -O caractere vai te dizer se o ultimo comando foi bem sucedido ou não. Você pode fazer isto de duas maneiras: +The character will tell you whether the last command was successful or not. It can do this in two ways: - alterando a cor (`red`/`green`) - alterando a forma (`❯`/`✖`) -Por padrão ele apenas muda de cor. Se você deseja alterar o formato de uma olhada [neste exemplo](#with-custom-error-shape). +By default it only changes color. If you also want to change its shape take a look at [this example](#with-custom-error-shape). ::: warning -`error_symbol` não é suportado no elvish e nu shell. +`error_symbol` is not supported on elvish and nu shell. ::: ::: warning -`vicmd_symbol` é suportado apenas no fish e zsh. +`vicmd_symbol` is only supported in fish and zsh. ::: @@ -451,7 +463,7 @@ vicmd_symbol = "[V](bold green) " ## CMake -O módulo `cmake` exibe a versão instalada do [CMake](https://cmake.org/). Por padrão o módulo será ativo se qualquer das condições a seguir for atendida: +The `cmake` module shows the currently installed version of [CMake](https://cmake.org/). By default the module will be activated if any of the following conditions are met: - O diretorio atual cotem um arquivo `CMakeLists.txt` - O diretorio atual tem um arquivo `CMakeCache.txt` @@ -477,46 +489,76 @@ O módulo `cmake` exibe a versão instalada do [CMake](https://cmake.org/). Por | symbol | | Espelha o valor da opção `symbol` | | style\* | | Espelha o valor da opção `style` | -\*: Essa variável só pode ser usada como parte de uma string de estilo +\*: This variable can only be used as a part of a style string -## Tempo de execução do comando +## COBOL / GNUCOBOL -O módulo `cmd_duration` exibi o tempo que o ultimo comando levou para executar. O módulo vai exibir somente se o comando levar mais de dois segundos, ou o valor de configuração `min_time` existir. +The `cobol` module shows the currently installed version of COBOL. By default, the module will be shown if any of the following conditions are met: -::: warning Não utilize o DEBUG-trap no Bash - -Se você esta rodando o Starship no `bash`, você não deve ativar a armadilha `DEBUG` após rodar `eval $(starship init $0)`, ou este módulo **vai** quebrar. - -::: - -Usuários do bash que precisam de funções pre-executadas podem usar [rcaloras's bash_preexec framework](https://github.com/rcaloras/bash-preexec). Simplesmente defina os arrays `preexec_functions` e `precmd_functions` antes de rodar `eval $(starship init $0)`, e depois pode proceder normalmente. +- The current directory contains any files ending in `.cob` or `.COB` +- The current directory contains any files ending in `.cbl` or `.CBL` ### Opções -| Opções | Padrão | Descrição | -| -------------------- | ----------------------------- | ------------------------------------------------------------- | -| `min_time` | `2_000` | Duração mais curta para exibir o tempo (em milissegundos). | -| `show_milliseconds` | `false` | Exibir milissegundos ou invés de segundos para duração. | -| `format` | `"took [$duration]($style) "` | O formato do módulo. | -| `style` | `"bold yellow"` | O estilo do módulo. | -| `disabled` | `false` | Desabilita o módulo `cmd_duration`. | -| `show_notifications` | `false` | Exibi notificações no desktop quando o comando for concluído. | -| `min_time_to_notify` | `45_000` | Tempo minimo para notificação (em milissegundos). | +| Opções | Padrão | Descrição | +| ------------------- | ------------------------------------ | ------------------------------------------------------------------------------------ | +| `symbol` | `"⚙️ "` | The symbol used before displaying the version of COBOL. | +| `format` | `"via [$symbol($version )]($style)"` | O formato do módulo. | +| `version_format` | `"v${raw}"` | O formato da versão. As variáveis disponíveis são `raw`, `major`, `minor`, & `patch` | +| `style` | `"bold blue"` | O estilo do módulo. | +| `detect_extensions` | `["cbl", "cob", "CBL", "COB"]` | Quais extensões devem ativar este módulo. | +| `detect_files` | `[]` | Quais nomes de arquivos devem ativar este módulo. | +| `detect_folders` | `[]` | Quais pastas devem ativar este módulo. | +| `disabled` | `false` | Disables the `cobol` module. | + +### Variáveis + +| Variável | Exemplo | Descrição | +| --------- | ---------- | --------------------------------- | +| version | `v3.1.2.0` | The version of `cobol` | +| symbol | | Espelha o valor da opção `symbol` | +| style\* | | Espelha o valor da opção `style` | + +\*: This variable can only be used as a part of a style string + +## Tempo de execução do comando + +The `cmd_duration` module shows how long the last command took to execute. The module will be shown only if the command took longer than two seconds, or the `min_time` config value, if it exists. + +::: warning Do not hook the DEBUG trap in Bash + +If you are running Starship in `bash`, do not hook the `DEBUG` trap after running `eval $(starship init $0)`, or this module **will** break. + +::: + +Bash users who need preexec-like functionality can use [rcaloras's bash_preexec framework](https://github.com/rcaloras/bash-preexec). Simply define the arrays `preexec_functions` and `precmd_functions` before running `eval $(starship init $0)`, and then proceed as normal. + +### Opções + +| Opções | Padrão | Descrição | +| -------------------- | ----------------------------- | ---------------------------------------------------------- | +| `min_time` | `2_000` | Shortest duration to show time for (in milliseconds). | +| `show_milliseconds` | `false` | Show milliseconds in addition to seconds for the duration. | +| `format` | `"took [$duration]($style) "` | O formato do módulo. | +| `style` | `"bold yellow"` | O estilo do módulo. | +| `disabled` | `false` | Disables the `cmd_duration` module. | +| `show_notifications` | `false` | Show desktop notifications when command completes. | +| `min_time_to_notify` | `45_000` | Shortest duration for notification (in milliseconds). | ::: tip -Para exibir notificações requer que o starship seja construído com suporte para `rust-notify`. Você consegue verificar se seu starship suporta notificações rodando `STARSHIP_LOG=debug starship module cmd_duration -d 60000` quando `show_notifications` é definido como `true`. +Showing desktop notifications requires starship to be built with `rust-notify` support. You check if your starship supports notifications by running `STARSHIP_LOG=debug starship module cmd_duration -d 60000` when `show_notifications` is set to `true`. ::: ### Variáveis -| Variável | Exemplo | Descrição | -| --------- | -------- | ----------------------------------------- | -| duration | `16m40s` | O tempo que levou para executar o comando | -| style\* | | Espelha o valor da opção `style` | +| Variável | Exemplo | Descrição | +| --------- | -------- | --------------------------------------- | +| duration | `16m40s` | The time it took to execute the command | +| style\* | | Espelha o valor da opção `style` | -\*: Essa variável só pode ser usada como parte de uma string de estilo +\*: This variable can only be used as a part of a style string ### Exemplo @@ -530,34 +572,34 @@ format = "underwent [$duration](bold yellow)" ## Conda -O módulo `conda` exibe o environment atual do conda, se `$CONDA_DEFAULT_ENV` é definido. +The `conda` module shows the current [Conda](https://docs.conda.io/en/latest/) environment, if `$CONDA_DEFAULT_ENV` is set. ::: tip -Isso não suprime o modificador de prompt do conda, você pode executar `conda config --set changeps1 False`. +This does not suppress conda's own prompt modifier, you may want to run `conda config --set changeps1 False`. ::: ### Opções -| Opções | Padrão | Descrição | -| ------------------- | -------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -| `truncation_length` | `1` | O número de diretórios do envirionment path deve ser truncado, se o environment foi criado via `conda create -p [path]`. `0` quer dizer sem truncação. Também consulte o módulo [`directory`](#directory). | -| `symbol` | `"🅒 "` | O simbolo usado antes do nome do environment. | -| `style` | `"bold green"` | O estilo do módulo. | -| `format` | `"via [$symbol$environment]($style) "` | O formato do módulo. | -| `ignore_base` | `true` | Ignora o environment `base` quando ativado. | -| `disabled` | `false` | Desabilita o módulo `conda`. | +| Opções | Padrão | Descrição | +| ------------------- | -------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | +| `truncation_length` | `1` | The number of directories the environment path should be truncated to, if the environment was created via `conda create -p [path]`. `0` means no truncation. Also see the [`directory`](#directory) module. | +| `symbol` | `"🅒 "` | The symbol used before the environment name. | +| `style` | `"bold green"` | O estilo do módulo. | +| `format` | `"via [$symbol$environment]($style) "` | O formato do módulo. | +| `ignore_base` | `true` | Ignores `base` environment when activated. | +| `disabled` | `false` | Disables the `conda` module. | ### Variáveis | Variável | Exemplo | Descrição | | ----------- | ------------ | --------------------------------- | -| environment | `astronauts` | O environment atual do conda | +| environment | `astronauts` | The current conda environment | | symbol | | Espelha o valor da opção `symbol` | | style\* | | Espelha o valor da opção `style` | -\*: Essa variável só pode ser usada como parte de uma string de estilo +\*: This variable can only be used as a part of a style string ### Exemplo @@ -570,33 +612,33 @@ format = "[$symbol$environment](dimmed green) " ## Crystal -O módulo `crystal` exibe a versão instalada atual do [Crystal](https://crystal-lang.org/). Por padrão o módulo vai exibir se uma das condições a seguir for atendida: +The `crystal` module shows the currently installed version of [Crystal](https://crystal-lang.org/). Por padrão o módulo vai exibir se uma das condições a seguir for atendida: -- O diretório atual contem um arquivo `shard.yml` -- O diretório atual contem um arquivo `.cr` +- The current directory contains a `shard.yml` file +- The current directory contains a `.cr` file ### Opções | Opções | Padrão | Descrição | | ------------------- | ------------------------------------ | ------------------------------------------------------------------------------------ | -| `symbol` | `"🔮 "` | O simbolo usado antes de exibir a versão do crystal. | +| `symbol` | `"🔮 "` | The symbol used before displaying the version of crystal. | | `format` | `"via [$symbol($version )]($style)"` | O formato do módulo. | | `version_format` | `"v${raw}"` | O formato da versão. As variáveis disponíveis são `raw`, `major`, `minor`, & `patch` | | `style` | `"bold red"` | O estilo do módulo. | | `detect_extensions` | `["cr"]` | Quais extensões devem ativar este módulo. | | `detect_files` | `["shard.yml"]` | Quais nomes de arquivos devem ativar este módulo. | | `detect_folders` | `[]` | Quais pastas devem ativar este módulo. | -| `disabled` | `false` | Desabilita o módulo `crystal`. | +| `disabled` | `false` | Disables the `crystal` module. | ### Variáveis | Variável | Exemplo | Descrição | | --------- | --------- | --------------------------------- | -| version | `v0.32.1` | A versão do `crystal` | +| version | `v0.32.1` | The version of `crystal` | | symbol | | Espelha o valor da opção `symbol` | | style\* | | Espelha o valor da opção `style` | -\*: Essa variável só pode ser usada como parte de uma string de estilo +\*: This variable can only be used as a part of a style string ### Exemplo @@ -609,11 +651,11 @@ format = "via [✨ $version](bold blue) " ## Dart -O módulo `dart` exibe a versão atual instalada do [Dart](https://dart.dev/). Por padrão o módulo vai exibir se uma das condições a seguir for atendida: +The `dart` module shows the currently installed version of [Dart](https://dart.dev/). Por padrão o módulo vai exibir se uma das condições a seguir for atendida: -- O diretório atual contem algum arquivo com extensão `.dart` -- O diretório atual contem um diretório `.dart_tool` -- O diretório atual contem um arquivo `pubspec.yaml`, `pubspec.yml` ou `pubspec.lock` +- The current directory contains a file with `.dart` extension +- The current directory contains a `.dart_tool` directory +- The current directory contains a `pubspec.yaml`, `pubspec.yml` or `pubspec.lock` file ### Opções @@ -621,12 +663,12 @@ O módulo `dart` exibe a versão atual instalada do [Dart](https://dart.dev/). P | ------------------- | ------------------------------------------------- | ------------------------------------------------------------------------------------ | | `format` | `"via [$symbol($version )]($style)"` | O formato do módulo. | | `version_format` | `"v${raw}"` | O formato da versão. As variáveis disponíveis são `raw`, `major`, `minor`, & `patch` | -| `symbol` | `"🎯 "` | Um formato de string que representa o simbolo do Dart | +| `symbol` | `"🎯 "` | A format string representing the symbol of Dart | | `detect_extensions` | `["dart"]` | Quais extensões devem ativar este módulo. | | `detect_files` | `["pubspec.yaml", "pubspec.yml", "pubspec.lock"]` | Quais nomes de arquivos devem ativar este módulo. | | `detect_folders` | `[".dart_tool"]` | Quais pastas devem ativar este módulo. | | `style` | `"bold blue"` | O estilo do módulo. | -| `disabled` | `false` | Desabilita o módulo `dart`. | +| `disabled` | `false` | Disables the `dart` module. | ### Variáveis @@ -636,7 +678,7 @@ O módulo `dart` exibe a versão atual instalada do [Dart](https://dart.dev/). P | symbol | | Espelha o valor da opção `symbol` | | style\* | | Espelha o valor da opção `style` | -\*: Essa variável só pode ser usada como parte de uma string de estilo +\*: This variable can only be used as a part of a style string ### Exemplo @@ -649,8 +691,8 @@ format = "via [🔰 $version](bold red) " ## Deno -O módulo `deno` exibe a versão instalada atual do [Deno](https://deno.land/). Por padrão o módulo vai exibir se uma das condições a seguir for atendida: -- O diretório contem um arquivo `mod.ts`, `mod.js`, `deps.ts` ou `deps.js` +The `deno` module shows you your currently installed version of [Deno](https://deno.land/). Por padrão o módulo vai exibir se uma das condições a seguir for atendida: +- The current directory contains a `mod.ts`, `mod.js`, `deps.ts` or `deps.js` file ### Opções @@ -658,18 +700,18 @@ O módulo `deno` exibe a versão instalada atual do [Deno](https://deno.land/). | ------------------- | -------------------------------------------- | ------------------------------------------------------------------------------------ | | `format` | `"via [$symbol($version )]($style)"` | O formato do módulo. | | `version_format` | `"v${raw}"` | O formato da versão. As variáveis disponíveis são `raw`, `major`, `minor`, & `patch` | -| `symbol` | `"🦕 "` | Um formato de string que representa o simbolo do Deno | +| `symbol` | `"🦕 "` | A format string representing the symbol of Deno | | `detect_extensions` | `[]` | Quais extensões devem ativar este módulo. | | `detect_files` | `["mod.ts", "mod.js", "deps.ts", "deps.js"]` | Quais nomes de arquivos devem ativar este módulo. | | `detect_folders` | `[]` | Quais pastas devem ativar este módulo. | | `style` | `"green bold"` | O estilo do módulo. | -| `disabled` | `false` | Desabilita o módulo `deno`. | +| `disabled` | `false` | Disables the `deno` module. | ### Variáveis | Variável | Exemplo | Descrição | | --------- | -------- | --------------------------------- | -| version | `v1.8.3` | A versão do `deno` | +| version | `v1.8.3` | The version of `deno` | | symbol | | Espelha o valor da opção `symbol` | | style\* | | Espelha o valor da opção `style` | @@ -684,28 +726,28 @@ format = "via [🦕 $version](green bold) " ## Diretório -O módulo `directory` exibe o caminho do diretório atual, truncando as três pastas pai. Seu diretório será truncando na raiz do repositório git que você estiver atualmente. +The `directory` module shows the path to your current directory, truncated to three parent folders. Your directory will also be truncated to the root of the git repo that you're currently in. -Quando usar a opção de estilo fish pwd, ao invés de esconder o caminho que é truncado, você vai ver um nome encurtado de cada diretório baseado no número que você habilitar para a opção. +When using the fish style pwd option, instead of hiding the path that is truncated, you will see a shortened name of each directory based on the number you enable for the option. -Por exemplo, dado `~/Dev/Nix/nixpkgs/pkgs` onde `nixpkgs` é o repositório raiz e a opção esta definida para `1`. Você verá `~/D/N/nixpkgs/pkgs`, enquanto antes seria `nixpkgs/pkgs`. +For example, given `~/Dev/Nix/nixpkgs/pkgs` where `nixpkgs` is the repo root, and the option set to `1`. You will now see `~/D/N/nixpkgs/pkgs`, whereas before it would have been `nixpkgs/pkgs`. ### Opções -| Opções | Padrão | Descrição | -| ------------------- | -------------------------------------------------- | ------------------------------------------------------------------------ | -| `truncation_length` | `3` | O número de pastas pais do diretório atual que serão truncadas. | -| `truncate_to_repo` | `true` | Seu diretório será truncado ou não para a raiz do repositório git atual. | -| `format` | `"[$path]($style)[$read_only]($read_only_style) "` | O formato do módulo. | -| `style` | `"bold cyan"` | O estilo do módulo. | -| `disabled` | `false` | Desabilita o módulo `directory`. | -| `read_only` | `"🔒"` | O simbolo que indica que o diretório atual é somente leitura. | -| `read_only_style` | `"red"` | O estilo para o simbolo de somente leitura. | -| `truncation_symbol` | `""` | O simbolo para prefixo de caminhos truncados. ex: "…/" | -| `home_symbol` | `"~"` | O simbolo para indicar o diretório home. | +| Opções | Padrão | Descrição | +| ------------------- | -------------------------------------------------- | -------------------------------------------------------------------------------- | +| `truncation_length` | `3` | The number of parent folders that the current directory should be truncated to. | +| `truncate_to_repo` | `true` | Whether or not to truncate to the root of the git repo that you're currently in. | +| `format` | `"[$path]($style)[$read_only]($read_only_style) "` | O formato do módulo. | +| `style` | `"bold cyan"` | O estilo do módulo. | +| `disabled` | `false` | Disables the `directory` module. | +| `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: "…/" | +| `home_symbol` | `"~"` | The symbol indicating home directory. |
-Este módulo tem algumas configurações avançadas que controlam como o diretório é exibido. +This module has a few advanced configuration options that control how the directory is displayed. | Advanced Option | Padrão | Descrição | | --------------------------- | ------ | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------- | @@ -729,10 +771,10 @@ Por exemplo, dado `~/Dev/Nix/nixpkgs/pkgs` onde `nixpkgs` é o repositório raiz | Variável | Exemplo | Descrição | | --------- | --------------------- | -------------------------------- | -| path | `"D:/Projects"` | O caminho do diretório atual | +| path | `"D:/Projects"` | The current directory path | | style\* | `"black bold dimmed"` | Espelha o valor da opção `style` | -\*: Essa variável só pode ser usada como parte de uma string de estilo +\*: This variable can only be used as a part of a style string ### Exemplo @@ -746,30 +788,30 @@ truncation_symbol = "…/" ## Docker Context -O módulo `docker_context` exibe o [Docker context](https://docs.docker.com/engine/context/working-with-contexts/) atual se não estiver definido como `default` ou se as variáveis de ambiente `DOCKER_HOST` ou `DOCKER_CONTEXT` estiverem definidas (se destinam a sobrescrever o contexto atual). +The `docker_context` module shows the currently active [Docker context](https://docs.docker.com/engine/context/working-with-contexts/) if it's not set to `default` or if the `DOCKER_HOST` or `DOCKER_CONTEXT` environment variables are set (as they are meant to override the context in use). ### Opções -| Opções | Padrão | Descrição | -| ------------------- | ------------------------------------------------------------- | ------------------------------------------------------------------------------------ | -| `format` | `"via [$symbol$context]($style) "` | O formato do módulo. | -| `symbol` | `"🐳 "` | O simbolo usado antes de exibir a versão do contexto docker. | -| `only_with_files` | `true` | Exibe somente quando houver um arquivo | -| `detect_extensions` | `[]` | Quais extensões devem acionar este módulo (precisa que `only_with_files` seja true). | -| `detect_files` | `["docker-compose.yml", "docker-compose.yaml", "Dockerfile"]` | Quais arquivos devem acionar este módulo (precisa que `only_with_files` seja true). | -| `detect_folders` | `[]` | Quais pastas devem acionar este módulo (precisa que `only_with_files` seja true). | -| `style` | `"blue bold"` | O estilo do módulo. | -| `disabled` | `false` | Desabilita o módulo `docker_context`. | +| Opções | Padrão | Descrição | +| ------------------- | ------------------------------------------------------------- | --------------------------------------------------------------------------------- | +| `format` | `"via [$symbol$context]($style) "` | O formato do módulo. | +| `symbol` | `"🐳 "` | The symbol used before displaying the Docker context. | +| `only_with_files` | `true` | Only show when there's a match | +| `detect_extensions` | `[]` | Which extensions should trigger this module (needs `only_with_files` to be true). | +| `detect_files` | `["docker-compose.yml", "docker-compose.yaml", "Dockerfile"]` | Which filenames should trigger this module (needs `only_with_files` to be true). | +| `detect_folders` | `[]` | Which folders should trigger this module (needs `only_with_files` to be true). | +| `style` | `"blue bold"` | O estilo do módulo. | +| `disabled` | `false` | Disables the `docker_context` module. | ### Variáveis | Variável | Exemplo | Descrição | | --------- | -------------- | --------------------------------- | -| context | `test_context` | O contexto atual do docker | +| context | `test_context` | The current docker context | | symbol | | Espelha o valor da opção `symbol` | | style\* | | Espelha o valor da opção `style` | -\*: Essa variável só pode ser usada como parte de uma string de estilo +\*: This variable can only be used as a part of a style string ### Exemplo @@ -782,9 +824,9 @@ format = "via [🐋 $context](blue bold)" ## Dotnet -O módulo `dotnet` exibe a versão relevante do [.NET Core SDK](https://dotnet.microsoft.com/) para a pasta atual. Se o SDK foi fixado na pasta atual, a versão será exibida. Caso contrario será exibida a ultima versão instalada do SDK. +The `dotnet` module shows the relevant version of the [.NET Core SDK](https://dotnet.microsoft.com/) for the current directory. If the SDK has been pinned in the current directory, the pinned version is shown. Otherwise the module shows the latest installed version of the SDK. -Por padrão o módulo vai apenas exibir no seu prompt quando um ou mais dos seguintes arquivos estiverem presente no diretório: +By default this module will only be shown in your prompt when one or more of the following files are present in the current directory: - `global.json` - `project.json` @@ -795,11 +837,11 @@ Por padrão o módulo vai apenas exibir no seu prompt quando um ou mais dos segu - `*.fsproj` - `*.xproj` -Você também precisa do .NET Core SDK instalado para usá-lo corretamente. +You'll also need the .NET Core SDK installed in order to use it correctly. -Internamente, este módulo usa seu próprio mecanismo de detecção de versão. Normalmente é duas vezes mais rápido que executar `dotnet --version`, mas pode exibir uma versão errado se o projeto .NET tiver o layout de diretório incomum. Se a precisão é mais importante que velocidade, você pode desabilitar o mecanismo definindo `heuristic = false` nas opções do modulo. +Internally, this module uses its own mechanism for version detection. Typically it is twice as fast as running `dotnet --version`, but it may show an incorrect version if your .NET project has an unusual directory layout. If accuracy is more important than speed, you can disable the mechanism by setting `heuristic = false` in the module options. -O módulo também vai exibir o Target Framework Moniker () quando o diretório atual tiver o arquivo csproj. +The module will also show the Target Framework Moniker () when there is a csproj file in the current directory. ### Opções @@ -807,24 +849,24 @@ O módulo também vai exibir o Target Framework Moniker ([\\w-]+)" = "gke-$cluster" ``` -## Quebra de linha +## Line Break The `line_break` module separates the prompt into two lines. @@ -1734,7 +1808,7 @@ The `lua` module shows the currently installed version of [Lua](http://www.lua.o | symbol | | Espelha o valor da opção `symbol` | | style\* | | Espelha o valor da opção `style` | -\*: Essa variável só pode ser usada como parte de uma string de estilo +\*: This variable can only be used as a part of a style string ### Exemplo @@ -1745,7 +1819,7 @@ The `lua` module shows the currently installed version of [Lua](http://www.lua.o format = "via [🌕 $version](bold blue) " ``` -## Uso de memória +## Memory Usage The `memory_usage` module shows current system memory and swap usage. @@ -1753,7 +1827,7 @@ By default the swap usage is displayed if the total system swap is non-zero. ::: tip -Este módulo é desabilitado por padrão. Para ativa-lo, defina `disabled` para `false` no seu arquivo de configuração. +This module is disabled by default. To enable it, set `disabled` to `false` in your configuration file. ::: @@ -1804,7 +1878,7 @@ The `hg_branch` module shows the active branch of the repo in your current direc | `style` | `"bold purple"` | O estilo do módulo. | | `format` | `"on [$symbol$branch]($style) "` | O formato do módulo. | | `truncation_length` | `2^63 - 1` | Truncates the hg branch name to `N` graphemes | -| `truncation_symbol` | `"…"` | O simbolo usado para indicar que o nome braço foi truncado. | +| `truncation_symbol` | `"…"` | The symbol used to indicate a branch name was truncated. | | `disabled` | `true` | Disables the `hg_branch` module. | ### Variáveis @@ -1815,7 +1889,7 @@ The `hg_branch` module shows the active branch of the repo in your current direc | symbol | | Espelha o valor da opção `symbol` | | style\* | | Espelha o valor da opção `style` | -\*: Essa variável só pode ser usada como parte de uma string de estilo +\*: This variable can only be used as a part of a style string ### Exemplo @@ -1832,7 +1906,7 @@ truncation_symbol = "" The `nim` module shows the currently installed version of [Nim](https://nim-lang.org/). Por padrão o módulo vai exibir se uma das condições a seguir for atendida: -- O diretório atual contem um arquivo `nim.cfg` +- The current directory contains a `nim.cfg` file - The current directory contains a file with the `.nim` extension - The current directory contains a file with the `.nims` extension - The current directory contains a file with the `.nimble` extension @@ -1841,7 +1915,7 @@ The `nim` module shows the currently installed version of [Nim](https://nim-lang | Opções | Padrão | Descrição | | ------------------- | ------------------------------------ | ------------------------------------------------------------------------------------ | -| `format` | `"via [$symbol($version )]($style)"` | O formato do módulo | +| `format` | `"via [$symbol($version )]($style)"` | The format for the module | | `version_format` | `"v${raw}"` | O formato da versão. As variáveis disponíveis são `raw`, `major`, `minor`, & `patch` | | `symbol` | `"👑 "` | The symbol used before displaying the version of Nim. | | `detect_extensions` | `["nim", "nims", "nimble"]` | Quais extensões devem ativar este módulo. | @@ -1858,7 +1932,7 @@ The `nim` module shows the currently installed version of [Nim](https://nim-lang | symbol | | Espelha o valor da opção `symbol` | | style\* | | Espelha o valor da opção `style` | -\*: Essa variável só pode ser usada como parte de uma string de estilo +\*: This variable can only be used as a part of a style string ### Exemplo @@ -1894,7 +1968,7 @@ The `nix_shell` module shows the [nix-shell](https://nixos.org/guides/nix-pills/ | symbol | | Espelha o valor da opção `symbol` | | style\* | | Espelha o valor da opção `style` | -\*: Essa variável só pode ser usada como parte de uma string de estilo +\*: This variable can only be used as a part of a style string ### Exemplo @@ -1912,7 +1986,7 @@ format = 'via [☃️ $state( \($name\))](bold blue) ' The `nodejs` module shows the currently installed version of [Node.js](https://nodejs.org/). Por padrão o módulo vai exibir se uma das condições a seguir for atendida: -- O diretório atual contem o arquivo `package.json` +- The current directory contains a `package.json` file - The current directory contains a `.node-version` file - The current directory contains a `.nvmrc` file - The current directory contains a `node_modules` directory @@ -1941,7 +2015,7 @@ The `nodejs` module shows the currently installed version of [Node.js](https://n | symbol | | Espelha o valor da opção `symbol` | | style\* | | Espelha o valor da opção `style` | -\*: Essa variável só pode ser usada como parte de uma string de estilo +\*: This variable can only be used as a part of a style string ### Exemplo @@ -1988,7 +2062,7 @@ The `ocaml` module shows the currently installed version of [OCaml](https://ocam | symbol | | Espelha o valor da opção `symbol` | | style\* | | Espelha o valor da opção `style` | -\*: Essa variável só pode ser usada como parte de uma string de estilo +\*: This variable can only be used as a part of a style string ### Exemplo @@ -2021,7 +2095,7 @@ The `openstack` module shows the current OpenStack cloud and project. The module | symbol | | Espelha o valor da opção `symbol` | | style\* | | Espelha o valor da opção `style` | -\*: Essa variável só pode ser usada como parte de uma string de estilo +\*: This variable can only be used as a part of a style string ### Exemplo @@ -2039,18 +2113,18 @@ symbol = "☁️ " 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`, `composer`, `gradle`, `julia`, `mix` and `helm` 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 -- [**nimble**](https://github.com/nim-lang/nimble) - The `nimble` package version is extracted from the `*.nimble` file present in the current directory with the `nimble dump` command -- [**poetry**](https://python-poetry.org/) – The `poetry` package version is extracted from the `pyproject.toml` present in the current directory -- [**python**](https://www.python.org) - The `python` package version is extracted from the `setup.cfg` present in the current directory -- [**composer**](https://getcomposer.org/) – The `composer` package version is extracted from the `composer.json` present in the current directory -- [**gradle**](https://gradle.org/) – The `gradle` package version is extracted from the `build.gradle` present -- [**julia**](https://docs.julialang.org/en/v1/stdlib/Pkg/) - The package version is extracted from the `Project.toml` present -- [**mix**](https://hexdocs.pm/mix/) - The `mix` package version is extracted from the `mix.exs` present -- [**helm**](https://helm.sh/docs/helm/helm_package/) - The `helm` chart version is extracted from the `Chart.yaml` present -- [**maven**](https://maven.apache.org/) - The `maven` package version is extracted from the `pom.xml` present -- [**meson**](https://mesonbuild.com/) - The `meson` package version is extracted from the `meson.build` present -- [**vlang**](https://vlang.io) - The `vlang` package version is extracted from the `v.mod` present +- [**Cargo**](https://doc.rust-lang.org/cargo/) – The `cargo` package version is extracted from the `Cargo.toml` present in the current directory +- [**Nimble**](https://github.com/nim-lang/nimble) - The `nimble` package version is extracted from the `*.nimble` file present in the current directory with the `nimble dump` command +- [**Poetry**](https://python-poetry.org/) – The `poetry` package version is extracted from the `pyproject.toml` present in the current directory +- [**Python**](https://www.python.org) - The `python` package version is extracted from the `setup.cfg` present in the current directory +- [**Composer**](https://getcomposer.org/) – The `composer` package version is extracted from the `composer.json` present in the current directory +- [**Gradle**](https://gradle.org/) – The `gradle` package version is extracted from the `build.gradle` present +- [**Julia**](https://docs.julialang.org/en/v1/stdlib/Pkg/) - The package version is extracted from the `Project.toml` present +- [**Mix**](https://hexdocs.pm/mix/) - The `mix` package version is extracted from the `mix.exs` present +- [**Helm**](https://helm.sh/docs/helm/helm_package/) - The `helm` chart version is extracted from the `Chart.yaml` present +- [**Maven**](https://maven.apache.org/) - The `maven` package version is extracted from the `pom.xml` present +- [**Meson**](https://mesonbuild.com/) - The `meson` package version is extracted from the `meson.build` present +- [**V**](https://vlang.io) - The `vlang` package version is extracted from the `v.mod` present > ⚠️ The version being shown is that of the package whose source code is in your current directory, not your package manager. @@ -2073,7 +2147,7 @@ The `package` module is shown when the current directory is the repository for a | symbol | | Espelha o valor da opção `symbol` | | style\* | | Espelha o valor da opção `style` | -\*: Essa variável só pode ser usada como parte de uma string de estilo +\*: This variable can only be used as a part of a style string ### Exemplo @@ -2128,7 +2202,7 @@ format = "via [🦪 $version]($style) " The `php` module shows the currently installed version of [PHP](https://www.php.net/). Por padrão o módulo vai exibir se uma das condições a seguir for atendida: -- O diretório atual contem um arquivo `composer.json` +- The current directory contains a `composer.json` file - The current directory contains a `.php-version` file - The current directory contains a `.php` extension @@ -2153,7 +2227,7 @@ The `php` module shows the currently installed version of [PHP](https://www.php. | symbol | | Espelha o valor da opção `symbol` | | style\* | | Espelha o valor da opção `style` | -\*: Essa variável só pode ser usada como parte de uma string de estilo +\*: This variable can only be used as a part of a style string ### Exemplo @@ -2168,7 +2242,7 @@ format = "via [🔹 $version](147 bold) " The `purescript` module shows the currently installed version of [PureScript](https://www.purescript.org/) version. Por padrão o módulo vai exibir se uma das condições a seguir for atendida: -- O diretório atual contem um arquivo `spago.dhall` +- The current directory contains a `spago.dhall` file - The current directory contains a file with the `.purs` extension ### Opções @@ -2192,7 +2266,7 @@ The `purescript` module shows the currently installed version of [PureScript](ht | symbol | | Espelha o valor da opção `symbol` | | style\* | | Espelha o valor da opção `style` | -\*: Essa variável só pode ser usada como parte de uma string de estilo +\*: This variable can only be used as a part of a style string ### Exemplo @@ -2214,10 +2288,10 @@ Por padrão o módulo vai exibir se uma das condições a seguir for atendida: - The current directory contains a `.python-version` file - The current directory contains a `Pipfile` file - The current directory contains a `__init__.py` file -- O diretório atual contem um arquivo `pyproject.toml` -- O diretório atual contem um arquivo `requirements.txt` -- O diretório atual contem um arquivo `setup.py` -- O diretório atual contem um arquivo `tox.ini` +- The current directory contains a `pyproject.toml` file +- The current directory contains a `requirements.txt` file +- The current directory contains a `setup.py` file +- The current directory contains a `tox.ini` file - The current directory contains a file with the `.py` extension. - A virtual environment is currently activated @@ -2294,7 +2368,7 @@ python_binary = ["./venv/bin/python", "python", "python3", "python2"] ## R -The `rlang` module shows the currently installed version of R. The module will be shown if any of the following conditions are met: +The `rlang` module shows the currently installed version of [R](https://www.r-project.org/). The module will be shown if any of the following conditions are met: - The current directory contains a file with the `.R` extension. - The current directory contains a file with the `.Rd` extension. @@ -2361,7 +2435,7 @@ By default the `red` module shows the currently installed version of [Red](https | symbol | | Espelha o valor da opção `symbol` | | style\* | | Espelha o valor da opção `style` | -\*: Essa variável só pode ser usada como parte de uma string de estilo +\*: This variable can only be used as a part of a style string ### Exemplo @@ -2401,7 +2475,7 @@ By default the `ruby` module shows the currently installed version of [Ruby](htt | symbol | | Espelha o valor da opção `symbol` | | style\* | | Espelha o valor da opção `style` | -\*: Essa variável só pode ser usada como parte de uma string de estilo +\*: This variable can only be used as a part of a style string ### Exemplo @@ -2440,7 +2514,7 @@ By default the `rust` module shows the currently installed version of [Rust](htt | symbol | | Espelha o valor da opção `symbol` | | style\* | | Espelha o valor da opção `style` | -\*: Essa variável só pode ser usada como parte de uma string de estilo +\*: This variable can only be used as a part of a style string ### Exemplo @@ -2480,7 +2554,7 @@ The `scala` module shows the currently installed version of [Scala](https://www. | symbol | | Espelha o valor da opção `symbol` | | style\* | | Espelha o valor da opção `style` | -\*: Essa variável só pode ser usada como parte de uma string de estilo +\*: This variable can only be used as a part of a style string ### Exemplo @@ -2493,11 +2567,11 @@ symbol = "🌟 " ## Shell -O módulo de `shell` exibe um indicador para o shell que esta sendo usado. +The `shell` module shows an indicator for currently used shell. ::: tip -Este módulo é desabilitado por padrão. Para ativa-lo, defina `disabled` para `false` no seu arquivo de configuração. +This module is disabled by default. To enable it, set `disabled` to `false` in your configuration file. ::: @@ -2505,8 +2579,8 @@ Este módulo é desabilitado por padrão. Para ativa-lo, defina `disabled` para | Opções | Padrão | Descrição | | ---------------------- | ------------ | ------------------------------------------------------------ | -| `bash_indicator` | `bsh` | Uma string para representar o bash. | -| `fish_indicator` | `fsh` | Uma string usada para representar o fish. | +| `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. | @@ -2537,7 +2611,7 @@ disabled = false ## SHLVL -The `shlvl` module shows the current `SHLVL` ("shell level") environment variable, if it is set to a number and meets or exceeds the specified threshold. +The `shlvl` module shows the current [`SHLVL`](https://tldp.org/LDP/abs/html/internalvariables.html#SHLVLREF) ("shell level") environment variable, if it is set to a number and meets or exceeds the specified threshold. ### Opções @@ -2558,7 +2632,7 @@ The `shlvl` module shows the current `SHLVL` ("shell level") environment variabl | symbol | | Espelha o valor da opção `symbol` | | style\* | | Espelha o valor da opção `style` | -\*: Essa variável só pode ser usada como parte de uma string de estilo +\*: This variable can only be used as a part of a style string ### Exemplo @@ -2592,7 +2666,7 @@ The `singularity` module shows the current [Singularity](https://sylabs.io/singu | symbol | | Espelha o valor da opção `symbol` | | style\* | | Espelha o valor da opção `style` | -\*: Essa variável só pode ser usada como parte de uma string de estilo +\*: This variable can only be used as a part of a style string ### Exemplo @@ -2609,7 +2683,7 @@ The `status` module displays the exit code of the previous command. The module w ::: tip -Este módulo é desabilitado por padrão. Para ativa-lo, defina `disabled` para `false` no seu arquivo de configuração. +This module is disabled by default. To enable it, set `disabled` to `false` in your configuration file. ::: @@ -2648,7 +2722,7 @@ Este módulo é desabilitado por padrão. Para ativa-lo, defina `disabled` para | symbol | | Espelha o valor da opção `symbol` | | style\* | | Espelha o valor da opção `style` | -\*: Essa variável só pode ser usada como parte de uma string de estilo +\*: This variable can only be used as a part of a style string ### Exemplo @@ -2693,7 +2767,7 @@ By default the `swift` module shows the currently installed version of [Swift](h | symbol | | Espelha o valor da opção `symbol` | | style\* | | Espelha o valor da opção `style` | -\*: Essa variável só pode ser usada como parte de uma string de estilo +\*: This variable can only be used as a part of a style string ### Exemplo @@ -2721,16 +2795,16 @@ Por padrão o módulo vai exibir se uma das condições a seguir for atendida: ### Opções -| Opções | Padrão | Descrição | -| ------------------- | ------------------------------------ | ----------------------------------------------------------------------------------- | -| `format` | `"via [$symbol$workspace]($style) "` | The format string for the module. | -| `version_format` | `"v${raw}"` | A versão formatada. As variáveis disponíveis são `raw`, `major`, `minor`, & `patch` | -| `symbol` | `"💠"` | A format string shown before the terraform workspace. | -| `detect_extensions` | `["tf", "hcl"]` | Quais extensões devem ativar este módulo. | -| `detect_files` | `[]` | Quais nomes de arquivos devem ativar este módulo. | -| `detect_folders` | `[".terraform"]` | Quais pastas devem ativar este módulo. | -| `style` | `"bold 105"` | O estilo do módulo. | -| `disabled` | `false` | Disables the `terraform` module. | +| Opções | Padrão | Descrição | +| ------------------- | ------------------------------------ | ------------------------------------------------------------------------------------ | +| `format` | `"via [$symbol$workspace]($style) "` | The format string for the module. | +| `version_format` | `"v${raw}"` | O formato da versão. As variáveis disponíveis são `raw`, `major`, `minor`, & `patch` | +| `symbol` | `"💠"` | A format string shown before the terraform workspace. | +| `detect_extensions` | `["tf", "hcl"]` | Quais extensões devem ativar este módulo. | +| `detect_files` | `[]` | Quais nomes de arquivos devem ativar este módulo. | +| `detect_folders` | `[".terraform"]` | Quais pastas devem ativar este módulo. | +| `style` | `"bold 105"` | O estilo do módulo. | +| `disabled` | `false` | Disables the `terraform` module. | ### Variáveis @@ -2741,7 +2815,7 @@ Por padrão o módulo vai exibir se uma das condições a seguir for atendida: | symbol | | Espelha o valor da opção `symbol` | | style\* | | Espelha o valor da opção `style` | -\*: Essa variável só pode ser usada como parte de uma string de estilo +\*: This variable can only be used as a part of a style string ### Exemplo @@ -2769,7 +2843,7 @@ The `time` module shows the current **local** time. The `format` configuration v ::: tip -Este módulo é desabilitado por padrão. Para ativa-lo, defina `disabled` para `false` no seu arquivo de configuração. +This module is disabled by default. To enable it, set `disabled` to `false` in your configuration file. ::: @@ -2791,10 +2865,10 @@ If `use_12hr` is `true`, then `time_format` defaults to `"%r"`. Otherwise, it de | Variável | Exemplo | Descrição | | --------- | ---------- | -------------------------------- | -| horário | `13:08:10` | The current time. | +| time | `13:08:10` | The current time. | | style\* | | Espelha o valor da opção `style` | -\*: Essa variável só pode ser usada como parte de uma string de estilo +\*: This variable can only be used as a part of a style string ### Exemplo @@ -2881,7 +2955,7 @@ The `vagrant` module shows the currently installed version of [Vagrant](https:// | symbol | | Espelha o valor da opção `symbol` | | style\* | | Espelha o valor da opção `style` | -\*: Essa variável só pode ser usada como parte de uma string de estilo +\*: This variable can only be used as a part of a style string ### Exemplo @@ -2892,9 +2966,9 @@ The `vagrant` module shows the currently installed version of [Vagrant](https:// format = "via [⍱ $version](bold white) " ``` -## VLang +## V -The `vlang` module shows you your currently installed version of V. By default the module will be shown if any of the following conditions are met: +The `vlang` module shows you your currently installed version of [V](https://vlang.io/). Por padrão o módulo vai exibir se uma das condições a seguir for atendida: - The current directory contains a file with `.v` extension - The current directory contains a `v.mod`, `vpkg.json` or `.vpkg-lock.json` file @@ -2923,7 +2997,7 @@ The `vlang` module shows you your currently installed version of V. By default t ```toml # ~/.config/starship.toml -[v] +[vlang] format = "via [V $version](blue bold) " ``` @@ -2944,11 +3018,11 @@ The `vcsh` module displays the current active [VCSH](https://github.com/RichiH/v | Variável | Exemplo | Descrição | | --------- | ------------------------------------------- | --------------------------------- | -| repo | `dotfiles` if in a VCSH repo named dotfiles | O nome do repositório ativo | +| repo | `dotfiles` if in a VCSH repo named dotfiles | The active repository name | | symbol | | Espelha o valor da opção `symbol` | | style\* | `black bold dimmed` | Espelha o valor da opção `style` | -\*: Essa variável só pode ser usada como parte de uma string de estilo +\*: This variable can only be used as a part of a style string ### Exemplo @@ -2986,7 +3060,7 @@ By default the the `zig` module shows the currently installed version of [Zig](h | symbol | | Espelha o valor da opção `symbol` | | style\* | | Espelha o valor da opção `style` | -\*: Essa variável só pode ser usada como parte de uma string de estilo +\*: This variable can only be used as a part of a style string ### Exemplo @@ -2997,7 +3071,7 @@ By default the the `zig` module shows the currently installed version of [Zig](h symbol = "⚡️ " ``` -## Comandos Personalizados +## Custom commands The `custom` modules show the output of some arbitrary commands. @@ -3011,7 +3085,7 @@ These modules will be shown if any of the following conditions are met: ::: tip -Vários módulos personalizados podem ser definidos usando `.`. +Multiple custom modules can be defined by using a `.`. ::: @@ -3029,30 +3103,30 @@ The order in which custom modules are shown can be individually set by including ### Opções -| Opções | Padrão | Descrição | -| ------------- | ------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -| `command` | | The command whose output should be printed. The command will be passed on stdin to the shell. | -| `when` | | A shell command used as a condition to show the module. The module will be shown if the command returns a `0` status code. | -| `shell` | | [See below](#custom-command-shell) | -| `descrição` | `""` | The description of the module that is shown when running `starship explain`. | -| `files` | `[]` | The files that will be searched in the working directory for a match. | -| `directories` | `[]` | The directories that will be searched in the working directory for a match. | -| `extensions` | `[]` | The extensions that will be searched in the working directory for a match. | -| `symbol` | `""` | The symbol used before displaying the command output. | -| `style` | `"bold green"` | O estilo do módulo. | -| `format` | `"[$symbol($output )]($style)"` | O formato do módulo. | -| `disabled` | `false` | Desabilita este módulo `custom`. | -| `os` | | Nome do sistema operacional onde módulo sera exibido (unix, linux, macos, windows, ... ) [Veja os possíveis valores](https://doc.rust-lang.org/std/env/consts/constant.OS.html). | +| Opções | Padrão | Descrição | +| ------------- | ------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | +| `command` | | The command whose output should be printed. The command will be passed on stdin to the shell. | +| `when` | | A shell command used as a condition to show the module. The module will be shown if the command returns a `0` status code. | +| `shell` | | [See below](#custom-command-shell) | +| `description` | `""` | The description of the module that is shown when running `starship explain`. | +| `files` | `[]` | The files that will be searched in the working directory for a match. | +| `directories` | `[]` | The directories that will be searched in the working directory for a match. | +| `extensions` | `[]` | The extensions that will be searched in the working directory for a match. | +| `symbol` | `""` | The symbol used before displaying the command output. | +| `style` | `"bold green"` | O estilo do módulo. | +| `format` | `"[$symbol($output )]($style)"` | O formato do módulo. | +| `disabled` | `false` | Disables this `custom` module. | +| `os` | | Operating System name on which the module will be shown (unix, linux, macos, windows, ... ) [See possible values](https://doc.rust-lang.org/std/env/consts/constant.OS.html). | ### Variáveis -| Variável | Descrição | -| --------- | --------------------------------- | -| output | A saída do comando no `shell` | -| symbol | Espelha o valor da opção `symbol` | -| style\* | Espelha o valor da opção `style` | +| Variável | Descrição | +| --------- | -------------------------------------- | +| output | The output of shell command in `shell` | +| symbol | Espelha o valor da opção `symbol` | +| style\* | Espelha o valor da opção `style` | -\*: Essa variável só pode ser usada como parte de uma string de estilo +\*: This variable can only be used as a part of a style string #### Comandos personalizados de shell diff --git a/docs/pt-BR/guide/README.md b/docs/pt-BR/guide/README.md index 90a593ef..e17fedcc 100644 --- a/docs/pt-BR/guide/README.md +++ b/docs/pt-BR/guide/README.md @@ -48,30 +48,6 @@ height="20" src="https://raw.githubusercontent.com/starship/starship/master/media/flag-us.png" alt="English" - /> -   - 日本語 -   - 繁體中文 -   - Русский   -   - 简体中文   +   + 日本語 +   + Português do Brasil +   + Русский   +   + 简体中文 +   + 繁體中文

@@ -160,8 +168,8 @@ ```sh sh -c "$(curl -fsSL https://starship.rs/install.sh)" ``` - Para atualizar o Starship de maneira manual, execute novamente o script acima. Isto irá substituir a versão atual sem alterar as configurações do Starship. + Para atualizar o Starship de maneira manual, execute novamente o script acima. Isto irá substituir a versão atual sem alterar as configurações do Starship. **Nota** - Os padrões de instalação do script podem ser alteradas e substituídas, consulte a ajuda de built-in. diff --git a/docs/pt-BR/presets/README.md b/docs/pt-BR/presets/README.md index 2333600b..8668fe57 100644 --- a/docs/pt-BR/presets/README.md +++ b/docs/pt-BR/presets/README.md @@ -112,6 +112,9 @@ format = '\[[$symbol($version)]($style)\]' [cmd_duration] format = '\[[⏱ $duration ]($style)\]' +[cobol] +format = '\[[$symbol($version)]($style)\]' + [conda] format = '\[[$symbol$environment]($style)\]' @@ -272,6 +275,9 @@ deleted = "x" [aws] symbol = "aws " +[cobol] +symbol = "cobol " + [conda] symbol = "conda " @@ -375,6 +381,9 @@ Está predefinição oculta a versão do runtime da linguagem. Se você trabalha [cmake] format = "via [$symbol]($style)" +[cobol] +format = "via [$symbol]($style)" + [crystal] format = "via [$symbol]($style)" diff --git a/docs/pt-PT/advanced-config/README.md b/docs/pt-PT/advanced-config/README.md index 0d59c601..d7b9ec4d 100644 --- a/docs/pt-PT/advanced-config/README.md +++ b/docs/pt-PT/advanced-config/README.md @@ -68,6 +68,33 @@ function set_win_title(){ starship_precmd_user_func="set_win_title" ``` +## Enable Right Prompt + +Some shells support a right prompt which renders on the same line as the input. Starship can set the content of the right prompt using the `right_format` option. Any module that can be used in `format` is also supported in `right_format`. The `$all` variable will only contain modules not explicitly used in either `format` or `right_format`. + +Note: The right prompt is a single line following the input location. To right align modules above the input line in a multi-line prompt, see the [fill module](/config/#fill). + +`right_format` is currently supported for the following shells: elvish, fish, zsh. + +### Example + +```toml +# ~/.config/starship.toml + +# A minimal left prompt +format = """$character""" + +# move the rest of the prompt to the right +right_format = """$all""" +``` + +Produces a prompt like the following: + +``` +▶ starship on  rprompt [!] is 📦 v0.57.0 via 🦀 v1.54.0 took 17s +``` + + ## Style Strings Style strings are a list of words, separated by whitespace. The words are not case sensitive (i.e. `bold` and `BoLd` are considered the same string). Each word can be one of the following: diff --git a/docs/pt-PT/config/README.md b/docs/pt-PT/config/README.md index 61f8fcfd..2fb31aa1 100644 --- a/docs/pt-PT/config/README.md +++ b/docs/pt-PT/config/README.md @@ -75,7 +75,7 @@ A text group is made up of two different parts. The first part, which is enclosed in a `[]`, is a [format string](#format-strings). You can add texts, variables, or even nested text groups in it. -In the second part, which is enclosed in a `()`, is a [style string](#style-strings). This can be used style the first part. +In the second part, which is enclosed in a `()`, is a [style string](#style-strings). This can be used to style the first part. For example: @@ -142,12 +142,14 @@ This is the list of prompt-wide configuration options. ### Options -| Option | Default | Description | -| ----------------- | ------------------------------ | ------------------------------------------------------------ | -| `format` | [link](#default-prompt-format) | Configure the format of the prompt. | -| `scan_timeout` | `30` | Timeout for starship to scan files (in milliseconds). | -| `command_timeout` | `500` | Timeout for commands executed by starship (in milliseconds). | -| `add_newline` | `true` | Inserts blank line between shell prompts. | +| Option | Default | Description | +| ----------------- | ------------------------------ | ---------------------------------------------------------------- | +| `format` | [link](#default-prompt-format) | Configure the format of the prompt. | +| `right_format` | `""` | See [Enable Right Prompt](/advanced-config/#enable-right-prompt) | +| `scan_timeout` | `30` | Timeout for starship to scan files (in milliseconds). | +| `command_timeout` | `500` | Timeout for commands executed by starship (in milliseconds). | +| `add_newline` | `true` | Inserts blank line between shell prompts. | + ### Example @@ -179,6 +181,7 @@ format = """ $username\ $hostname\ $shlvl\ +$singularity\ $kubernetes\ $directory\ $vcsh\ @@ -191,6 +194,7 @@ $hg_branch\ $docker_context\ $package\ $cmake\ +$cobol\ $dart\ $deno\ $dotnet\ @@ -202,6 +206,7 @@ $helm\ $java\ $julia\ $kotlin\ +$lua\ $nim\ $nodejs\ $ocaml\ @@ -209,6 +214,7 @@ $perl\ $php\ $purescript\ $python\ +$rlang\ $red\ $ruby\ $rust\ @@ -229,7 +235,6 @@ $crystal\ $custom\ $cmd_duration\ $line_break\ -$lua\ $jobs\ $battery\ $time\ @@ -238,6 +243,13 @@ $shell\ $character""" ``` +If you just want to extend the default format, you can use `$all`; modules you explicitly add to the format will not be duplicated. Eg. + +```toml +# Move the directory to the second line +format="$all$directory$character" +``` + ## AWS The `aws` module shows the current AWS region and profile. This is based on `AWS_REGION`, `AWS_DEFAULT_REGION`, and `AWS_PROFILE` env var with `~/.aws/config` file. This module also shows an expiration timer when using temporary credentials. @@ -479,6 +491,36 @@ The `cmake` module shows the currently installed version of [CMake](https://cmak \*: This variable can only be used as a part of a style string +## COBOL / GNUCOBOL + +The `cobol` module shows the currently installed version of COBOL. By default, the module will be shown if any of the following conditions are met: + +- The current directory contains any files ending in `.cob` or `.COB` +- The current directory contains any files ending in `.cbl` or `.CBL` + +### Options + +| Option | Default | Description | +| ------------------- | ------------------------------------ | ------------------------------------------------------------------------- | +| `symbol` | `"⚙️ "` | The symbol used before displaying the version of COBOL. | +| `format` | `"via [$symbol($version )]($style)"` | The format for the module. | +| `version_format` | `"v${raw}"` | The version format. Available vars are `raw`, `major`, `minor`, & `patch` | +| `style` | `"bold blue"` | The style for the module. | +| `detect_extensions` | `["cbl", "cob", "CBL", "COB"]` | Which extensions should trigger this module. | +| `detect_files` | `[]` | Which filenames should trigger this module. | +| `detect_folders` | `[]` | Which folders should trigger this module. | +| `disabled` | `false` | Disables the `cobol` module. | + +### Variables + +| Variable | Example | Description | +| --------- | ---------- | ------------------------------------ | +| version | `v3.1.2.0` | The version of `cobol` | +| 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 + ## Command Duration The `cmd_duration` module shows how long the last command took to execute. The module will be shown only if the command took longer than two seconds, or the `min_time` config value, if it exists. @@ -530,7 +572,7 @@ format = "underwent [$duration](bold yellow)" ## Conda -The `conda` module shows the current conda environment, if `$CONDA_DEFAULT_ENV` is set. +The `conda` module shows the current [Conda](https://docs.conda.io/en/latest/) environment, if `$CONDA_DEFAULT_ENV` is set. ::: tip @@ -1017,6 +1059,35 @@ The `erlang` module shows the currently installed version of [Erlang/OTP](https: format = "via [e $version](bold red) " ``` +## 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. + +### Options + +| Option | Default | Description | +| -------- | -------------- | --------------------------------- | +| `symbol` | `"."` | The symbol used to fill the line. | +| `style` | `"bold black"` | The style for the module. | + +### Example + +```toml +# ~/.config/starship.toml +format="AA $fill BB $fill CC" + +[fill] +symbol = "-" +style = "bold green" +``` + +Produces a prompt that looks like: + +``` +AA -------------------------------------------- BB -------------------------------------------- CC + +``` + ## 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. @@ -1205,12 +1276,13 @@ This module is disabled by default. To enable it, set `disabled` to `false` in y ### Options -| Option | Default | Description | -| --------------- | -------------------------------------------------------- | ---------------------------------- | -| `added_style` | `"bold green"` | The style for the added count. | -| `deleted_style` | `"bold red"` | The style for the deleted count. | -| `format` | `'[+$added]($added_style) [-$deleted]($deleted_style) '` | The format for the module. | -| `disabled` | `true` | Disables the `git_metrics` module. | +| Option | Default | Description | +| -------------------- | ------------------------------------------------------------ | ------------------------------------- | +| `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. | +| `disabled` | `true` | Disables the `git_metrics` module. | ### Variables @@ -1318,9 +1390,9 @@ diverged = "⇕⇡${ahead_count}⇣${behind_count}" behind = "⇣${count}" ``` -## Golang +## Go -The `golang` module shows the currently installed version of [Golang](https://golang.org/). By default the module will be shown if any of the following conditions are met: +The `golang` module shows the currently installed version of [Go](https://golang.org/). By default the module will be shown if any of the following conditions are met: - The current directory contains a `go.mod` file - The current directory contains a `go.sum` file @@ -2041,18 +2113,18 @@ symbol = "☁️ " 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`, `composer`, `gradle`, `julia`, `mix` and `helm` 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 -- [**nimble**](https://github.com/nim-lang/nimble) - The `nimble` package version is extracted from the `*.nimble` file present in the current directory with the `nimble dump` command -- [**poetry**](https://python-poetry.org/) – The `poetry` package version is extracted from the `pyproject.toml` present in the current directory -- [**python**](https://www.python.org) - The `python` package version is extracted from the `setup.cfg` present in the current directory -- [**composer**](https://getcomposer.org/) – The `composer` package version is extracted from the `composer.json` present in the current directory -- [**gradle**](https://gradle.org/) – The `gradle` package version is extracted from the `build.gradle` present -- [**julia**](https://docs.julialang.org/en/v1/stdlib/Pkg/) - The package version is extracted from the `Project.toml` present -- [**mix**](https://hexdocs.pm/mix/) - The `mix` package version is extracted from the `mix.exs` present -- [**helm**](https://helm.sh/docs/helm/helm_package/) - The `helm` chart version is extracted from the `Chart.yaml` present -- [**maven**](https://maven.apache.org/) - The `maven` package version is extracted from the `pom.xml` present -- [**meson**](https://mesonbuild.com/) - The `meson` package version is extracted from the `meson.build` present -- [**vlang**](https://vlang.io) - The `vlang` package version is extracted from the `v.mod` present +- [**Cargo**](https://doc.rust-lang.org/cargo/) – The `cargo` package version is extracted from the `Cargo.toml` present in the current directory +- [**Nimble**](https://github.com/nim-lang/nimble) - The `nimble` package version is extracted from the `*.nimble` file present in the current directory with the `nimble dump` command +- [**Poetry**](https://python-poetry.org/) – The `poetry` package version is extracted from the `pyproject.toml` present in the current directory +- [**Python**](https://www.python.org) - The `python` package version is extracted from the `setup.cfg` present in the current directory +- [**Composer**](https://getcomposer.org/) – The `composer` package version is extracted from the `composer.json` present in the current directory +- [**Gradle**](https://gradle.org/) – The `gradle` package version is extracted from the `build.gradle` present +- [**Julia**](https://docs.julialang.org/en/v1/stdlib/Pkg/) - The package version is extracted from the `Project.toml` present +- [**Mix**](https://hexdocs.pm/mix/) - The `mix` package version is extracted from the `mix.exs` present +- [**Helm**](https://helm.sh/docs/helm/helm_package/) - The `helm` chart version is extracted from the `Chart.yaml` present +- [**Maven**](https://maven.apache.org/) - The `maven` package version is extracted from the `pom.xml` present +- [**Meson**](https://mesonbuild.com/) - The `meson` package version is extracted from the `meson.build` present +- [**V**](https://vlang.io) - The `vlang` package version is extracted from the `v.mod` present > ⚠️ The version being shown is that of the package whose source code is in your current directory, not your package manager. @@ -2296,7 +2368,7 @@ python_binary = ["./venv/bin/python", "python", "python3", "python2"] ## R -The `rlang` module shows the currently installed version of R. The module will be shown if any of the following conditions are met: +The `rlang` module shows the currently installed version of [R](https://www.r-project.org/). The module will be shown if any of the following conditions are met: - The current directory contains a file with the `.R` extension. - The current directory contains a file with the `.Rd` extension. @@ -2539,7 +2611,7 @@ disabled = false ## SHLVL -The `shlvl` module shows the current `SHLVL` ("shell level") environment variable, if it is set to a number and meets or exceeds the specified threshold. +The `shlvl` module shows the current [`SHLVL`](https://tldp.org/LDP/abs/html/internalvariables.html#SHLVLREF) ("shell level") environment variable, if it is set to a number and meets or exceeds the specified threshold. ### Options @@ -2894,9 +2966,9 @@ The `vagrant` module shows the currently installed version of [Vagrant](https:// format = "via [⍱ $version](bold white) " ``` -## VLang +## V -The `vlang` module shows you your currently installed version of V. By default the module will be shown if any of the following conditions are met: +The `vlang` module shows you your currently installed version of [V](https://vlang.io/). By default the module will be shown if any of the following conditions are met: - The current directory contains a file with `.v` extension - The current directory contains a `v.mod`, `vpkg.json` or `.vpkg-lock.json` file @@ -2925,7 +2997,7 @@ The `vlang` module shows you your currently installed version of V. By default t ```toml # ~/.config/starship.toml -[v] +[vlang] format = "via [V $version](blue bold) " ``` diff --git a/docs/pt-PT/guide/README.md b/docs/pt-PT/guide/README.md index 5641182f..b91ef6c4 100644 --- a/docs/pt-PT/guide/README.md +++ b/docs/pt-PT/guide/README.md @@ -48,30 +48,6 @@ height="20" src="https://raw.githubusercontent.com/starship/starship/master/media/flag-us.png" alt="English" - /> -   - 日本語 -   - 繁體中文 -   - Русский   -   - 简体中文   +   + 日本語 +   + Português do Brasil +   + Русский   +   + 简体中文 +   + 繁體中文

@@ -160,8 +168,8 @@ ```sh sh -c "$(curl -fsSL https://starship.rs/install.sh)" ``` - To update the Starship itself, rerun the above script. It will replace the current version without touching Starship's configuration. + To update the Starship itself, rerun the above script. It will replace the current version without touching Starship's configuration. **Note** - The defaults of the install script can be overridden see the built-in help. diff --git a/docs/pt-PT/presets/README.md b/docs/pt-PT/presets/README.md index c6cc6f60..61165f5b 100644 --- a/docs/pt-PT/presets/README.md +++ b/docs/pt-PT/presets/README.md @@ -112,6 +112,9 @@ format = '\[[$symbol($version)]($style)\]' [cmd_duration] format = '\[[⏱ $duration ]($style)\]' +[cobol] +format = '\[[$symbol($version)]($style)\]' + [conda] format = '\[[$symbol$environment]($style)\]' @@ -272,6 +275,9 @@ deleted = "x" [aws] symbol = "aws " +[cobol] +symbol = "cobol " + [conda] symbol = "conda " @@ -375,6 +381,9 @@ This preset hides the version of language runtimes. If you work in containers or [cmake] format = "via [$symbol]($style)" +[cobol] +format = "via [$symbol]($style)" + [crystal] format = "via [$symbol]($style)" diff --git a/docs/ru-RU/advanced-config/README.md b/docs/ru-RU/advanced-config/README.md index e40c4c6d..551c8d97 100644 --- a/docs/ru-RU/advanced-config/README.md +++ b/docs/ru-RU/advanced-config/README.md @@ -68,9 +68,36 @@ function set_win_title(){ starship_precmd_user_func="set_win_title" ``` +## Enable Right Prompt + +Some shells support a right prompt which renders on the same line as the input. Starship can set the content of the right prompt using the `right_format` option. Any module that can be used in `format` is also supported in `right_format`. The `$all` variable will only contain modules not explicitly used in either `format` or `right_format`. + +Note: The right prompt is a single line following the input location. To right align modules above the input line in a multi-line prompt, see the [fill module](/config/#fill). + +`right_format` is currently supported for the following shells: elvish, fish, zsh. + +### Пример + +```toml +# ~/.config/starship.toml + +# A minimal left prompt +format = """$character""" + +# move the rest of the prompt to the right +right_format = """$all""" +``` + +Produces a prompt like the following: + +``` +▶ starship on  rprompt [!] is 📦 v0.57.0 via 🦀 v1.54.0 took 17s +``` + + ## Строки стиля -Строки стиля - это список слов, разделенных пробелами. Слова не чувствительны к регистру (то есть `bold` и `BoLd` считаются одной строкой). Каждое слово может быть одним из следующих: +Style strings are a list of words, separated by whitespace. The words are not case sensitive (i.e. `bold` and `BoLd` are considered the same string). Each word can be one of the following: - `bold` - `italic` @@ -82,14 +109,14 @@ starship_precmd_user_func="set_win_title" - `` - `none` -где `` является цветовым спецификатором (обсуждается ниже). `fg:` and `` currently do the same thing, though this may change in the future. `inverted` swaps the background and foreground colors. Порядок слов в строке не имеет значения. +where `` is a color specifier (discussed below). `fg:` and `` currently do the same thing, though this may change in the future. `inverted` swaps the background and foreground colors. The order of words in the string does not matter. -Токен `none` переопределяет все остальные токены в строке, если он не является частью спецификатора `bg:` так, например, `fg:red none fg:blue` все равно создаст строку без стиля. `bg:none` sets the background to the default color so `fg:red bg:none` is equivalent to `red` or `fg:red` and `bg:green fg:red bg:none` is also equivalent to `fg:red` or `red`. Использование `none` в сочетании с другими токенами может стать ошибкой в будущем. +The `none` token overrides all other tokens in a string if it is not part of a `bg:` specifier, so that e.g. `fg:red none fg:blue` will still create a string with no styling. `bg:none` sets the background to the default color so `fg:red bg:none` is equivalent to `red` or `fg:red` and `bg:green fg:red bg:none` is also equivalent to `fg:red` or `red`. It may become an error to use `none` in conjunction with other tokens in the future. -Цветовой спецификатор может быть одним из следующих: +A color specifier can be one of the following: - Некоторые из стандартных цветов терминалов: `black`, `red`, `green`, `blue`, `gellow`, `purple`, `cyan`, `white`. Вы можете по желанию добавить префикс `bright-`, чтобы получить яркую версию (например, `bright-white`). - `#`, за которой следует шестизначное шестнадцатеричное число. Это определяет [шестнадцатеричный код цвета RGB](https://www.w3schools.com/colors/colors_hexadecimal.asp). - Число от 0 до 255. Это определяет [8-битный код цвета ANSI](https://i.stack.imgur.com/KTSQa.png). -Если для переднего плана/фона задано несколько цветов, то последняя из строк будет иметь приоритет. +If multiple colors are specified for foreground/background, the last one in the string will take priority. diff --git a/docs/ru-RU/config/README.md b/docs/ru-RU/config/README.md index 70a56d96..c33c9e9b 100644 --- a/docs/ru-RU/config/README.md +++ b/docs/ru-RU/config/README.md @@ -75,7 +75,7 @@ $ENV:STARSHIP_CACHE = "$HOME\AppData\Local\Temp" Первая часть, которая заключена в `[]`, это [формат строки](#format-strings). Вы можете добавлять в него тексты, переменные, или даже вложенные текстовые группы. -Во второй части, которая заключена в `()`, это строка стиля [](#style-strings). Это может быть использовано в стиле первой части. +Во второй части, которая заключена в `()`, это строка стиля [](#style-strings). This can be used to style the first part. Например: @@ -142,12 +142,14 @@ format = ''' ### Опции -| Параметр | По умолчанию | Описание | -| ----------------- | -------------------------------- | ------------------------------------------------------------ | -| `format` | [ссылка](#default-prompt-format) | Настройка форматирования оболочки. | -| `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` | Timeout for starship to scan files (in milliseconds). | +| `command_timeout` | `500` | Timeout for commands executed by starship (in milliseconds). | +| `add_newline` | `true` | Inserts blank line between shell prompts. | + ### Пример @@ -179,6 +181,7 @@ format = """ $username\ $hostname\ $shlvl\ +$singularity\ $kubernetes\ $directory\ $vcsh\ @@ -191,6 +194,7 @@ $hg_branch\ $docker_context\ $package\ $cmake\ +$cobol\ $dart\ $deno\ $dotnet\ @@ -202,6 +206,7 @@ $helm\ $java\ $julia\ $kotlin\ +$lua\ $nim\ $nodejs\ $ocaml\ @@ -209,6 +214,7 @@ $perl\ $php\ $purescript\ $python\ +$rlang\ $red\ $ruby\ $rust\ @@ -229,7 +235,6 @@ $crystal\ $custom\ $cmd_duration\ $line_break\ -$lua\ $jobs\ $battery\ $time\ @@ -238,9 +243,16 @@ $shell\ $character""" ``` +If you just want to extend the default format, you can use `$all`; modules you explicitly add to the format will not be duplicated. Eg. + +```toml +# Move the directory to the second line +format="$all$directory$character" +``` + ## AWS -Модуль `aws` показывает текущий регион и профиль AWS. Основано на `AWS_REGION`, `AWS_DEFAULT_REGION`, и `AWS_PROFILE` переменных окружения и файле`~/.aws/config`. This module also shows an expiration timer when using temporary credentials. +The `aws` module shows the current AWS region and profile. This is based on `AWS_REGION`, `AWS_DEFAULT_REGION`, and `AWS_PROFILE` env var with `~/.aws/config` file. This module also shows an expiration timer when using temporary credentials. When using [aws-vault](https://github.com/99designs/aws-vault) the profile is read from the `AWS_VAULT` env var and the credentials expiration date is read from the `AWS_SESSION_EXPIRATION` env var. @@ -269,7 +281,7 @@ When using [AWSume](https://awsu.me) the profile is read from the `AWSUME_PROFIL | symbol | | Отражает значение параметра `symbol` | | style\* | | Отражает значение параметра `style` | -\*: Эта переменная может использоваться только в качестве части строки style +\*: This variable can only be used as a part of a style string ### Примеры @@ -314,7 +326,7 @@ symbol = "🅰 " ## Батарея -Модуль `battery` показывает насколько заряжена батарея девайса и статус зарядки на данный момент. Модуль виден только, если заряд батареи устройства меньше 10%. +The `battery` module shows how charged the device's battery is and its current charging status. The module is only visible when the device's battery is below 10%. ### Опции @@ -342,7 +354,7 @@ discharging_symbol = "💀 " ### Отображение батареи -The `display` configuration option is used to define when the battery indicator should be shown (threshold), which symbol would be used (symbol), and what it would like (style). Если `display` не предоставлено. Значение по умолчанию: +The `display` configuration option is used to define when the battery indicator should be shown (threshold), which symbol would be used (symbol), and what it would like (style). If no `display` is provided. Значение по умолчанию: ```toml [[battery.display]] @@ -354,7 +366,7 @@ The default value for the `charging_symbol` and `discharging_symbol` option is r #### Опции -Опция `display` представляет собой массив следующей таблицы. +The `display` option is an array of the following table. | Параметр | По умолчанию | Описание | | -------------------- | ------------ | --------------------------------------------------------------------------------------------------------- | @@ -381,9 +393,9 @@ discharging_symbol = 💦 ## Символ -Модуль `character` показывает символ (обычно, стрелка) рядом с вводимым текстом в терминале. +The `character` module shows a character (usually an arrow) beside where the text is entered in your terminal. -Символ показывает, была ли последняя команда успешной или нет. It can do this in two ways: +The character will tell you whether the last command was successful or not. It can do this in two ways: - changing color (`red`/`green`) - changing shape (`❯`/`✖`) @@ -477,31 +489,61 @@ The `cmake` module shows the currently installed version of [CMake](https://cmak | symbol | | Отражает значение параметра `symbol` | | style\* | | Отражает значение параметра `style` | -\*: Эта переменная может использоваться только в качестве части строки style +\*: This variable can only be used as a part of a style string -## Длительность команды +## COBOL / GNUCOBOL -Модуль `cmd_duration` показывает время исполнения последней команды. Модуль будет показан только, если команда заняла более двух секунд, или если задан параметр `min_time`. +The `cobol` module shows the currently installed version of COBOL. By default, the module will be shown if any of the following conditions are met: -::: предупреждение Не подключайте ловушку DEBUG к Bash - -Если вы испоьзуете Starship в `bash`, не подключайте ловушку `DEBUG` после запуска `eval $(starship init $0)`, иначе этот модуль сломается. - -::: - -Пользователи Bash, которым нужна функциональность, подобная preexec, могут использовать [фреймворк bash_preexec от rcaloras](https://github.com/rcaloras/bash-preexec). Просто определите массивы `preexec_functions` и `precmd_functions` перед запуском `eval $(starship init $0)`, а затем продолжайте нормально. +- The current directory contains any files ending in `.cob` or `.COB` +- The current directory contains any files ending in `.cbl` or `.CBL` ### Опции -| Параметр | По умолчанию | Описание | -| -------------------- | ----------------------------- | -------------------------------------------------------------------- | -| `min_time` | `2_000` | Кратчайшая продолжительность для показа времени (в миллисекундах). | -| `show_milliseconds` | `false` | Показывать миллисекунды в дополнение к секундам в продолжительности. | -| `format` | `"took [$duration]($style) "` | Формат модуля. | -| `style` | `"bold yellow"` | Стиль модуля. | -| `disabled` | `false` | Отключает модуль `cmd_duration`. | -| `show_notifications` | `false` | Show desktop notifications when command completes. | -| `min_time_to_notify` | `45_000` | Shortest duration for notification (in milliseconds). | +| Параметр | По умолчанию | Описание | +| ------------------- | ------------------------------------ | ------------------------------------------------------------------------- | +| `symbol` | `"⚙️ "` | The symbol used before displaying the version of COBOL. | +| `format` | `"via [$symbol($version )]($style)"` | Формат модуля. | +| `version_format` | `"v${raw}"` | The version format. Available vars are `raw`, `major`, `minor`, & `patch` | +| `style` | `"bold blue"` | Стиль модуля. | +| `detect_extensions` | `["cbl", "cob", "CBL", "COB"]` | Which extensions should trigger this module. | +| `detect_files` | `[]` | Which filenames should trigger this module. | +| `detect_folders` | `[]` | Which folders should trigger this module. | +| `disabled` | `false` | Disables the `cobol` module. | + +### Переменные + +| Переменная | Пример | Описание | +| ---------- | ---------- | ------------------------------------ | +| version | `v3.1.2.0` | The version of `cobol` | +| symbol | | Отражает значение параметра `symbol` | +| style\* | | Отражает значение параметра `style` | + +\*: This variable can only be used as a part of a style string + +## Длительность команды + +The `cmd_duration` module shows how long the last command took to execute. The module will be shown only if the command took longer than two seconds, or the `min_time` config value, if it exists. + +::: warning Do not hook the DEBUG trap in Bash + +If you are running Starship in `bash`, do not hook the `DEBUG` trap after running `eval $(starship init $0)`, or this module **will** break. + +::: + +Bash users who need preexec-like functionality can use [rcaloras's bash_preexec framework](https://github.com/rcaloras/bash-preexec). Simply define the arrays `preexec_functions` and `precmd_functions` before running `eval $(starship init $0)`, and then proceed as normal. + +### Опции + +| Параметр | По умолчанию | Описание | +| -------------------- | ----------------------------- | ---------------------------------------------------------- | +| `min_time` | `2_000` | Shortest duration to show time for (in milliseconds). | +| `show_milliseconds` | `false` | Show milliseconds in addition to seconds for the duration. | +| `format` | `"took [$duration]($style) "` | Формат модуля. | +| `style` | `"bold yellow"` | Стиль модуля. | +| `disabled` | `false` | Disables the `cmd_duration` module. | +| `show_notifications` | `false` | Show desktop notifications when command completes. | +| `min_time_to_notify` | `45_000` | Shortest duration for notification (in milliseconds). | ::: tip @@ -516,7 +558,7 @@ Showing desktop notifications requires starship to be built with `rust-notify` s | duration | `16m40s` | The time it took to execute the command | | style\* | | Отражает значение параметра `style` | -\*: Эта переменная может использоваться только в качестве части строки style +\*: This variable can only be used as a part of a style string ### Пример @@ -528,26 +570,26 @@ min_time = 500 format = "underwent [$duration](bold yellow)" ``` -## Конда +## Conda -Модуль `conda` показывает текущее окружение conda, если `$CONDA_DEFAULT_ENV` присвоено значение. +The `conda` module shows the current [Conda](https://docs.conda.io/en/latest/) environment, if `$CONDA_DEFAULT_ENV` is set. ::: tip -Это не подавляет модификатор командной строки самой conda. Возможно, вы захотите запустить `conda config --set changeps1 False`. +This does not suppress conda's own prompt modifier, you may want to run `conda config --set changeps1 False`. ::: ### Опции -| Параметр | По умолчанию | Описание | -| ------------------- | -------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | -| `truncation_length` | `1` | Количество каталогов, в которых путь к окружению должен быть усечен, если окружение было создано через `conda create -p [path]`. `0` означает без усечения. Также смотрите модуль [`directory`](#directory). | -| `symbol` | `"🅒 "` | Символ перед названием окружения. | -| `style` | `"bold green"` | Стиль модуля. | -| `format` | `"via [$symbol$environment]($style) "` | Формат модуля. | -| `ignore_base` | `true` | Ignores `base` environment when activated. | -| `disabled` | `false` | Отключает модуль `conda`. | +| Параметр | По умолчанию | Описание | +| ------------------- | -------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | +| `truncation_length` | `1` | The number of directories the environment path should be truncated to, if the environment was created via `conda create -p [path]`. `0` means no truncation. Also see the [`directory`](#directory) module. | +| `symbol` | `"🅒 "` | The symbol used before the environment name. | +| `style` | `"bold green"` | Стиль модуля. | +| `format` | `"via [$symbol$environment]($style) "` | Формат модуля. | +| `ignore_base` | `true` | Ignores `base` environment when activated. | +| `disabled` | `false` | Disables the `conda` module. | ### Переменные @@ -557,7 +599,7 @@ format = "underwent [$duration](bold yellow)" | symbol | | Отражает значение параметра `symbol` | | style\* | | Отражает значение параметра `style` | -\*: Эта переменная может использоваться только в качестве части строки style +\*: This variable can only be used as a part of a style string ### Пример @@ -572,21 +614,21 @@ format = "[$symbol$environment](dimmed green) " The `crystal` module shows the currently installed version of [Crystal](https://crystal-lang.org/). By default the module will be shown if any of the following conditions are met: -- Текущий каталог содержит файл `shard.yml` -- Текущий каталог содержит файл `.cr` +- The current directory contains a `shard.yml` file +- The current directory contains a `.cr` file ### Опции | Параметр | По умолчанию | Описание | | ------------------- | ------------------------------------ | ------------------------------------------------------------------------- | -| `symbol` | `"🔮 "` | Символ, используемый перед отображением версии crystal. | +| `symbol` | `"🔮 "` | The symbol used before displaying the version of crystal. | | `format` | `"via [$symbol($version )]($style)"` | Формат модуля. | | `version_format` | `"v${raw}"` | The version format. Available vars are `raw`, `major`, `minor`, & `patch` | | `style` | `"bold red"` | Стиль модуля. | | `detect_extensions` | `["cr"]` | Which extensions should trigger this module. | | `detect_files` | `["shard.yml"]` | Which filenames should trigger this module. | | `detect_folders` | `[]` | Which folders should trigger this module. | -| `disabled` | `false` | Отключает модуль `crystal`. | +| `disabled` | `false` | Disables the `crystal` module. | ### Переменные @@ -596,7 +638,7 @@ The `crystal` module shows the currently installed version of [Crystal](https:// | symbol | | Отражает значение параметра `symbol` | | style\* | | Отражает значение параметра `style` | -\*: Эта переменная может использоваться только в качестве части строки style +\*: This variable can only be used as a part of a style string ### Пример @@ -636,7 +678,7 @@ The `dart` module shows the currently installed version of [Dart](https://dart.d | symbol | | Отражает значение параметра `symbol` | | style\* | | Отражает значение параметра `style` | -\*: Эта переменная может использоваться только в качестве части строки style +\*: This variable can only be used as a part of a style string ### Пример @@ -650,7 +692,7 @@ format = "via [🔰 $version](bold red) " ## Deno The `deno` module shows you your currently installed version of [Deno](https://deno.land/). By default the module will be shown if any of the following conditions are met: -- Текущий каталог содержит файл `mod.ts`, `mod.js`, `deps.ts` или `deps.js` +- The current directory contains a `mod.ts`, `mod.js`, `deps.ts` or `deps.js` file ### Опции @@ -684,33 +726,33 @@ format = "via [🦕 $version](green bold) " ## Каталог -Модуль `directory` показывает путь к вашей текущей директории, усеченной до трех родительских папок. Ваш каталог также будет отсечен до корня git репозитория, в котором вы находитесь. +The `directory` module shows the path to your current directory, truncated to three parent folders. Your directory will also be truncated to the root of the git repo that you're currently in. -При использовании стиля оболочки fish, вместо скрытия усеченного каталога, вы увидите укороченное имя каталога, зависимое от числа символов вы установите для этой опции. +When using the fish style pwd option, instead of hiding the path that is truncated, you will see a shortened name of each directory based on the number you enable for the option. -Например, возьмем `~/Dev/Nix/nixpkgs/pkgs` где `nixpkgs` является корневым репозиторием, и в опции установлено `1`. Вы увидите `~/D/N/nixpkgs/pkgs`, а до этого было бы `nixpkgs/pkgs`. +For example, given `~/Dev/Nix/nixpkgs/pkgs` where `nixpkgs` is the repo root, and the option set to `1`. You will now see `~/D/N/nixpkgs/pkgs`, whereas before it would have been `nixpkgs/pkgs`. ### Опции -| Параметр | По умолчанию | Описание | -| ------------------- | -------------------------------------------------- | ---------------------------------------------------------------------------- | -| `truncation_length` | `3` | Количество родительских папок, к которым должен быть усечен текущий каталог. | -| `truncate_to_repo` | `true` | Следует или нет обрезать до корня репозитория git, в котором вы находитесь. | -| `format` | `"[$path]($style)[$read_only]($read_only_style) "` | Формат модуля. | -| `style` | `"bold cyan"` | Стиль модуля. | -| `disabled` | `false` | Отключает модуль `directory`. | -| `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: "…/" | -| `home_symbol` | `"~"` | The symbol indicating home directory. | +| Параметр | По умолчанию | Описание | +| ------------------- | -------------------------------------------------- | -------------------------------------------------------------------------------- | +| `truncation_length` | `3` | The number of parent folders that the current directory should be truncated to. | +| `truncate_to_repo` | `true` | Whether or not to truncate to the root of the git repo that you're currently in. | +| `format` | `"[$path]($style)[$read_only]($read_only_style) "` | Формат модуля. | +| `style` | `"bold cyan"` | Стиль модуля. | +| `disabled` | `false` | Disables the `directory` module. | +| `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: "…/" | +| `home_symbol` | `"~"` | The symbol indicating home directory. |
-Этот модуль имеет несколько расширенных опций конфигурации, которые контролируют отображение каталога. +This module has a few advanced configuration options that control how the directory is displayed. | Advanced Option | По умолчанию | Описание | | --------------------------- | ------------ | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------- | | `substitutions` | | A table of substitutions to be made to the path. | -| `fish_style_pwd_dir_length` | `0` | Количество символов, используемых при использовании логики создания пути из fish. | +| `fish_style_pwd_dir_length` | `0` | The number of characters to use when applying fish shell pwd path logic. | | `use_logical_path` | `true` | If `true` render the logical path sourced from the shell via `PWD` or `--logical-path`. If `false` instead render the physical filesystem path with symlinks resolved. | `substitutions` allows you to define arbitrary replacements for literal strings that occur in the path, for example long network prefixes or development directories (i.e. Java). Note that this will disable the fish style PWD. @@ -721,7 +763,7 @@ format = "via [🦕 $version](green bold) " "src/com/long/java/path" = "mypath" ``` -`fish_style_pwd_dir_length` взаимодействует со стандартными параметрами усечения, которые могут сначала показаться странными: если он не равен нулю, элементы пути, который обычно усекается, вместо этого отображаются с указанным количеством символов. For example, the path `/built/this/city/on/rock/and/roll`, which would normally be displayed as as `rock/and/roll`, would be displayed as `/b/t/c/o/rock/and/roll` with `fish_style_pwd_dir_length = 1`--the path components that would normally be removed are displayed with a single character. For `fish_style_pwd_dir_length = 2`, it would be `/bu/th/ci/on/rock/and/roll`. +`fish_style_pwd_dir_length` interacts with the standard truncation options in a way that can be surprising at first: if it's non-zero, the components of the path that would normally be truncated are instead displayed with that many characters. For example, the path `/built/this/city/on/rock/and/roll`, which would normally be displayed as as `rock/and/roll`, would be displayed as `/b/t/c/o/rock/and/roll` with `fish_style_pwd_dir_length = 1`--the path components that would normally be removed are displayed with a single character. For `fish_style_pwd_dir_length = 2`, it would be `/bu/th/ci/on/rock/and/roll`.
@@ -732,7 +774,7 @@ format = "via [🦕 $version](green bold) " | path | `"D:/Projects"` | The current directory path | | style\* | `"black bold dimmed"` | Отражает значение параметра `style` | -\*: Эта переменная может использоваться только в качестве части строки style +\*: This variable can only be used as a part of a style string ### Пример @@ -744,7 +786,7 @@ truncation_length = 8 truncation_symbol = "…/" ``` -## Контекст Docker +## Docker Context The `docker_context` module shows the currently active [Docker context](https://docs.docker.com/engine/context/working-with-contexts/) if it's not set to `default` or if the `DOCKER_HOST` or `DOCKER_CONTEXT` environment variables are set (as they are meant to override the context in use). @@ -769,7 +811,7 @@ The `docker_context` module shows the currently active [Docker context](https:// | symbol | | Отражает значение параметра `symbol` | | style\* | | Отражает значение параметра `style` | -\*: Эта переменная может использоваться только в качестве части строки style +\*: This variable can only be used as a part of a style string ### Пример @@ -782,7 +824,7 @@ format = "via [🐋 $context](blue bold)" ## Dotnet -The `dotnet` module shows the relevant version of the [.NET Core SDK](https://dotnet.microsoft.com/) for the current directory. Если SDK был закреплен в текущей директории, будет показана закрепленная версия. В противном случае модуль отображает последнюю установленную версию SDK. +The `dotnet` module shows the relevant version of the [.NET Core SDK](https://dotnet.microsoft.com/) for the current directory. If the SDK has been pinned in the current directory, the pinned version is shown. Otherwise the module shows the latest installed version of the SDK. By default this module will only be shown in your prompt when one or more of the following files are present in the current directory: @@ -797,7 +839,7 @@ By default this module will only be shown in your prompt when one or more of the You'll also need the .NET Core SDK installed in order to use it correctly. -Внутренне этот модуль использует свой собственный механизм определения версий. Обычно он в два раза быстрее, чем `dotnet --version`, но он может показывать неправильную версию, если ваш .NET проект имеет необычный формат каталога. Если точность важнее, чем скорость, вы можете отключить механизм опцией `heuristic = false` в настройках модуля. +Internally, this module uses its own mechanism for version detection. Typically it is twice as fast as running `dotnet --version`, but it may show an incorrect version if your .NET project has an unusual directory layout. If accuracy is more important than speed, you can disable the mechanism by setting `heuristic = false` in the module options. The module will also show the Target Framework Moniker () when there is a csproj file in the current directory. @@ -807,13 +849,13 @@ The module will also show the Target Framework Moniker ([\\w-]+)" = "gke-$cluster" ``` -## Перевод Строки +## Line Break -Модуль `line_break` разделяет командную строку на две строки. +The `line_break` module separates the prompt into two lines. ### Опции -| Параметр | По умолчанию | Описание | -| ---------- | ------------ | ------------------------------------------------------------------------ | -| `disabled` | `false` | Отключает модуль `line_break`, отображая командную строку в одну строку. | +| Параметр | По умолчанию | Описание | +| ---------- | ------------ | ------------------------------------------------------------------ | +| `disabled` | `false` | Disables the `line_break` module, making the prompt a single line. | ### Пример @@ -1736,7 +1808,7 @@ The `lua` module shows the currently installed version of [Lua](http://www.lua.o | symbol | | Отражает значение параметра `symbol` | | style\* | | Отражает значение параметра `style` | -\*: Эта переменная может использоваться только в качестве части строки style +\*: This variable can only be used as a part of a style string ### Пример @@ -1747,27 +1819,27 @@ The `lua` module shows the currently installed version of [Lua](http://www.lua.o format = "via [🌕 $version](bold blue) " ``` -## Использование памяти +## Memory Usage -Модуль `memory_usage` отображает текущую системную память и использование подкачки. +The `memory_usage` module shows current system memory and swap usage. -По умолчанию использование подкачки отображается, если общая сумма подкачки системы не равна нулю. +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. ::: ### Опции -| Параметр | По умолчанию | Описание | -| ----------- | ----------------------------------------------- | ------------------------------------------------------------------ | -| `threshold` | `75` | Скрывать использование памяти, если она не превышает этот процент. | -| `format` | `"via $symbol [${ram}( \| ${swap})]($style) "` | Формат модуля. | -| `symbol` | `"🐏"` | Символ, используемый перед отображением использования памяти. | -| `style` | `"bold dimmed white"` | Стиль модуля. | -| `disabled` | `true` | Отключает модуль `memory_usage`. | +| Параметр | По умолчанию | Описание | +| ----------- | ----------------------------------------------- | -------------------------------------------------------- | +| `threshold` | `75` | Hide the memory usage unless it exceeds this percentage. | +| `format` | `"via $symbol [${ram}( \| ${swap})]($style) "` | Формат модуля. | +| `symbol` | `"🐏"` | The symbol used before displaying the memory usage. | +| `style` | `"bold dimmed white"` | Стиль модуля. | +| `disabled` | `true` | Disables the `memory_usage` module. | ### Переменные @@ -1794,20 +1866,20 @@ symbol = " " style = "bold dimmed green" ``` -## Ветка Mercurial +## Mercurial Branch -Модуль `hg_branch` показывает активную ветку репозитория в вашем текущем каталоге. +The `hg_branch` module shows the active branch of the repo in your current directory. ### Опции -| Параметр | По умолчанию | Описание | -| ------------------- | -------------------------------- | ---------------------------------------------------------------------------------------- | -| `symbol` | `" "` | Символ, используемый перед закладкой hg или именем ветки репозитория в текущем каталоге. | -| `style` | `"bold purple"` | Стиль модуля. | -| `format` | `"on [$symbol$branch]($style) "` | Формат модуля. | -| `truncation_length` | `2^63 - 1` | Truncates the hg branch name to `N` graphemes | -| `truncation_symbol` | `"…"` | Символ, используемый для обозначения усечения названия ветки. | -| `disabled` | `true` | Отключает модуль `hg_branch`. | +| Параметр | По умолчанию | Описание | +| ------------------- | -------------------------------- | -------------------------------------------------------------------------------------------- | +| `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) "` | Формат модуля. | +| `truncation_length` | `2^63 - 1` | Truncates the hg branch name to `N` graphemes | +| `truncation_symbol` | `"…"` | The symbol used to indicate a branch name was truncated. | +| `disabled` | `true` | Disables the `hg_branch` module. | ### Переменные @@ -1817,7 +1889,7 @@ style = "bold dimmed green" | symbol | | Отражает значение параметра `symbol` | | style\* | | Отражает значение параметра `style` | -\*: Эта переменная может использоваться только в качестве части строки style +\*: This variable can only be used as a part of a style string ### Пример @@ -1834,7 +1906,7 @@ truncation_symbol = "" The `nim` module shows the currently installed version of [Nim](https://nim-lang.org/). By default the module will be shown if any of the following conditions are met: -- Текущий каталог содержит файл `nim.cfg` +- The current directory contains a `nim.cfg` file - The current directory contains a file with the `.nim` extension - The current directory contains a file with the `.nims` extension - The current directory contains a file with the `.nimble` extension @@ -1843,7 +1915,7 @@ The `nim` module shows the currently installed version of [Nim](https://nim-lang | Параметр | По умолчанию | Описание | | ------------------- | ------------------------------------ | ------------------------------------------------------------------------- | -| `format` | `"via [$symbol($version )]($style)"` | Формат модуля | +| `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 Nim. | | `detect_extensions` | `["nim", "nims", "nimble"]` | Which extensions should trigger this module. | @@ -1860,7 +1932,7 @@ The `nim` module shows the currently installed version of [Nim](https://nim-lang | symbol | | Отражает значение параметра `symbol` | | style\* | | Отражает значение параметра `style` | -\*: Эта переменная может использоваться только в качестве части строки style +\*: This variable can only be used as a part of a style string ### Пример @@ -1874,7 +1946,7 @@ 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. ### Опции @@ -1885,7 +1957,7 @@ The `nix_shell` module shows the [nix-shell](https://nixos.org/guides/nix-pills/ | `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`. | +| `disabled` | `false` | Disables the `nix_shell` module. | ### Переменные @@ -1896,7 +1968,7 @@ The `nix_shell` module shows the [nix-shell](https://nixos.org/guides/nix-pills/ | symbol | | Отражает значение параметра `symbol` | | style\* | | Отражает значение параметра `style` | -\*: Эта переменная может использоваться только в качестве части строки style +\*: This variable can only be used as a part of a style string ### Пример @@ -1914,10 +1986,10 @@ format = 'via [☃️ $state( \($name\))](bold blue) ' The `nodejs` module shows the currently installed version of [Node.js](https://nodejs.org/). By default the module will be shown if any of the following conditions are met: -- Текущий каталог содержит файл `package.json` +- The current directory contains a `package.json` file - The current directory contains a `.node-version` file - The current directory contains a `.nvmrc` file -- Текущий каталог содержит каталог `node_modules` +- The current directory contains a `node_modules` directory - The current directory contains a file with the `.js`, `.mjs` or `.cjs` extension - The current directory contains a file with the `.ts` extension @@ -1932,7 +2004,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. | ### Переменные @@ -1943,7 +2015,7 @@ The `nodejs` module shows the currently installed version of [Node.js](https://n | symbol | | Отражает значение параметра `symbol` | | style\* | | Отражает значение параметра `style` | -\*: Эта переменная может использоваться только в качестве части строки style +\*: This variable can only be used as a part of a style string ### Пример @@ -1990,7 +2062,7 @@ The `ocaml` module shows the currently installed version of [OCaml](https://ocam | symbol | | Отражает значение параметра `symbol` | | style\* | | Отражает значение параметра `style` | -\*: Эта переменная может использоваться только в качестве части строки style +\*: This variable can only be used as a part of a style string ### Пример @@ -2023,7 +2095,7 @@ The `openstack` module shows the current OpenStack cloud and project. The module | symbol | | Отражает значение параметра `symbol` | | style\* | | Отражает значение параметра `style` | -\*: Эта переменная может использоваться только в качестве части строки style +\*: This variable can only be used as a part of a style string ### Пример @@ -2036,23 +2108,23 @@ style = "bold yellow" symbol = "☁️ " ``` -## Версия пакета +## Package Version -Модуль `package` отображается, когда текущий каталог является репозиторием для пакета и показывает его текущую версию. The module currently supports `npm`, `nimble`, `cargo`, `poetry`, `composer`, `gradle`, `julia`, `mix` and `helm` 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`, `composer`, `gradle`, `julia`, `mix` and `helm` 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 -- [**nimble**](https://github.com/nim-lang/nimble) - The `nimble` package version is extracted from the `*.nimble` file present in the current directory with the `nimble dump` command -- [**poetry**](https://python-poetry.org/) – The `poetry` package version is extracted from the `pyproject.toml` present in the current directory -- [**python**](https://www.python.org) - The `python` package version is extracted from the `setup.cfg` present in the current directory -- [**composer**](https://getcomposer.org/) – The `composer` package version is extracted from the `composer.json` present in the current directory -- [**gradle**](https://gradle.org/) – The `gradle` package version is extracted from the `build.gradle` present -- [**julia**](https://docs.julialang.org/en/v1/stdlib/Pkg/) - The package version is extracted from the `Project.toml` present -- [**mix**](https://hexdocs.pm/mix/) - The `mix` package version is extracted from the `mix.exs` present -- [**helm**](https://helm.sh/docs/helm/helm_package/) - The `helm` chart version is extracted from the `Chart.yaml` present -- [**maven**](https://maven.apache.org/) - The `maven` package version is extracted from the `pom.xml` present -- [**meson**](https://mesonbuild.com/) - The `meson` package version is extracted from the `meson.build` present -- [**vlang**](https://vlang.io) - The `vlang` package version is extracted from the `v.mod` present +- [**Cargo**](https://doc.rust-lang.org/cargo/) – The `cargo` package version is extracted from the `Cargo.toml` present in the current directory +- [**Nimble**](https://github.com/nim-lang/nimble) - The `nimble` package version is extracted from the `*.nimble` file present in the current directory with the `nimble dump` command +- [**Poetry**](https://python-poetry.org/) – The `poetry` package version is extracted from the `pyproject.toml` present in the current directory +- [**Python**](https://www.python.org) - The `python` package version is extracted from the `setup.cfg` present in the current directory +- [**Composer**](https://getcomposer.org/) – The `composer` package version is extracted from the `composer.json` present in the current directory +- [**Gradle**](https://gradle.org/) – The `gradle` package version is extracted from the `build.gradle` present +- [**Julia**](https://docs.julialang.org/en/v1/stdlib/Pkg/) - The package version is extracted from the `Project.toml` present +- [**Mix**](https://hexdocs.pm/mix/) - The `mix` package version is extracted from the `mix.exs` present +- [**Helm**](https://helm.sh/docs/helm/helm_package/) - The `helm` chart version is extracted from the `Chart.yaml` present +- [**Maven**](https://maven.apache.org/) - The `maven` package version is extracted from the `pom.xml` present +- [**Meson**](https://mesonbuild.com/) - The `meson` package version is extracted from the `meson.build` present +- [**V**](https://vlang.io) - The `vlang` package version is extracted from the `v.mod` present > ⚠ Показана версия пакета, исходный код которого находится в текущем каталоге, а не в менеджере пакетов. @@ -2061,11 +2133,11 @@ symbol = "☁️ " | Параметр | По умолчанию | Описание | | ----------------- | --------------------------------- | ------------------------------------------------------------------------- | | `format` | `"is [$symbol$version]($style) "` | Формат модуля. | -| `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. | ### Переменные @@ -2075,7 +2147,7 @@ symbol = "☁️ " | symbol | | Отражает значение параметра `symbol` | | style\* | | Отражает значение параметра `style` | -\*: Эта переменная может использоваться только в качестве части строки style +\*: This variable can only be used as a part of a style string ### Пример @@ -2130,8 +2202,8 @@ 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: -- Текущий каталог содержит файл `composer.json` -- Текущий каталог содержит файл `.php-version` +- The current directory contains a `composer.json` file +- The current directory contains a `.php-version` file - The current directory contains a `.php` extension ### Опции @@ -2140,12 +2212,12 @@ The `php` module shows the currently installed version of [PHP](https://www.php. | ------------------- | ------------------------------------ | ------------------------------------------------------------------------- | | `format` | `"via [$symbol($version )]($style)"` | Формат модуля. | | `version_format` | `"v${raw}"` | The version format. Available vars are `raw`, `major`, `minor`, & `patch` | -| `symbol` | `"🐘 "` | Символ, используемый перед отображением версии PHP. | +| `symbol` | `"🐘 "` | The symbol used before displaying the version of PHP. | | `detect_extensions` | `["php"]` | Which extensions should trigger this module. | | `detect_files` | `["composer.json", ".php-version"]` | Which filenames should trigger this module. | | `detect_folders` | `[]` | Which folders should trigger this module. | | `style` | `"147 bold"` | Стиль модуля. | -| `disabled` | `false` | Отключает модуль `php`. | +| `disabled` | `false` | Disables the `php` module. | ### Переменные @@ -2155,7 +2227,7 @@ The `php` module shows the currently installed version of [PHP](https://www.php. | symbol | | Отражает значение параметра `symbol` | | style\* | | Отражает значение параметра `style` | -\*: Эта переменная может использоваться только в качестве части строки style +\*: This variable can only be used as a part of a style string ### Пример @@ -2170,7 +2242,7 @@ format = "via [🔹 $version](147 bold) " The `purescript` module shows the currently installed version of [PureScript](https://www.purescript.org/) version. By default the module will be shown if any of the following conditions are met: -- Текущий каталог содержит файл `spago.dhall` +- The current directory contains a `spago.dhall` file - The current directory contains a file with the `.purs` extension ### Опции @@ -2194,7 +2266,7 @@ The `purescript` module shows the currently installed version of [PureScript](ht | symbol | | Отражает значение параметра `symbol` | | style\* | | Отражает значение параметра `style` | -\*: Эта переменная может использоваться только в качестве части строки style +\*: This variable can only be used as a part of a style string ### Пример @@ -2213,15 +2285,15 @@ If `pyenv_version_name` is set to `true`, it will display the pyenv version name By default the module will be shown if any of the following conditions are met: -- Текущий каталог содержит файл `.python-version` -- Текущий каталог содержит файл `Pipfile` +- The current directory contains a `.python-version` file +- The current directory contains a `Pipfile` file - The current directory contains a `__init__.py` file -- Текущий каталог содержит файл `pyproject.toml` -- Текущий каталог содержит файл `requirements.txt` -- Текущий каталог содержит файл `setup.py` -- Текущий каталог содержит файл `tox.ini` -- Текущий каталог содержит файл с расширением `.py`. -- Виртуальная среда в данный момент активирована +- The current directory contains a `pyproject.toml` file +- The current directory contains a `requirements.txt` file +- The current directory contains a `setup.py` file +- The current directory contains a `tox.ini` file +- The current directory contains a file with the `.py` extension. +- A virtual environment is currently activated ### Опции @@ -2231,7 +2303,7 @@ 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 | @@ -2296,7 +2368,7 @@ python_binary = ["./venv/bin/python", "python", "python3", "python2"] ## R -The `rlang` module shows the currently installed version of R. The module will be shown if any of the following conditions are met: +The `rlang` module shows the currently installed version of [R](https://www.r-project.org/). The module will be shown if any of the following conditions are met: - The current directory contains a file with the `.R` extension. - The current directory contains a file with the `.Rd` extension. @@ -2338,7 +2410,7 @@ format = "with [📐 $version](blue bold) " ## 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 @@ -2363,7 +2435,7 @@ By default the `red` module shows the currently installed version of [Red](https | symbol | | Отражает значение параметра `symbol` | | style\* | | Отражает значение параметра `style` | -\*: Эта переменная может использоваться только в качестве части строки style +\*: This variable can only be used as a part of a style string ### Пример @@ -2376,11 +2448,11 @@ 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` -- Текущий каталог содержит файл `.ruby-version` -- Текущий каталог содержит файл `.rb` +- The current directory contains a `Gemfile` file +- The current directory contains a `.ruby-version` file +- The current directory contains a `.rb` file ### Опции @@ -2393,7 +2465,7 @@ By default the `ruby` module shows the currently installed version of [Ruby](htt | `detect_files` | `["Gemfile", ".ruby-version"]` | Which filenames should trigger this module. | | `detect_folders` | `[]` | Which folders should trigger this module. | | `style` | `"bold red"` | Стиль модуля. | -| `disabled` | `false` | Отключает модуль `ruby`. | +| `disabled` | `false` | Disables the `ruby` module. | ### Переменные @@ -2403,7 +2475,7 @@ By default the `ruby` module shows the currently installed version of [Ruby](htt | symbol | | Отражает значение параметра `symbol` | | style\* | | Отражает значение параметра `style` | -\*: Эта переменная может использоваться только в качестве части строки style +\*: This variable can only be used as a part of a style string ### Пример @@ -2416,10 +2488,10 @@ 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` +- The current directory contains a `Cargo.toml` file +- The current directory contains a file with the `.rs` extension ### Опции @@ -2432,7 +2504,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. | ### Переменные @@ -2442,7 +2514,7 @@ By default the `rust` module shows the currently installed version of [Rust](htt | symbol | | Отражает значение параметра `symbol` | | style\* | | Отражает значение параметра `style` | -\*: Эта переменная может использоваться только в качестве части строки style +\*: This variable can only be used as a part of a style string ### Пример @@ -2482,7 +2554,7 @@ The `scala` module shows the currently installed version of [Scala](https://www. | symbol | | Отражает значение параметра `symbol` | | style\* | | Отражает значение параметра `style` | -\*: Эта переменная может использоваться только в качестве части строки style +\*: This variable can only be used as a part of a style string ### Пример @@ -2499,7 +2571,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. ::: @@ -2539,7 +2611,7 @@ disabled = false ## SHLVL -The `shlvl` module shows the current `SHLVL` ("shell level") environment variable, if it is set to a number and meets or exceeds the specified threshold. +The `shlvl` module shows the current [`SHLVL`](https://tldp.org/LDP/abs/html/internalvariables.html#SHLVLREF) ("shell level") environment variable, if it is set to a number and meets or exceeds the specified threshold. ### Опции @@ -2560,7 +2632,7 @@ The `shlvl` module shows the current `SHLVL` ("shell level") environment variabl | symbol | | Отражает значение параметра `symbol` | | style\* | | Отражает значение параметра `style` | -\*: Эта переменная может использоваться только в качестве части строки style +\*: This variable can only be used as a part of a style string ### Пример @@ -2594,7 +2666,7 @@ The `singularity` module shows the current [Singularity](https://sylabs.io/singu | symbol | | Отражает значение параметра `symbol` | | style\* | | Отражает значение параметра `style` | -\*: Эта переменная может использоваться только в качестве части строки style +\*: This variable can only be used as a part of a style string ### Пример @@ -2611,7 +2683,7 @@ The `status` module displays the exit code of the previous command. The module w ::: tip -По умолчанию этот модуль отключен. Чтобы включить его, установите `disabled` на `false` в файле конфигурации. +This module is disabled by default. To enable it, set `disabled` to `false` in your configuration file. ::: @@ -2650,7 +2722,7 @@ The `status` module displays the exit code of the previous command. The module w | symbol | | Отражает значение параметра `symbol` | | style\* | | Отражает значение параметра `style` | -\*: Эта переменная может использоваться только в качестве части строки style +\*: This variable can only be used as a part of a style string ### Пример @@ -2669,7 +2741,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 @@ -2695,7 +2767,7 @@ By default the `swift` module shows the currently installed version of [Swift](h | symbol | | Отражает значение параметра `symbol` | | style\* | | Отражает значение параметра `style` | -\*: Эта переменная может использоваться только в качестве части строки style +\*: This variable can only be used as a part of a style string ### Пример @@ -2718,7 +2790,7 @@ By default the Terraform version is not shown, since this is slow for current ve By default the module will be shown if any of the following conditions are met: -- Текущий каталог содержит папку `.terraform` +- The current directory contains a `.terraform` folder - Current directory contains a file with the `.tf` or `.hcl` extensions ### Опции @@ -2732,7 +2804,7 @@ By default the module will be shown if any of the following conditions are met: | `detect_files` | `[]` | Which filenames should trigger this module. | | `detect_folders` | `[".terraform"]` | Which folders should trigger this module. | | `style` | `"bold 105"` | Стиль модуля. | -| `disabled` | `false` | Отключает модуль `terraform`. | +| `disabled` | `false` | Disables the `terraform` module. | ### Переменные @@ -2743,7 +2815,7 @@ By default the module will be shown if any of the following conditions are met: | symbol | | Отражает значение параметра `symbol` | | style\* | | Отражает значение параметра `style` | -\*: Эта переменная может использоваться только в качестве части строки style +\*: This variable can only be used as a part of a style string ### Пример @@ -2767,36 +2839,36 @@ format = "[🏎💨 $workspace]($style) " ## Время -Модуль `time` показывает текущее **локальное** время. Значение конфигурации `format` используется пакетом [`chrono`](https://crates.io/crates/chrono) для контроля того, как отображается время. Ознакомьтесь с [документацией 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. ::: ### Опции -| Параметр | По умолчанию | Описание | -| ----------------- | ----------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------- | -| `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 | +| Параметр | По умолчанию | Описание | +| ----------------- | ----------------------- | ---------------------------------------------------------------------------------------------------------------------------------- | +| `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"`. Иначе по умолчанию используется `"%T"`. Manually setting `time_format` will override the `use_12hr` setting. +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. ### Переменные | Переменная | Пример | Описание | | ---------- | ---------- | ----------------------------------- | -| время | `13:08:10` | The current time. | +| time | `13:08:10` | The current time. | | style\* | | Отражает значение параметра `style` | -\*: Эта переменная может использоваться только в качестве части строки style +\*: This variable can only be used as a part of a style string ### Пример @@ -2811,14 +2883,14 @@ 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: -- Текущий пользователь - root -- Текущий пользователь отличается от залогиненного -- Пользователь подключен к SSH-сессии -- Переменная `show_always` равна true +- The current user is root +- The current user isn't the same as the one that is logged in +- The user is currently connected as an SSH session +- The variable `show_always` is set to true ::: tip @@ -2828,13 +2900,13 @@ SSH connection is detected by checking environment variables `SSH_CONNECTION`, ` ### Опции -| Параметр | По умолчанию | Описание | -| ------------- | ----------------------- | ------------------------------------------------------- | -| `style_root` | `"bold red"` | Стиль, используемый для пользователя root. | -| `style_user` | `"bold yellow"` | Стиль, используемый для всех пользователей, кроме root. | -| `format` | `"[$user]($style) in "` | Формат модуля. | -| `show_always` | `false` | Всегда показывать модуль `username`. | -| `disabled` | `false` | Отключает модуль `username`. | +| Параметр | По умолчанию | Описание | +| ------------- | ----------------------- | ------------------------------------- | +| `style_root` | `"bold red"` | The style used when the user is root. | +| `style_user` | `"bold yellow"` | The style used for non-root users. | +| `format` | `"[$user]($style) in "` | Формат модуля. | +| `show_always` | `false` | Always shows the `username` module. | +| `disabled` | `false` | Disables the `username` module. | ### Переменные @@ -2883,7 +2955,7 @@ The `vagrant` module shows the currently installed version of [Vagrant](https:// | symbol | | Отражает значение параметра `symbol` | | style\* | | Отражает значение параметра `style` | -\*: Эта переменная может использоваться только в качестве части строки style +\*: This variable can only be used as a part of a style string ### Пример @@ -2894,9 +2966,9 @@ The `vagrant` module shows the currently installed version of [Vagrant](https:// format = "via [⍱ $version](bold white) " ``` -## VLang +## V -The `vlang` module shows you your currently installed version of V. By default the module will be shown if any of the following conditions are met: +The `vlang` module shows you your currently installed version of [V](https://vlang.io/). By default the module will be shown if any of the following conditions are met: - The current directory contains a file with `.v` extension - The current directory contains a `v.mod`, `vpkg.json` or `.vpkg-lock.json` file @@ -2925,7 +2997,7 @@ The `vlang` module shows you your currently installed version of V. By default t ```toml # ~/.config/starship.toml -[v] +[vlang] format = "via [V $version](blue bold) " ``` @@ -2950,7 +3022,7 @@ The `vcsh` module displays the current active [VCSH](https://github.com/RichiH/v | symbol | | Отражает значение параметра `symbol` | | style\* | `black bold dimmed` | Отражает значение параметра `style` | -\*: Эта переменная может использоваться только в качестве части строки style +\*: This variable can only be used as a part of a style string ### Пример @@ -2963,7 +3035,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 @@ -2988,7 +3060,7 @@ By default the the `zig` module shows the currently installed version of [Zig](h | symbol | | Отражает значение параметра `symbol` | | style\* | | Отражает значение параметра `style` | -\*: Эта переменная может использоваться только в качестве части строки style +\*: This variable can only be used as a part of a style string ### Пример @@ -3036,7 +3108,7 @@ The order in which custom modules are shown can be individually set by including | `command` | | The command whose output should be printed. The command will be passed on stdin to the shell. | | `when` | | A shell command used as a condition to show the module. The module will be shown if the command returns a `0` status code. | | `shell` | | [See below](#custom-command-shell) | -| `описание` | `""` | The description of the module that is shown when running `starship explain`. | +| `description` | `""` | The description of the module that is shown when running `starship explain`. | | `files` | `[]` | The files that will be searched in the working directory for a match. | | `directories` | `[]` | The directories that will be searched in the working directory for a match. | | `extensions` | `[]` | The extensions that will be searched in the working directory for a match. | @@ -3054,7 +3126,7 @@ The order in which custom modules are shown can be individually set by including | symbol | Отражает значение параметра `symbol` | | style\* | Отражает значение параметра `style` | -\*: Эта переменная может использоваться только в качестве части строки style +\*: This variable can only be used as a part of a style string #### Custom command shell diff --git a/docs/ru-RU/guide/README.md b/docs/ru-RU/guide/README.md index 6f49b56c..081b8dae 100644 --- a/docs/ru-RU/guide/README.md +++ b/docs/ru-RU/guide/README.md @@ -48,30 +48,6 @@ height="20" src="https://raw.githubusercontent.com/starship/starship/master/media/flag-us.png" alt="English" - /> -   - 日本語 -   - 繁體中文 -   - Русский   -   - 简体中文   +   + 日本語 +   + Português do Brasil +   + Русский   +   + 简体中文 +   + 繁體中文

@@ -160,8 +168,8 @@ ```sh sh -c "$(curl -fsSL https://starship.rs/install.sh)" ``` - Для обновления Starship перезапустите этот скрипт. Он заменит текущую версию без изменения конфигурации. + Для обновления Starship перезапустите этот скрипт. Он заменит текущую версию без изменения конфигурации. **Примечание** - Значения по умолчанию из установочного скрипта могут быть переопределены. Для уточнения смотрите встроенную справку. diff --git a/docs/ru-RU/presets/README.md b/docs/ru-RU/presets/README.md index bdc804f6..e696862a 100644 --- a/docs/ru-RU/presets/README.md +++ b/docs/ru-RU/presets/README.md @@ -112,6 +112,9 @@ format = '\[[$symbol($version)]($style)\]' [cmd_duration] format = '\[[⏱ $duration ]($style)\]' +[cobol] +format = '\[[$symbol($version)]($style)\]' + [conda] format = '\[[$symbol$environment]($style)\]' @@ -272,6 +275,9 @@ deleted = "x" [aws] symbol = "aws " +[cobol] +symbol = "cobol " + [conda] symbol = "conda " @@ -375,6 +381,9 @@ This preset hides the version of language runtimes. If you work in containers or [cmake] format = "via [$symbol]($style)" +[cobol] +format = "via [$symbol]($style)" + [crystal] format = "via [$symbol]($style)" diff --git a/docs/tr-TR/advanced-config/README.md b/docs/tr-TR/advanced-config/README.md index 1b39223d..89301d9f 100644 --- a/docs/tr-TR/advanced-config/README.md +++ b/docs/tr-TR/advanced-config/README.md @@ -67,6 +67,33 @@ function set_win_title(){ starship_precmd_user_func="set_win_title" ``` +## Enable Right Prompt + +Some shells support a right prompt which renders on the same line as the input. Starship can set the content of the right prompt using the `right_format` option. Any module that can be used in `format` is also supported in `right_format`. The `$all` variable will only contain modules not explicitly used in either `format` or `right_format`. + +Note: The right prompt is a single line following the input location. To right align modules above the input line in a multi-line prompt, see the [fill module](/config/#fill). + +`right_format` is currently supported for the following shells: elvish, fish, zsh. + +### Example + +```toml +# ~/.config/starship.toml + +# A minimal left prompt +format = """$character""" + +# move the rest of the prompt to the right +right_format = """$all""" +``` + +Produces a prompt like the following: + +``` +▶ starship on  rprompt [!] is 📦 v0.57.0 via 🦀 v1.54.0 took 17s +``` + + ## Style Strings Style strings are a list of words, separated by whitespace. The words are not case sensitive (i.e. `bold` and `BoLd` are considered the same string). Each word can be one of the following: diff --git a/docs/tr-TR/config/README.md b/docs/tr-TR/config/README.md index 3d994b90..5cc5fd4f 100644 --- a/docs/tr-TR/config/README.md +++ b/docs/tr-TR/config/README.md @@ -75,7 +75,7 @@ A text group is made up of two different parts. The first part, which is enclosed in a `[]`, is a [format string](#format-strings). You can add texts, variables, or even nested text groups in it. -In the second part, which is enclosed in a `()`, is a [style string](#style-strings). This can be used style the first part. +In the second part, which is enclosed in a `()`, is a [style string](#style-strings). This can be used to style the first part. For example: @@ -142,12 +142,14 @@ This is the list of prompt-wide configuration options. ### Options -| Option | Default | Description | -| ----------------- | ------------------------------ | ------------------------------------------------------------ | -| `format` | [link](#default-prompt-format) | Configure the format of the prompt. | -| `scan_timeout` | `30` | Timeout for starship to scan files (in milliseconds). | -| `command_timeout` | `500` | Timeout for commands executed by starship (in milliseconds). | -| `add_newline` | `true` | Inserts blank line between shell prompts. | +| Option | Default | Description | +| ----------------- | ------------------------------ | ---------------------------------------------------------------- | +| `format` | [link](#default-prompt-format) | Configure the format of the prompt. | +| `right_format` | `""` | See [Enable Right Prompt](/advanced-config/#enable-right-prompt) | +| `scan_timeout` | `30` | Timeout for starship to scan files (in milliseconds). | +| `command_timeout` | `500` | Timeout for commands executed by starship (in milliseconds). | +| `add_newline` | `true` | Inserts blank line between shell prompts. | + ### Example @@ -179,6 +181,7 @@ format = """ $username\ $hostname\ $shlvl\ +$singularity\ $kubernetes\ $directory\ $vcsh\ @@ -191,6 +194,7 @@ $hg_branch\ $docker_context\ $package\ $cmake\ +$cobol\ $dart\ $deno\ $dotnet\ @@ -202,6 +206,7 @@ $helm\ $java\ $julia\ $kotlin\ +$lua\ $nim\ $nodejs\ $ocaml\ @@ -209,6 +214,7 @@ $perl\ $php\ $purescript\ $python\ +$rlang\ $red\ $ruby\ $rust\ @@ -229,7 +235,6 @@ $crystal\ $custom\ $cmd_duration\ $line_break\ -$lua\ $jobs\ $battery\ $time\ @@ -238,6 +243,13 @@ $shell\ $character""" ``` +If you just want to extend the default format, you can use `$all`; modules you explicitly add to the format will not be duplicated. Eg. + +```toml +# Move the directory to the second line +format="$all$directory$character" +``` + ## AWS The `aws` module shows the current AWS region and profile. This is based on `AWS_REGION`, `AWS_DEFAULT_REGION`, and `AWS_PROFILE` env var with `~/.aws/config` file. This module also shows an expiration timer when using temporary credentials. @@ -479,6 +491,36 @@ The `cmake` module shows the currently installed version of [CMake](https://cmak \*: This variable can only be used as a part of a style string +## COBOL / GNUCOBOL + +The `cobol` module shows the currently installed version of COBOL. By default, the module will be shown if any of the following conditions are met: + +- The current directory contains any files ending in `.cob` or `.COB` +- The current directory contains any files ending in `.cbl` or `.CBL` + +### Options + +| Option | Default | Description | +| ------------------- | ------------------------------------ | ------------------------------------------------------------------------- | +| `symbol` | `"⚙️ "` | The symbol used before displaying the version of COBOL. | +| `format` | `"via [$symbol($version )]($style)"` | The format for the module. | +| `version_format` | `"v${raw}"` | The version format. Available vars are `raw`, `major`, `minor`, & `patch` | +| `style` | `"bold blue"` | The style for the module. | +| `detect_extensions` | `["cbl", "cob", "CBL", "COB"]` | Which extensions should trigger this module. | +| `detect_files` | `[]` | Which filenames should trigger this module. | +| `detect_folders` | `[]` | Which folders should trigger this module. | +| `disabled` | `false` | Disables the `cobol` module. | + +### Variables + +| Variable | Example | Description | +| --------- | ---------- | ------------------------------------ | +| version | `v3.1.2.0` | The version of `cobol` | +| 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 + ## Command Duration The `cmd_duration` module shows how long the last command took to execute. The module will be shown only if the command took longer than two seconds, or the `min_time` config value, if it exists. @@ -530,7 +572,7 @@ format = "underwent [$duration](bold yellow)" ## Conda -The `conda` module shows the current conda environment, if `$CONDA_DEFAULT_ENV` is set. +The `conda` module shows the current [Conda](https://docs.conda.io/en/latest/) environment, if `$CONDA_DEFAULT_ENV` is set. ::: tip @@ -1017,6 +1059,35 @@ The `erlang` module shows the currently installed version of [Erlang/OTP](https: format = "via [e $version](bold red) " ``` +## 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. + +### Options + +| Option | Default | Description | +| -------- | -------------- | --------------------------------- | +| `symbol` | `"."` | The symbol used to fill the line. | +| `style` | `"bold black"` | The style for the module. | + +### Example + +```toml +# ~/.config/starship.toml +format="AA $fill BB $fill CC" + +[fill] +symbol = "-" +style = "bold green" +``` + +Produces a prompt that looks like: + +``` +AA -------------------------------------------- BB -------------------------------------------- CC + +``` + ## 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. @@ -1205,12 +1276,13 @@ This module is disabled by default. To enable it, set `disabled` to `false` in y ### Options -| Option | Default | Description | -| --------------- | -------------------------------------------------------- | ---------------------------------- | -| `added_style` | `"bold green"` | The style for the added count. | -| `deleted_style` | `"bold red"` | The style for the deleted count. | -| `format` | `'[+$added]($added_style) [-$deleted]($deleted_style) '` | The format for the module. | -| `disabled` | `true` | Disables the `git_metrics` module. | +| Option | Default | Description | +| -------------------- | ------------------------------------------------------------ | ------------------------------------- | +| `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. | +| `disabled` | `true` | Disables the `git_metrics` module. | ### Variables @@ -1318,9 +1390,9 @@ diverged = "⇕⇡${ahead_count}⇣${behind_count}" behind = "⇣${count}" ``` -## Golang +## Go -The `golang` module shows the currently installed version of [Golang](https://golang.org/). By default the module will be shown if any of the following conditions are met: +The `golang` module shows the currently installed version of [Go](https://golang.org/). By default the module will be shown if any of the following conditions are met: - The current directory contains a `go.mod` file - The current directory contains a `go.sum` file @@ -2041,18 +2113,18 @@ symbol = "☁️ " 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`, `composer`, `gradle`, `julia`, `mix` and `helm` 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 -- [**nimble**](https://github.com/nim-lang/nimble) - The `nimble` package version is extracted from the `*.nimble` file present in the current directory with the `nimble dump` command -- [**poetry**](https://python-poetry.org/) – The `poetry` package version is extracted from the `pyproject.toml` present in the current directory -- [**python**](https://www.python.org) - The `python` package version is extracted from the `setup.cfg` present in the current directory -- [**composer**](https://getcomposer.org/) – The `composer` package version is extracted from the `composer.json` present in the current directory -- [**gradle**](https://gradle.org/) – The `gradle` package version is extracted from the `build.gradle` present -- [**julia**](https://docs.julialang.org/en/v1/stdlib/Pkg/) - The package version is extracted from the `Project.toml` present -- [**mix**](https://hexdocs.pm/mix/) - The `mix` package version is extracted from the `mix.exs` present -- [**helm**](https://helm.sh/docs/helm/helm_package/) - The `helm` chart version is extracted from the `Chart.yaml` present -- [**maven**](https://maven.apache.org/) - The `maven` package version is extracted from the `pom.xml` present -- [**meson**](https://mesonbuild.com/) - The `meson` package version is extracted from the `meson.build` present -- [**vlang**](https://vlang.io) - The `vlang` package version is extracted from the `v.mod` present +- [**Cargo**](https://doc.rust-lang.org/cargo/) – The `cargo` package version is extracted from the `Cargo.toml` present in the current directory +- [**Nimble**](https://github.com/nim-lang/nimble) - The `nimble` package version is extracted from the `*.nimble` file present in the current directory with the `nimble dump` command +- [**Poetry**](https://python-poetry.org/) – The `poetry` package version is extracted from the `pyproject.toml` present in the current directory +- [**Python**](https://www.python.org) - The `python` package version is extracted from the `setup.cfg` present in the current directory +- [**Composer**](https://getcomposer.org/) – The `composer` package version is extracted from the `composer.json` present in the current directory +- [**Gradle**](https://gradle.org/) – The `gradle` package version is extracted from the `build.gradle` present +- [**Julia**](https://docs.julialang.org/en/v1/stdlib/Pkg/) - The package version is extracted from the `Project.toml` present +- [**Mix**](https://hexdocs.pm/mix/) - The `mix` package version is extracted from the `mix.exs` present +- [**Helm**](https://helm.sh/docs/helm/helm_package/) - The `helm` chart version is extracted from the `Chart.yaml` present +- [**Maven**](https://maven.apache.org/) - The `maven` package version is extracted from the `pom.xml` present +- [**Meson**](https://mesonbuild.com/) - The `meson` package version is extracted from the `meson.build` present +- [**V**](https://vlang.io) - The `vlang` package version is extracted from the `v.mod` present > ⚠️ The version being shown is that of the package whose source code is in your current directory, not your package manager. @@ -2296,7 +2368,7 @@ python_binary = ["./venv/bin/python", "python", "python3", "python2"] ## R -The `rlang` module shows the currently installed version of R. The module will be shown if any of the following conditions are met: +The `rlang` module shows the currently installed version of [R](https://www.r-project.org/). The module will be shown if any of the following conditions are met: - The current directory contains a file with the `.R` extension. - The current directory contains a file with the `.Rd` extension. @@ -2539,7 +2611,7 @@ disabled = false ## SHLVL -The `shlvl` module shows the current `SHLVL` ("shell level") environment variable, if it is set to a number and meets or exceeds the specified threshold. +The `shlvl` module shows the current [`SHLVL`](https://tldp.org/LDP/abs/html/internalvariables.html#SHLVLREF) ("shell level") environment variable, if it is set to a number and meets or exceeds the specified threshold. ### Options @@ -2894,9 +2966,9 @@ The `vagrant` module shows the currently installed version of [Vagrant](https:// format = "via [⍱ $version](bold white) " ``` -## VLang +## V -The `vlang` module shows you your currently installed version of V. By default the module will be shown if any of the following conditions are met: +The `vlang` module shows you your currently installed version of [V](https://vlang.io/). By default the module will be shown if any of the following conditions are met: - The current directory contains a file with `.v` extension - The current directory contains a `v.mod`, `vpkg.json` or `.vpkg-lock.json` file @@ -2925,7 +2997,7 @@ The `vlang` module shows you your currently installed version of V. By default t ```toml # ~/.config/starship.toml -[v] +[vlang] format = "via [V $version](blue bold) " ``` diff --git a/docs/tr-TR/guide/README.md b/docs/tr-TR/guide/README.md index 11a165ce..a8d04975 100644 --- a/docs/tr-TR/guide/README.md +++ b/docs/tr-TR/guide/README.md @@ -48,30 +48,6 @@ height="20" src="https://raw.githubusercontent.com/starship/starship/master/media/flag-us.png" alt="English" - /> -   - 日本語 -   - 繁體中文 -   - Русский   -   - 简体中文   +   + 日本語 +   + Português do Brasil +   + Русский   +   + 简体中文 +   + 繁體中文

@@ -160,8 +168,8 @@ ```sh sh -c "$(curl -fsSL https://starship.rs/install.sh)" ``` - To update the Starship itself, rerun the above script. It will replace the current version without touching Starship's configuration. + To update the Starship itself, rerun the above script. It will replace the current version without touching Starship's configuration. **Note** - The defaults of the install script can be overridden see the built-in help. diff --git a/docs/tr-TR/presets/README.md b/docs/tr-TR/presets/README.md index ac113b6c..1e9e1785 100644 --- a/docs/tr-TR/presets/README.md +++ b/docs/tr-TR/presets/README.md @@ -112,6 +112,9 @@ format = '\[[$symbol($version)]($style)\]' [cmd_duration] format = '\[[⏱ $duration ]($style)\]' +[cobol] +format = '\[[$symbol($version)]($style)\]' + [conda] format = '\[[$symbol$environment]($style)\]' @@ -272,6 +275,9 @@ deleted = "x" [aws] symbol = "aws " +[cobol] +symbol = "cobol " + [conda] symbol = "conda " @@ -375,6 +381,9 @@ This preset hides the version of language runtimes. If you work in containers or [cmake] format = "via [$symbol]($style)" +[cobol] +format = "via [$symbol]($style)" + [crystal] format = "via [$symbol]($style)" diff --git a/docs/vi-VN/advanced-config/README.md b/docs/vi-VN/advanced-config/README.md index 63b4bd19..f7253df3 100644 --- a/docs/vi-VN/advanced-config/README.md +++ b/docs/vi-VN/advanced-config/README.md @@ -68,9 +68,36 @@ function set_win_title(){ starship_precmd_user_func="set_win_title" ``` +## Enable Right Prompt + +Some shells support a right prompt which renders on the same line as the input. Starship can set the content of the right prompt using the `right_format` option. Any module that can be used in `format` is also supported in `right_format`. The `$all` variable will only contain modules not explicitly used in either `format` or `right_format`. + +Note: The right prompt is a single line following the input location. To right align modules above the input line in a multi-line prompt, see the [fill module](/config/#fill). + +`right_format` is currently supported for the following shells: elvish, fish, zsh. + +### Ví dụ + +```toml +# ~/.config/starship.toml + +# A minimal left prompt +format = """$character""" + +# move the rest of the prompt to the right +right_format = """$all""" +``` + +Produces a prompt like the following: + +``` +▶ starship on  rprompt [!] is 📦 v0.57.0 via 🦀 v1.54.0 took 17s +``` + + ## Các chuỗi kiểu -Chuỗi kiểu là một danh sách các từ, được phân cách bởi khoảng trắng. Các từ là không phân biệt hoa thường (ví dụ. `bold` và `Bold` là hai chuỗi tương đương). Mỗi từ có thể là một trong các từ sau: +Style strings are a list of words, separated by whitespace. The words are not case sensitive (i.e. `bold` and `BoLd` are considered the same string). Each word can be one of the following: - `bold` - `nghiêng` @@ -82,14 +109,14 @@ Chuỗi kiểu là một danh sách các từ, được phân cách bởi khoả - `` - `none` -`` là một nơi quy định màu (được bàn luận ở phía dưới). `fg:` and `` currently do the same thing, though this may change in the future. `inverted` swaps the background and foreground colors. Thứ tự các từ trong chuỗi là không quan trọng. +where `` is a color specifier (discussed below). `fg:` and `` currently do the same thing, though this may change in the future. `inverted` swaps the background and foreground colors. The order of words in the string does not matter. -Từ mã `none` ghi đè tất cả các từ mã khác trong chuỗi nếu nó không là một phần của `bg:` specifier, vậy nên `fg:red none fg:blue` sẽ vẫn tạo một chuỗi mà không có kiểu. `bg:none` sets the background to the default color so `fg:red bg:none` is equivalent to `red` or `fg:red` and `bg:green fg:red bg:none` is also equivalent to `fg:red` or `red`. Nó có thể trở thành một lỗi để sử dụng `none` trong việc kết hợp với các từ mã khác trong tương lai. +The `none` token overrides all other tokens in a string if it is not part of a `bg:` specifier, so that e.g. `fg:red none fg:blue` will still create a string with no styling. `bg:none` sets the background to the default color so `fg:red bg:none` is equivalent to `red` or `fg:red` and `bg:green fg:red bg:none` is also equivalent to `fg:red` or `red`. It may become an error to use `none` in conjunction with other tokens in the future. -Một quy định màu có thể là một trong các thứ sau: +A color specifier can be one of the following: - Một tròn các màu chuẩn của terminal: `black`, `red`, `green`, `blue`, `yellow`, `purple`, `cyan`, `white`. Bạn có thể tuỳ chọn những tiền tố này với `bright` để có được phiên bản sáng hơn (ví dụ: `bright-white`). - Một `#` được theo sau bởi một số thập lục phân gồm sáu chữ số. Cái này quy định một [mã thập lục phân cho màu RGB](https://www.w3schools.com/colors/colors_hexadecimal.asp). - Một số nằm giữa 0-255. Cái này quy định một [mã màu ANSI 8-bit](https://i.stack.imgur.com/KTSQa.png). -Nếu nhiều màu được quy định cho màu chữ/màu nền, cái cuối cùng trong chuỗi sẽ được ưu tiên. +If multiple colors are specified for foreground/background, the last one in the string will take priority. diff --git a/docs/vi-VN/config/README.md b/docs/vi-VN/config/README.md index ed35436c..510ce998 100644 --- a/docs/vi-VN/config/README.md +++ b/docs/vi-VN/config/README.md @@ -75,7 +75,7 @@ Một nhóm văn bản được tạo nên bởi hai phần khác nhau. Phần đầu tiên, cái được bao bọc trong một `[]`, là một [định dạng chuỗi](#format-strings). Bạn có thể thêm các văn bản, các biến, hoặc thậm chí các nhóm văn bản lồng nhau vào trong nó. -Phần thứ hai, cái được bao bọc trong một `()`, là một [chuỗi kiểu](#style-strings). Cái này có thể được sử dụng để quy định kiểu của phần đầu tiên. +Phần thứ hai, cái được bao bọc trong một `()`, là một [chuỗi kiểu](#style-strings). This can be used to style the first part. Ví dụ: @@ -142,12 +142,14 @@ Cái này là danh sách các tuỳ chọn cho cấu hình prompt-wide. ### Các tuỳ chọn -| Tuỳ chọn | Mặc định | Mô tả | -| ----------------- | ------------------------------ | ------------------------------------------------------------------------ | -| `format` | [link](#default-prompt-format) | Cấu hình định dạng của prompt. | -| `scan_timeout` | `30` | Timeout của starship cho việc quét các tập tin (tính theo milliseconds). | -| `command_timeout` | `500` | Timeout for commands executed by starship (in milliseconds). | -| `add_newline` | `true` | Chèn dòng trắng giữa các dấu nhắc lệnh. | +| Tuỳ chọn | Mặc định | Mô tả | +| ----------------- | ------------------------------ | ---------------------------------------------------------------- | +| `format` | [link](#default-prompt-format) | Cấu hình định dạng của prompt. | +| `right_format` | `""` | See [Enable Right Prompt](/advanced-config/#enable-right-prompt) | +| `scan_timeout` | `30` | Timeout for starship to scan files (in milliseconds). | +| `command_timeout` | `500` | Timeout for commands executed by starship (in milliseconds). | +| `add_newline` | `true` | Inserts blank line between shell prompts. | + ### Ví dụ @@ -179,6 +181,7 @@ format = """ $username\ $hostname\ $shlvl\ +$singularity\ $kubernetes\ $directory\ $vcsh\ @@ -191,6 +194,7 @@ $hg_branch\ $docker_context\ $package\ $cmake\ +$cobol\ $dart\ $deno\ $dotnet\ @@ -202,6 +206,7 @@ $helm\ $java\ $julia\ $kotlin\ +$lua\ $nim\ $nodejs\ $ocaml\ @@ -209,6 +214,7 @@ $perl\ $php\ $purescript\ $python\ +$rlang\ $red\ $ruby\ $rust\ @@ -229,7 +235,6 @@ $crystal\ $custom\ $cmd_duration\ $line_break\ -$lua\ $jobs\ $battery\ $time\ @@ -238,9 +243,16 @@ $shell\ $character""" ``` +If you just want to extend the default format, you can use `$all`; modules you explicitly add to the format will not be duplicated. Eg. + +```toml +# Move the directory to the second line +format="$all$directory$character" +``` + ## AWS -`aws` module cho biết region và profile hiện tại của AWS. Cái này dựa trên các biến môi trường `AWS_REGION`, `AWS_DEFAULT_REGION`, và `AWS_PROFILE` với tập tin `~/.aws/config`. This module also shows an expiration timer when using temporary credentials. +The `aws` module shows the current AWS region and profile. This is based on `AWS_REGION`, `AWS_DEFAULT_REGION`, and `AWS_PROFILE` env var with `~/.aws/config` file. This module also shows an expiration timer when using temporary credentials. When using [aws-vault](https://github.com/99designs/aws-vault) the profile is read from the `AWS_VAULT` env var and the credentials expiration date is read from the `AWS_SESSION_EXPIRATION` env var. @@ -269,7 +281,7 @@ When using [AWSume](https://awsu.me) the profile is read from the `AWSUME_PROFIL | symbol | | Giá trị ghi đè tuỳ chọn `symbol` | | style\* | | Giá trị ghi đè của `style` | -\*: Biến này có thể chỉ được sử dụng như một phần của style string +\*: This variable can only be used as a part of a style string ### Các vị dụ @@ -314,7 +326,7 @@ symbol = "🅰 " ## Battery -`battery` module cho biết cách sạc pin của thiết bị là gì và tình trạng sạc hiện tại của nó. Module chỉ được nhìn thấy khi pin của thiết bị dưới 10%. +The `battery` module shows how charged the device's battery is and its current charging status. The module is only visible when the device's battery is below 10%. ### Các tuỳ chọn @@ -342,7 +354,7 @@ discharging_symbol = "💀 " ### Hiển thị pin -The `display` configuration option is used to define when the battery indicator should be shown (threshold), which symbol would be used (symbol), and what it would like (style). Nếu `display` không được cung cấp. Mặc định như sau: +The `display` configuration option is used to define when the battery indicator should be shown (threshold), which symbol would be used (symbol), and what it would like (style). If no `display` is provided. Mặc định như sau: ```toml [[battery.display]] @@ -354,7 +366,7 @@ The default value for the `charging_symbol` and `discharging_symbol` option is r #### Các tuỳ chọn -Tuỳ chọn `display` là một mảng của của bảng sau. +The `display` option is an array of the following table. | Tuỳ chọn | Mặc định | Mô tả | | -------------------- | ---------- | --------------------------------------------------------------------------------------------------------- | @@ -381,14 +393,14 @@ discharging_symbol = 💦 ## Character -Module `character` cho biết một kí tự (thường là một mũi tên) bên cạnh nơi văn bản được nhập trong terminal của bạn. +The `character` module shows a character (usually an arrow) beside where the text is entered in your terminal. -Kí tự sẽ nói cho bạn câu lệnh cuối liệu thành công hay thất bại. Nó có thể làm điều này bằng hai cách: +The character will tell you whether the last command was successful or not. It can do this in two ways: - thay đổi màu(`đỏ`/`xanh lá`) - thay đổi hình dạng (`❯`/`✖`) -Mặc định, nó chỉ thay đổi màu. If you also want to change its shape take a look at [this example](#with-custom-error-shape). +By default it only changes color. If you also want to change its shape take a look at [this example](#with-custom-error-shape). ::: cảnh báo @@ -451,7 +463,7 @@ vicmd_symbol = "[V](bold green) " ## CMake -The `cmake` module shows the currently installed version of [CMake](https://cmake.org/). Mặc định module sẽ được kích hoạt nếu thoả mãn bất kì điều kiện nào dưới đây: +The `cmake` module shows the currently installed version of [CMake](https://cmake.org/). By default the module will be activated if any of the following conditions are met: - Đường dẫn hiện tại chứa một tập tin `CmakeLists.txt` - Đường dẫn hiện tại chứa một tập tin `CMakeCache.txt` @@ -477,46 +489,76 @@ The `cmake` module shows the currently installed version of [CMake](https://cmak | symbol | | Giá trị ghi đè tuỳ chọn `symbol` | | style\* | | Giá trị ghi đè của `style` | -\*: Biến này có thể chỉ được sử dụng như một phần của style string +\*: This variable can only be used as a part of a style string -## Command Duration +## COBOL / GNUCOBOL -Module `cmd_duration`. cho biết câu lệnh cuối cùng thực thi trong bao lâu. Module sẽ được hiện chỉ khi câu lệnh lấy nhiều hơn 2 giây, hoặc giá trị cấu hình `min_time`, nếu nó tồn tại. +The `cobol` module shows the currently installed version of COBOL. By default, the module will be shown if any of the following conditions are met: -::: cảnh báo Không thể hook DEBUG trap trong Bash - -Nếu bạn đang chạy Starship trong `bash`, không thể hook `DEBUG` trap sau khi chạy `eval $(starship init $0)`, hoặc module này **sẽ** ngắt. - -::: - -Người dùng Bash, những người cần chức năng giống preexec có thể sử dụng [rcaloras's bash_preexec framework](https://github.com/rcaloras/bash-preexec). Đơn giản là định nghĩa các mảng `preexec_functions` và `precmd_functions` trước khi chạy `eval $(starship init $0)`, và sau đó thực thi như bình thường. +- The current directory contains any files ending in `.cob` or `.COB` +- The current directory contains any files ending in `.cbl` or `.CBL` ### Các tuỳ chọn -| Tuỳ chọn | Mặc định | Mô tả | -| -------------------- | ----------------------------- | ---------------------------------------------------------------------- | -| `min_time` | `2_000` | Khoảng thời gian ngắn nhất để hiện thời gian (tính bằng milliseconds). | -| `show_milliseconds` | `false` | Hiện milliseconds. | -| `format` | `"took [$duration]($style) "` | Định dạng cho module. | -| `style` | `"bold yellow"` | Kiểu cho module. | -| `disabled` | `false` | Vô hiệu module `cmd_duration`. | -| `show_notifications` | `false` | Hiện thông báo desktop khi câu lệnh hoàn thành. | -| `min_time_to_notify` | `45_000` | Khoảng thời gian ngắn nhất để thông báo (tính bằng milliseconds). | +| Tuỳ chọn | Mặc định | Mô tả | +| ------------------- | ------------------------------------ | ------------------------------------------------------------------------- | +| `symbol` | `"⚙️ "` | The symbol used before displaying the version of COBOL. | +| `format` | `"via [$symbol($version )]($style)"` | Định dạng cho module. | +| `version_format` | `"v${raw}"` | The version format. Available vars are `raw`, `major`, `minor`, & `patch` | +| `style` | `"bold blue"` | Kiểu cho module. | +| `detect_extensions` | `["cbl", "cob", "CBL", "COB"]` | Những tiện ích mở rộng nào sẽ kích hoạt mô-đun này. | +| `detect_files` | `[]` | Tên tệp nào sẽ kích hoạt mô-đun này. | +| `detect_folders` | `[]` | Những thư mục nào sẽ kích hoạt mô-đun này. | +| `disabled` | `false` | Disables the `cobol` module. | -::: thử thuật +### Các biến -Hiện thông báo desktop yêu cầu starship được built với sự hỗ trợ của `rust-notify`. Bạn kiểm tra nếu starship hỗ trợ các thông báo bằng cách chạy `STARSHIP_LOG=debug starship module cmd_duration -d 60000` khi `show_notifications` được thiết lập là `true`. +| Biến | Ví dụ | Mô tả | +| --------- | ---------- | -------------------------------- | +| version | `v3.1.2.0` | The version of `cobol` | +| symbol | | Giá trị ghi đè tuỳ chọn `symbol` | +| style\* | | Giá trị ghi đè của `style` | + +\*: This variable can only be used as a part of a style string + +## Command Duration + +The `cmd_duration` module shows how long the last command took to execute. The module will be shown only if the command took longer than two seconds, or the `min_time` config value, if it exists. + +::: warning Do not hook the DEBUG trap in Bash + +If you are running Starship in `bash`, do not hook the `DEBUG` trap after running `eval $(starship init $0)`, or this module **will** break. + +::: + +Bash users who need preexec-like functionality can use [rcaloras's bash_preexec framework](https://github.com/rcaloras/bash-preexec). Simply define the arrays `preexec_functions` and `precmd_functions` before running `eval $(starship init $0)`, and then proceed as normal. + +### Các tuỳ chọn + +| Tuỳ chọn | Mặc định | Mô tả | +| -------------------- | ----------------------------- | ---------------------------------------------------------- | +| `min_time` | `2_000` | Shortest duration to show time for (in milliseconds). | +| `show_milliseconds` | `false` | Show milliseconds in addition to seconds for the duration. | +| `format` | `"took [$duration]($style) "` | Định dạng cho module. | +| `style` | `"bold yellow"` | Kiểu cho module. | +| `disabled` | `false` | Disables the `cmd_duration` module. | +| `show_notifications` | `false` | Show desktop notifications when command completes. | +| `min_time_to_notify` | `45_000` | Shortest duration for notification (in milliseconds). | + +::: tip + +Showing desktop notifications requires starship to be built with `rust-notify` support. You check if your starship supports notifications by running `STARSHIP_LOG=debug starship module cmd_duration -d 60000` when `show_notifications` is set to `true`. ::: ### Các biến -| Biến | Ví dụ | Mô tả | -| --------- | -------- | ------------------------------------- | -| duration | `16m40s` | Thời gian nó lấy để thực thi câu lệnh | -| style\* | | Giá trị ghi đè của `style` | +| Biến | Ví dụ | Mô tả | +| --------- | -------- | --------------------------------------- | +| duration | `16m40s` | The time it took to execute the command | +| style\* | | Giá trị ghi đè của `style` | -\*: Biến này có thể chỉ được sử dụng như một phần của style string +\*: This variable can only be used as a part of a style string ### Ví dụ @@ -530,11 +572,11 @@ format = "underwent [$duration](bold yellow)" ## Conda -Module `conda` cho biết môi trường conda hiện tại, nếu `$CONDA_DEFAULT_ENV` được thiết lập. +The `conda` module shows the current [Conda](https://docs.conda.io/en/latest/) environment, if `$CONDA_DEFAULT_ENV` is set. -::: thử thuật +::: tip -Cái này không loại bỏ conda's prompt mà nó sở hữu, bạn có thể muốn chạy `conda config --set changeps1 False`. +This does not suppress conda's own prompt modifier, you may want to run `conda config --set changeps1 False`. ::: @@ -542,22 +584,22 @@ Cái này không loại bỏ conda's prompt mà nó sở hữu, bạn có thể | Tuỳ chọn | Mặc định | Mô tả | | ------------------- | -------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -| `truncation_length` | `1` | Số lượng đường dẫn của biến môi trường nên được cắt bớt, nếu biến môi trường được tạo thông qua via `conda create -p [path]`. `0` nghĩa là không cắt bớt. Cũng thấy trong module [`directory`](#directory). | -| `symbol` | `"🅒 "` | Kí hiệu sử dụng trước tên biến môi trường. | +| `truncation_length` | `1` | The number of directories the environment path should be truncated to, if the environment was created via `conda create -p [path]`. `0` means no truncation. Also see the [`directory`](#directory) module. | +| `symbol` | `"🅒 "` | The symbol used before the environment name. | | `style` | `"bold green"` | Kiểu cho module. | | `format` | `"via [$symbol$environment]($style) "` | Định dạng cho module. | -| `ignore_base` | `true` | Bỏ qua biến môi trường `base` khi đã kích hoạt. | -| `disabled` | `false` | Vô hiệu module `conda`. | +| `ignore_base` | `true` | Ignores `base` environment when activated. | +| `disabled` | `false` | Disables the `conda` module. | ### Các biến -| Biến | Ví dụ | Mô tả | -| ----------- | ------------ | ---------------------------------- | -| environment | `astronauts` | Biến môi trường hiện tại của conda | -| symbol | | Giá trị ghi đè tuỳ chọn `symbol` | -| style\* | | Giá trị ghi đè của `style` | +| Biến | Ví dụ | Mô tả | +| ----------- | ------------ | -------------------------------- | +| environment | `astronauts` | The current conda environment | +| symbol | | Giá trị ghi đè tuỳ chọn `symbol` | +| style\* | | Giá trị ghi đè của `style` | -\*: Biến này có thể chỉ được sử dụng như một phần của style string +\*: This variable can only be used as a part of a style string ### Ví dụ @@ -572,31 +614,31 @@ format = "[$symbol$environment](dimmed green) " The `crystal` module shows the currently installed version of [Crystal](https://crystal-lang.org/). Mặc định module sẽ được hiển thị nếu có bất kì điều kiện nào dưới đây thoả mãn: -- Đường dẫn hiện tại chứa một tập tin `shard.yml` -- Đường dẫn hiện tại chứa một tập tin `.cr` +- The current directory contains a `shard.yml` file +- The current directory contains a `.cr` file -### Options +### Các tuỳ chọn | Tuỳ chọn | Mặc định | Mô tả | | ------------------- | ------------------------------------ | ------------------------------------------------------------------------- | -| `symbol` | `"🔮 "` | Kí hiệu sử dụng trước phiên bản hiển thị của crystal. | +| `symbol` | `"🔮 "` | The symbol used before displaying the version of crystal. | | `format` | `"via [$symbol($version )]($style)"` | Định dạng cho module. | | `version_format` | `"v${raw}"` | The version format. Available vars are `raw`, `major`, `minor`, & `patch` | | `style` | `"bold red"` | Kiểu cho module. | | `detect_extensions` | `["cr"]` | Những tiện ích mở rộng nào sẽ kích hoạt mô-đun này. | | `detect_files` | `["shard.yml"]` | Tên tệp nào sẽ kích hoạt mô-đun này. | | `detect_folders` | `[]` | Những thư mục nào sẽ kích hoạt mô-đun này. | -| `disabled` | `false` | Vô hiệu hoá module `crystal`. | +| `disabled` | `false` | Disables the `crystal` module. | ### Các biến | Biến | Ví dụ | Mô tả | | --------- | --------- | -------------------------------- | -| version | `v0.32.1` | Phiên bản của `crystal` | +| version | `v0.32.1` | The version of `crystal` | | symbol | | Giá trị ghi đè tuỳ chọn `symbol` | | style\* | | Giá trị ghi đè của `style` | -\*: Biến này có thể chỉ được sử dụng như một phần của style string +\*: This variable can only be used as a part of a style string ### Ví dụ @@ -611,9 +653,9 @@ format = "via [✨ $version](bold blue) " The `dart` module shows the currently installed version of [Dart](https://dart.dev/). Mặc định module sẽ được hiển thị nếu có bất kì điều kiện nào dưới đây thoả mãn: -- Đường dẫn hiện tại chứa một tập tin với phần mở rộng `.dart` -- Đường dẫn hiện tại chứa một đường dẫn `.dart_tool` -- Đường dẫn hiện tại chứa một tệp tin `pubspec.yaml`, `pubspec.yml` hoặc `pubspec.lock` +- The current directory contains a file with `.dart` extension +- The current directory contains a `.dart_tool` directory +- The current directory contains a `pubspec.yaml`, `pubspec.yml` or `pubspec.lock` file ### Các tuỳ chọn @@ -621,22 +663,22 @@ The `dart` module shows the currently installed version of [Dart](https://dart.d | ------------------- | ------------------------------------------------- | ------------------------------------------------------------------------- | | `format` | `"via [$symbol($version )]($style)"` | Định dạng cho module. | | `version_format` | `"v${raw}"` | The version format. Available vars are `raw`, `major`, `minor`, & `patch` | -| `symbol` | `"🎯 "` | Một chuỗi định dạng hiển thị biểu tượng của Dart | +| `symbol` | `"🎯 "` | A format string representing the symbol of Dart | | `detect_extensions` | `["dart"]` | Những tiện ích mở rộng nào sẽ kích hoạt mô-đun này. | | `detect_files` | `["pubspec.yaml", "pubspec.yml", "pubspec.lock"]` | Tên tệp nào sẽ kích hoạt mô-đun này. | | `detect_folders` | `[".dart_tool"]` | Những thư mục nào sẽ kích hoạt mô-đun này. | | `style` | `"bold blue"` | Kiểu cho module. | -| `disabled` | `false` | Vô hiệu `dart` module. | +| `disabled` | `false` | Disables the `dart` module. | ### Các biến | Biến | Ví dụ | Mô tả | | --------- | -------- | -------------------------------- | -| version | `v2.8.4` | Phiên bản của `dart` | +| version | `v2.8.4` | The version of `dart` | | symbol | | Giá trị ghi đè tuỳ chọn `symbol` | | style\* | | Giá trị ghi đè của `style` | -\*: Biến này có thể chỉ được sử dụng như một phần của style string +\*: This variable can only be used as a part of a style string ### Ví dụ @@ -684,30 +726,30 @@ format = "via [🦕 $version](green bold) " ## Đường dẫn -`directory` module hiển thị đường dẫn thư mục hiện hành của bạn,, cắt ngắn ba thư mục cha. Đường dẫn của bạn cũng sẽ được cắt ngắn tới đường dẫn gốc của git repo hiện tại của bạn. +The `directory` module shows the path to your current directory, truncated to three parent folders. Your directory will also be truncated to the root of the git repo that you're currently in. -Khi sử dụng fish style pwd option, thay vì ẩn đường dẫn được rút gọn, bạn sẽ thấy một tên ngắn cho mỗi thư mục dựa trên số bạn cho phép trng tùy chọn. +When using the fish style pwd option, instead of hiding the path that is truncated, you will see a shortened name of each directory based on the number you enable for the option. -Cho ví dụ, `~/Dev/Nix/nixpkgs/pkgs` nơi `nixpkgs` là gốc của repo, và tuỳ chọn thiết lập sang `1`. Bây giờ bạn sẽ thấy `~/D/N/nixpkgs/pkgs`, trong khi trước nó là `nixpkgs/pkgs`. +For example, given `~/Dev/Nix/nixpkgs/pkgs` where `nixpkgs` is the repo root, and the option set to `1`. You will now see `~/D/N/nixpkgs/pkgs`, whereas before it would have been `nixpkgs/pkgs`. ### Các tuỳ chọn -| Tuỳ chọn | Mặc định | Mô tả | -| ------------------- | -------------------------------------------------- | ------------------------------------------------------------------ | -| `truncation_length` | `3` | Số lượng thư mục cha của thư mục hiện tại nên được rút gọn. | -| `truncate_to_repo` | `true` | Có hoặc không rút gọn đường dẫn gốc của git repo hiện tại của bạn. | -| `format` | `"[$path]($style)[$read_only]($read_only_style) "` | Định dạng cho module. | -| `style` | `"bold cyan"` | Kiểu cho module. | -| `disabled` | `false` | Vô hiệu mô đun `directory`. | -| `read_only` | `"🔒"` | Biểu tượng để nhận biết thư mục hiện tại là chỉ đọc. | -| `read_only_style` | `"red"` | Style cho biểu tượng chỉ đọc. | -| `truncation_symbol` | `""` | Biểu tượng tiền tố cho các đường dẫn rút gọn. ví dụ: "…/" | -| `home_symbol` | `"~"` | Biểu tượng nhận biết thư mục home. | +| Tuỳ chọn | Mặc định | Mô tả | +| ------------------- | -------------------------------------------------- | -------------------------------------------------------------------------------- | +| `truncation_length` | `3` | The number of parent folders that the current directory should be truncated to. | +| `truncate_to_repo` | `true` | Whether or not to truncate to the root of the git repo that you're currently in. | +| `format` | `"[$path]($style)[$read_only]($read_only_style) "` | Định dạng cho module. | +| `style` | `"bold cyan"` | Kiểu cho module. | +| `disabled` | `false` | Disables the `directory` module. | +| `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: "…/" | +| `home_symbol` | `"~"` | The symbol indicating home directory. |
-Mô đun này có một vài tùy chọn nâng cao để điều khiển cách thư mục được hiển thị. +This module has a few advanced configuration options that control how the directory is displayed. -| Tùy chọn nâng cao | Mặc định | Mô tả | +| Advanced Option | Mặc định | Mô tả | | --------------------------- | -------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------- | | `substitutions` | | A table of substitutions to be made to the path. | | `fish_style_pwd_dir_length` | `0` | The number of characters to use when applying fish shell pwd path logic. | @@ -729,10 +771,10 @@ Cho ví dụ, `~/Dev/Nix/nixpkgs/pkgs` nơi `nixpkgs` là gốc của repo, và | Biến | Ví dụ | Mô tả | | --------- | --------------------- | -------------------------- | -| path | `"D:/Projects"` | Đường dẫn thư mục hiện tại | +| path | `"D:/Projects"` | The current directory path | | style\* | `"black bold dimmed"` | Giá trị ghi đè của `style` | -\*: Biến này có thể chỉ được sử dụng như một phần của style string +\*: This variable can only be used as a part of a style string ### Ví dụ @@ -750,26 +792,26 @@ The `docker_context` module shows the currently active [Docker context](https:// ### Các tuỳ chọn -| Tuỳ chọn | Mặc định | Mô tả | -| ------------------- | ------------------------------------------------------------- | ---------------------------------------------------------------------------------------- | -| `format` | `"via [$symbol$context]($style) "` | Định dạng cho module. | -| `symbol` | `"🐳 "` | Biểu tượng sử dụng để hiển thị trước Docker context. | -| `only_with_files` | `true` | Chỉ hiển thị khi có một tệp tin khớp | -| `detect_extensions` | `[]` | Các mở rộng nào nên kích hoạt mô đun này (cần `only_with_files` thiết lập là true). | -| `detect_files` | `["docker-compose.yml", "docker-compose.yaml", "Dockerfile"]` | Tên tệp tin nào nên kích hoạt mô đun này (cần `only_with_files` được thiết lập là true). | -| `detect_folders` | `[]` | Thư mục nào nên kích hoạt mô đun này (cần `only_with_files` được thiết lập là true). | -| `style` | `"blue bold"` | Kiểu cho module. | -| `disabled` | `false` | Vô hiệu mô đun `docker_context`. | +| Tuỳ chọn | Mặc định | Mô tả | +| ------------------- | ------------------------------------------------------------- | --------------------------------------------------------------------------------- | +| `format` | `"via [$symbol$context]($style) "` | Định dạng cho module. | +| `symbol` | `"🐳 "` | The symbol used before displaying the Docker context. | +| `only_with_files` | `true` | Only show when there's a match | +| `detect_extensions` | `[]` | Which extensions should trigger this module (needs `only_with_files` to be true). | +| `detect_files` | `["docker-compose.yml", "docker-compose.yaml", "Dockerfile"]` | Which filenames should trigger this module (needs `only_with_files` to be true). | +| `detect_folders` | `[]` | Which folders should trigger this module (needs `only_with_files` to be true). | +| `style` | `"blue bold"` | Kiểu cho module. | +| `disabled` | `false` | Disables the `docker_context` module. | ### Các biến | Biến | Ví dụ | Mô tả | | --------- | -------------- | -------------------------------- | -| context | `test_context` | Docker context hiện tại | +| context | `test_context` | The current docker context | | symbol | | Giá trị ghi đè tuỳ chọn `symbol` | | style\* | | Giá trị ghi đè của `style` | -\*: Biến này có thể chỉ được sử dụng như một phần của style string +\*: This variable can only be used as a part of a style string ### Ví dụ @@ -782,9 +824,9 @@ format = "via [🐋 $context](blue bold)" ## Dotnet -The `dotnet` module shows the relevant version of the [.NET Core SDK](https://dotnet.microsoft.com/) for the current directory. Nếu SDK được ghim trong thư mục hiện tại, phiên bản ghim đó được hiển thị. Ngược lại, mô đun hiển thị phiên bản cuối cùng của SDK được cài đặt. +The `dotnet` module shows the relevant version of the [.NET Core SDK](https://dotnet.microsoft.com/) for the current directory. If the SDK has been pinned in the current directory, the pinned version is shown. Otherwise the module shows the latest installed version of the SDK. -Mặc định, mô đun này sẽ chỉ được hiển thị trong dấu nhắc lệnh của bạn khi một hoặc nhiều tệp tin dưới đây xuất hiện trong thư mục hiện tại: +By default this module will only be shown in your prompt when one or more of the following files are present in the current directory: - `global.json` - `project.json` @@ -795,11 +837,11 @@ Mặc định, mô đun này sẽ chỉ được hiển thị trong dấu nhắc - `*.fsproj` - `*.xproj` -Bạn cũng sẽ cần cài đặt .NET Core SDK đúng cách để sử dụng một cách chính xác. +You'll also need the .NET Core SDK installed in order to use it correctly. -Mô đun này sử dụng cơ chế của bản thân để phát hiện phiên bản của chính nó. Thông thường, nó nhanh gấp đôi nếu chạy `dotnet --version`, nhưng nó có thể hiện sai phiên bản nếu dự án .NET của bạn có một cấu trúc thư mục bất thường. Nếu độ chính xác quan trọng hơn tốc độ, bạn có thể vô hiệu cơ chế bằng cài đặt `heuristic = false` trong các tùy chọn mô đun. +Internally, this module uses its own mechanism for version detection. Typically it is twice as fast as running `dotnet --version`, but it may show an incorrect version if your .NET project has an unusual directory layout. If accuracy is more important than speed, you can disable the mechanism by setting `heuristic = false` in the module options. -Mô đun cũng sẽ hiện Target Framework Moniker () khi có một tệp tin csproj trong thư mục hiện tại. +The module will also show the Target Framework Moniker () when there is a csproj file in the current directory. ### Các tuỳ chọn @@ -807,24 +849,24 @@ Mô đun cũng sẽ hiện Target Framework Moniker ( ⚠️ The version being shown is that of the package whose source code is in your current directory, not your package manager. @@ -2075,7 +2147,7 @@ The `package` module is shown when the current directory is the repository for a | symbol | | Giá trị ghi đè tuỳ chọn `symbol` | | style\* | | Giá trị ghi đè của `style` | -\*: Biến này có thể chỉ được sử dụng như một phần của style string +\*: This variable can only be used as a part of a style string ### Ví dụ @@ -2130,7 +2202,7 @@ format = "via [🦪 $version]($style) " The `php` module shows the currently installed version of [PHP](https://www.php.net/). Mặc định module sẽ được hiển thị nếu có bất kì điều kiện nào dưới đây thoả mãn: -- Đường dẫn hiện tại chứa một tập tin `composer.json` +- The current directory contains a `composer.json` file - The current directory contains a `.php-version` file - The current directory contains a `.php` extension @@ -2155,7 +2227,7 @@ The `php` module shows the currently installed version of [PHP](https://www.php. | symbol | | Giá trị ghi đè tuỳ chọn `symbol` | | style\* | | Giá trị ghi đè của `style` | -\*: Biến này có thể chỉ được sử dụng như một phần của style string +\*: This variable can only be used as a part of a style string ### Ví dụ @@ -2170,7 +2242,7 @@ format = "via [🔹 $version](147 bold) " The `purescript` module shows the currently installed version of [PureScript](https://www.purescript.org/) version. Mặc định module sẽ được hiển thị nếu có bất kì điều kiện nào dưới đây thoả mãn: -- Đường dẫn hiện tại chứa một tập tin `spago.dhall` +- The current directory contains a `spago.dhall` file - The current directory contains a file with the `.purs` extension ### Các tuỳ chọn @@ -2194,7 +2266,7 @@ The `purescript` module shows the currently installed version of [PureScript](ht | symbol | | Giá trị ghi đè tuỳ chọn `symbol` | | style\* | | Giá trị ghi đè của `style` | -\*: Biến này có thể chỉ được sử dụng như một phần của style string +\*: This variable can only be used as a part of a style string ### Ví dụ @@ -2216,10 +2288,10 @@ Mặc định module sẽ được hiển thị nếu có bất kì điều ki - The current directory contains a `.python-version` file - The current directory contains a `Pipfile` file - The current directory contains a `__init__.py` file -- Đường dẫn hiện tại chứa một tập tin `pyproject.toml` -- Đường dẫn hiện tại chứa một tập tin `requirements.txt` -- Đường dẫn hiện tại chứa một tập tin `setup.py` -- Đường dẫn hiện tại chứa một tập tin `tox.ini` +- The current directory contains a `pyproject.toml` file +- The current directory contains a `requirements.txt` file +- The current directory contains a `setup.py` file +- The current directory contains a `tox.ini` file - The current directory contains a file with the `.py` extension. - A virtual environment is currently activated @@ -2239,7 +2311,7 @@ Mặc định module sẽ được hiển thị nếu có bất kì điều ki | `detect_folders` | `[]` | Thư mục nào sẽ kích hoạt mô-đun này | | `disabled` | `false` | Disables the `python` module. | -::: thử thuật +::: tip The `python_binary` variable accepts either a string or a list of strings. Starship will try executing each binary until it gets a result. Note you can only change the binary that Starship executes to get the version of Python not the arguments that are used. @@ -2296,7 +2368,7 @@ python_binary = ["./venv/bin/python", "python", "python3", "python2"] ## R -The `rlang` module shows the currently installed version of R. The module will be shown if any of the following conditions are met: +The `rlang` module shows the currently installed version of [R](https://www.r-project.org/). The module will be shown if any of the following conditions are met: - The current directory contains a file with the `.R` extension. - The current directory contains a file with the `.Rd` extension. @@ -2338,7 +2410,7 @@ format = "with [📐 $version](blue bold) " ## Red -By default the `red` module shows the currently installed version of [Red](https://www.red-lang.org/). Module cho sẽ được hiện nếu bất kì điều kiện nào dưới đây thoả mãn: +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 @@ -2363,7 +2435,7 @@ By default the `red` module shows the currently installed version of [Red](https | symbol | | Giá trị ghi đè tuỳ chọn `symbol` | | style\* | | Giá trị ghi đè của `style` | -\*: Biến này có thể chỉ được sử dụng như một phần của style string +\*: This variable can only be used as a part of a style string ### Ví dụ @@ -2376,7 +2448,7 @@ symbol = "🔴 " ## Ruby -By default the `ruby` module shows the currently installed version of [Ruby](https://www.ruby-lang.org/). Module cho sẽ được hiện nếu bất kì điều kiện nào dưới đây thoả mãn: +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: - The current directory contains a `Gemfile` file - The current directory contains a `.ruby-version` file @@ -2403,7 +2475,7 @@ By default the `ruby` module shows the currently installed version of [Ruby](htt | symbol | | Giá trị ghi đè tuỳ chọn `symbol` | | style\* | | Giá trị ghi đè của `style` | -\*: Biến này có thể chỉ được sử dụng như một phần của style string +\*: This variable can only be used as a part of a style string ### Ví dụ @@ -2416,7 +2488,7 @@ symbol = "🔺 " ## Rust -By default the `rust` module shows the currently installed version of [Rust](https://www.rust-lang.org/). Module cho sẽ được hiện nếu bất kì điều kiện nào dưới đây thoả mãn: +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: - The current directory contains a `Cargo.toml` file - The current directory contains a file with the `.rs` extension @@ -2442,7 +2514,7 @@ By default the `rust` module shows the currently installed version of [Rust](htt | symbol | | Giá trị ghi đè tuỳ chọn `symbol` | | style\* | | Giá trị ghi đè của `style` | -\*: Biến này có thể chỉ được sử dụng như một phần của style string +\*: This variable can only be used as a part of a style string ### Ví dụ @@ -2482,7 +2554,7 @@ The `scala` module shows the currently installed version of [Scala](https://www. | symbol | | Giá trị ghi đè tuỳ chọn `symbol` | | style\* | | Giá trị ghi đè của `style` | -\*: Biến này có thể chỉ được sử dụng như một phần của style string +\*: This variable can only be used as a part of a style string ### Ví dụ @@ -2497,9 +2569,9 @@ symbol = "🌟 " The `shell` module shows an indicator for currently used shell. -::: thử thuật +::: tip -Mặc định, mô đun này được vô hiệu. Để kích hoạt nó, thiết lập `disabled` sang `false` trong tập tin cấu hình của bạn. +This module is disabled by default. To enable it, set `disabled` to `false` in your configuration file. ::: @@ -2539,7 +2611,7 @@ disabled = false ## SHLVL -The `shlvl` module shows the current `SHLVL` ("shell level") environment variable, if it is set to a number and meets or exceeds the specified threshold. +The `shlvl` module shows the current [`SHLVL`](https://tldp.org/LDP/abs/html/internalvariables.html#SHLVLREF) ("shell level") environment variable, if it is set to a number and meets or exceeds the specified threshold. ### Các tuỳ chọn @@ -2560,7 +2632,7 @@ The `shlvl` module shows the current `SHLVL` ("shell level") environment variabl | symbol | | Giá trị ghi đè tuỳ chọn `symbol` | | style\* | | Giá trị ghi đè của `style` | -\*: Biến này có thể chỉ được sử dụng như một phần của style string +\*: This variable can only be used as a part of a style string ### Ví dụ @@ -2594,7 +2666,7 @@ The `singularity` module shows the current [Singularity](https://sylabs.io/singu | symbol | | Giá trị ghi đè tuỳ chọn `symbol` | | style\* | | Giá trị ghi đè của `style` | -\*: Biến này có thể chỉ được sử dụng như một phần của style string +\*: This variable can only be used as a part of a style string ### Ví dụ @@ -2609,9 +2681,9 @@ format = '[📦 \[$env\]]($style) ' The `status` module displays the exit code of the previous command. The module will be shown only if the exit code is not `0`. -::: thử thuật +::: tip -Mặc định, mô đun này được vô hiệu. Để kích hoạt nó, thiết lập `disabled` sang `false` trong tập tin cấu hình của bạn. +This module is disabled by default. To enable it, set `disabled` to `false` in your configuration file. ::: @@ -2650,7 +2722,7 @@ Mặc định, mô đun này được vô hiệu. Để kích hoạt nó, thiế | symbol | | Giá trị ghi đè tuỳ chọn `symbol` | | style\* | | Giá trị ghi đè của `style` | -\*: Biến này có thể chỉ được sử dụng như một phần của style string +\*: This variable can only be used as a part of a style string ### Ví dụ @@ -2669,7 +2741,7 @@ disabled = false ## Swift -By default the `swift` module shows the currently installed version of [Swift](https://swift.org/). Module cho sẽ được hiện nếu bất kì điều kiện nào dưới đây thoả mãn: +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 @@ -2695,7 +2767,7 @@ By default the `swift` module shows the currently installed version of [Swift](h | symbol | | Giá trị ghi đè tuỳ chọn `symbol` | | style\* | | Giá trị ghi đè của `style` | -\*: Biến này có thể chỉ được sử dụng như một phần của style string +\*: This variable can only be used as a part of a style string ### Ví dụ @@ -2710,7 +2782,7 @@ format = "via [🏎 $version](red bold)" The `terraform` module shows the currently selected [Terraform workspace](https://www.terraform.io/docs/language/state/workspaces.html) and version. -::: thử thuật +::: tip By default the Terraform version is not shown, since this is slow for current versions of Terraform when a lot of plugins are in use. If you still want to enable it, [follow the example shown below](#with-terraform-version). @@ -2743,7 +2815,7 @@ Mặc định module sẽ được hiển thị nếu có bất kì điều ki | symbol | | Giá trị ghi đè tuỳ chọn `symbol` | | style\* | | Giá trị ghi đè của `style` | -\*: Biến này có thể chỉ được sử dụng như một phần của style string +\*: This variable can only be used as a part of a style string ### Ví dụ @@ -2769,9 +2841,9 @@ format = "[🏎💨 $workspace]($style) " 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. -::: thử thuật +::: tip -Mặc định, mô đun này được vô hiệu. Để kích hoạt nó, thiết lập `disabled` sang `false` trong tập tin cấu hình của bạn. +This module is disabled by default. To enable it, set `disabled` to `false` in your configuration file. ::: @@ -2793,10 +2865,10 @@ If `use_12hr` is `true`, then `time_format` defaults to `"%r"`. Otherwise, it de | Biến | Ví dụ | Mô tả | | --------- | ---------- | -------------------------- | -| thời gian | `13:08:10` | The current time. | +| time | `13:08:10` | The current time. | | style\* | | Giá trị ghi đè của `style` | -\*: Biến này có thể chỉ được sử dụng như một phần của style string +\*: This variable can only be used as a part of a style string ### Ví dụ @@ -2813,14 +2885,14 @@ time_range = "10:00:00-14:00:00" ## Username -The `username` module shows active user's username. Module cho sẽ được hiện nếu bất kì điều kiện nào dưới đây thoả mãn: +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 - The current user isn't the same as the one that is logged in - The user is currently connected as an SSH session - The variable `show_always` is set to true -::: thử thuật +::: tip SSH connection is detected by checking environment variables `SSH_CONNECTION`, `SSH_CLIENT`, and `SSH_TTY`. If your SSH host does not set up these variables, one workaround is to set one of them with a dummy value. @@ -2883,7 +2955,7 @@ The `vagrant` module shows the currently installed version of [Vagrant](https:// | symbol | | Giá trị ghi đè tuỳ chọn `symbol` | | style\* | | Giá trị ghi đè của `style` | -\*: Biến này có thể chỉ được sử dụng như một phần của style string +\*: This variable can only be used as a part of a style string ### Ví dụ @@ -2894,9 +2966,9 @@ The `vagrant` module shows the currently installed version of [Vagrant](https:// format = "via [⍱ $version](bold white) " ``` -## VLang +## V -The `vlang` module shows you your currently installed version of V. By default the module will be shown if any of the following conditions are met: +The `vlang` module shows you your currently installed version of [V](https://vlang.io/). Mặc định module sẽ được hiển thị nếu có bất kì điều kiện nào dưới đây thoả mãn: - The current directory contains a file with `.v` extension - The current directory contains a `v.mod`, `vpkg.json` or `.vpkg-lock.json` file @@ -2925,7 +2997,7 @@ The `vlang` module shows you your currently installed version of V. By default t ```toml # ~/.config/starship.toml -[v] +[vlang] format = "via [V $version](blue bold) " ``` @@ -2950,7 +3022,7 @@ The `vcsh` module displays the current active [VCSH](https://github.com/RichiH/v | symbol | | Giá trị ghi đè tuỳ chọn `symbol` | | style\* | `black bold dimmed` | Giá trị ghi đè của `style` | -\*: Biến này có thể chỉ được sử dụng như một phần của style string +\*: This variable can only be used as a part of a style string ### Ví dụ @@ -2963,7 +3035,7 @@ format = "[🆅 $repo](bold blue) " ## Zig -By default the the `zig` module shows the currently installed version of [Zig](https://ziglang.org/). Module cho sẽ được hiện nếu bất kì điều kiện nào dưới đây thoả mãn: +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 @@ -2988,7 +3060,7 @@ By default the the `zig` module shows the currently installed version of [Zig](h | symbol | | Giá trị ghi đè tuỳ chọn `symbol` | | style\* | | Giá trị ghi đè của `style` | -\*: Biến này có thể chỉ được sử dụng như một phần của style string +\*: This variable can only be used as a part of a style string ### Ví dụ @@ -3011,19 +3083,19 @@ These modules will be shown if any of the following conditions are met: - The `when` command returns 0 - The current Operating System (std::env::consts::OS) matchs with `os` field if defined. -::: thử thuật +::: tip Multiple custom modules can be defined by using a `.`. ::: -::: thử thuật +::: tip The order in which custom modules are shown can be individually set by including `${custom.foo}` in the top level `format` (as it includes a dot, you need to use `${...}`). By default, the `custom` module will simply show all custom modules in the order they were defined. ::: -::: thử thuật +::: tip [Issue #1252](https://github.com/starship/starship/discussions/1252) contains examples of custom modules. If you have an interesting example not covered there, feel free to share it there! @@ -3036,7 +3108,7 @@ The order in which custom modules are shown can be individually set by including | `command` | | The command whose output should be printed. The command will be passed on stdin to the shell. | | `when` | | A shell command used as a condition to show the module. The module will be shown if the command returns a `0` status code. | | `shell` | | [See below](#custom-command-shell) | -| `mô tả` | `""` | The description of the module that is shown when running `starship explain`. | +| `description` | `""` | The description of the module that is shown when running `starship explain`. | | `files` | `[]` | The files that will be searched in the working directory for a match. | | `directories` | `[]` | The directories that will be searched in the working directory for a match. | | `extensions` | `[]` | The extensions that will be searched in the working directory for a match. | @@ -3054,7 +3126,7 @@ The order in which custom modules are shown can be individually set by including | symbol | Giá trị ghi đè tuỳ chọn `symbol` | | style\* | Giá trị ghi đè của `style` | -\*: Biến này có thể chỉ được sử dụng như một phần của style string +\*: This variable can only be used as a part of a style string #### Custom command shell diff --git a/docs/vi-VN/guide/README.md b/docs/vi-VN/guide/README.md index ce39f2c9..c9c3ed22 100644 --- a/docs/vi-VN/guide/README.md +++ b/docs/vi-VN/guide/README.md @@ -48,30 +48,6 @@ height="20" src="https://raw.githubusercontent.com/starship/starship/master/media/flag-us.png" alt="Tiếng Anh" - /> -   - Tiếng Nhật -   - Tiếng Trung hiện đại -   - Tiếng Nga   Tiếng Đức -   - Tiếng Trung giản thể   Tiếng Tây Ban Nha   Thiếng Pháp +   + 日本語 +   + Português do Brasil +   + Русский   +   + 简体中文 +   + 繁體中文

@@ -160,8 +168,8 @@ ```sh sh -c "$(curl -fsSL https://starship.rs/install.sh)" ``` - Để cập nhật chính Starship, hãy chạy lại đoạn script bên trên. Nó sẽ thay thế phiên bản hiện tại mà không hề thay đổi gì những cài đặt của Starship trước đó. + Để cập nhật chính Starship, hãy chạy lại đoạn script bên trên. Nó sẽ thay thế phiên bản hiện tại mà không hề thay đổi gì những cài đặt của Starship trước đó. **Ghi chú** - Script cài đặt mặc định có thể bị ghi đè. diff --git a/docs/vi-VN/presets/README.md b/docs/vi-VN/presets/README.md index bde892c1..065c850a 100644 --- a/docs/vi-VN/presets/README.md +++ b/docs/vi-VN/presets/README.md @@ -112,6 +112,9 @@ format = '\[[$symbol($version)]($style)\]' [cmd_duration] format = '\[[⏱ $duration ]($style)\]' +[cobol] +format = '\[[$symbol($version)]($style)\]' + [conda] format = '\[[$symbol$environment]($style)\]' @@ -272,6 +275,9 @@ deleted = "x" [aws] symbol = "aws " +[cobol] +symbol = "cobol " + [conda] symbol = "conda " @@ -375,6 +381,9 @@ This preset hides the version of language runtimes. If you work in containers or [cmake] format = "via [$symbol]($style)" +[cobol] +format = "via [$symbol]($style)" + [crystal] format = "via [$symbol]($style)" diff --git a/docs/zh-CN/advanced-config/README.md b/docs/zh-CN/advanced-config/README.md index ea8a3701..65fc5ff4 100644 --- a/docs/zh-CN/advanced-config/README.md +++ b/docs/zh-CN/advanced-config/README.md @@ -68,9 +68,36 @@ function set_win_title(){ starship_precmd_user_func="set_win_title" ``` +## Enable Right Prompt + +Some shells support a right prompt which renders on the same line as the input. Starship can set the content of the right prompt using the `right_format` option. Any module that can be used in `format` is also supported in `right_format`. The `$all` variable will only contain modules not explicitly used in either `format` or `right_format`. + +Note: The right prompt is a single line following the input location. To right align modules above the input line in a multi-line prompt, see the [fill module](/config/#fill). + +`right_format` is currently supported for the following shells: elvish, fish, zsh. + +### 示例 + +```toml +# ~/.config/starship.toml + +# A minimal left prompt +format = """$character""" + +# move the rest of the prompt to the right +right_format = """$all""" +``` + +Produces a prompt like the following: + +``` +▶ starship on  rprompt [!] is 📦 v0.57.0 via 🦀 v1.54.0 took 17s +``` + + ## 样式设定 -样式字符串是用空格分隔的单词列表。 其中单词不是大小写敏感的(例如 `bold` 和 `BoLd` 被视为同一字符串)。 每个单词可以是以下之一: +Style strings are a list of words, separated by whitespace. The words are not case sensitive (i.e. `bold` and `BoLd` are considered the same string). Each word can be one of the following: - `bold` - `italic` @@ -82,14 +109,14 @@ starship_precmd_user_func="set_win_title" - `` - `none` -`` 是颜色说明符(下面解释)。 `fg:` and `` currently do the same thing, though this may change in the future. `inverted` swaps the background and foreground colors. 字符串中的单词顺序不影响显示结果。 +where `` is a color specifier (discussed below). `fg:` and `` currently do the same thing, though this may change in the future. `inverted` swaps the background and foreground colors. The order of words in the string does not matter. -The `none` token overrides all other tokens in a string if it is not part of a `bg:` specifier, so that e.g. `fg:red none fg:blue` will still create a string with no styling. `bg:none` sets the background to the default color so `fg:red bg:none` is equivalent to `red` or `fg:red` and `bg:green fg:red bg:none` is also equivalent to `fg:red` or `red`. 未来可能会将 `none` 与其它标识符一起使用视为一种错误。 +The `none` token overrides all other tokens in a string if it is not part of a `bg:` specifier, so that e.g. `fg:red none fg:blue` will still create a string with no styling. `bg:none` sets the background to the default color so `fg:red bg:none` is equivalent to `red` or `fg:red` and `bg:green fg:red bg:none` is also equivalent to `fg:red` or `red`. It may become an error to use `none` in conjunction with other tokens in the future. -颜色说明符可以是以下内容之一: +A color specifier can be one of the following: - 标准终端颜色之一:`black`,`red`,`green`,`blue`,`yellow`,`purple`,`cyan`,`white`。 您可以使用可选前缀 `bright-` 来获取明亮版本的颜色(例如,`bright-white`)。 - 一个 `#` 后跟一个六位十六进制数。 这将指定一个 [十六进制 RGB 颜色代码](https://www.w3schools.com/colors/colors_hexadecimal.asp)。 - 0-255 之间的数字。 这将指定一个 [8 位 ANSI 颜色码](https://i.stack.imgur.com/KTSQa.png)。 -如果为文本/背景指定了多个颜色,字符串中最后指定的颜色将具有最高优先级。 +If multiple colors are specified for foreground/background, the last one in the string will take priority. diff --git a/docs/zh-CN/config/README.md b/docs/zh-CN/config/README.md index 1ac71bb3..68e7e269 100644 --- a/docs/zh-CN/config/README.md +++ b/docs/zh-CN/config/README.md @@ -75,7 +75,7 @@ A text group is made up of two different parts. The first part, which is enclosed in a `[]`, is a [format string](#format-strings). You can add texts, variables, or even nested text groups in it. -In the second part, which is enclosed in a `()`, is a [style string](#style-strings). This can be used style the first part. +In the second part, which is enclosed in a `()`, is a [style string](#style-strings). This can be used to style the first part. For example: @@ -142,12 +142,14 @@ format = ''' ### 配置项 -| Option | 默认值 | 描述 | -| ----------------- | ----------------------------- | --------------------------- | -| `format` | [见下文](#default-prompt-format) | 配置提示符的格式。 | -| `scan_timeout` | `30` | Starship 扫描文件的超时时间(单位:毫秒)。 | -| `command_timeout` | `500` | Startship 执行命令的超时时间(单位:毫秒)。 | -| `add_newline` | `true` | 在 shell 提示符之间插入空行。 | +| Option | 默认值 | 描述 | +| ----------------- | ----------------------------- | ---------------------------------------------------------------- | +| `format` | [见下文](#default-prompt-format) | 配置提示符的格式。 | +| `right_format` | `""` | See [Enable Right Prompt](/advanced-config/#enable-right-prompt) | +| `scan_timeout` | `30` | Timeout for starship to scan files (in milliseconds). | +| `command_timeout` | `500` | Timeout for commands executed by starship (in milliseconds). | +| `add_newline` | `true` | Inserts blank line between shell prompts. | + ### 示例 @@ -179,6 +181,7 @@ format = """ $username\ $hostname\ $shlvl\ +$singularity\ $kubernetes\ $directory\ $vcsh\ @@ -191,6 +194,7 @@ $hg_branch\ $docker_context\ $package\ $cmake\ +$cobol\ $dart\ $deno\ $dotnet\ @@ -202,6 +206,7 @@ $helm\ $java\ $julia\ $kotlin\ +$lua\ $nim\ $nodejs\ $ocaml\ @@ -209,6 +214,7 @@ $perl\ $php\ $purescript\ $python\ +$rlang\ $red\ $ruby\ $rust\ @@ -229,7 +235,6 @@ $crystal\ $custom\ $cmd_duration\ $line_break\ -$lua\ $jobs\ $battery\ $time\ @@ -238,9 +243,16 @@ $shell\ $character""" ``` +If you just want to extend the default format, you can use `$all`; modules you explicitly add to the format will not be duplicated. Eg. + +```toml +# Move the directory to the second line +format="$all$directory$character" +``` + ## AWS -`aws` 组件显示当前 AWS 主机所在区域与配置信息。 各组件基于 `AWS_REGION`,`AWS_DEFAULT_REGION` 和 `AWS_PROFILE` 环境变量与 `~/.aws/config` 文件。 This module also shows an expiration timer when using temporary credentials. +The `aws` module shows the current AWS region and profile. This is based on `AWS_REGION`, `AWS_DEFAULT_REGION`, and `AWS_PROFILE` env var with `~/.aws/config` file. This module also shows an expiration timer when using temporary credentials. When using [aws-vault](https://github.com/99designs/aws-vault) the profile is read from the `AWS_VAULT` env var and the credentials expiration date is read from the `AWS_SESSION_EXPIRATION` env var. @@ -314,7 +326,7 @@ symbol = "🅰 " ## Battery -`battery` 组件显示电池充电情况和当前充电状态。 这个组件只会在当前电量低于 10% 时显示。 +The `battery` module shows how charged the device's battery is and its current charging status. The module is only visible when the device's battery is below 10%. ### 配置项 @@ -342,7 +354,7 @@ discharging_symbol = "💀 " ### Battery 组件的显示 -The `display` configuration option is used to define when the battery indicator should be shown (threshold), which symbol would be used (symbol), and what it would like (style). 如果 `display` 没有设置, 默认设置如下: +The `display` configuration option is used to define when the battery indicator should be shown (threshold), which symbol would be used (symbol), and what it would like (style). If no `display` is provided. 默认设置如下: ```toml [[battery.display]] @@ -354,7 +366,7 @@ The default value for the `charging_symbol` and `discharging_symbol` option is r #### 配置项 -`display` 字段的子字段如下: +The `display` option is an array of the following table. | Option | 默认值 | 描述 | | -------------------- | ---------- | --------------------------------------------------------------------------------------------------------- | @@ -381,9 +393,9 @@ discharging_symbol = 💦 ## Character -`character` 组件用于在您输入终端的文本旁显示一个字符(通常是一个箭头)。 +The `character` module shows a character (usually an arrow) beside where the text is entered in your terminal. -这个字符可以告诉您最后一个命令是否执行成功。 It can do this in two ways: +The character will tell you whether the last command was successful or not. It can do this in two ways: - changing color (`red`/`green`) - changing shape (`❯`/`✖`) @@ -479,29 +491,59 @@ The `cmake` module shows the currently installed version of [CMake](https://cmak \*: This variable can only be used as a part of a style string -## Command Duration +## COBOL / GNUCOBOL -`cmd_duration` 组件显示上一个命令执行的时间。 此组件只在命令执行时间长于两秒时显示,或者当其 `min_time` 字段被设置时,按此值为执行时间的显示下限。 +The `cobol` module shows the currently installed version of COBOL. By default, the module will be shown if any of the following conditions are met: -::: warning 不要在 Bash 里捕获 DEBUG 信号 - -如果您正在 `bash` 上使用 Starship,在运行 `eval $(starship)` 后,不要捕获 `DEBUG` 信号,否则此组件**将会**坏掉。 - -::: - -需要在自动每一条命令前执行某些操作的 Bash 用户可以使用 [rcaloras 的 bash_preexec 框架](https://github.com/rcaloras/bash-preexec)。 只需要在执行 `eval $(starship init $0)` 前简单地定义 `preexec_functions` 和 `precmd_functions` 两个列表,就可以照常运行了。 +- The current directory contains any files ending in `.cob` or `.COB` +- The current directory contains any files ending in `.cbl` or `.CBL` ### 配置项 -| Option | 默认值 | 描述 | -| -------------------- | ----------------------------- | ----------------------------------------------------- | -| `min_time` | `2_000` | 显示此组件所需的最短执行时长(单位:毫秒)。 | -| `show_milliseconds` | `false` | 除了秒数外在执行时长中额外显示毫秒。 | -| `format` | `"took [$duration]($style) "` | 组件格式化模板。 | -| `style` | `"bold yellow"` | 此组件的样式。 | -| `disabled` | `false` | 禁用 `cmd_duration` 组件。 | -| `show_notifications` | `false` | Show desktop notifications when command completes. | -| `min_time_to_notify` | `45_000` | Shortest duration for notification (in milliseconds). | +| Option | 默认值 | 描述 | +| ------------------- | ------------------------------------ | ------------------------------------------------------------------------- | +| `symbol` | `"⚙️ "` | The symbol used before displaying the version of COBOL. | +| `format` | `"via [$symbol($version )]($style)"` | 组件格式化模板。 | +| `version_format` | `"v${raw}"` | The version format. Available vars are `raw`, `major`, `minor`, & `patch` | +| `style` | `"bold blue"` | 此组件的样式。 | +| `detect_extensions` | `["cbl", "cob", "CBL", "COB"]` | Which extensions should trigger this module. | +| `detect_files` | `[]` | Which filenames should trigger this module. | +| `detect_folders` | `[]` | Which folders should trigger this module. | +| `disabled` | `false` | Disables the `cobol` module. | + +### Variables + +| 字段 | 示例 | 描述 | +| --------- | ---------- | ---------------------- | +| version | `v3.1.2.0` | The version of `cobol` | +| symbol | | `symbol`对应值 | +| style\* | | `style`对应值 | + +\*: This variable can only be used as a part of a style string + +## Command Duration + +The `cmd_duration` module shows how long the last command took to execute. The module will be shown only if the command took longer than two seconds, or the `min_time` config value, if it exists. + +::: warning Do not hook the DEBUG trap in Bash + +If you are running Starship in `bash`, do not hook the `DEBUG` trap after running `eval $(starship init $0)`, or this module **will** break. + +::: + +Bash users who need preexec-like functionality can use [rcaloras's bash_preexec framework](https://github.com/rcaloras/bash-preexec). Simply define the arrays `preexec_functions` and `precmd_functions` before running `eval $(starship init $0)`, and then proceed as normal. + +### 配置项 + +| Option | 默认值 | 描述 | +| -------------------- | ----------------------------- | ---------------------------------------------------------- | +| `min_time` | `2_000` | Shortest duration to show time for (in milliseconds). | +| `show_milliseconds` | `false` | Show milliseconds in addition to seconds for the duration. | +| `format` | `"took [$duration]($style) "` | 组件格式化模板。 | +| `style` | `"bold yellow"` | 此组件的样式。 | +| `disabled` | `false` | Disables the `cmd_duration` module. | +| `show_notifications` | `false` | Show desktop notifications when command completes. | +| `min_time_to_notify` | `45_000` | Shortest duration for notification (in milliseconds). | ::: tip @@ -530,24 +572,24 @@ format = "underwent [$duration](bold yellow)" ## Conda -`conda` 组件在 `$CONDA_DEFAULT_ENV` 被设置时显示当前 conda 环境。 +The `conda` module shows the current [Conda](https://docs.conda.io/en/latest/) environment, if `$CONDA_DEFAULT_ENV` is set. ::: tip -此组件没有禁用 conda 自带的提示符修改,您可能需要执行 `conda config --set changeps1 False`。 +This does not suppress conda's own prompt modifier, you may want to run `conda config --set changeps1 False`. ::: ### 配置项 -| Option | 默认值 | 描述 | -| ------------------- | -------------------------------------- | ---------------------------------------------------------------------------------------------------------------- | -| `truncation_length` | `1` | 如果这个 conda 环境是通过 `conda create -p [path]` 创建的,环境路径的目录深度应该被截断到此数量。 `0` 表示不用截断。 另请参阅 [`directory`](#directory) 组件。 | -| `symbol` | `"🅒 "` | 在环境名之前显示的符号。 | -| `style` | `"bold green"` | 此组件的样式。 | -| `format` | `"via [$symbol$environment]($style) "` | 组件格式化模板。 | -| `ignore_base` | `true` | Ignores `base` environment when activated. | -| `disabled` | `false` | 禁用 `conda` 组件。 | +| Option | 默认值 | 描述 | +| ------------------- | -------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | +| `truncation_length` | `1` | The number of directories the environment path should be truncated to, if the environment was created via `conda create -p [path]`. `0` means no truncation. Also see the [`directory`](#directory) module. | +| `symbol` | `"🅒 "` | The symbol used before the environment name. | +| `style` | `"bold green"` | 此组件的样式。 | +| `format` | `"via [$symbol$environment]($style) "` | 组件格式化模板。 | +| `ignore_base` | `true` | Ignores `base` environment when activated. | +| `disabled` | `false` | Disables the `conda` module. | ### Variables @@ -572,7 +614,7 @@ format = "[$symbol$environment](dimmed green) " The `crystal` module shows the currently installed version of [Crystal](https://crystal-lang.org/). By default the module will be shown if any of the following conditions are met: -- 当前目录包含一个 `shard.yml` 文件 +- The current directory contains a `shard.yml` file - The current directory contains a `.cr` file ### 配置项 @@ -613,7 +655,7 @@ The `dart` module shows the currently installed version of [Dart](https://dart.d - The current directory contains a file with `.dart` extension - The current directory contains a `.dart_tool` directory -- 当前目录包含 `pubspec.yaml`,`pubspec.yml` 或 `pubspec.lock` 文件 +- The current directory contains a `pubspec.yaml`, `pubspec.yml` or `pubspec.lock` file ### 配置项 @@ -684,33 +726,33 @@ format = "via [🦕 $version](green bold) " ## Directory -`directory` 组件显示当前目录的路径,显示的路径会截断到三个父目录以内。 如果您处于一个 git 仓库中,显示的路径则最多会截断到该仓库的根目录。 +The `directory` module shows the path to your current directory, truncated to three parent folders. Your directory will also be truncated to the root of the git repo that you're currently in. -当使用 fish 风格的当前目录显示样式时,您会看到基于您的设置的每个上级目录的短名称,而不是隐藏被截断的上级目录。 +When using the fish style pwd option, instead of hiding the path that is truncated, you will see a shortened name of each directory based on the number you enable for the option. -例如,对于 `~/Dev/Nix/nixpkgs/pkgs`,其中 `nixpkgs` 是 git 仓库根目录,fish 风格相关选项设置为 `1`。 您将会看到 `~/D/N/nixpkgs/pkgs`,而在设置 fish 风格之前,当前路径将显示成 `nixpkgs/pkgs`。 +For example, given `~/Dev/Nix/nixpkgs/pkgs` where `nixpkgs` is the repo root, and the option set to `1`. You will now see `~/D/N/nixpkgs/pkgs`, whereas before it would have been `nixpkgs/pkgs`. ### 配置项 -| Option | 默认值 | 描述 | -| ------------------- | -------------------------------------------------- | ----------------------------------------------------- | -| `truncation_length` | `3` | 当前目录路径被截断后最多保留的父目录数量。 | -| `truncate_to_repo` | `true` | 是否只截断到您当前处于的 git 仓库根目录下。 | -| `format` | `"[$path]($style)[$read_only]($read_only_style) "` | 组件格式化模板。 | -| `style` | `"bold cyan"` | 此组件的样式。 | -| `disabled` | `false` | 禁用 `directory` 组件。 | -| `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: "…/" | -| `home_symbol` | `"~"` | The symbol indicating home directory. | +| Option | 默认值 | 描述 | +| ------------------- | -------------------------------------------------- | -------------------------------------------------------------------------------- | +| `truncation_length` | `3` | The number of parent folders that the current directory should be truncated to. | +| `truncate_to_repo` | `true` | Whether or not to truncate to the root of the git repo that you're currently in. | +| `format` | `"[$path]($style)[$read_only]($read_only_style) "` | 组件格式化模板。 | +| `style` | `"bold cyan"` | 此组件的样式。 | +| `disabled` | `false` | Disables the `directory` module. | +| `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: "…/" | +| `home_symbol` | `"~"` | The symbol indicating home directory. |
-此组件有几个高级配置选项来控制当前目录路径的显示方式。 +This module has a few advanced configuration options that control how the directory is displayed. | Advanced Option | 默认值 | 描述 | | --------------------------- | ------ | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------- | | `substitutions` | | A table of substitutions to be made to the path. | -| `fish_style_pwd_dir_length` | `0` | 使用 fish shell 当前目录路径逻辑时每个省略目录名使用的字符数。 | +| `fish_style_pwd_dir_length` | `0` | The number of characters to use when applying fish shell pwd path logic. | | `use_logical_path` | `true` | If `true` render the logical path sourced from the shell via `PWD` or `--logical-path`. If `false` instead render the physical filesystem path with symlinks resolved. | `substitutions` allows you to define arbitrary replacements for literal strings that occur in the path, for example long network prefixes or development directories (i.e. Java). Note that this will disable the fish style PWD. @@ -782,7 +824,7 @@ format = "via [🐋 $context](blue bold)" ## Dotnet -The `dotnet` module shows the relevant version of the [.NET Core SDK](https://dotnet.microsoft.com/) for the current directory. 如果当前目录已被绑定了一个版本的 SDK,则显示被帮定的版本。 否则此组件将显示最新安装的 SDK 版本。 +The `dotnet` module shows the relevant version of the [.NET Core SDK](https://dotnet.microsoft.com/) for the current directory. If the SDK has been pinned in the current directory, the pinned version is shown. Otherwise the module shows the latest installed version of the SDK. By default this module will only be shown in your prompt when one or more of the following files are present in the current directory: @@ -797,7 +839,7 @@ By default this module will only be shown in your prompt when one or more of the You'll also need the .NET Core SDK installed in order to use it correctly. -在内部,此组件使用自己的版本检测机制。 一般来说此组件是直接执行 `dotnet --version` 的两倍快,但当你的 .NET 项目使用了不常见的目录布局时此组件可能显示一个错误的版本。 如果相比于速度您更需要正确的版本号,您可以在组件设置中设置 `heuristic = false` 来禁用该机制。 +Internally, this module uses its own mechanism for version detection. Typically it is twice as fast as running `dotnet --version`, but it may show an incorrect version if your .NET project has an unusual directory layout. If accuracy is more important than speed, you can disable the mechanism by setting `heuristic = false` in the module options. The module will also show the Target Framework Moniker () when there is a csproj file in the current directory. @@ -807,13 +849,13 @@ The module will also show the Target Framework Moniker ( ⚠ 此组件显示的是源代码在当前目录中的软件包的版本,而不是包管理器的版本。 @@ -2061,11 +2133,11 @@ symbol = "☁️ " | Option | 默认值 | 描述 | | ----------------- | --------------------------------- | ------------------------------------------------------------------------- | | `format` | `"is [$symbol$version]($style) "` | 组件格式化模板。 | -| `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 @@ -2130,7 +2202,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: -- 当前目录包含一个 `composer.json` 文件 +- The current directory contains a `composer.json` file - The current directory contains a `.php-version` file - The current directory contains a `.php` extension @@ -2140,12 +2212,12 @@ The `php` module shows the currently installed version of [PHP](https://www.php. | ------------------- | ------------------------------------ | ------------------------------------------------------------------------- | | `format` | `"via [$symbol($version )]($style)"` | 组件格式化模板。 | | `version_format` | `"v${raw}"` | The version format. Available vars are `raw`, `major`, `minor`, & `patch` | -| `symbol` | `"🐘 "` | 这个字段的内容会显示在当前 PHP 版本之前。 | +| `symbol` | `"🐘 "` | The symbol used before displaying the version of PHP. | | `detect_extensions` | `["php"]` | Which extensions should trigger this module. | | `detect_files` | `["composer.json", ".php-version"]` | Which filenames should trigger this module. | | `detect_folders` | `[]` | Which folders should trigger this module. | | `style` | `"147 bold"` | 此组件的样式。 | -| `disabled` | `false` | 禁用 `php` 组件。 | +| `disabled` | `false` | Disables the `php` module. | ### Variables @@ -2170,7 +2242,7 @@ format = "via [🔹 $version](147 bold) " The `purescript` module shows the currently installed version of [PureScript](https://www.purescript.org/) version. By default the module will be shown if any of the following conditions are met: -- 当前目录包含 `spago.dhall` 文件 +- The current directory contains a `spago.dhall` file - The current directory contains a file with the `.purs` extension ### 配置项 @@ -2209,19 +2281,19 @@ format = "via [$symbol$version](bold white)" The `python` module shows the currently installed version of [Python](https://www.python.org/) and the current [Python virtual environment](https://docs.python.org/tutorial/venv.html) if one is activated. -如果`pyenv_version_name`被设置为`true`, 本组件将会展示pyenv版本名。 否则则显示通过`python --version`获得的版本号 +If `pyenv_version_name` is set to `true`, it will display the pyenv version name. Otherwise, it will display the version number from `python --version`. By default the module will be shown if any of the following conditions are met: -- 当前目录包含 `.python-version` 文件 -- 当前目录包含 `Pipfile` 文件 -- 当前目录包含一个名为`__init__.py`的文件 -- 当前目录包含 `pyproject.toml` 文件 -- 当前目录包含 `requirements.txt` 文件 -- 当前目录包含 `setup.py` 文件 -- 当前目录包含一个 `tox.ini` 文件 -- 当前目录包含一个使用 `.py` 扩展名的文件. -- 当前处于一个活跃的 python 虚拟环境中 +- The current directory contains a `.python-version` file +- The current directory contains a `Pipfile` file +- The current directory contains a `__init__.py` file +- The current directory contains a `pyproject.toml` file +- The current directory contains a `requirements.txt` file +- The current directory contains a `setup.py` file +- The current directory contains a `tox.ini` file +- The current directory contains a file with the `.py` extension. +- A virtual environment is currently activated ### 配置项 @@ -2229,15 +2301,15 @@ By default the module will be shown if any of the following conditions are met: | -------------------- | ------------------------------------------------------------------------------------------------------------ | -------------------------------------------------------------------------------------- | | `format` | `'via [${symbol}${pyenv_prefix}(${version} )(\($virtualenv\) )]($style)'` | 组件格式化模板。 | | `version_format` | `"v${raw}"` | The version format. Available vars are `raw`, `major`, `minor`, & `patch` | -| `symbol` | `"🐍 "` | 用于表示Python的格式化字符串。 | +| `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 @@ -2251,11 +2323,11 @@ The default values and order for `python_binary` was chosen to first identify th | 字段 | 示例 | 描述 | | ------------ | --------------- | ------------------------------------------ | -| version | `"v3.8.1"` | `python`版本 | +| version | `"v3.8.1"` | The version of `python` | | symbol | `"🐍 "` | `symbol`对应值 | | style | `"yellow bold"` | `style`对应值 | | pyenv_prefix | `"pyenv "` | Mirrors the value of option `pyenv_prefix` | -| virtualenv | `"venv"` | 当前`virtualenv`名称 | +| virtualenv | `"venv"` | The current `virtualenv` name | ### 示例 @@ -2296,7 +2368,7 @@ python_binary = ["./venv/bin/python", "python", "python3", "python2"] ## R -The `rlang` module shows the currently installed version of R. The module will be shown if any of the following conditions are met: +The `rlang` module shows the currently installed version of [R](https://www.r-project.org/). The module will be shown if any of the following conditions are met: - The current directory contains a file with the `.R` extension. - The current directory contains a file with the `.Rd` extension. @@ -2338,7 +2410,7 @@ format = "with [📐 $version](blue bold) " ## 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 @@ -2376,11 +2448,11 @@ 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 `Gemfile` file - The current directory contains a `.ruby-version` file -- 当前目录包含 `.rb` 文件 +- The current directory contains a `.rb` file ### 配置项 @@ -2393,7 +2465,7 @@ By default the `ruby` module shows the currently installed version of [Ruby](htt | `detect_files` | `["Gemfile", ".ruby-version"]` | Which filenames should trigger this module. | | `detect_folders` | `[]` | Which folders should trigger this module. | | `style` | `"bold red"` | 此组件的样式。 | -| `disabled` | `false` | 禁用 `ruby` 组件。 | +| `disabled` | `false` | Disables the `ruby` module. | ### Variables @@ -2416,10 +2488,10 @@ 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` 扩展名的文件 +- The current directory contains a `Cargo.toml` file +- The current directory contains a file with the `.rs` extension ### 配置项 @@ -2432,7 +2504,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 @@ -2499,7 +2571,7 @@ The `shell` module shows an indicator for currently used shell. ::: tip -此组件默认被禁用。 若要启用此组件,请在配置文件中设置 `disable` 字段为 `false`。 +This module is disabled by default. To enable it, set `disabled` to `false` in your configuration file. ::: @@ -2539,7 +2611,7 @@ disabled = false ## SHLVL -The `shlvl` module shows the current `SHLVL` ("shell level") environment variable, if it is set to a number and meets or exceeds the specified threshold. +The `shlvl` module shows the current [`SHLVL`](https://tldp.org/LDP/abs/html/internalvariables.html#SHLVLREF) ("shell level") environment variable, if it is set to a number and meets or exceeds the specified threshold. ### 配置项 @@ -2611,7 +2683,7 @@ The `status` module displays the exit code of the previous command. The module w ::: tip -此组件默认被禁用。 若要启用此组件,请在配置文件中设置 `disable` 字段为 `false`。 +This module is disabled by default. To enable it, set `disabled` to `false` in your configuration file. ::: @@ -2669,7 +2741,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 @@ -2718,7 +2790,7 @@ By default the Terraform version is not shown, since this is slow for current ve By default the module will be shown if any of the following conditions are met: -- 当前目录包含 `.terraform` 目录 +- The current directory contains a `.terraform` folder - Current directory contains a file with the `.tf` or `.hcl` extensions ### 配置项 @@ -2732,7 +2804,7 @@ By default the module will be shown if any of the following conditions are met: | `detect_files` | `[]` | Which filenames should trigger this module. | | `detect_folders` | `[".terraform"]` | Which folders should trigger this module. | | `style` | `"bold 105"` | 此组件的样式。 | -| `disabled` | `false` | 禁用 `terraform` 组件。 | +| `disabled` | `false` | Disables the `terraform` module. | ### Variables @@ -2767,27 +2839,27 @@ format = "[🏎💨 $workspace]($style) " ## Time -`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 -此组件默认被禁用。 若要启用此组件,请在配置文件中设置 `disable` 字段为 `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"`. 否则,其默认值为 `"%T"`。 Manually setting `time_format` will override the `use_12hr` setting. +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. ### Variables @@ -2813,12 +2885,12 @@ 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: -- 当前用户是 root -- 当前用户与登录用户不相同 -- 用户正通过 SSH 会话连接访问 -- 字段 `show_always` 被设置为 true +- The current user is root +- The current user isn't the same as the one that is logged in +- The user is currently connected as an SSH session +- The variable `show_always` is set to true ::: tip @@ -2828,13 +2900,13 @@ SSH connection is detected by checking environment variables `SSH_CONNECTION`, ` ### 配置项 -| Option | 默认值 | 描述 | -| ------------- | ----------------------- | ------------------- | -| `style_root` | `"bold red"` | 当前用户为 root 时使用的样式。 | -| `style_user` | `"bold yellow"` | 非 root 用户使用的样式。 | -| `format` | `"[$user]($style) in "` | 组件格式化模板。 | -| `show_always` | `false` | 总是显示 `username` 组件。 | -| `disabled` | `false` | 禁用 `username` 组件。 | +| Option | 默认值 | 描述 | +| ------------- | ----------------------- | ------------------------------------- | +| `style_root` | `"bold red"` | The style used when the user is root. | +| `style_user` | `"bold yellow"` | The style used for non-root users. | +| `format` | `"[$user]($style) in "` | 组件格式化模板。 | +| `show_always` | `false` | Always shows the `username` module. | +| `disabled` | `false` | Disables the `username` module. | ### Variables @@ -2894,9 +2966,9 @@ The `vagrant` module shows the currently installed version of [Vagrant](https:// format = "via [⍱ $version](bold white) " ``` -## VLang +## V -The `vlang` module shows you your currently installed version of V. By default the module will be shown if any of the following conditions are met: +The `vlang` module shows you your currently installed version of [V](https://vlang.io/). By default the module will be shown if any of the following conditions are met: - The current directory contains a file with `.v` extension - The current directory contains a `v.mod`, `vpkg.json` or `.vpkg-lock.json` file @@ -2925,7 +2997,7 @@ The `vlang` module shows you your currently installed version of V. By default t ```toml # ~/.config/starship.toml -[v] +[vlang] format = "via [V $version](blue bold) " ``` @@ -2963,7 +3035,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 @@ -3036,7 +3108,7 @@ The order in which custom modules are shown can be individually set by including | `command` | | The command whose output should be printed. The command will be passed on stdin to the shell. | | `when` | | A shell command used as a condition to show the module. The module will be shown if the command returns a `0` status code. | | `shell` | | [See below](#custom-command-shell) | -| `描述` | `""` | The description of the module that is shown when running `starship explain`. | +| `description` | `""` | The description of the module that is shown when running `starship explain`. | | `files` | `[]` | The files that will be searched in the working directory for a match. | | `directories` | `[]` | The directories that will be searched in the working directory for a match. | | `extensions` | `[]` | The extensions that will be searched in the working directory for a match. | diff --git a/docs/zh-CN/guide/README.md b/docs/zh-CN/guide/README.md index 833361c2..13fecf89 100644 --- a/docs/zh-CN/guide/README.md +++ b/docs/zh-CN/guide/README.md @@ -48,30 +48,6 @@ height="20" src="https://raw.githubusercontent.com/starship/starship/master/media/flag-us.png" alt="English" - /> -   - 日本語 -   - 繁體中文 -   - Русский   -   - 简体中文   +   + 日本語 +   + Português do Brasil +   + Русский   +   + 简体中文 +   + 繁體中文

@@ -160,8 +168,8 @@ ```sh sh -c "$(curl -fsSL https://starship.rs/install.sh)" ``` - To update the Starship itself, rerun the above script. It will replace the current version without touching Starship's configuration. + To update the Starship itself, rerun the above script. It will replace the current version without touching Starship's configuration. **Note** - The defaults of the install script can be overridden see the built-in help. diff --git a/docs/zh-CN/presets/README.md b/docs/zh-CN/presets/README.md index d24d336a..7fc4df60 100644 --- a/docs/zh-CN/presets/README.md +++ b/docs/zh-CN/presets/README.md @@ -112,6 +112,9 @@ format = '\[[$symbol($version)]($style)\]' [cmd_duration] format = '\[[⏱ $duration ]($style)\]' +[cobol] +format = '\[[$symbol($version)]($style)\]' + [conda] format = '\[[$symbol$environment]($style)\]' @@ -272,6 +275,9 @@ deleted = "x" [aws] symbol = "aws " +[cobol] +symbol = "cobol " + [conda] symbol = "conda " @@ -375,6 +381,9 @@ This preset hides the version of language runtimes. If you work in containers or [cmake] format = "via [$symbol]($style)" +[cobol] +format = "via [$symbol]($style)" + [crystal] format = "via [$symbol]($style)" diff --git a/docs/zh-TW/advanced-config/README.md b/docs/zh-TW/advanced-config/README.md index 712c3553..d73720bf 100644 --- a/docs/zh-TW/advanced-config/README.md +++ b/docs/zh-TW/advanced-config/README.md @@ -68,9 +68,36 @@ function set_win_title(){ starship_precmd_user_func="set_win_title" ``` +## Enable Right Prompt + +Some shells support a right prompt which renders on the same line as the input. Starship can set the content of the right prompt using the `right_format` option. Any module that can be used in `format` is also supported in `right_format`. The `$all` variable will only contain modules not explicitly used in either `format` or `right_format`. + +Note: The right prompt is a single line following the input location. To right align modules above the input line in a multi-line prompt, see the [fill module](/config/#fill). + +`right_format` is currently supported for the following shells: elvish, fish, zsh. + +### 範例 + +```toml +# ~/.config/starship.toml + +# A minimal left prompt +format = """$character""" + +# move the rest of the prompt to the right +right_format = """$all""" +``` + +Produces a prompt like the following: + +``` +▶ starship on  rprompt [!] is 📦 v0.57.0 via 🦀 v1.54.0 took 17s +``` + + ## 風格字串 -風格字串是一個以空白分開的單詞清單。 單字並不會區分大小寫(換句話說,`bold` 與 `BoLd` 是被當作兩個相同的字串)。 每個單詞可以是下列其中之一: +Style strings are a list of words, separated by whitespace. The words are not case sensitive (i.e. `bold` and `BoLd` are considered the same string). Each word can be one of the following: - `bold` - `斜體字` @@ -82,14 +109,14 @@ starship_precmd_user_func="set_win_title" - `` - `none` -其中 `` 是指定顏色用的(下面解釋)。 `fg:` and `` currently do the same thing, though this may change in the future. `inverted` swaps the background and foreground colors. 單詞在字串中的順序不重要。 +where `` is a color specifier (discussed below). `fg:` and `` currently do the same thing, though this may change in the future. `inverted` swaps the background and foreground colors. The order of words in the string does not matter. -The `none` token overrides all other tokens in a string if it is not part of a `bg:` specifier, so that e.g. `fg:red none fg:blue` will still create a string with no styling. `bg:none` sets the background to the default color so `fg:red bg:none` is equivalent to `red` or `fg:red` and `bg:green fg:red bg:none` is also equivalent to `fg:red` or `red`. 未來可能會將 `none` 與其他符號一起使用的情形視為是一種錯誤。 +The `none` token overrides all other tokens in a string if it is not part of a `bg:` specifier, so that e.g. `fg:red none fg:blue` will still create a string with no styling. `bg:none` sets the background to the default color so `fg:red bg:none` is equivalent to `red` or `fg:red` and `bg:green fg:red bg:none` is also equivalent to `fg:red` or `red`. It may become an error to use `none` in conjunction with other tokens in the future. -一個顏色指定符號可以是下列其中之一: +A color specifier can be one of the following: - 任一個標準終端機顏色:`black`、`red`、`green`、`blue`、`yellow`、`purple`、`cyan`、`white`。 你可以選擇性地加上前綴 `bright-` 來取得明亮版本的顏色(例如:`bright-white`)。 - 一個 `#` 後面跟隨著六位數的十六進位數字。 這個指定了 [RGB 十六進制色碼](https://www.w3schools.com/colors/colors_hexadecimal.asp)。 - 一個介於 0~255 之間的數字。 這個指定了 [8-bit ANSI 色碼](https://i.stack.imgur.com/KTSQa.png)。 -如果前景/後景被指定了多種顏色,最後一個顏色具有最高優先性。 +If multiple colors are specified for foreground/background, the last one in the string will take priority. diff --git a/docs/zh-TW/config/README.md b/docs/zh-TW/config/README.md index 9ab5a759..1e984112 100644 --- a/docs/zh-TW/config/README.md +++ b/docs/zh-TW/config/README.md @@ -75,7 +75,7 @@ A text group is made up of two different parts. The first part, which is enclosed in a `[]`, is a [format string](#format-strings). You can add texts, variables, or even nested text groups in it. -In the second part, which is enclosed in a `()`, is a [style string](#style-strings). This can be used style the first part. +In the second part, which is enclosed in a `()`, is a [style string](#style-strings). This can be used to style the first part. For example: @@ -142,12 +142,14 @@ format = ''' ### 選項 -| Option | 預設 | 說明 | -| ----------------- | ---------------------------- | ------------------------------------------------------------ | -| `format` | [連結](#default-prompt-format) | Configure the format of the prompt. | -| `scan_timeout` | `30` | Timeout for starship to scan files (in milliseconds). | -| `command_timeout` | `500` | Timeout for commands executed by starship (in milliseconds). | -| `add_newline` | `true` | Inserts blank line between shell prompts. | +| Option | 預設 | 說明 | +| ----------------- | ---------------------------- | ---------------------------------------------------------------- | +| `format` | [連結](#default-prompt-format) | Configure the format of the prompt. | +| `right_format` | `""` | See [Enable Right Prompt](/advanced-config/#enable-right-prompt) | +| `scan_timeout` | `30` | Timeout for starship to scan files (in milliseconds). | +| `command_timeout` | `500` | Timeout for commands executed by starship (in milliseconds). | +| `add_newline` | `true` | Inserts blank line between shell prompts. | + ### 範例 @@ -179,6 +181,7 @@ format = """ $username\ $hostname\ $shlvl\ +$singularity\ $kubernetes\ $directory\ $vcsh\ @@ -191,6 +194,7 @@ $hg_branch\ $docker_context\ $package\ $cmake\ +$cobol\ $dart\ $deno\ $dotnet\ @@ -202,6 +206,7 @@ $helm\ $java\ $julia\ $kotlin\ +$lua\ $nim\ $nodejs\ $ocaml\ @@ -209,6 +214,7 @@ $perl\ $php\ $purescript\ $python\ +$rlang\ $red\ $ruby\ $rust\ @@ -229,7 +235,6 @@ $crystal\ $custom\ $cmd_duration\ $line_break\ -$lua\ $jobs\ $battery\ $time\ @@ -238,9 +243,16 @@ $shell\ $character""" ``` +If you just want to extend the default format, you can use `$all`; modules you explicitly add to the format will not be duplicated. Eg. + +```toml +# Move the directory to the second line +format="$all$directory$character" +``` + ## AWS -`aws` 模組顯示現在 AWS 的區域與概況。 這是根據 `AWS_REGION`、`AWS_DEFAULT_REGION` 與 `AWS_PROFILE` 環境變數及 `~/.aws/config` 檔案。 This module also shows an expiration timer when using temporary credentials. +The `aws` module shows the current AWS region and profile. This is based on `AWS_REGION`, `AWS_DEFAULT_REGION`, and `AWS_PROFILE` env var with `~/.aws/config` file. This module also shows an expiration timer when using temporary credentials. When using [aws-vault](https://github.com/99designs/aws-vault) the profile is read from the `AWS_VAULT` env var and the credentials expiration date is read from the `AWS_SESSION_EXPIRATION` env var. @@ -314,7 +326,7 @@ symbol = "🅰 " ## 電池 -`battery` 模組顯示電池的電量以及現在的充電狀態。 這個模組只會在裝置的電量低於 10% 的時候看見。 +The `battery` module shows how charged the device's battery is and its current charging status. The module is only visible when the device's battery is below 10%. ### 選項 @@ -342,7 +354,7 @@ discharging_symbol = "💀 " ### 電池顯示 -The `display` configuration option is used to define when the battery indicator should be shown (threshold), which symbol would be used (symbol), and what it would like (style). 如果沒有提供 `display`。 預設如下: +The `display` configuration option is used to define when the battery indicator should be shown (threshold), which symbol would be used (symbol), and what it would like (style). If no `display` is provided. 預設如下: ```toml [[battery.display]] @@ -354,7 +366,7 @@ The default value for the `charging_symbol` and `discharging_symbol` option is r #### 選項 -`display` 選項是一個下列表格的陣列。 +The `display` option is an array of the following table. | Option | 預設 | 說明 | | -------------------- | ---------- | --------------------------------------------------------------------------------------------------------- | @@ -381,9 +393,9 @@ discharging_symbol = 💦 ## 字元 -`character` 模組在你的文字輸入處旁顯示一個字元 (通常是箭頭)。 +The `character` module shows a character (usually an arrow) beside where the text is entered in your terminal. -這個字元會告訴你最後的指令是成功還是失敗。 It can do this in two ways: +The character will tell you whether the last command was successful or not. It can do this in two ways: - changing color (`red`/`green`) - changing shape (`❯`/`✖`) @@ -479,29 +491,59 @@ The `cmake` module shows the currently installed version of [CMake](https://cmak \*: This variable can only be used as a part of a style string -## 指令持續時間 +## COBOL / GNUCOBOL -`cmd_duration` 模組顯示最後一個指令執行所花費的時間。 這個模組只會在指令花費超過兩秒或是有設定 `min_time` 時,超過設定值時出現。 +The `cobol` module shows the currently installed version of COBOL. By default, the module will be shown if any of the following conditions are met: -::: warning 不要在 Bash 中設置 DEBUG trap - -如果你在 `bash` 中使用 Starship,不要在執行 `eval $(starship init $0)` 之後設置 `DEBUG` trap,不然這個模組**會**壞掉。 - -::: - -想使用類似 preexec 功能的 Bash 使用者可以 [rcaloras 的 bash_preexec 框架](https://github.com/rcaloras/bash-preexec)。 只要在 `eval $(starship init $0)` 之前簡單地定義 `preexec_functions` 與 `precmd_functions` 兩個陣列,然後就可以照常進行。 +- The current directory contains any files ending in `.cob` or `.COB` +- The current directory contains any files ending in `.cbl` or `.CBL` ### 選項 -| Option | 預設 | 說明 | -| -------------------- | ----------------------------- | ----------------------------------------------------- | -| `min_time` | `2_000` | Shortest duration to show time for (in milliseconds). | -| `show_milliseconds` | `false` | 顯示時間除了以秒為單位外,亦以毫秒顯示 | -| `format` | `"took [$duration]($style) "` | The format for the module. | -| `style` | `"bold yellow"` | 這個模組的風格。 | -| `disabled` | `false` | 停用 `cmd_duration` 模組。 | -| `show_notifications` | `false` | Show desktop notifications when command completes. | -| `min_time_to_notify` | `45_000` | Shortest duration for notification (in milliseconds). | +| Option | 預設 | 說明 | +| ------------------- | ------------------------------------ | ------------------------------------------------------------------------- | +| `symbol` | `"⚙️ "` | The symbol used before displaying the version of COBOL. | +| `format` | `"via [$symbol($version )]($style)"` | The format for the module. | +| `version_format` | `"v${raw}"` | The version format. Available vars are `raw`, `major`, `minor`, & `patch` | +| `style` | `"bold blue"` | 這個模組的風格。 | +| `detect_extensions` | `["cbl", "cob", "CBL", "COB"]` | Which extensions should trigger this module. | +| `detect_files` | `[]` | Which filenames should trigger this module. | +| `detect_folders` | `[]` | Which folders should trigger this module. | +| `disabled` | `false` | Disables the `cobol` module. | + +### Variables + +| 變數 | 範例 | 說明 | +| --------- | ---------- | ------------------------------------ | +| version | `v3.1.2.0` | The version of `cobol` | +| 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 + +## 指令持續時間 + +The `cmd_duration` module shows how long the last command took to execute. The module will be shown only if the command took longer than two seconds, or the `min_time` config value, if it exists. + +::: warning Do not hook the DEBUG trap in Bash + +If you are running Starship in `bash`, do not hook the `DEBUG` trap after running `eval $(starship init $0)`, or this module **will** break. + +::: + +Bash users who need preexec-like functionality can use [rcaloras's bash_preexec framework](https://github.com/rcaloras/bash-preexec). Simply define the arrays `preexec_functions` and `precmd_functions` before running `eval $(starship init $0)`, and then proceed as normal. + +### 選項 + +| Option | 預設 | 說明 | +| -------------------- | ----------------------------- | ---------------------------------------------------------- | +| `min_time` | `2_000` | Shortest duration to show time for (in milliseconds). | +| `show_milliseconds` | `false` | Show milliseconds in addition to seconds for the duration. | +| `format` | `"took [$duration]($style) "` | The format for the module. | +| `style` | `"bold yellow"` | 這個模組的風格。 | +| `disabled` | `false` | Disables the `cmd_duration` module. | +| `show_notifications` | `false` | Show desktop notifications when command completes. | +| `min_time_to_notify` | `45_000` | Shortest duration for notification (in milliseconds). | ::: tip @@ -530,7 +572,7 @@ format = "underwent [$duration](bold yellow)" ## Conda -如果有設定 `$CONDA_DEFAULT_ENV` 時,`conda` 模組顯示現在 conda 的環境。 +The `conda` module shows the current [Conda](https://docs.conda.io/en/latest/) environment, if `$CONDA_DEFAULT_ENV` is set. ::: tip @@ -540,14 +582,14 @@ This does not suppress conda's own prompt modifier, you may want to run `conda c ### 選項 -| Option | 預設 | 說明 | -| ------------------- | -------------------------------------- | ----------------------------------------------------------------------------------------------- | -| `truncation_length` | `1` | 如果環境變數由所`conda create -p [path]`產生時,環境變數的資料夾需要截斷的數目。 `0` 表示不截斷 也請參考 [`directory`](#directory)模組 | -| `symbol` | `"🅒 "` | 環境名稱前使用的符號。 | -| `style` | `"bold green"` | 這個模組的風格。 | -| `format` | `"via [$symbol$environment]($style) "` | The format for the module. | -| `ignore_base` | `true` | Ignores `base` environment when activated. | -| `disabled` | `false` | 停用 `conda` 模組。 | +| Option | 預設 | 說明 | +| ------------------- | -------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | +| `truncation_length` | `1` | The number of directories the environment path should be truncated to, if the environment was created via `conda create -p [path]`. `0` means no truncation. Also see the [`directory`](#directory) module. | +| `symbol` | `"🅒 "` | The symbol used before the environment name. | +| `style` | `"bold green"` | 這個模組的風格。 | +| `format` | `"via [$symbol$environment]($style) "` | The format for the module. | +| `ignore_base` | `true` | Ignores `base` environment when activated. | +| `disabled` | `false` | Disables the `conda` module. | ### Variables @@ -572,8 +614,8 @@ format = "[$symbol$environment](dimmed green) " The `crystal` module shows the currently installed version of [Crystal](https://crystal-lang.org/). By default the module will be shown if any of the following conditions are met: -- 現在資料夾中含有一個 `shard.yml` 檔案 -- 現在資料夾中含有一個`.cr`檔案 +- The current directory contains a `shard.yml` file +- The current directory contains a `.cr` file ### 選項 @@ -613,7 +655,7 @@ The `dart` module shows the currently installed version of [Dart](https://dart.d - The current directory contains a file with `.dart` extension - The current directory contains a `.dart_tool` directory -- 現在資料夾中包含一個 `pubspec.yaml`、`pubspec.yml` 或 `pubspec.lock` 檔案 +- The current directory contains a `pubspec.yaml`, `pubspec.yml` or `pubspec.lock` file ### 選項 @@ -684,33 +726,33 @@ format = "via [🦕 $version](green bold) " ## 資料夾 -`directory` 模組顯示到現在資料夾的路徑,並裁減到前三層資料夾。 你的資料夾也會被裁減到你所在的 git 儲存庫的根目錄。 +The `directory` module shows the path to your current directory, truncated to three parent folders. Your directory will also be truncated to the root of the git repo that you're currently in. -如果正在使用 fish 風格的 pwd 選項,將不會隱藏被裁減的資料夾,而是會根據你在選項中設定的數字看到每一層資料夾的縮寫。 +When using the fish style pwd option, instead of hiding the path that is truncated, you will see a shortened name of each directory based on the number you enable for the option. -例如,給定一個右列的路徑 `~/Dev/Nix/nixpkgs/pkgs` 其中 `nixpkgs` 是儲存庫的根目錄,而且該選項被設定為 `1`。 你會看到 `~/D/N/nixpkgs/pkgs`,而在這個設定之前則是 `nixpkgs/pkgs`。 +For example, given `~/Dev/Nix/nixpkgs/pkgs` where `nixpkgs` is the repo root, and the option set to `1`. You will now see `~/D/N/nixpkgs/pkgs`, whereas before it would have been `nixpkgs/pkgs`. ### 選項 -| Option | 預設 | 說明 | -| ------------------- | -------------------------------------------------- | ----------------------------------------------------- | -| `truncation_length` | `3` | 到達現在資料夾的路徑中,要被裁減掉的資料夾數目。 | -| `truncate_to_repo` | `true` | 是否要裁減到你現在所在的 git 儲存庫的根目錄。 | -| `format` | `"[$path]($style)[$read_only]($read_only_style) "` | The format for the module. | -| `style` | `"bold cyan"` | 這個模組的風格。 | -| `disabled` | `false` | 停用 `directory` 模組。 | -| `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: "…/" | -| `home_symbol` | `"~"` | The symbol indicating home directory. | +| Option | 預設 | 說明 | +| ------------------- | -------------------------------------------------- | -------------------------------------------------------------------------------- | +| `truncation_length` | `3` | The number of parent folders that the current directory should be truncated to. | +| `truncate_to_repo` | `true` | Whether or not to truncate to the root of the git repo that you're currently in. | +| `format` | `"[$path]($style)[$read_only]($read_only_style) "` | The format for the module. | +| `style` | `"bold cyan"` | 這個模組的風格。 | +| `disabled` | `false` | Disables the `directory` module. | +| `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: "…/" | +| `home_symbol` | `"~"` | The symbol indicating home directory. |
-這個模組有些進階設定選項可以控制顯示資料夾。 +This module has a few advanced configuration options that control how the directory is displayed. | Advanced Option | 預設 | 說明 | | --------------------------- | ------ | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------- | | `substitutions` | | A table of substitutions to be made to the path. | -| `fish_style_pwd_dir_length` | `0` | 當使用 fish shell 的 pwd 路徑邏輯時使用的字元數量。 | +| `fish_style_pwd_dir_length` | `0` | The number of characters to use when applying fish shell pwd path logic. | | `use_logical_path` | `true` | If `true` render the logical path sourced from the shell via `PWD` or `--logical-path`. If `false` instead render the physical filesystem path with symlinks resolved. | `substitutions` allows you to define arbitrary replacements for literal strings that occur in the path, for example long network prefixes or development directories (i.e. Java). Note that this will disable the fish style PWD. @@ -782,7 +824,7 @@ format = "via [🐋 $context](blue bold)" ## Dotnet -The `dotnet` module shows the relevant version of the [.NET Core SDK](https://dotnet.microsoft.com/) for the current directory. 如果這個資料夾已經選定一個 SDK,則顯示這個 SDK 的版本。 如果沒有的話,則顯示最新安裝的 SDK 版本。 +The `dotnet` module shows the relevant version of the [.NET Core SDK](https://dotnet.microsoft.com/) for the current directory. If the SDK has been pinned in the current directory, the pinned version is shown. Otherwise the module shows the latest installed version of the SDK. By default this module will only be shown in your prompt when one or more of the following files are present in the current directory: @@ -797,7 +839,7 @@ By default this module will only be shown in your prompt when one or more of the You'll also need the .NET Core SDK installed in order to use it correctly. -這個模組內部是使用它自己的機制來偵測版本。 一般來說這個模組有 `dotnet --version` 的兩倍快,但是它可能會在你的 .NET 專案有不尋常的資料夾結構時顯示不正確的版本。 如果精確度比速度更重要的話,你可以藉由設定模組中的 `heuristic = false` 選項來停用這個功能。 +Internally, this module uses its own mechanism for version detection. Typically it is twice as fast as running `dotnet --version`, but it may show an incorrect version if your .NET project has an unusual directory layout. If accuracy is more important than speed, you can disable the mechanism by setting `heuristic = false` in the module options. The module will also show the Target Framework Moniker () when there is a csproj file in the current directory. @@ -807,13 +849,13 @@ The module will also show the Target Framework Moniker ([\\w-]+)" = "gke-$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. | ### 範例 @@ -1747,27 +1819,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 @@ -1806,7 +1878,7 @@ The `hg_branch` module shows the active branch of the repo in your current direc | `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` | `"…"` | 用來指示分支名稱被縮減的符號。 | +| `truncation_symbol` | `"…"` | The symbol used to indicate a branch name was truncated. | | `disabled` | `true` | Disables the `hg_branch` module. | ### Variables @@ -1834,7 +1906,7 @@ truncation_symbol = "" The `nim` module shows the currently installed version of [Nim](https://nim-lang.org/). By default the module will be shown if any of the following conditions are met: -- 現在資料夾中含有一個 `nim.cfg` 檔案 +- The current directory contains a `nim.cfg` file - The current directory contains a file with the `.nim` extension - The current directory contains a file with the `.nims` extension - The current directory contains a file with the `.nimble` extension @@ -1874,7 +1946,7 @@ 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. ### 選項 @@ -1885,7 +1957,7 @@ The `nix_shell` module shows the [nix-shell](https://nixos.org/guides/nix-pills/ | `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` 模組。 | +| `disabled` | `false` | Disables the `nix_shell` module. | ### Variables @@ -1914,10 +1986,10 @@ format = 'via [☃️ $state( \($name\))](bold blue) ' The `nodejs` module shows the currently installed version of [Node.js](https://nodejs.org/). By default the module will be shown if any of the following conditions are met: -- 現在資料夾中包含一個 `package.json` 檔案 +- The current directory contains a `package.json` file - The current directory contains a `.node-version` file - The current directory contains a `.nvmrc` file -- 現在資料夾中包含一個 `node_modules` 資料夾 +- The current directory contains a `node_modules` directory - The current directory contains a file with the `.js`, `.mjs` or `.cjs` extension - The current directory contains a file with the `.ts` extension @@ -1932,7 +2004,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 @@ -2036,23 +2108,23 @@ style = "bold yellow" symbol = "☁️ " ``` -## 套件版本 +## Package Version -The `package` 模組在現在資料夾是一個套件的儲藏庫時出現,並顯示他的現在版本。 The module currently supports `npm`, `nimble`, `cargo`, `poetry`, `composer`, `gradle`, `julia`, `mix` and `helm` 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`, `composer`, `gradle`, `julia`, `mix` and `helm` 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 -- [**nimble**](https://github.com/nim-lang/nimble) - The `nimble` package version is extracted from the `*.nimble` file present in the current directory with the `nimble dump` command -- [**poetry**](https://python-poetry.org/) – The `poetry` package version is extracted from the `pyproject.toml` present in the current directory -- [**python**](https://www.python.org) - The `python` package version is extracted from the `setup.cfg` present in the current directory -- [**composer**](https://getcomposer.org/) – The `composer` package version is extracted from the `composer.json` present in the current directory -- [**gradle**](https://gradle.org/) – The `gradle` package version is extracted from the `build.gradle` present -- [**julia**](https://docs.julialang.org/en/v1/stdlib/Pkg/) - The package version is extracted from the `Project.toml` present -- [**mix**](https://hexdocs.pm/mix/) - The `mix` package version is extracted from the `mix.exs` present -- [**helm**](https://helm.sh/docs/helm/helm_package/) - The `helm` chart version is extracted from the `Chart.yaml` present -- [**maven**](https://maven.apache.org/) - The `maven` package version is extracted from the `pom.xml` present -- [**meson**](https://mesonbuild.com/) - The `meson` package version is extracted from the `meson.build` present -- [**vlang**](https://vlang.io) - The `vlang` package version is extracted from the `v.mod` present +- [**Cargo**](https://doc.rust-lang.org/cargo/) – The `cargo` package version is extracted from the `Cargo.toml` present in the current directory +- [**Nimble**](https://github.com/nim-lang/nimble) - The `nimble` package version is extracted from the `*.nimble` file present in the current directory with the `nimble dump` command +- [**Poetry**](https://python-poetry.org/) – The `poetry` package version is extracted from the `pyproject.toml` present in the current directory +- [**Python**](https://www.python.org) - The `python` package version is extracted from the `setup.cfg` present in the current directory +- [**Composer**](https://getcomposer.org/) – The `composer` package version is extracted from the `composer.json` present in the current directory +- [**Gradle**](https://gradle.org/) – The `gradle` package version is extracted from the `build.gradle` present +- [**Julia**](https://docs.julialang.org/en/v1/stdlib/Pkg/) - The package version is extracted from the `Project.toml` present +- [**Mix**](https://hexdocs.pm/mix/) - The `mix` package version is extracted from the `mix.exs` present +- [**Helm**](https://helm.sh/docs/helm/helm_package/) - The `helm` chart version is extracted from the `Chart.yaml` present +- [**Maven**](https://maven.apache.org/) - The `maven` package version is extracted from the `pom.xml` present +- [**Meson**](https://mesonbuild.com/) - The `meson` package version is extracted from the `meson.build` present +- [**V**](https://vlang.io) - The `vlang` package version is extracted from the `v.mod` present > ⚠️ 顯示出來的版本是從你的現在資料夾之中擷取出來的,並非從套件管理員取得。 @@ -2061,11 +2133,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 @@ -2130,7 +2202,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: -- 現在資料夾中含有一個 `composer.json` 檔案 +- The current directory contains a `composer.json` file - The current directory contains a `.php-version` file - The current directory contains a `.php` extension @@ -2170,7 +2242,7 @@ format = "via [🔹 $version](147 bold) " The `purescript` module shows the currently installed version of [PureScript](https://www.purescript.org/) version. By default the module will be shown if any of the following conditions are met: -- 現在資料夾中含有一個 `spago.dhall` 檔案 +- The current directory contains a `spago.dhall` file - The current directory contains a file with the `.purs` extension ### 選項 @@ -2213,14 +2285,14 @@ If `pyenv_version_name` is set to `true`, it will display the pyenv version name By default the module will be shown if any of the following conditions are met: -- 目前資料夾中有一個 `.python-version` 檔案 -- 目前資料夾中有一個 `Pipfile` 檔案 +- The current directory contains a `.python-version` file +- The current directory contains a `Pipfile` file - The current directory contains a `__init__.py` file -- 目前資料夾中有一個 `pyproject.toml` 檔案 -- 目前資料夾中有一個 `requirements.txt` 檔案 -- 現在資料夾中含有一個 `setup.py` 檔案 -- 目前資料夾中有一個 `tox.ini` 檔案 -- 目前資料夾中有一個 `.py` 副檔名的檔案. +- The current directory contains a `pyproject.toml` file +- The current directory contains a `requirements.txt` file +- The current directory contains a `setup.py` file +- The current directory contains a `tox.ini` file +- The current directory contains a file with the `.py` extension. - A virtual environment is currently activated ### 選項 @@ -2231,13 +2303,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 @@ -2296,7 +2368,7 @@ python_binary = ["./venv/bin/python", "python", "python3", "python2"] ## R -The `rlang` module shows the currently installed version of R. The module will be shown if any of the following conditions are met: +The `rlang` module shows the currently installed version of [R](https://www.r-project.org/). The module will be shown if any of the following conditions are met: - The current directory contains a file with the `.R` extension. - The current directory contains a file with the `.Rd` extension. @@ -2338,7 +2410,7 @@ format = "with [📐 $version](blue bold) " ## 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 @@ -2376,11 +2448,11 @@ 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 `Gemfile` file - The current directory contains a `.ruby-version` file -- 目前資料夾中有一個 `.rb` 檔案 +- The current directory contains a `.rb` file ### 選項 @@ -2393,7 +2465,7 @@ By default the `ruby` module shows the currently installed version of [Ruby](htt | `detect_files` | `["Gemfile", ".ruby-version"]` | Which filenames should trigger this module. | | `detect_folders` | `[]` | Which folders should trigger this module. | | `style` | `"bold red"` | 這個模組的風格。 | -| `disabled` | `false` | 停用 `ruby` 模組。 | +| `disabled` | `false` | Disables the `ruby` module. | ### Variables @@ -2416,10 +2488,10 @@ 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` 副檔名 +- The current directory contains a `Cargo.toml` file +- The current directory contains a file with the `.rs` extension ### 選項 @@ -2432,7 +2504,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 @@ -2499,7 +2571,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. ::: @@ -2539,7 +2611,7 @@ disabled = false ## SHLVL -The `shlvl` module shows the current `SHLVL` ("shell level") environment variable, if it is set to a number and meets or exceeds the specified threshold. +The `shlvl` module shows the current [`SHLVL`](https://tldp.org/LDP/abs/html/internalvariables.html#SHLVLREF) ("shell level") environment variable, if it is set to a number and meets or exceeds the specified threshold. ### 選項 @@ -2611,7 +2683,7 @@ The `status` module displays the exit code of the previous command. The module w ::: tip -這個模組預設是停用的。 想要啟用它的話,請在設定檔中將 `disabled` 設定為 `false`。 +This module is disabled by default. To enable it, set `disabled` to `false` in your configuration file. ::: @@ -2669,7 +2741,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 @@ -2767,33 +2839,33 @@ 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"`. 不然的話,它會被預設為 `"%T"`。 Manually setting `time_format` will override the `use_12hr` setting. +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. ### Variables | 變數 | 範例 | 說明 | | --------- | ---------- | ----------------------------------- | -| 時間 | `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 @@ -2811,14 +2883,14 @@ 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: -- 目前使用者為 root -- 目前使用者並非登入時的使用者 -- 使用者透過 SSH session 進行連線 -- 變數 `show_always` 被設為 true +- The current user is root +- The current user isn't the same as the one that is logged in +- The user is currently connected as an SSH session +- The variable `show_always` is set to true ::: tip @@ -2828,13 +2900,13 @@ SSH connection is detected by checking environment variables `SSH_CONNECTION`, ` ### 選項 -| Option | 預設 | 說明 | -| ------------- | ----------------------- | -------------------------- | -| `style_root` | `"bold red"` | 使用者為 root 時使用的風格。 | -| `style_user` | `"bold yellow"` | 非 root 使用者時使用的風格。 | -| `format` | `"[$user]($style) in "` | The format for the module. | -| `show_always` | `false` | 總是顯示 `username` 模組。 | -| `disabled` | `false` | 停用 `username` 模組。 | +| Option | 預設 | 說明 | +| ------------- | ----------------------- | ------------------------------------- | +| `style_root` | `"bold red"` | The style used when the user is root. | +| `style_user` | `"bold yellow"` | The style used for non-root users. | +| `format` | `"[$user]($style) in "` | The format for the module. | +| `show_always` | `false` | Always shows the `username` module. | +| `disabled` | `false` | Disables the `username` module. | ### Variables @@ -2894,9 +2966,9 @@ The `vagrant` module shows the currently installed version of [Vagrant](https:// format = "via [⍱ $version](bold white) " ``` -## VLang +## V -The `vlang` module shows you your currently installed version of V. By default the module will be shown if any of the following conditions are met: +The `vlang` module shows you your currently installed version of [V](https://vlang.io/). By default the module will be shown if any of the following conditions are met: - The current directory contains a file with `.v` extension - The current directory contains a `v.mod`, `vpkg.json` or `.vpkg-lock.json` file @@ -2925,7 +2997,7 @@ The `vlang` module shows you your currently installed version of V. By default t ```toml # ~/.config/starship.toml -[v] +[vlang] format = "via [V $version](blue bold) " ``` @@ -2963,7 +3035,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 @@ -3036,7 +3108,7 @@ The order in which custom modules are shown can be individually set by including | `command` | | The command whose output should be printed. The command will be passed on stdin to the shell. | | `when` | | A shell command used as a condition to show the module. The module will be shown if the command returns a `0` status code. | | `shell` | | [See below](#custom-command-shell) | -| `說明` | `""` | The description of the module that is shown when running `starship explain`. | +| `description` | `""` | The description of the module that is shown when running `starship explain`. | | `files` | `[]` | The files that will be searched in the working directory for a match. | | `directories` | `[]` | The directories that will be searched in the working directory for a match. | | `extensions` | `[]` | The extensions that will be searched in the working directory for a match. | diff --git a/docs/zh-TW/guide/README.md b/docs/zh-TW/guide/README.md index a1f75bb2..3e45dfec 100644 --- a/docs/zh-TW/guide/README.md +++ b/docs/zh-TW/guide/README.md @@ -48,30 +48,6 @@ height="20" src="https://raw.githubusercontent.com/starship/starship/master/media/flag-us.png" alt="English" - /> -   - 日本語 -   - 繁體中文 -   - Русский   -   - 简体中文   +   + 日本語 +   + Português do Brasil +   + Русский   +   + 简体中文 +   + 繁體中文

@@ -160,8 +168,8 @@ ```sh sh -c "$(curl -fsSL https://starship.rs/install.sh)" ``` - 如果想更新已安裝的 Starship,請重新執行上述指令。 指令只會更新 Starship 執行檔本身,不會影響到任何已撰寫的設定檔。 + 如果想更新已安裝的 Starship,請重新執行上述指令。 指令只會更新 Starship 執行檔本身,不會影響到任何已撰寫的設定檔。 **備註** —— 安裝腳本的預設值可以被覆蓋,請使用以下指令查看內置說明。 diff --git a/docs/zh-TW/presets/README.md b/docs/zh-TW/presets/README.md index 4c4cceb0..a85d05b5 100644 --- a/docs/zh-TW/presets/README.md +++ b/docs/zh-TW/presets/README.md @@ -112,6 +112,9 @@ format = '\[[$symbol($version)]($style)\]' [cmd_duration] format = '\[[⏱ $duration ]($style)\]' +[cobol] +format = '\[[$symbol($version)]($style)\]' + [conda] format = '\[[$symbol$environment]($style)\]' @@ -272,6 +275,9 @@ deleted = "x" [aws] symbol = "aws " +[cobol] +symbol = "cobol " + [conda] symbol = "conda " @@ -375,6 +381,9 @@ symbol = "swift " [cmake] format = "via [$symbol]($style)" +[cobol] +format = "via [$symbol]($style)" + [crystal] format = "via [$symbol]($style)"