1
0
mirror of https://github.com/Llewellynvdm/starship.git synced 2024-11-24 13:47:38 +00:00

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

* New translations README.md (Sorani (Kurdish))

* New translations README.md (Chinese Traditional)

* New translations README.md (Chinese Simplified)

* New translations README.md (Chinese Simplified)

* New translations README.md (Chinese Traditional)

* New translations README.md (Vietnamese)

* New translations README.md (Vietnamese)

* New translations README.md (Portuguese, Brazilian)

* New translations README.md (Indonesian)

* New translations README.md (Indonesian)

* New translations README.md (Chinese Traditional)

* New translations README.md (Portuguese, Brazilian)

* New translations README.md (Vietnamese)

* New translations README.md (Indonesian)

* New translations README.md (Sorani (Kurdish))

* New translations bracketed-segments.md (Portuguese, Brazilian)

* New translations nerd-font.md (Portuguese, Brazilian)

* New translations README.md (French)

* New translations README.md (French)

* New translations README.md (French)

* New translations README.md (French)

* New translations README.md (French)

* New translations README.md (French)

* New translations README.md (Spanish)

* New translations README.md (French)

* New translations README.md (Arabic)

* New translations README.md (Indonesian)

* New translations README.md (Portuguese, Brazilian)

* New translations README.md (Vietnamese)

* New translations README.md (Chinese Traditional)

* New translations README.md (Chinese Simplified)

* New translations README.md (Turkish)

* New translations README.md (Portuguese)

* New translations README.md (Russian)

* New translations README.md (Polish)

* New translations README.md (Dutch)

* New translations README.md (Korean)

* New translations README.md (Japanese)

* New translations README.md (Italian)

* New translations README.md (German)

* New translations README.md (Sorani (Kurdish))

* New translations README.md (French)

* New translations README.md (French)

* New translations README.md (French)

* New translations README.md (French)

* New translations README.md (French)

* New translations README.md (French)

* New translations README.md (Japanese)

* New translations README.md (Japanese)

* New translations README.md (Japanese)

* New translations README.md (Japanese)

* New translations README.md (Japanese)

* New translations README.md (Japanese)

* New translations README.md (Japanese)

* New translations README.md (Japanese)

* New translations README.md (Japanese)

* New translations README.md (French)

* New translations README.md (French)

* New translations README.md (French)

* New translations README.md (French)

* New translations README.md (French)

* New translations README.md (French)

* New translations README.md (French)

* New translations README.md (French)

* New translations README.md (French)

* New translations README.md (French)

* New translations README.md (French)

* New translations README.md (French)

* New translations README.md (French)

* New translations README.md (French)

* New translations README.md (French)

* New translations README.md (French)

* New translations README.md (French)

* New translations README.md (French)

* New translations README.md (French)

* New translations README.md (French)

* New translations README.md (French)

* New translations README.md (French)

* New translations README.md (French)

* New translations README.md (French)

* New translations README.md (Spanish)

* New translations README.md (Chinese Traditional)

* New translations README.md (Russian)

* New translations README.md (Turkish)

* New translations README.md (Turkish)

* New translations README.md (Chinese Simplified)

* New translations README.md (Chinese Simplified)

* New translations README.md (Chinese Traditional)

* New translations README.md (Vietnamese)

* New translations README.md (Portuguese)

* New translations README.md (Vietnamese)

* New translations README.md (Portuguese, Brazilian)

* New translations README.md (Portuguese, Brazilian)

* New translations README.md (Indonesian)

* New translations README.md (Indonesian)

* New translations README.md (Sorani (Kurdish))

* New translations README.md (Russian)

* New translations README.md (Portuguese)

* New translations README.md (French)

* New translations README.md (Italian)

* New translations README.md (French)

* New translations README.md (Spanish)

* New translations README.md (Arabic)

* New translations README.md (Arabic)

* New translations README.md (German)

* New translations README.md (German)

* New translations README.md (Italian)

* New translations README.md (Polish)

* New translations README.md (Japanese)

* New translations README.md (Japanese)

* New translations README.md (Korean)

* New translations README.md (Korean)

* New translations README.md (Dutch)

* New translations README.md (Dutch)

* New translations README.md (Polish)

* New translations README.md (Sorani (Kurdish))

* New translations README.md (Spanish)

* New translations README.md (Spanish)

* New translations README.md (Spanish)

* New translations README.md (Russian)

* New translations README.md (Indonesian)

* New translations README.md (Portuguese, Brazilian)

* New translations README.md (Vietnamese)

* New translations README.md (Chinese Traditional)

* New translations README.md (Chinese Simplified)

* New translations README.md (Turkish)

* New translations README.md (Portuguese)

* New translations README.md (French)

* New translations README.md (Polish)

* New translations README.md (Dutch)

* New translations README.md (Korean)

* New translations README.md (Japanese)

* New translations README.md (Italian)

* New translations README.md (German)

* New translations README.md (Arabic)

* New translations README.md (Sorani (Kurdish))

* New translations README.md (Spanish)

* New translations README.md (Russian)

* New translations README.md (Indonesian)

* New translations README.md (Portuguese, Brazilian)

* New translations README.md (Vietnamese)

* New translations README.md (Chinese Traditional)

* New translations README.md (Chinese Simplified)

* New translations README.md (Turkish)

* New translations README.md (Portuguese)

* New translations README.md (French)

* New translations README.md (Polish)

* New translations README.md (Dutch)

* New translations README.md (Korean)

* New translations README.md (Japanese)

* New translations README.md (Italian)

* New translations README.md (German)

* New translations README.md (Arabic)

* New translations README.md (Sorani (Kurdish))

* New translations README.md (Spanish)

* New translations README.md (Korean)

* New translations README.md (Japanese)

* New translations README.md (Italian)

* New translations README.md (German)

* New translations README.md (Arabic)

* New translations README.md (French)

* New translations README.md (Chinese Simplified)

* New translations README.md (Chinese Traditional)

* New translations README.md (Portuguese, Brazilian)

* New translations README.md (Vietnamese)

* New translations README.md (Polish)

* New translations README.md (Turkish)

* New translations README.md (Russian)

* New translations README.md (Portuguese)

* New translations README.md (Dutch)

* New translations README.md (Indonesian)

* New translations README.md (Sorani (Kurdish))

* New translations README.md (Spanish)

* New translations README.md (Spanish)

* New translations README.md (Spanish)

* New translations README.md (Spanish)

* New translations README.md (Spanish)

* New translations README.md (Spanish)

* New translations README.md (Spanish)

* New translations README.md (Spanish)

* New translations README.md (Spanish)

* New translations README.md (Spanish)

* New translations README.md (Spanish)

* New translations README.md (Spanish)

* New translations README.md (Spanish)

* New translations README.md (Spanish)

* New translations README.md (Spanish)

* New translations README.md (Spanish)

* New translations README.md (Spanish)

* New translations README.md (Spanish)

* New translations README.md (Spanish)

* New translations README.md (Spanish)

* New translations README.md (Spanish)

* New translations bracketed-segments.md (Spanish)

* New translations nerd-font.md (Spanish)

* New translations no-runtimes.md (Spanish)

* New translations plain-text.md (Spanish)

* New translations pure-preset.md (Spanish)

* New translations pastel-powerline.md (Spanish)

* New translations README.md (Chinese Simplified)

* New translations README.md (Arabic)

* New translations README.md (German)

* New translations README.md (Italian)

* New translations README.md (Japanese)

* New translations README.md (French)

* New translations README.md (Japanese)

* New translations README.md (Russian)

* New translations README.md (Chinese Simplified)

* New translations README.md (Chinese Traditional)

* New translations README.md (Vietnamese)

* New translations README.md (Portuguese, Brazilian)

* New translations README.md (Indonesian)

* New translations README.md (Spanish)

* New translations README.md (Russian)

* New translations README.md (Indonesian)

* New translations README.md (Portuguese, Brazilian)

* New translations README.md (Vietnamese)

* New translations README.md (Chinese Traditional)

* New translations README.md (Chinese Simplified)

* New translations README.md (Turkish)

* New translations README.md (Portuguese)

* New translations README.md (French)

* New translations README.md (Polish)

* New translations README.md (Dutch)

* New translations README.md (Korean)

* New translations README.md (Japanese)

* New translations README.md (Italian)

* New translations README.md (German)

* New translations README.md (Arabic)

* New translations README.md (Sorani (Kurdish))

* New translations README.md (Japanese)

* New translations README.md (Japanese)

* New translations README.md (Spanish)

* New translations README.md (Russian)

* New translations README.md (Indonesian)

* New translations README.md (Portuguese, Brazilian)

* New translations README.md (Vietnamese)

* New translations README.md (Chinese Traditional)

* New translations README.md (Chinese Simplified)

* New translations README.md (Turkish)

* New translations README.md (Portuguese)

* New translations README.md (French)

* New translations README.md (Polish)

* New translations README.md (Dutch)

* New translations README.md (Korean)

* New translations README.md (Japanese)

* New translations README.md (Italian)

* New translations README.md (German)

* New translations README.md (Arabic)

* New translations README.md (Sorani (Kurdish))
This commit is contained in:
Matan Kushner 2022-04-18 09:48:28 -05:00 committed by GitHub
parent 2e9516398d
commit 6a187dcbd7
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
102 changed files with 6681 additions and 5008 deletions

View File

@ -120,7 +120,7 @@ description: Starship is the minimal, blazing fast, and extremely customizable p
#### Elvish #### Elvish
::: warning يدعم فقط elvish v0.17 أو أعلى. ::: ::: warning يدعم فقط elvish v0.18 أو أعلى. :::
أضف ما يلي إلى نهاية `~/.elvish/rc.elv`: أضف ما يلي إلى نهاية `~/.elvish/rc.elv`:

View File

@ -131,7 +131,7 @@ Invoke-Expression (&starship init powershell)
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`. 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). 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, xonsh, cmd. `right_format` is currently supported for the following shells: elvish, fish, zsh, xonsh, cmd.

View File

@ -9,6 +9,9 @@ mkdir -p ~/.config && touch ~/.config/starship.toml
All configuration for starship is done in this [TOML](https://github.com/toml-lang/toml) file: All configuration for starship is done in this [TOML](https://github.com/toml-lang/toml) file:
```toml ```toml
# Get editor completions based on the config schema
"$schema" = 'https://starship.rs/config-schema.json'
# Inserts a blank line between shell prompts # Inserts a blank line between shell prompts
add_newline = true add_newline = true
@ -199,6 +202,7 @@ $hg_branch\
$docker_context\ $docker_context\
$package\ $package\
$buf\ $buf\
$c\
$cmake\ $cmake\
$cobol\ $cobol\
$container\ $container\
@ -235,6 +239,7 @@ $vagrant\
$zig\ $zig\
$nix_shell\ $nix_shell\
$conda\ $conda\
$spack\
$memory_usage\ $memory_usage\
$aws\ $aws\
$gcloud\ $gcloud\
@ -263,9 +268,9 @@ format = "$all$directory$character"
## AWS ## AWS
The `aws` module shows the current AWS region and profile when credentials, a `credential_process` or a `sso_start_url` have been setup. 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. The `aws` module shows the current AWS region and profile when credentials, a `credential_process` or a `sso_start_url` have been setup. Alternatively, you can force this module to show the region and profile even when the credentials have not been setup with the `force_display` option. 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.
The module will display a profile only if its credentials are present in `~/.aws/credentials` or a `credential_process` is defined in `~/.aws/config`. Alternatively, having any of the `AWS_ACCESS_KEY_ID`, `AWS_SECRET_ACCESS_KEY`, or `AWS_SESSION_TOKEN` env vars defined will also suffice. The module will display a profile only if its credentials are present in `~/.aws/credentials` or a `credential_process` is defined in `~/.aws/config`. Alternatively, having any of the `AWS_ACCESS_KEY_ID`, `AWS_SECRET_ACCESS_KEY`, or `AWS_SESSION_TOKEN` env vars defined will also suffice. If the option `force_display` is set to `true`, all available information will be displayed even if the conditions above are not respected.
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. 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.
@ -275,15 +280,16 @@ When using [AWSume](https://awsu.me) the profile is read from the `AWSUME_PROFIL
### Options ### Options
| Option | الافتراضي | الوصف | | Option | الافتراضي | الوصف |
| ------------------- | -------------------------------------------------------------------- | ----------------------------------------------------------------- | | ------------------- | -------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------- |
| `format` | `'on [$symbol($profile )(\($region\) )(\[$duration\])]($style)'` | The format for the module. | | `format` | `'on [$symbol($profile )(\($region\) )(\[$duration\])]($style)'` | The format for the module. |
| `symbol` | `"☁️ "` | The symbol used before displaying the current AWS profile. | | `symbol` | `"☁️ "` | The symbol used before displaying the current AWS profile. |
| `region_aliases` | | Table of region aliases to display in addition to the AWS name. | | `region_aliases` | | Table of region aliases to display in addition to the AWS name. |
| `profile_aliases` | | Table of profile aliases to display in addition to the AWS name. | | `profile_aliases` | | Table of profile aliases to display in addition to the AWS name. |
| `style` | `"bold yellow"` | The style for the module. | | `style` | `"bold yellow"` | The style for the module. |
| `expiration_symbol` | `X` | The symbol displayed when the temporary credentials have expired. | | `expiration_symbol` | `X` | The symbol displayed when the temporary credentials have expired. |
| `disabled` | `false` | Disables the `AWS` module. | | `disabled` | `false` | Disables the `AWS` module. |
| `force_display` | `false` | If `true` displays info even if `credentials`, `credential_process` or `sso_start_url` have not been setup. |
### Variables ### Variables
@ -472,6 +478,52 @@ The `buf` module shows the currently installed version of [Buf](https://buf.buil
symbol = "🦬 " symbol = "🦬 "
``` ```
## C
The `c` module shows some information about your C compiler. By default the module will be shown if the current directory contains a `.c` or `.h` file.
### Options
| Option | الافتراضي | الوصف |
| ------------------- | --------------------------------------------------------------------------- | ------------------------------------------------------------------------- |
| `format` | `"via [$symbol($version(-$name) )]($style)"` | The format string for the module. |
| `version_format` | `"v${raw}"` | The version format. Available vars are `raw`, `major`, `minor`, & `patch` |
| `symbol` | `"C "` | The symbol used before displaying the compiler details |
| `detect_extensions` | `["c", "h"]` | Which extensions should trigger this module. |
| `detect_files` | `[]` | Which filenames should trigger this module. |
| `detect_folders` | `[]` | Which folders should trigger this module. |
| `commands` | [ [ "cc", "--version" ], [ "gcc", "--version" ], [ "clang", "--version" ] ] | How to detect what the compiler is |
| `style` | `"bold 149"` | The style for the module. |
| `disabled` | `false` | Disables the `c` module. |
### Variables
| Variable | مثال | الوصف |
| -------- | ------ | ------------------------------------ |
| name | clang | The name of the compiler |
| version | 13.0.0 | The version of the compiler |
| symbol | | Mirrors the value of option `symbol` |
| style | | Mirrors the value of option `style` |
NB that `version` is not in the default format.
### Commands
The `commands` option accepts a list of commands to determine the compiler version and name.
Each command is represented as a list of the executable name, followed by its arguments, usually something like `["mycc", "--version"]`. Starship will try executing each command until it gets a result on STDOUT.
If a C compiler is not supported by this module, you can request it by [raising an issue on GitHub](https://github.com/starship/starship/).
### مثال
```toml
# ~/.config/starship.toml
[c]
format = "via [$name $version]($style)"
```
## Character ## Character
The `character` module shows a character (usually an arrow) beside where the text is entered in your terminal. The `character` module shows a character (usually an arrow) beside where the text is entered in your terminal.
@ -962,7 +1014,7 @@ You'll also need the .NET Core SDK installed in order to use it correctly.
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. 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 (<https://docs.microsoft.com/en-us/dotnet/standard/frameworks#supported-target-framework-versions>) when there is a csproj file in the current directory. The module will also show the Target Framework Moniker (<https://docs.microsoft.com/en-us/dotnet/standard/frameworks#supported-target-frameworks>) when there is a `.csproj` file in the current directory.
### Options ### Options
@ -1103,13 +1155,13 @@ default = "unknown user"
### Options ### Options
| Option | الافتراضي | الوصف | | Option | الافتراضي | الوصف |
| ---------- | ------------------------------ | ---------------------------------------------------------------------------- | | ----------- | ------------------------------ | ---------------------------------------------------------------------------- |
| `symbol` | `""` | The symbol used before displaying the variable value. | | `symbol` | `""` | The symbol used before displaying the variable value. |
| `variable` | | The environment variable to be displayed. | | `variable` | | The environment variable to be displayed. |
| `default` | | The default value to be displayed when the selected variable is not defined. | | `الافتراضي` | | The default value to be displayed when the selected variable is not defined. |
| `format` | `"with [$env_value]($style) "` | The format for the module. | | `format` | `"with [$env_value]($style) "` | The format for the module. |
| `disabled` | `false` | Disables the `env_var` module. | | `disabled` | `false` | Disables the `env_var` module. |
### Variables ### Variables
@ -1234,7 +1286,7 @@ The `gcloud` module shows the current configuration for [`gcloud`](https://cloud
| account | `foo` | The current GCP profile | | account | `foo` | The current GCP profile |
| domain | `example.com` | The current GCP profile domain | | domain | `example.com` | The current GCP profile domain |
| project | | The current GCP project | | project | | The current GCP project |
| active | `default` | The active config name written in `~/.config/gcloud/active_config` | | active | `الافتراضي` | The active config name written in `~/.config/gcloud/active_config` |
| symbol | | Mirrors the value of option `symbol` | | symbol | | Mirrors the value of option `symbol` |
| style\* | | Mirrors the value of option `style` | | style\* | | Mirrors the value of option `style` |
@ -2969,6 +3021,39 @@ The `singularity` module shows the current [Singularity](https://sylabs.io/singu
format = '[📦 \[$env\]]($style) ' format = '[📦 \[$env\]]($style) '
``` ```
## Spack
The `spack` module shows the current [Spack](https://spack.readthedocs.io/en/latest/) environment, if `$SPACK_ENV` is set.
### Options
| Option | الافتراضي | الوصف |
| ------------------- | -------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------- |
| `truncation_length` | `1` | The number of directories the environment path should be truncated to. `0` means no truncation. Also see the [`directory`](#directory) module. |
| `symbol` | `"🅢 "` | The symbol used before the environment name. |
| `style` | `"bold blue"` | The style for the module. |
| `format` | `"via [$symbol$environment]($style) "` | The format for the module. |
| `disabled` | `false` | Disables the `spack` module. |
### Variables
| Variable | مثال | الوصف |
| ----------- | ------------ | ------------------------------------ |
| environment | `astronauts` | The current spack environment |
| symbol | | Mirrors the value of option `symbol` |
| style\* | | Mirrors the value of option `style` |
*: This variable can only be used as a part of a style string
### مثال
```toml
# ~/.config/starship.toml
[spack]
format = "[$symbol$environment](dimmed blue) "
```
## Status ## Status
The `status` module displays the exit code of the previous command. If $success_symbol is empty (default), the module will be shown only if the exit code is not `0`. The status code will cast to a signed 32-bit integer. The `status` module displays the exit code of the previous command. If $success_symbol is empty (default), the module will be shown only if the exit code is not `0`. The status code will cast to a signed 32-bit integer.
@ -3147,12 +3232,12 @@ By default the module will be shown if any of the following conditions are met:
### Variables ### Variables
| Variable | مثال | الوصف | | Variable | مثال | الوصف |
| --------- | ---------- | ------------------------------------ | | --------- | ----------- | ------------------------------------ |
| version | `v0.12.24` | The version of `terraform` | | version | `v0.12.24` | The version of `terraform` |
| workspace | `default` | The current Terraform workspace | | workspace | `الافتراضي` | The current Terraform workspace |
| symbol | | Mirrors the value of option `symbol` | | symbol | | Mirrors the value of option `symbol` |
| style\* | | Mirrors the value of option `style` | | style\* | | Mirrors the value of option `style` |
*: This variable can only be used as a part of a style string *: This variable can only be used as a part of a style string
@ -3226,7 +3311,7 @@ time_range = "10:00:00-14:00:00"
The `username` module shows active user's username. The module will be shown if any of the following conditions are met: 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 is root/admin
- The current user isn't the same as the one that is logged in - The current user isn't the same as the one that is logged in
- The user is currently connected as an SSH session - The user is currently connected as an SSH session
- The variable `show_always` is set to true - The variable `show_always` is set to true
@ -3239,13 +3324,13 @@ SSH connection is detected by checking environment variables `SSH_CONNECTION`, `
### Options ### Options
| Option | الافتراضي | الوصف | | Option | الافتراضي | الوصف |
| ------------- | ----------------------- | ------------------------------------- | | ------------- | ----------------------- | ------------------------------------------- |
| `style_root` | `"bold red"` | The style used when the user is root. | | `style_root` | `"bold red"` | The style used when the user is root/admin. |
| `style_user` | `"bold yellow"` | The style used for non-root users. | | `style_user` | `"bold yellow"` | The style used for non-root users. |
| `format` | `"[$user]($style) in "` | The format for the module. | | `format` | `"[$user]($style) in "` | The format for the module. |
| `show_always` | `false` | Always shows the `username` module. | | `show_always` | `false` | Always shows the `username` module. |
| `disabled` | `false` | Disables the `username` module. | | `disabled` | `false` | Disables the `username` module. |
### Variables ### Variables
@ -3417,9 +3502,9 @@ The `custom` modules show the output of some arbitrary commands.
These modules will be shown if any of the following conditions are met: These modules will be shown if any of the following conditions are met:
- The current directory contains a file whose name is in `files` - The current directory contains a file whose name is in `detect_files`
- The current directory contains a directory whose name is in `directories` - The current directory contains a directory whose name is in `detect_folders`
- The current directory contains a file whose extension is in `extensions` - The current directory contains a file whose extension is in `detect_extensions`
- The `when` command returns 0 - The `when` command returns 0
- The current Operating System (std::env::consts::OS) matchs with `os` field if defined. - The current Operating System (std::env::consts::OS) matchs with `os` field if defined.
@ -3451,20 +3536,22 @@ Format strings can also contain shell specific prompt sequences, e.g. [Bash](htt
### Options ### Options
| Option | الافتراضي | الوصف | | Option | الافتراضي | الوصف |
| ------------- | ------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | | ------------------- | ------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `command` | `""` | The command whose output should be printed. The command will be passed on stdin to the shell. | | `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. | | `when` | `false` | Either a boolean value (`true` or `false`, without quotes) or a string shell command used as a condition to show the module. In case of a string, the module will be shown if the command returns a `0` status code. |
| `shell` | | [See below](#custom-command-shell) | | `shell` | | [See below](#custom-command-shell) |
| `description` | `"<custom module>"` | The description of the module that is shown when running `starship explain`. | | `الوصف` | `"<custom module>"` | 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. | | `detect_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. | | `detect_folders` | `[]` | 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. | | `detect_extensions` | `[]` | The extensions that will be searched in the working directory for a match. |
| `symbol` | `""` | The symbol used before displaying the command output. | | `symbol` | `""` | The symbol used before displaying the command output. |
| `style` | `"bold green"` | The style for the module. | | `style` | `"bold green"` | The style for the module. |
| `format` | `"[$symbol($output )]($style)"` | The format for the module. | | `format` | `"[$symbol($output )]($style)"` | The format for the module. |
| `disabled` | `false` | Disables this `custom` 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). | | `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). |
| `use_stdin` | | An optional boolean value that overrides whether commands should be forwarded to the shell via the standard input or as an argument. If unset standard input is used by default, unless the shell does not support it (cmd, nushell). Setting this disables shell-specific argument handling. |
| `ignore_timeout` | `false` | Ignore global `command_timeout` setting and keep running external commands, no matter how long they take. |
### Variables ### Variables
@ -3487,7 +3574,7 @@ If unset, it will fallback to STARSHIP_SHELL and then to "sh" on Linux, and "cmd
The `command` will be passed in on stdin. The `command` will be passed in on stdin.
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. 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 -`. If `shell` is not given or only contains one element and Starship detects Cmd will be used, the following argument will automatically be added: `/C` and `stdin` will be set to `false`. If `shell` is not given or only contains one element and Starship detects Nushell will be used, the following arguments will automatically be added: `-c` and `stdin` will be set to `false`. This behavior can be avoided by explicitly passing arguments to the shell, e.g.
```toml ```toml
shell = ["pwsh", "-Command", "-"] shell = ["pwsh", "-Command", "-"]
@ -3512,12 +3599,18 @@ Automatic detection of shells and proper parameters addition are currently imple
[custom.foo] [custom.foo]
command = "echo foo" # shows output of command command = "echo foo" # shows output of command
files = ["foo"] # can specify filters but wildcards are not supported detect_files = ["foo"] # can specify filters but wildcards are not supported
when = """ test "$HOME" == "$PWD" """ when = """ test "$HOME" == "$PWD" """
format = " transcending [$output]($style)" format = " transcending [$output]($style)"
[custom.time] [custom.time]
command = "time /T" command = "time /T"
extensions = ["pst"] # filters *.pst files detect_extensions = ["pst"] # filters *.pst files
shell = ["pwsh.exe", "-NoProfile", "-Command", "-"] shell = ["pwsh.exe", "-NoProfile", "-Command", "-"]
[custom.time-as-arg]
command = "time /T"
detect_extensions = ["pst"] # filters *.pst files
shell = ["pwsh.exe", "-NoProfile", "-Command"]
use_stdin = false
``` ```

View File

@ -160,7 +160,7 @@
- **سهل:** سريع التثبيت استخدمه في دقائق. - **سهل:** سريع التثبيت استخدمه في دقائق.
<p align="center"> <p align="center">
<a href="https://starship.rs/config/"><strong>Explore the Starship docs&nbsp;&nbsp;</strong></a> <a href="https://starship.rs/config/"><strong>تصفّح مستندات Starship&nbsp;&nbsp;</strong></a>
</p> </p>
<a name="🚀-installation"></a> <a name="🚀-installation"></a>
@ -297,7 +297,7 @@ load(io.popen('starship init cmd'):read("*a"))()
eval (starship init elvish) eval (starship init elvish)
``` ```
Note: Only Elvish v0.17+ is supported Note: Only Elvish v0.18+ is supported
</details> </details>
@ -400,15 +400,15 @@ If you're looking to further customize Starship:
## 🤝 المساهمة ## 🤝 المساهمة
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). نبحث دائماً عن مساهمين من **جميع المستويات**! إذا كنت تتطلع إلى تسهيل طريقك إلى المشروع، جرب [إنشاء اول مشكلة](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/). إذا كنت تتحدث بطلاقة بلغة غير إنجليزية، فإننا نقدر أي مساعدة للحفاظ على ترجمة المستندات وتحديثها بلغات أخرى. إذا كنت ترغب في المساعدة، يمكن المساهمة بالترجمة على [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. 👋 إذا كنت مهتما بالمساهمة في starship، يرجى إلقاء نظرة على [دليل المساهمة](https://github.com/starship/starship/blob/master/CONTRIBUTING.md) لدينا. أيضا، لا تتردد في أن تنضم لنا في [Discord](https://discord.gg/8Jzqu3T) وقُل مرحبا. 👋
## 💭 مستوحاة من قبل ## 💭 مستوحاة من قبل
Please check out these previous works that helped inspire the creation of starship. 🙏 يرجى التحقق من هذه الأعمال السابقة التي ساعدت على إنشاء starship. 🙏
- **[denysdovhan/spaceship-prompt](https://github.com/denysdovhan/spaceship-prompt)** A ZSH prompt for astronauts. - **[denysdovhan/spaceship-prompt](https://github.com/denysdovhan/spaceship-prompt)** A ZSH prompt for astronauts.

View File

@ -1,4 +1,4 @@
# Advanced Installation # التثبيت المتقدم
To install starship, you need to do two things: To install starship, you need to do two things:

View File

@ -120,7 +120,7 @@ description: 'Starship: یەکێ لە promptـە سوکەڵە، خێرا، و ب
#### Elvish #### Elvish
::: warning تەنها elvish v0.17 یان بەرزتر پشتگیری کراوە. ::: ::: warning تەنها elvish v0.18 یان بەرزتر پشتگیری کراوە. :::
ئەمەی خوارەوە زیادبکە لە کۆتایی `~/.elvish/rc.elv`: ئەمەی خوارەوە زیادبکە لە کۆتایی `~/.elvish/rc.elv`:

View File

@ -131,7 +131,7 @@ Invoke-Expression (&starship init powershell)
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`. 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). 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, xonsh, cmd. `right_format` is currently supported for the following shells: elvish, fish, zsh, xonsh, cmd.

View File

@ -9,6 +9,9 @@ mkdir -p ~/.config && touch ~/.config/starship.toml
هەموو ڕێکخستنەکان بۆ Starship ئەنجام ئەدرێن لەم پەڕگەی [TOML](https://github.com/toml-lang/toml)ـەدا: هەموو ڕێکخستنەکان بۆ Starship ئەنجام ئەدرێن لەم پەڕگەی [TOML](https://github.com/toml-lang/toml)ـەدا:
```toml ```toml
# Get editor completions based on the config schema
"$schema" = 'https://starship.rs/config-schema.json'
# Inserts a blank line between shell prompts # Inserts a blank line between shell prompts
add_newline = true add_newline = true
@ -199,6 +202,7 @@ $hg_branch\
$docker_context\ $docker_context\
$package\ $package\
$buf\ $buf\
$c\
$cmake\ $cmake\
$cobol\ $cobol\
$container\ $container\
@ -235,6 +239,7 @@ $vagrant\
$zig\ $zig\
$nix_shell\ $nix_shell\
$conda\ $conda\
$spack\
$memory_usage\ $memory_usage\
$aws\ $aws\
$gcloud\ $gcloud\
@ -263,9 +268,9 @@ format = "$all$directory$character"
## AWS ## AWS
The `aws` module shows the current AWS region and profile when credentials, a `credential_process` or a `sso_start_url` have been setup. 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. The `aws` module shows the current AWS region and profile when credentials, a `credential_process` or a `sso_start_url` have been setup. Alternatively, you can force this module to show the region and profile even when the credentials have not been setup with the `force_display` option. 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.
The module will display a profile only if its credentials are present in `~/.aws/credentials` or a `credential_process` is defined in `~/.aws/config`. Alternatively, having any of the `AWS_ACCESS_KEY_ID`, `AWS_SECRET_ACCESS_KEY`, or `AWS_SESSION_TOKEN` env vars defined will also suffice. The module will display a profile only if its credentials are present in `~/.aws/credentials` or a `credential_process` is defined in `~/.aws/config`. Alternatively, having any of the `AWS_ACCESS_KEY_ID`, `AWS_SECRET_ACCESS_KEY`, or `AWS_SESSION_TOKEN` env vars defined will also suffice. If the option `force_display` is set to `true`, all available information will be displayed even if the conditions above are not respected.
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. 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.
@ -275,15 +280,16 @@ When using [AWSume](https://awsu.me) the profile is read from the `AWSUME_PROFIL
### Options ### Options
| Option | Default | Description | | Option | Default | Description |
| ------------------- | -------------------------------------------------------------------- | ----------------------------------------------------------------- | | ------------------- | -------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------- |
| `format` | `'on [$symbol($profile )(\($region\) )(\[$duration\])]($style)'` | The format for the module. | | `format` | `'on [$symbol($profile )(\($region\) )(\[$duration\])]($style)'` | The format for the module. |
| `symbol` | `"☁️ "` | The symbol used before displaying the current AWS profile. | | `symbol` | `"☁️ "` | The symbol used before displaying the current AWS profile. |
| `region_aliases` | | Table of region aliases to display in addition to the AWS name. | | `region_aliases` | | Table of region aliases to display in addition to the AWS name. |
| `profile_aliases` | | Table of profile aliases to display in addition to the AWS name. | | `profile_aliases` | | Table of profile aliases to display in addition to the AWS name. |
| `style` | `"bold yellow"` | The style for the module. | | `style` | `"bold yellow"` | The style for the module. |
| `expiration_symbol` | `X` | The symbol displayed when the temporary credentials have expired. | | `expiration_symbol` | `X` | The symbol displayed when the temporary credentials have expired. |
| `disabled` | `false` | Disables the `AWS` module. | | `disabled` | `false` | Disables the `AWS` module. |
| `force_display` | `false` | If `true` displays info even if `credentials`, `credential_process` or `sso_start_url` have not been setup. |
### Variables ### Variables
@ -472,6 +478,52 @@ The `buf` module shows the currently installed version of [Buf](https://buf.buil
symbol = "🦬 " symbol = "🦬 "
``` ```
## C
The `c` module shows some information about your C compiler. By default the module will be shown if the current directory contains a `.c` or `.h` file.
### Options
| Option | Default | Description |
| ------------------- | --------------------------------------------------------------------------- | ------------------------------------------------------------------------- |
| `format` | `"via [$symbol($version(-$name) )]($style)"` | The format string for the module. |
| `version_format` | `"v${raw}"` | The version format. Available vars are `raw`, `major`, `minor`, & `patch` |
| `symbol` | `"C "` | The symbol used before displaying the compiler details |
| `detect_extensions` | `["c", "h"]` | Which extensions should trigger this module. |
| `detect_files` | `[]` | Which filenames should trigger this module. |
| `detect_folders` | `[]` | Which folders should trigger this module. |
| `commands` | [ [ "cc", "--version" ], [ "gcc", "--version" ], [ "clang", "--version" ] ] | How to detect what the compiler is |
| `style` | `"bold 149"` | The style for the module. |
| `disabled` | `false` | Disables the `c` module. |
### Variables
| گۆڕاو | نموونە | Description |
| ------- | ------ | ------------------------------------ |
| name | clang | The name of the compiler |
| version | 13.0.0 | The version of the compiler |
| symbol | | Mirrors the value of option `symbol` |
| style | | Mirrors the value of option `style` |
NB that `version` is not in the default format.
### Commands
The `commands` option accepts a list of commands to determine the compiler version and name.
Each command is represented as a list of the executable name, followed by its arguments, usually something like `["mycc", "--version"]`. Starship will try executing each command until it gets a result on STDOUT.
If a C compiler is not supported by this module, you can request it by [raising an issue on GitHub](https://github.com/starship/starship/).
### نموونە
```toml
# ~/.config/starship.toml
[c]
format = "via [$name $version]($style)"
```
## Character ## Character
The `character` module shows a character (usually an arrow) beside where the text is entered in your terminal. The `character` module shows a character (usually an arrow) beside where the text is entered in your terminal.
@ -962,7 +1014,7 @@ You'll also need the .NET Core SDK installed in order to use it correctly.
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. 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 (<https://docs.microsoft.com/en-us/dotnet/standard/frameworks#supported-target-framework-versions>) when there is a csproj file in the current directory. The module will also show the Target Framework Moniker (<https://docs.microsoft.com/en-us/dotnet/standard/frameworks#supported-target-frameworks>) when there is a `.csproj` file in the current directory.
### Options ### Options
@ -1106,7 +1158,7 @@ default = "unknown user"
| Option | Default | Description | | Option | Default | Description |
| ---------- | ------------------------------ | ---------------------------------------------------------------------------- | | ---------- | ------------------------------ | ---------------------------------------------------------------------------- |
| `symbol` | `""` | The symbol used before displaying the variable value. | | `symbol` | `""` | The symbol used before displaying the variable value. |
| `variable` | | The environment variable to be displayed. | | `گۆڕاو` | | The environment variable to be displayed. |
| `default` | | The default value to be displayed when the selected variable is not defined. | | `default` | | The default value to be displayed when the selected variable is not defined. |
| `format` | `"with [$env_value]($style) "` | The format for the module. | | `format` | `"with [$env_value]($style) "` | The format for the module. |
| `disabled` | `false` | Disables the `env_var` module. | | `disabled` | `false` | Disables the `env_var` module. |
@ -2182,12 +2234,12 @@ The `nix_shell` module shows the [nix-shell](https://nixos.org/guides/nix-pills/
### Variables ### Variables
| گۆڕاو | نموونە | Description | | گۆڕاو | نموونە | Description |
| --------- | ------- | ------------------------------------ | | --------- | -------- | ------------------------------------ |
| state | `pure` | The state of the nix-shell | | state | `بێخەوش` | The state of the nix-shell |
| name | `lorri` | The name of the nix-shell | | name | `lorri` | The name of the nix-shell |
| symbol | | Mirrors the value of option `symbol` | | symbol | | Mirrors the value of option `symbol` |
| style\* | | Mirrors the value of option `style` | | style\* | | Mirrors the value of option `style` |
*: This variable can only be used as a part of a style string *: This variable can only be used as a part of a style string
@ -2969,6 +3021,39 @@ The `singularity` module shows the current [Singularity](https://sylabs.io/singu
format = '[📦 \[$env\]]($style) ' format = '[📦 \[$env\]]($style) '
``` ```
## Spack
The `spack` module shows the current [Spack](https://spack.readthedocs.io/en/latest/) environment, if `$SPACK_ENV` is set.
### Options
| Option | Default | Description |
| ------------------- | -------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------- |
| `truncation_length` | `1` | The number of directories the environment path should be truncated to. `0` means no truncation. Also see the [`directory`](#directory) module. |
| `symbol` | `"🅢 "` | The symbol used before the environment name. |
| `style` | `"bold blue"` | The style for the module. |
| `format` | `"via [$symbol$environment]($style) "` | The format for the module. |
| `disabled` | `false` | Disables the `spack` module. |
### Variables
| گۆڕاو | نموونە | Description |
| ----------- | ------------ | ------------------------------------ |
| environment | `astronauts` | The current spack environment |
| symbol | | Mirrors the value of option `symbol` |
| style\* | | Mirrors the value of option `style` |
*: This variable can only be used as a part of a style string
### نموونە
```toml
# ~/.config/starship.toml
[spack]
format = "[$symbol$environment](dimmed blue) "
```
## Status ## Status
The `status` module displays the exit code of the previous command. If $success_symbol is empty (default), the module will be shown only if the exit code is not `0`. The status code will cast to a signed 32-bit integer. The `status` module displays the exit code of the previous command. If $success_symbol is empty (default), the module will be shown only if the exit code is not `0`. The status code will cast to a signed 32-bit integer.
@ -3226,7 +3311,7 @@ time_range = "10:00:00-14:00:00"
The `username` module shows active user's username. The module will be shown if any of the following conditions are met: 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 is root/admin
- The current user isn't the same as the one that is logged in - The current user isn't the same as the one that is logged in
- The user is currently connected as an SSH session - The user is currently connected as an SSH session
- The variable `show_always` is set to true - The variable `show_always` is set to true
@ -3239,13 +3324,13 @@ SSH connection is detected by checking environment variables `SSH_CONNECTION`, `
### Options ### Options
| Option | Default | Description | | Option | Default | Description |
| ------------- | ----------------------- | ------------------------------------- | | ------------- | ----------------------- | ------------------------------------------- |
| `style_root` | `"bold red"` | The style used when the user is root. | | `style_root` | `"bold red"` | The style used when the user is root/admin. |
| `style_user` | `"bold yellow"` | The style used for non-root users. | | `style_user` | `"bold yellow"` | The style used for non-root users. |
| `format` | `"[$user]($style) in "` | The format for the module. | | `format` | `"[$user]($style) in "` | The format for the module. |
| `show_always` | `false` | Always shows the `username` module. | | `show_always` | `false` | Always shows the `username` module. |
| `disabled` | `false` | Disables the `username` module. | | `disabled` | `false` | Disables the `username` module. |
### Variables ### Variables
@ -3417,9 +3502,9 @@ The `custom` modules show the output of some arbitrary commands.
These modules will be shown if any of the following conditions are met: These modules will be shown if any of the following conditions are met:
- The current directory contains a file whose name is in `files` - The current directory contains a file whose name is in `detect_files`
- The current directory contains a directory whose name is in `directories` - The current directory contains a directory whose name is in `detect_folders`
- The current directory contains a file whose extension is in `extensions` - The current directory contains a file whose extension is in `detect_extensions`
- The `when` command returns 0 - The `when` command returns 0
- The current Operating System (std::env::consts::OS) matchs with `os` field if defined. - The current Operating System (std::env::consts::OS) matchs with `os` field if defined.
@ -3451,20 +3536,22 @@ Format strings can also contain shell specific prompt sequences, e.g. [Bash](htt
### Options ### Options
| Option | Default | Description | | Option | Default | Description |
| ------------- | ------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | | ------------------- | ------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `command` | `""` | The command whose output should be printed. The command will be passed on stdin to the shell. | | `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. | | `when` | `false` | Either a boolean value (`true` or `false`, without quotes) or a string shell command used as a condition to show the module. In case of a string, the module will be shown if the command returns a `0` status code. |
| `shell` | | [See below](#custom-command-shell) | | `shell` | | [See below](#custom-command-shell) |
| `description` | `"<custom module>"` | The description of the module that is shown when running `starship explain`. | | `description` | `"<custom module>"` | The description of the module that is shown when running `starship explain`. |
| `files` | `[]` | The files that will be searched in the working directory for a match. | | `detect_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. | | `detect_folders` | `[]` | 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. | | `detect_extensions` | `[]` | The extensions that will be searched in the working directory for a match. |
| `symbol` | `""` | The symbol used before displaying the command output. | | `symbol` | `""` | The symbol used before displaying the command output. |
| `style` | `"bold green"` | The style for the module. | | `style` | `"bold green"` | The style for the module. |
| `format` | `"[$symbol($output )]($style)"` | The format for the module. | | `format` | `"[$symbol($output )]($style)"` | The format for the module. |
| `disabled` | `false` | Disables this `custom` 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). | | `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). |
| `use_stdin` | | An optional boolean value that overrides whether commands should be forwarded to the shell via the standard input or as an argument. If unset standard input is used by default, unless the shell does not support it (cmd, nushell). Setting this disables shell-specific argument handling. |
| `ignore_timeout` | `false` | Ignore global `command_timeout` setting and keep running external commands, no matter how long they take. |
### Variables ### Variables
@ -3487,7 +3574,7 @@ If unset, it will fallback to STARSHIP_SHELL and then to "sh" on Linux, and "cmd
The `command` will be passed in on stdin. The `command` will be passed in on stdin.
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. 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 -`. If `shell` is not given or only contains one element and Starship detects Cmd will be used, the following argument will automatically be added: `/C` and `stdin` will be set to `false`. If `shell` is not given or only contains one element and Starship detects Nushell will be used, the following arguments will automatically be added: `-c` and `stdin` will be set to `false`. This behavior can be avoided by explicitly passing arguments to the shell, e.g.
```toml ```toml
shell = ["pwsh", "-Command", "-"] shell = ["pwsh", "-Command", "-"]
@ -3512,12 +3599,18 @@ Automatic detection of shells and proper parameters addition are currently imple
[custom.foo] [custom.foo]
command = "echo foo" # shows output of command command = "echo foo" # shows output of command
files = ["foo"] # can specify filters but wildcards are not supported detect_files = ["foo"] # can specify filters but wildcards are not supported
when = """ test "$HOME" == "$PWD" """ when = """ test "$HOME" == "$PWD" """
format = " transcending [$output]($style)" format = " transcending [$output]($style)"
[custom.time] [custom.time]
command = "time /T" command = "time /T"
extensions = ["pst"] # filters *.pst files detect_extensions = ["pst"] # filters *.pst files
shell = ["pwsh.exe", "-NoProfile", "-Command", "-"] shell = ["pwsh.exe", "-NoProfile", "-Command", "-"]
[custom.time-as-arg]
command = "time /T"
detect_extensions = ["pst"] # filters *.pst files
shell = ["pwsh.exe", "-NoProfile", "-Command"]
use_stdin = false
``` ```

View File

@ -141,7 +141,7 @@
<img <img
src="https://raw.githubusercontent.com/starship/starship/master/media/demo.gif" src="https://raw.githubusercontent.com/starship/starship/master/media/demo.gif"
alt="Starship with iTerm2 and the Snazzy theme" alt="Starship لەگەڵ iTerm2 و ڕووکاری Snazzy"
width="50%" width="50%"
align="right" align="right"
/> />
@ -156,7 +156,7 @@
- **ئاسان:** خێرا لە دامەزراندن – دەست ئەکەیت بە بەکارهێنانی لە چەند خولەکێکدا. - **ئاسان:** خێرا لە دامەزراندن – دەست ئەکەیت بە بەکارهێنانی لە چەند خولەکێکدا.
<p align="center"> <p align="center">
<a href="https://starship.rs/config/"><strong>Explore the Starship docs&nbsp;&nbsp;</strong></a> <a href="https://starship.rs/config/"><strong>بەڵگەنامەکانی Starship بگەڕێ&nbsp;&nbsp;</strong></a>
</p> </p>
<a name="🚀-installation"></a> <a name="🚀-installation"></a>
@ -293,7 +293,7 @@ load(io.popen('starship init cmd'):read("*a"))()
eval (starship init elvish) eval (starship init elvish)
``` ```
Note: Only Elvish v0.17+ is supported Note: Only Elvish v0.18+ is supported
</details> </details>
@ -396,15 +396,15 @@ If you're looking to further customize Starship:
## 🤝 بەژداریکردن ## 🤝 بەژداریکردن
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). ئێمە هەموو کات ئەگەڕێین بۆ بەژداریکەرێک لە هەر **ئاست و توانایەکدا بێت**! ئەگەر بەدوای ئەوەوەی کە بێیتە ئەم پڕۆژەیەوە [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/). ئەگەر پاراویت لە زمانێک جگە لە ئینگلیزی، ئێمە زۆر خۆشحاڵدەبین بە هەر یارمەتییەک کە بەڵگەنامەکانمان بە وەرگێڕدراوی بهێڵێتەوە و نوێکراوی بهێڵێتەوە بە زمانەکانی دیکە. ئەگەر نیازت هەیە یارمەتی بدەیت، ئەتوانی بەژداری لە وەرگێڕاندا بکەیت لەسەر [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. 👋 ئەگەر حەزئەکەیت یارمەتی بدەیت بە بەژداریکردن لە starship، تکایە سەیری [ڕێبەری بەژداریکردن](https://github.com/starship/starship/blob/master/CONTRIBUTING.md)ـەکەمان بکە. هەروەها، شەرم مەکە وەرە نێوە [ڕاژەی Discord](https://discord.gg/8Jzqu3T)ـەکەمانەوە و سڵاوێک بکە. 👋
## 💭 ئیلهامبەخشەکان ## 💭 ئیلهامبەخشەکان
Please check out these previous works that helped inspire the creation of starship. 🙏 تکایە ئەم کارە کۆنانە سەیربکەوە کە ئیلهامی دروستکردنی starship دا. 🙏
- **[denysdovhan/spaceship-prompt](https://github.com/denysdovhan/spaceship-prompt)** A ZSH prompt for astronauts. - **[denysdovhan/spaceship-prompt](https://github.com/denysdovhan/spaceship-prompt)** A ZSH prompt for astronauts.
@ -414,9 +414,9 @@ Please check out these previous works that helped inspire the creation of starsh
<p align="center"> <p align="center">
<br> <br>
<img width="100" src="https://raw.githubusercontent.com/starship/starship/master/media/icon.png" alt="Starship rocket icon"> <img width="100" src="https://raw.githubusercontent.com/starship/starship/master/media/icon.png" alt="ئایکۆنی مووشەکی Starship">
</p> </p>
## 📝 مۆڵەتنامە ## 📝 مۆڵەتنامە
Copyright © 2019-present, [Starship Contributors](https://github.com/starship/starship/graphs/contributors).<br /> This project is [ISC](https://github.com/starship/starship/blob/master/LICENSE) licensed. هەموو مافێکی پارێزراوە © 2019-ئێستا، [بەژداریکەرانی Starship](https://github.com/starship/starship/graphs/contributors). <br />ئەم پڕۆژەیە لە ژێر مۆڵەتنامەی [ISC](https://github.com/starship/starship/blob/master/LICENSE)ـە.

View File

@ -120,7 +120,7 @@ description: Starship ist eine minimale, super schnelle, und extrem anpassbare P
#### Elvish #### Elvish
::: warning Nur elvish v0.17 oder höher ist unterstützt. ::: ::: warning Nur elvish v0.18 oder höher ist unterstützt. :::
Trage folgendes am Ende von `~/.config/fish/rc.elv` ein: Trage folgendes am Ende von `~/.config/fish/rc.elv` ein:
@ -169,7 +169,7 @@ description: Starship ist eine minimale, super schnelle, und extrem anpassbare P
``` ```
#### Cmd #### Cmd
You need to use [Clink](https://chrisant996.github.io/clink/clink.html) (v1.2.30+) with Cmd. Add the following to a file `starship.lua` and place this file in Clink scripts directory: You need to use [Clink](https://chrisant996.github.io/clink/clink.html) (v1.2.30+) with Cmd. Add the following to a file `starship.lua` and place this file in Clink scripts directory:

View File

@ -131,7 +131,7 @@ Invoke-Expression (&starship init powershell)
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`. 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). 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, xonsh, cmd. `right_format` is currently supported for the following shells: elvish, fish, zsh, xonsh, cmd.

View File

@ -9,6 +9,9 @@ mkdir -p ~/.config && touch ~/.config/starship.toml
Die gesamte Konfiguration von Starship erfolgt in dieser [TOML](https://github.com/toml-lang/toml)-Datei: Die gesamte Konfiguration von Starship erfolgt in dieser [TOML](https://github.com/toml-lang/toml)-Datei:
```toml ```toml
# Get editor completions based on the config schema
"$schema" = 'https://starship.rs/config-schema.json'
# Inserts a blank line between shell prompts # Inserts a blank line between shell prompts
add_newline = true add_newline = true
@ -199,6 +202,7 @@ $hg_branch\
$docker_context\ $docker_context\
$package\ $package\
$buf\ $buf\
$c\
$cmake\ $cmake\
$cobol\ $cobol\
$container\ $container\
@ -235,6 +239,7 @@ $vagrant\
$zig\ $zig\
$nix_shell\ $nix_shell\
$conda\ $conda\
$spack\
$memory_usage\ $memory_usage\
$aws\ $aws\
$gcloud\ $gcloud\
@ -263,9 +268,9 @@ format = "$all$directory$character"
## AWS ## AWS
The `aws` module shows the current AWS region and profile when credentials, a `credential_process` or a `sso_start_url` have been setup. 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 when credentials, a `credential_process` or a `sso_start_url` have been setup. Alternatively, you can force this module to show the region and profile even when the credentials have not been setup with the `force_display` option. 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 module will display a profile only if its credentials are present in `~/.aws/credentials` or a `credential_process` is defined in `~/.aws/config`. Alternatively, having any of the `AWS_ACCESS_KEY_ID`, `AWS_SECRET_ACCESS_KEY`, or `AWS_SESSION_TOKEN` env vars defined will also suffice. The module will display a profile only if its credentials are present in `~/.aws/credentials` or a `credential_process` is defined in `~/.aws/config`. Alternatively, having any of the `AWS_ACCESS_KEY_ID`, `AWS_SECRET_ACCESS_KEY`, or `AWS_SESSION_TOKEN` env vars defined will also suffice. If the option `force_display` is set to `true`, all available information will be displayed even if the conditions above are not respected.
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. 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.
@ -275,15 +280,16 @@ When using [AWSume](https://awsu.me) the profile is read from the `AWSUME_PROFIL
### Optionen ### Optionen
| Option | Standardwert | Beschreibung | | Option | Standardwert | Beschreibung |
| ------------------- | -------------------------------------------------------------------- | -------------------------------------------------------------------------------- | | ------------------- | -------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------- |
| `format` | `'on [$symbol($profile )(\($region\) )(\[$duration\])]($style)'` | Das Format für das Modul. | | `format` | `'on [$symbol($profile )(\($region\) )(\[$duration\])]($style)'` | Das Format für das Modul. |
| `symbol` | `"☁️ "` | Symbol das vor dem aktuellen AWS-Profil angezeigt wird. | | `symbol` | `"☁️ "` | Symbol das vor dem aktuellen AWS-Profil angezeigt wird. |
| `region_aliases` | | Tabelle der Regionaliasen, die zusätzlich zum AWS-Namen angezeigt werden sollen. | | `region_aliases` | | Tabelle der Regionaliasen, die zusätzlich zum AWS-Namen angezeigt werden sollen. |
| `profile_aliases` | | Table of profile aliases to display in addition to the AWS name. | | `profile_aliases` | | Table of profile aliases to display in addition to the AWS name. |
| `style` | `"bold yellow"` | Stil für dieses Modul. | | `style` | `"bold yellow"` | Stil für dieses Modul. |
| `expiration_symbol` | `X` | The symbol displayed when the temporary credentials have expired. | | `expiration_symbol` | `X` | Das Symbol, das angezeigt wird, wenn die temporären Anmeldeinformationen abgelaufen sind. |
| `disabled` | `false` | Disables the `AWS` module. | | `disabled` | `false` | Deaktiviert das `aws`-Modul. |
| `force_display` | `false` | If `true` displays info even if `credentials`, `credential_process` or `sso_start_url` have not been setup. |
### Variables ### Variables
@ -472,11 +478,57 @@ The `buf` module shows the currently installed version of [Buf](https://buf.buil
symbol = "🦬 " symbol = "🦬 "
``` ```
## C
The `c` module shows some information about your C compiler. By default the module will be shown if the current directory contains a `.c` or `.h` file.
### Optionen
| Option | Standardwert | Beschreibung |
| ------------------- | --------------------------------------------------------------------------- | ------------------------------------------------------------------------- |
| `format` | `"via [$symbol($version(-$name) )]($style)"` | The format string for the module. |
| `version_format` | `"v${raw}"` | The version format. Available vars are `raw`, `major`, `minor`, & `patch` |
| `symbol` | `"C "` | The symbol used before displaying the compiler details |
| `detect_extensions` | `["c", "h"]` | Which extensions should trigger this module. |
| `detect_files` | `[]` | Which filenames should trigger this module. |
| `detect_folders` | `[]` | Which folders should trigger this module. |
| `commands` | [ [ "cc", "--version" ], [ "gcc", "--version" ], [ "clang", "--version" ] ] | How to detect what the compiler is |
| `style` | `"bold 149"` | Stil für dieses Modul. |
| `disabled` | `false` | Disables the `c` module. |
### Variables
| Variable | Beispiel | Beschreibung |
| -------- | -------- | ------------------------------------- |
| name | clang | The name of the compiler |
| version | 13.0.0 | The version of the compiler |
| symbol | | Spiegelt den Wert der Option `symbol` |
| style | | Spiegelt den Wert der Option `style` |
NB that `version` is not in the default format.
### Commands
The `commands` option accepts a list of commands to determine the compiler version and name.
Each command is represented as a list of the executable name, followed by its arguments, usually something like `["mycc", "--version"]`. Starship will try executing each command until it gets a result on STDOUT.
If a C compiler is not supported by this module, you can request it by [raising an issue on GitHub](https://github.com/starship/starship/).
### Beispiel
```toml
# ~/.config/starship.toml
[c]
format = "via [$name $version]($style)"
```
## Zeichen ## Zeichen
The `character` module shows a character (usually an arrow) beside where the text is entered in your terminal. Das `character` Modul zeigt ein Zeichen ( meistens einen Pfeil "") vor der Texteingabe an.
The character will tell you whether the last command was successful or not. It can do this in two ways: Das Zeichen zeigt an ob der letzte Befehl erfolgreich war, oder einen Fehler erzeugt hat. It can do this in two ways:
- changing color (`red`/`green`) - changing color (`red`/`green`)
- changing shape (``/`✖`) - changing shape (``/`✖`)
@ -497,7 +549,7 @@ By default it only changes color. If you also want to change its shape take a lo
| `success_symbol` | `"[](bold green)"` | The format string used before the text input if the previous command succeeded. | | `success_symbol` | `"[](bold green)"` | The format string used before the text input if the previous command succeeded. |
| `error_symbol` | `"[](bold red)"` | The format string used before the text input if the previous command failed. | | `error_symbol` | `"[](bold red)"` | The format string used before the text input if the previous command failed. |
| `vicmd_symbol` | `"[](bold green)"` | The format string used before the text input if the shell is in vim normal mode. | | `vicmd_symbol` | `"[](bold green)"` | The format string used before the text input if the shell is in vim normal mode. |
| `disabled` | `false` | Disables the `character` module. | | `disabled` | `false` | Deaktiviert das `character`-Modul. |
### Variables ### Variables
@ -598,25 +650,25 @@ The `cobol` module shows the currently installed version of COBOL. By default, t
## Befehlsdauer ## 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. 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</0> angezeigt wird.
::: warning Do not hook the DEBUG trap in Bash ::: warning Nicht die DEBUG-trap in der Bash hooken
If you are running Starship in `bash`, do not hook the `DEBUG` trap after running `eval $(starship init $0)`, or this module **will** break. 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 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. 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.
### Optionen ### Optionen
| Option | Standardwert | Beschreibung | | Option | Standardwert | Beschreibung |
| ---------------------- | ----------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------- | | ---------------------- | ----------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `min_time` | `2_000` | Shortest duration to show time for (in milliseconds). | | `min_time` | `2_000` | Schwellwert für kleinste anzuzeigende Laufzeit (in Millisekunden). |
| `show_milliseconds` | `false` | Show milliseconds in addition to seconds for the duration. | | `show_milliseconds` | `false` | Zeige Millisekunden zusätzlich zu Sekunden. |
| `format` | `"took [$duration]($style) "` | Das Format für das Modul. | | `format` | `"took [$duration]($style) "` | Das Format für das Modul. |
| `style` | `"bold yellow"` | Stil für dieses Modul. | | `style` | `"bold yellow"` | Stil für dieses Modul. |
| `disabled` | `false` | Disables the `cmd_duration` module. | | `disabled` | `false` | Deaktiviert das `cmd_duration`-Modul. |
| `show_notifications` | `false` | Show desktop notifications when command completes. | | `show_notifications` | `false` | Show desktop notifications when command completes. |
| `min_time_to_notify` | `45_000` | Shortest duration for notification (in milliseconds). | | `min_time_to_notify` | `45_000` | Shortest duration for notification (in milliseconds). |
| `notification_timeout` | | Duration to show notification for (in milliseconds). If unset, notification timeout will be determined by daemon. Not all notification daemons honor this option. | | `notification_timeout` | | Duration to show notification for (in milliseconds). If unset, notification timeout will be determined by daemon. Not all notification daemons honor this option. |
@ -646,20 +698,20 @@ The `conda` module shows the current [Conda](https://docs.conda.io/en/latest/) e
::: tip ::: tip
This does not suppress conda's own prompt modifier, you may want to run `conda config --set changeps1 False`. 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.
::: :::
### Optionen ### Optionen
| Option | Standardwert | Beschreibung | | 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. | | `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` | `"🅒 "` | The symbol used before the environment name. | | `symbol` | `"🅒 "` | Symbol das vor dem Umgebungsnamen angezeigt wird. |
| `style` | `"bold green"` | Stil für dieses Modul. | | `style` | `"bold green"` | Stil für dieses Modul. |
| `format` | `"via [$symbol$environment]($style) "` | Das Format für das Modul. | | `format` | `"via [$symbol$environment]($style) "` | Das Format für das Modul. |
| `ignore_base` | `true` | Ignores `base` environment when activated. | | `ignore_base` | `true` | Ignores `base` environment when activated. |
| `disabled` | `false` | Disables the `conda` module. | | `disabled` | `false` | Deaktiviert das `conda`-Modul. |
### Variables ### Variables
@ -716,7 +768,7 @@ format = "[$symbol \\[$name\\]]($style) "
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/). By default the module will be shown if any of the following conditions are met:
- The current directory contains a `shard.yml` file - Das aktuelle Verzeichnis enthält eine `shard.yml`-Datei
- The current directory contains a `.cr` file - The current directory contains a `.cr` file
### Optionen ### Optionen
@ -757,7 +809,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 file with `.dart` extension
- The current directory contains a `.dart_tool` directory - The current directory contains a `.dart_tool` directory
- The current directory contains a `pubspec.yaml`, `pubspec.yml` or `pubspec.lock` file - Das aktuelle Verzeichnis enthält `pubspec.yaml`, `pubspec.yml` oder `pubspec.lock`
### Optionen ### Optionen
@ -829,7 +881,7 @@ format = "via [🦕 $version](green bold) "
## Verzeichnis ## Verzeichnis
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. 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.
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. 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.
@ -839,11 +891,11 @@ For example, given `~/Dev/Nix/nixpkgs/pkgs` where `nixpkgs` is the repo root, an
| Option | Standardwert | Beschreibung | | Option | Standardwert | Beschreibung |
| ------------------- | ----------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------- | | ------------------- | ----------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------- |
| `truncation_length` | `3` | The number of parent folders that the current directory should be truncated to. | | `truncation_length` | `3` | Die Anzahl der übergeordneten Ordner, die angezeigt werden. |
| `truncate_to_repo` | `true` | Whether or not to truncate to the root of the git repo that you're currently in. | | `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) "` | Das Format für das Modul. | | `format` | `"[$path]($style)[$read_only]($read_only_style) "` | Das Format für das Modul. |
| `style` | `"bold cyan"` | Stil für dieses Modul. | | `style` | `"bold cyan"` | Stil für dieses Modul. |
| `disabled` | `false` | Disables the `directory` module. | | `disabled` | `false` | Deaktiviert das `directory`-Modul. |
| `read_only` | `"🔒"` | The symbol indicating current directory is read only. | | `read_only` | `"🔒"` | The symbol indicating current directory is read only. |
| `read_only_style` | `"red"` | The style for the read only symbol. | | `read_only_style` | `"red"` | The style for the read only symbol. |
| `truncation_symbol` | `""` | The symbol to prefix to truncated paths. eg: "…/" | | `truncation_symbol` | `""` | The symbol to prefix to truncated paths. eg: "…/" |
@ -853,7 +905,7 @@ For example, given `~/Dev/Nix/nixpkgs/pkgs` where `nixpkgs` is the repo root, an
| `use_os_path_sep` | `true` | Use the OS specific path separator instead of always using `/` (e.g. `\` on Windows) | | `use_os_path_sep` | `true` | Use the OS specific path separator instead of always using `/` (e.g. `\` on Windows) |
<details> <details>
<summary>This module has a few advanced configuration options that control how the directory is displayed.</summary> <summary>Dieses Modul hat einige erweiterte Konfigurationsoptionen, welche die Darstellung von Verzeichnissen steuern.</summary>
| Advanced Option | Standardwert | Beschreibung | | Advanced Option | Standardwert | Beschreibung |
| --------------------------- | ------------ | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------- | | --------------------------- | ------------ | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
@ -962,21 +1014,21 @@ You'll also need the .NET Core SDK installed in order to use it correctly.
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. 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 (<https://docs.microsoft.com/en-us/dotnet/standard/frameworks#supported-target-framework-versions>) when there is a csproj file in the current directory. The module will also show the Target Framework Moniker (<https://docs.microsoft.com/en-us/dotnet/standard/frameworks#supported-target-frameworks>) when there is a `.csproj` file in the current directory.
### Optionen ### Optionen
| Option | Standardwert | Beschreibung | | Option | Standartwert | Beschreibung |
| ------------------- | ------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------- | | ------------------- | ------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------- |
| `format` | `"via [$symbol($version )(🎯 $tfm )]($style)"` | Das Format für das Modul. | | `format` | `"via [$symbol($version )(🎯 $tfm )]($style)"` | Das Format für das Modul. |
| `version_format` | `"v${raw}"` | The version format. Available vars are `raw`, `major`, `minor`, & `patch` | | `version_format` | `"v${raw}"` | The version format. Available vars are `raw`, `major`, `minor`, & `patch` |
| `symbol` | `".NET "` | The symbol used before displaying the version of dotnet. | | `symbol` | `".NET "` | Symbol das vor der dotnet-Version angezeigt wird. |
| `heuristic` | `true` | Use faster version detection to keep starship snappy. | | `heuristic` | `true` | Schnelle Versionserkennung nutzen um Starship bedienbar zu halten. |
| `detect_extensions` | `["csproj", "fsproj", "xproj"]` | Which extensions should trigger this module. | | `detect_extensions` | `["csproj", "fsproj", "xproj"]` | Which extensions should trigger this module. |
| `detect_files` | `["global.json", "project.json", "Directory.Build.props", "Directory.Build.targets", "Packages.props"]` | Which filenames should trigger this module. | | `detect_files` | `["global.json", "project.json", "Directory.Build.props", "Directory.Build.targets", "Packages.props"]` | Which filenames should trigger this module. |
| `detect_folders` | `[]` | Which folders should trigger this modules. | | `detect_folders` | `[]` | Which folders should trigger this modules. |
| `style` | `"bold blue"` | Stil für dieses Modul. | | `style` | `"bold blue"` | Stil für dieses Modul. |
| `disabled` | `false` | Disables the `dotnet` module. | | `disabled` | `false` | Deaktiviert das `dotnet`-Modul. |
### Variables ### Variables
@ -1004,11 +1056,11 @@ heuristic = false
The `elixir` module shows the currently installed version of [Elixir](https://elixir-lang.org/) and [Erlang/OTP](https://erlang.org/doc/). By default the module will be shown if any of the following conditions are met: The `elixir` module shows the currently installed version of [Elixir](https://elixir-lang.org/) and [Erlang/OTP](https://erlang.org/doc/). By default the module will be shown if any of the following conditions are met:
- The current directory contains a `mix.exs` file. - Das aktuelle Verzeichnis enthält eine `mix.exs`-Datei.
### Optionen ### Optionen
| Option | Standartwert | Beschreibung | | Option | Standardwert | Beschreibung |
| ------------------- | ----------------------------------------------------------- | ------------------------------------------------------------------------- | | ------------------- | ----------------------------------------------------------- | ------------------------------------------------------------------------- |
| `format` | `'via [$symbol($version \(OTP $otp_version\) )]($style)'` | The format for the module elixir. | | `format` | `'via [$symbol($version \(OTP $otp_version\) )]($style)'` | The format for the module elixir. |
| `version_format` | `"v${raw}"` | The version format. Available vars are `raw`, `major`, `minor`, & `patch` | | `version_format` | `"v${raw}"` | The version format. Available vars are `raw`, `major`, `minor`, & `patch` |
@ -1043,8 +1095,8 @@ symbol = "🔮 "
The `elm` module shows the currently installed version of [Elm](https://elm-lang.org/). By default the module will be shown if any of the following conditions are met: The `elm` module shows the currently installed version of [Elm](https://elm-lang.org/). By default the module will be shown if any of the following conditions are met:
- The current directory contains a `elm.json` file - Das aktuelle Verzeichnis enthält eine `elm.json`-Datei
- The current directory contains a `elm-package.json` file - Das aktuelle Verzeichnis enthält eine `elm-package.json`-Datei
- The current directory contains a `.elm-version` file - The current directory contains a `.elm-version` file
- The current directory contains a `elm-stuff` folder - The current directory contains a `elm-stuff` folder
- The current directory contains `*.elm` files - The current directory contains `*.elm` files
@ -1103,13 +1155,13 @@ default = "unknown user"
### Optionen ### Optionen
| Option | Standardwert | Beschreibung | | Option | Standardwert | Beschreibung |
| ---------- | ------------------------------ | ---------------------------------------------------------------------------- | | ---------- | ------------------------------ | ---------------------------------------------------------------------------------------- |
| `symbol` | `""` | The symbol used before displaying the variable value. | | `symbol` | `""` | Das Symbol, das vor der Anzeige der Variable verwendet wird. |
| `variable` | | The environment variable to be displayed. | | `variable` | | Die anzuzeigende Umgebungsvariable. |
| `default` | | The default value to be displayed when the selected variable is not defined. | | `default` | | Der Standardwert, der angezeigt wird, wenn die ausgewählte Variable nicht definiert ist. |
| `format` | `"with [$env_value]($style) "` | Das Format für das Modul. | | `format` | `"with [$env_value]($style) "` | Das Format für das Modul. |
| `disabled` | `false` | Disables the `env_var` module. | | `disabled` | `false` | Deaktiviert das `env_var`-Modul. |
### Variables ### Variables
@ -1147,8 +1199,8 @@ default = "unknown user"
The `erlang` module shows the currently installed version of [Erlang/OTP](https://erlang.org/doc/). By default the module will be shown if any of the following conditions are met: The `erlang` module shows the currently installed version of [Erlang/OTP](https://erlang.org/doc/). By default the module will be shown if any of the following conditions are met:
- The current directory contains a `rebar.config` file. - Das aktuelle Verzeichnis enthält eine `rebar.config`-Datei.
- The current directory contains a `erlang.mk` file. - Das aktuelle Verzeichnis enthält eine `erlang.mk`-Datei.
### Optionen ### Optionen
@ -1284,9 +1336,9 @@ format = 'on [$symbol$account(@$domain)(\($project\))]($style) '
very-long-project-name = "vlpn" very-long-project-name = "vlpn"
``` ```
## Git Branch ## Git-Branch
The `git_branch` module shows the active branch of the repo in your current directory. Das `git_branch`-Modul zeigt den aktiven Git-Branch des Repositories im aktuellen Verzeichnis an.
### Optionen ### Optionen
@ -1300,7 +1352,7 @@ The `git_branch` module shows the active branch of the repo in your current dire
| `truncation_symbol` | `"…"` | The symbol used to indicate a branch name was truncated. You can use `""` for no symbol. | | `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. | | `only_attached` | `false` | Only show the branch name when not in a detached `HEAD` state. |
| `ignore_branches` | `[]` | A list of names to avoid displaying. Useful for "master" or "main". | | `ignore_branches` | `[]` | A list of names to avoid displaying. Useful for "master" or "main". |
| `disabled` | `false` | Disables the `git_branch` module. | | `disabled` | `false` | Deaktiviert das `git_branch`-Modul. |
### Variables ### Variables
@ -1361,7 +1413,7 @@ commit_hash_length = 4
tag_symbol = "🔖 " tag_symbol = "🔖 "
``` ```
## Git State ## Git-Zustand
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. 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.
@ -1378,7 +1430,7 @@ The `git_state` module will show in directories which are part of a git reposito
| `am_or_rebase` | `"AM/REBASE"` | A format string displayed when an ambiguous `apply-mailbox` or `rebase` 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"` | Stil für dieses Modul. | | `style` | `"bold yellow"` | Stil für dieses Modul. |
| `format` | `'\([$state( $progress_current/$progress_total)]($style)\) '` | Das Format für das Modul. | | `format` | `'\([$state( $progress_current/$progress_total)]($style)\) '` | Das Format für das Modul. |
| `disabled` | `false` | Disables the `git_state` module. | | `disabled` | `false` | Deaktiviert das `git_state`-Modul. |
### Variables ### Variables
@ -1407,7 +1459,7 @@ The `git_metrics` module will show the number of added and deleted lines in the
::: tip ::: tip
This module is disabled by default. To enable it, set `disabled` to `false` in your configuration file. Dieses Modul ist standardmäßig deaktiviert. Setze in deiner Konfiguration `disabled` auf `false` um es zu aktivieren.
::: :::
@ -1470,7 +1522,7 @@ The Git Status module is very slow in Windows directories (for example under `/m
| `deleted` | `"✘"` | The format of `deleted` | | `deleted` | `"✘"` | The format of `deleted` |
| `style` | `"bold red"` | Stil für dieses Modul. | | `style` | `"bold red"` | Stil für dieses Modul. |
| `ignore_submodules` | `false` | Ignore changes to submodules. | | `ignore_submodules` | `false` | Ignore changes to submodules. |
| `disabled` | `false` | Disables the `git_status` module. | | `disabled` | `false` | Deaktiviert das `git_status`-Modul. |
| `windows_starship` | | Use this (Linux) path to a Windows Starship executable to render `git_status` when on Windows paths in WSL. | | `windows_starship` | | Use this (Linux) path to a Windows Starship executable to render `git_status` when on Windows paths in WSL. |
### Variables ### Variables
@ -1548,14 +1600,14 @@ windows_starship = '/mnt/c/Users/username/scoop/apps/starship/current/starship.e
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 `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 - Das aktuelle Verzeichnis enthält eine `go.mod`-Datei
- The current directory contains a `go.sum` file - Das aktuelle Verzeichnis enthält eine `go.sum`-Datei
- The current directory contains a `glide.yaml` file - Das aktuelle Verzeichnis enthält eine `glide.yaml`-Datei
- The current directory contains a `Gopkg.yml` file - Das aktuelle Verzeichnis enthält eine `Gopkg.yml`-Datei
- The current directory contains a `Gopkg.lock` file - Das aktuelle Verzeichnis enthält eine `Gopkg.lock`-Datei
- The current directory contains a `.go-version` file - The current directory contains a `.go-version` file
- The current directory contains a `Godeps` directory - Das aktuelle Verzeichnis enthält ein `Godeps`-Verzeichnis
- The current directory contains a file with the `.go` extension - Das aktuelle Verzeichnis enthält eine Datei mit der `.go`-Erweiterung
### Optionen ### Optionen
@ -1568,7 +1620,7 @@ The `golang` module shows the currently installed version of [Go](https://golang
| `detect_files` | `["go.mod", "go.sum", "glide.yaml", "Gopkg.yml", "Gopkg.lock", ".go-version"]` | Which filenames should trigger this module. | | `detect_files` | `["go.mod", "go.sum", "glide.yaml", "Gopkg.yml", "Gopkg.lock", ".go-version"]` | Which filenames should trigger this module. |
| `detect_folders` | `["Godeps"]` | Which folders should trigger this module. | | `detect_folders` | `["Godeps"]` | Which folders should trigger this module. |
| `style` | `"bold cyan"` | Stil für dieses Modul. | | `style` | `"bold cyan"` | Stil für dieses Modul. |
| `disabled` | `false` | Disables the `golang` module. | | `disabled` | `false` | Deaktiviert das `golang`-Modul. |
### Variables ### Variables
@ -1595,7 +1647,7 @@ The `haskell` module finds the current selected GHC version and/or the selected
By default the module will be shown if any of the following conditions are met: By default the module will be shown if any of the following conditions are met:
- The current directory contains a `stack.yaml` file - Das aktuelle Verzeichnis enthält eine `stack.yaml`-Datei
- The current directory contains any `.hs`, `.cabal`, or `.hs-boot` file - The current directory contains any `.hs`, `.cabal`, or `.hs-boot` file
### Optionen ### Optionen
@ -1626,7 +1678,7 @@ By default the module will be shown if any of the following conditions are met:
The `helm` module shows the currently installed version of [Helm](https://helm.sh/). By default the module will be shown if any of the following conditions are met: The `helm` module shows the currently installed version of [Helm](https://helm.sh/). By default the module will be shown if any of the following conditions are met:
- The current directory contains a `helmfile.yaml` file - Das aktuelle Verzeichnis enthält eine `helmfile.yaml`-Datei
- The current directory contains a `Chart.yaml` file - The current directory contains a `Chart.yaml` file
### Optionen ### Optionen
@ -1663,17 +1715,17 @@ format = "via [⎈ $version](bold white) "
## Hostname ## Hostname
The `hostname` module shows the system hostname. Das `hostname`-Modul zeigt den Hostnamen des Systems an.
### Optionen ### Optionen
| Option | Standardwert | Beschreibung | | Option | Standardwert | Beschreibung |
| ---------- | --------------------------- | ------------------------------------------------------------------------------------------------------------------------------------ | | ---------- | --------------------------- | ------------------------------------------------------------------------------------------------------------------------------------ |
| `ssh_only` | `true` | Only show hostname when connected to an SSH session. | | `ssh_only` | `true` | Zeigt den Hostnamen nur, wenn via SSH-Sitzung verbunden. |
| `trim_at` | `"."` | String that the hostname is cut off at, after the first match. `"."` will stop after the first dot. `""` will disable any truncation | | `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 "` | Das Format für das Modul. | | `format` | `"[$hostname]($style) in "` | Das Format für das Modul. |
| `style` | `"bold dimmed green"` | Stil für dieses Modul. | | `style` | `"bold dimmed green"` | Stil für dieses Modul. |
| `disabled` | `false` | Disables the `hostname` module. | | `disabled` | `false` | Deaktiviert das `hostname`-Modul. |
### Variables ### Variables
@ -1714,7 +1766,7 @@ The `java` module shows the currently installed version of [Java](https://www.or
| `detect_folders` | `[]` | Which folders should trigger this modules. | | `detect_folders` | `[]` | Which folders should trigger this modules. |
| `symbol` | `"☕ "` | A format string representing the symbol of Java | | `symbol` | `"☕ "` | A format string representing the symbol of Java |
| `style` | `"red dimmed"` | Stil für dieses Modul. | | `style` | `"red dimmed"` | Stil für dieses Modul. |
| `disabled` | `false` | Disables the `java` module. | | `disabled` | `false` | Deaktiviert das `Java`-Modul. |
### Variables ### Variables
@ -1759,15 +1811,15 @@ The `threshold` option is deprecated, but if you want to use it, the module will
### Optionen ### Optionen
| Option | Standardwert | Beschreibung | | Option | Standardwert | Beschreibung |
| ------------------ | ----------------------------- | ------------------------------------------------------------------------ | | ------------------ | ----------------------------- | -------------------------------------------------------------------------------- |
| `threshold`* | `1` | Show number of jobs if exceeded. | | `threshold`* | `1` | Zeigt die Anzahl der Jobs wenn der angegebene Schwellenwert überschritten wurde. |
| `symbol_threshold` | `1` | Show `symbol` if the job count is at least `symbol_threshold`. | | `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`. | | `number_threshold` | `2` | Show the number of jobs if the job count is at least `number_threshold`. |
| `format` | `"[$symbol$number]($style) "` | Das Format für das Modul. | | `format` | `"[$symbol$number]($style) "` | Das Format für das Modul. |
| `symbol` | `"✦"` | The string used to represent the `symbol` variable. | | `symbol` | `"✦"` | The string used to represent the `symbol` variable. |
| `style` | `"bold blue"` | Stil für dieses Modul. | | `style` | `"bold blue"` | Stil für dieses Modul. |
| `disabled` | `false` | Disables the `jobs` module. | | `disabled` | `false` | Deaktiviert das `jobs`-Modul. |
*: This option is deprecated, please use the `number_threshold` and `symbol_threshold` options instead. *: This option is deprecated, please use the `number_threshold` and `symbol_threshold` options instead.
@ -1885,7 +1937,7 @@ Displays the current [Kubernetes context](https://kubernetes.io/docs/concepts/co
::: tip ::: tip
This module is disabled by default. To enable it, set `disabled` to `false` in your configuration file. Dieses Modul ist standardmäßig deaktiviert. Setze in deiner Konfiguration `disabled` auf `false` um es zu aktivieren.
::: :::
@ -1897,7 +1949,7 @@ This module is disabled by default. To enable it, set `disabled` to `false` in y
| `format` | `'[$symbol$context( \($namespace\))]($style) in '` | Das Format für das Modul. | | `format` | `'[$symbol$context( \($namespace\))]($style) in '` | Das Format für das Modul. |
| `style` | `"cyan bold"` | Stil für dieses Modul. | | `style` | `"cyan bold"` | Stil für dieses Modul. |
| `context_aliases` | | Table of context aliases to display. | | `context_aliases` | | Table of context aliases to display. |
| `disabled` | `true` | Disables the `kubernetes` module. | | `disabled` | `true` | Deaktiviert das `kubernetes`-Modul. |
### Variables ### Variables
@ -1947,15 +1999,15 @@ Long and automatically generated cluster names can be identified and shortened u
"gke_.*_(?P<var_cluster>[\\w-]+)" = "gke-$var_cluster" "gke_.*_(?P<var_cluster>[\\w-]+)" = "gke-$var_cluster"
``` ```
## Line Break ## Zeilenumbruch
The `line_break` module separates the prompt into two lines. Das `line_break`-Modul unterteilt den Prompt in zwei Zeilen.
### Optionen ### Optionen
| Option | Standardwert | Beschreibung | | Option | Standardwert | Beschreibung |
| ---------- | ------------ | ------------------------------------------------------------------ | | ---------- | ------------ | ---------------------------------------------------------------------- |
| `disabled` | `false` | Disables the `line_break` module, making the prompt a single line. | | `disabled` | `false` | Deaktiviert das `line_break`-Modul, wodurch der Prompt einzeilig wird. |
### Beispiel ### Beispiel
@ -2040,27 +2092,27 @@ The `lua` module shows the currently installed version of [Lua](http://www.lua.o
format = "via [🌕 $version](bold blue) " format = "via [🌕 $version](bold blue) "
``` ```
## Memory Usage ## Speicherauslastung
The `memory_usage` module shows current system memory and swap usage. Das `memory_usage` Modul zeigt den aktuellen Systemspeicher und die swap-Nutzung an.
By default the swap usage is displayed if the total system swap is non-zero. Standardmäßig wird die swap-Nutzung angezeigt, wenn der gesamte System-swap nicht Null ist.
::: tip ::: tip
This module is disabled by default. To enable it, set `disabled` to `false` in your configuration file. Dieses Modul ist standardmäßig deaktiviert. Setze in deiner Konfiguration `disabled` auf `false` um es zu aktivieren.
::: :::
### Optionen ### Optionen
| Option | Standardwert | Beschreibung | | Option | Standardwert | Beschreibung |
| ----------- | ----------------------------------------------- | -------------------------------------------------------- | | ----------- | ----------------------------------------------- | --------------------------------------------------------------------- |
| `threshold` | `75` | Hide the memory usage unless it exceeds this percentage. | | `threshold` | `75` | Speicherauslastung ausblenden, wenn sie unter diesem Prozentsatz ist. |
| `format` | `"via $symbol [${ram}( \| ${swap})]($style) "` | Das Format für das Modul. | | `format` | `"via $symbol [${ram}( \| ${swap})]($style) "` | Das Format für das Modul. |
| `symbol` | `"🐏"` | The symbol used before displaying the memory usage. | | `symbol` | `"🐏"` | Symbol das vor der Speicherauslastung angezeigt wird. |
| `style` | `"bold dimmed white"` | Stil für dieses Modul. | | `style` | `"bold dimmed white"` | Stil für dieses Modul. |
| `disabled` | `true` | Disables the `memory_usage` module. | | `disabled` | `true` | Deaktiviert das `memory_usage`-Modul. |
### Variables ### Variables
@ -2127,7 +2179,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: 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:
- The current directory contains a `nim.cfg` file - Das aktuelle Verzeichnis enthält eine `nim.cfg`-Datei
- The current directory contains a file with the `.nim` extension - 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 `.nims` extension
- The current directory contains a file with the `.nimble` extension - The current directory contains a file with the `.nimble` extension
@ -2136,7 +2188,7 @@ The `nim` module shows the currently installed version of [Nim](https://nim-lang
| Option | Standardwert | Beschreibung | | Option | Standardwert | Beschreibung |
| ------------------- | ------------------------------------ | ------------------------------------------------------------------------- | | ------------------- | ------------------------------------ | ------------------------------------------------------------------------- |
| `format` | `"via [$symbol($version )]($style)"` | The format for the module | | `format` | `"via [$symbol($version )]($style)"` | Das Format für das Modul |
| `version_format` | `"v${raw}"` | The version format. Available vars are `raw`, `major`, `minor`, & `patch` | | `version_format` | `"v${raw}"` | The version format. Available vars are `raw`, `major`, `minor`, & `patch` |
| `symbol` | `"👑 "` | The symbol used before displaying the version of Nim. | | `symbol` | `"👑 "` | The symbol used before displaying the version of Nim. |
| `detect_extensions` | `["nim", "nims", "nimble"]` | Which extensions should trigger this module. | | `detect_extensions` | `["nim", "nims", "nimble"]` | Which extensions should trigger this module. |
@ -2165,9 +2217,9 @@ style = "yellow"
symbol = "🎣 " 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. The module will be shown when inside a nix-shell environment. 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.
### Optionen ### Optionen
@ -2178,7 +2230,7 @@ The `nix_shell` module shows the [nix-shell](https://nixos.org/guides/nix-pills/
| `style` | `"bold blue"` | Stil für dieses Modul. | | `style` | `"bold blue"` | Stil für dieses Modul. |
| `impure_msg` | `"impure"` | A format string shown when the shell is impure. | | `impure_msg` | `"impure"` | A format string shown when the shell is impure. |
| `pure_msg` | `"pure"` | A format string shown when the shell is pure. | | `pure_msg` | `"pure"` | A format string shown when the shell is pure. |
| `disabled` | `false` | Disables the `nix_shell` module. | | `disabled` | `false` | Deaktiviert das `nix_shell`-Modul. |
### Variables ### Variables
@ -2207,10 +2259,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: 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:
- The current directory contains a `package.json` file - Das aktuelle Verzeichnis enthält eine `package.json`-Datei
- The current directory contains a `.node-version` file - The current directory contains a `.node-version` file
- The current directory contains a `.nvmrc` file - The current directory contains a `.nvmrc` file
- The current directory contains a `node_modules` directory - Das aktuelle Verzeichnis enthält ein `node_modules`-Verzeichnis
- The current directory contains a file with the `.js`, `.mjs` or `.cjs` extension - The current directory contains a file with the `.js`, `.mjs` or `.cjs` extension
- The current directory contains a file with the `.ts`, `.mts` or `.cts` extension - The current directory contains a file with the `.ts`, `.mts` or `.cts` extension
@ -2225,7 +2277,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_files` | `["package.json", ".node-version"]` | Which filenames should trigger this module. |
| `detect_folders` | `["node_modules"]` | Which folders should trigger this module. | | `detect_folders` | `["node_modules"]` | Which folders should trigger this module. |
| `style` | `"bold green"` | Stil für dieses Modul. | | `style` | `"bold green"` | Stil für dieses Modul. |
| `disabled` | `false` | Disables the `nodejs` module. | | `disabled` | `false` | Deaktiviert das `nodejs`-Modul. |
| `not_capable_style` | `bold red` | The style for the module when an engines property in package.json does not match the Node.js version. | | `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 ### Variables
@ -2329,9 +2381,9 @@ style = "bold yellow"
symbol = "☁️ " symbol = "☁️ "
``` ```
## Package Version ## Paketversion
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`, `helm`, `shards` and `dart` packages. 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`, `helm`, `shards` and `dart` packages.
- [**npm**](https://docs.npmjs.com/cli/commands/npm) The `npm` package version is extracted from the `package.json` present in the current directory - [**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 - [**Cargo**](https://doc.rust-lang.org/cargo/) The `cargo` package version is extracted from the `Cargo.toml` present in the current directory
@ -2357,11 +2409,11 @@ The `package` module is shown when the current directory is the repository for a
| Option | Standardwert | Beschreibung | | Option | Standardwert | Beschreibung |
| ----------------- | --------------------------------- | ------------------------------------------------------------------------- | | ----------------- | --------------------------------- | ------------------------------------------------------------------------- |
| `format` | `"is [$symbol$version]($style) "` | Das Format für das Modul. | | `format` | `"is [$symbol$version]($style) "` | Das Format für das Modul. |
| `symbol` | `"📦 "` | The symbol used before displaying the version the package. | | `symbol` | `"📦 "` | Symbol das vor der Paketversion angezeigt wird. |
| `version_format` | `"v${raw}"` | The version format. Available vars are `raw`, `major`, `minor`, & `patch` | | `version_format` | `"v${raw}"` | The version format. Available vars are `raw`, `major`, `minor`, & `patch` |
| `style` | `"bold 208"` | Stil für dieses Modul. | | `style` | `"bold 208"` | Stil für dieses Modul. |
| `display_private` | `false` | Enable displaying version for packages marked as private. | | `display_private` | `false` | Enable displaying version for packages marked as private. |
| `disabled` | `false` | Disables the `package` module. | | `disabled` | `false` | Deaktiviert das `package`-Modul. |
### Variables ### Variables
@ -2426,7 +2478,7 @@ format = "via [🦪 $version]($style) "
The `php` module shows the currently installed version of [PHP](https://www.php.net/). By default the module will be shown if any of the following conditions are met: The `php` module shows the currently installed version of [PHP](https://www.php.net/). By default the module will be shown if any of the following conditions are met:
- The current directory contains a `composer.json` file - Das aktuelle Verzeichnis enthält eine `composer.json`-Datei
- The current directory contains a `.php-version` file - The current directory contains a `.php-version` file
- The current directory contains a `.php` extension - The current directory contains a `.php` extension
@ -2436,12 +2488,12 @@ The `php` module shows the currently installed version of [PHP](https://www.php.
| ------------------- | ------------------------------------ | ------------------------------------------------------------------------- | | ------------------- | ------------------------------------ | ------------------------------------------------------------------------- |
| `format` | `"via [$symbol($version )]($style)"` | Das Format für das Modul. | | `format` | `"via [$symbol($version )]($style)"` | Das Format für das Modul. |
| `version_format` | `"v${raw}"` | The version format. Available vars are `raw`, `major`, `minor`, & `patch` | | `version_format` | `"v${raw}"` | The version format. Available vars are `raw`, `major`, `minor`, & `patch` |
| `symbol` | `"🐘 "` | The symbol used before displaying the version of PHP. | | `symbol` | `"🐘 "` | Symbol das vor der PHP-Version angezeigt wird. |
| `detect_extensions` | `["php"]` | Which extensions should trigger this module. | | `detect_extensions` | `["php"]` | Which extensions should trigger this module. |
| `detect_files` | `["composer.json", ".php-version"]` | Which filenames should trigger this module. | | `detect_files` | `["composer.json", ".php-version"]` | Which filenames should trigger this module. |
| `detect_folders` | `[]` | Which folders should trigger this module. | | `detect_folders` | `[]` | Which folders should trigger this module. |
| `style` | `"147 bold"` | Stil für dieses Modul. | | `style` | `"147 bold"` | Stil für dieses Modul. |
| `disabled` | `false` | Disables the `php` module. | | `disabled` | `false` | Deaktiviert das `php`-Modul. |
### Variables ### Variables
@ -2489,13 +2541,13 @@ By default the module will be shown if any of the following conditions are met:
### Variables ### Variables
| Variable | Beispiel | Beschreibung | | Variable | Beispiel | Beschreibung |
| --------- | ---------- | ------------------------------------- | | ------------ | ---------- | ------------------------------------- |
| version | `v0.12.24` | The version of `pulumi` | | version | `v0.12.24` | The version of `pulumi` |
| stack | `dev` | The current Pulumi stack | | stack | `dev` | The current Pulumi stack |
| username | `alice` | The current Pulumi username | | benutzername | `alice` | The current Pulumi username |
| symbol | | Spiegelt den Wert der Option `symbol` | | symbol | | Spiegelt den Wert der Option `symbol` |
| style\* | | Spiegelt den Wert der Option `style` | | style\* | | Spiegelt den Wert der Option `style` |
*: This variable can only be used as a part of a style string *: This variable can only be used as a part of a style string
@ -2523,7 +2575,7 @@ format = "[$symbol$stack]($style) "
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. By default the module will be shown if any of the following conditions are met:
- The current directory contains a `spago.dhall` file - Das aktuelle Verzeichnis enthält eine `spago.dhall`-Datei
- The current directory contains a file with the `.purs` extension - The current directory contains a file with the `.purs` extension
### Optionen ### Optionen
@ -2566,15 +2618,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: By default the module will be shown if any of the following conditions are met:
- The current directory contains a `.python-version` file - Das aktuelle Verzeichnis enthält eine `.python-version`-Datei
- The current directory contains a `Pipfile` file - Das aktuelle Verzeichnis enthält eine `Pipfile`-Datei
- The current directory contains a `__init__.py` file - The current directory contains a `__init__.py` file
- The current directory contains a `pyproject.toml` file - Das aktuelle Verzeichnis enthält eine `pyproject.toml`-Datei
- The current directory contains a `requirements.txt` file - Das aktuelle Verzeichnis enthält eine `requirements.txt`-Datei
- The current directory contains a `setup.py` file - Das aktuelle Verzeichnis enthält eine `setup.py`-Datei
- The current directory contains a `tox.ini` file - Das aktuelle Verzeichnis enthält eine `tox.ini`-Datei
- The current directory contains a file with the `.py` extension. - Das aktuelle Verzeichnis enthält eine Datei mit der `.py`-Erweiterung.
- A virtual environment is currently activated - Ein virtualenv ist momentan aktiv
### Optionen ### Optionen
@ -2584,13 +2636,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` | | `version_format` | `"v${raw}"` | The version format. Available vars are `raw`, `major`, `minor`, & `patch` |
| `symbol` | `"🐍 "` | A format string representing the symbol of Python | | `symbol` | `"🐍 "` | A format string representing the symbol of Python |
| `style` | `"yellow bold"` | Stil für dieses Modul. | | `style` | `"yellow bold"` | Stil für dieses Modul. |
| `pyenv_version_name` | `false` | Use pyenv to get Python version | | `pyenv_version_name` | `false` | Verwende `pyenv` um die Python-Versionzu beziehen. |
| `pyenv_prefix` | `pyenv` | Prefix before pyenv version display, only used if pyenv is used | | `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. | | `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_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_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 | | `detect_folders` | `[]` | Which folders should trigger this module |
| `disabled` | `false` | Disables the `python` module. | | `disabled` | `false` | Deaktiviert das `python`-Modul. |
::: tip ::: tip
@ -2731,9 +2783,9 @@ symbol = "🔴 "
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/). Das Modul wird nur dann angezeigt, wenn eine der folgenden Bedingungen zutrifft:
- The current directory contains a `Gemfile` file - Das aktuelle Verzeichnis enthält eine `Gemfile`-Datei
- The current directory contains a `.ruby-version` file - The current directory contains a `.ruby-version` file
- The current directory contains a `.rb` file - Das aktuelle Verzeichnis enthält eine `.rb`-Datei
- The environment variables `RUBY_VERSION` or `RBENV_VERSION` are set - The environment variables `RUBY_VERSION` or `RBENV_VERSION` are set
Starship gets the current Ruby version by running `ruby -v`. Starship gets the current Ruby version by running `ruby -v`.
@ -2750,7 +2802,7 @@ Starship gets the current Ruby version by running `ruby -v`.
| `detect_folders` | `[]` | Which folders should trigger this module. | | `detect_folders` | `[]` | Which folders should trigger this module. |
| `detect_variables` | `["RUBY_VERSION", "RBENV_VERSION"]` | Which environment variables should trigger this module. | | `detect_variables` | `["RUBY_VERSION", "RBENV_VERSION"]` | Which environment variables should trigger this module. |
| `style` | `"bold red"` | Stil für dieses Modul. | | `style` | `"bold red"` | Stil für dieses Modul. |
| `disabled` | `false` | Disables the `ruby` module. | | `disabled` | `false` | Deaktiviert das `ruby`-Modul. |
### Variables ### Variables
@ -2775,8 +2827,8 @@ symbol = "🔺 "
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/). Das Modul wird nur dann angezeigt, wenn eine der folgenden Bedingungen zutrifft:
- The current directory contains a `Cargo.toml` file - Das aktuelle Verzeichnis enthält eine `Cargo.toml`-Datei
- The current directory contains a file with the `.rs` extension - Das aktuelle Verzeichnis enthält eine Datei mit der `.rs`-Erweiterung
### Optionen ### Optionen
@ -2789,7 +2841,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_files` | `["Cargo.toml"]` | Which filenames should trigger this module. |
| `detect_folders` | `[]` | Which folders should trigger this module. | | `detect_folders` | `[]` | Which folders should trigger this module. |
| `style` | `"bold red"` | Stil für dieses Modul. | | `style` | `"bold red"` | Stil für dieses Modul. |
| `disabled` | `false` | Disables the `rust` module. | | `disabled` | `false` | Deaktiviert das `rust`-Modul. |
### Variables ### Variables
@ -2856,7 +2908,7 @@ The `shell` module shows an indicator for currently used shell.
::: tip ::: tip
This module is disabled by default. To enable it, set `disabled` to `false` in your configuration file. Dieses Modul ist standardmäßig deaktiviert. Setze in deiner Konfiguration `disabled` auf `false` um es zu aktivieren.
::: :::
@ -2872,7 +2924,7 @@ This module is disabled by default. To enable it, set `disabled` to `false` in y
| `elvish_indicator` | `esh` | A format string used to represent elvish. | | `elvish_indicator` | `esh` | A format string used to represent elvish. |
| `tcsh_indicator` | `tsh` | A format string used to represent tcsh. | | `tcsh_indicator` | `tsh` | A format string used to represent tcsh. |
| `xonsh_indicator` | `xsh` | A format string used to represent xonsh. | | `xonsh_indicator` | `xsh` | A format string used to represent xonsh. |
| `cmd_indicator` | `cmd` | A format string used to represent cmd. | | `cmd_indicator` | `cmd` | A format string used to represent cmd. |
| `nu_indicator` | `nu` | A format string used to represent nu. | | `nu_indicator` | `nu` | A format string used to represent nu. |
| `unknown_indicator` | | The default value to be displayed when the shell is unknown. | | `unknown_indicator` | | The default value to be displayed when the shell is unknown. |
| `format` | `"[$indicator]($style) "` | Das Format für das Modul. | | `format` | `"[$indicator]($style) "` | Das Format für das Modul. |
@ -2884,7 +2936,7 @@ This module is disabled by default. To enable it, set `disabled` to `false` in y
| Variable | Standardwert | Beschreibung | | Variable | Standardwert | Beschreibung |
| --------- | ------------ | ---------------------------------------------------------- | | --------- | ------------ | ---------------------------------------------------------- |
| indicator | | Mirrors the value of `indicator` for currently used shell. | | indicator | | Mirrors the value of `indicator` for currently used shell. |
| style\* | | Mirrors the value of option `style`. | | style\* | | Spiegelt den Wert der Option `style`. |
*: This variable can only be used as a part of a style string *: This variable can only be used as a part of a style string
@ -2969,13 +3021,46 @@ The `singularity` module shows the current [Singularity](https://sylabs.io/singu
format = '[📦 \[$env\]]($style) ' format = '[📦 \[$env\]]($style) '
``` ```
## Spack
The `spack` module shows the current [Spack](https://spack.readthedocs.io/en/latest/) environment, if `$SPACK_ENV` is set.
### Optionen
| Option | Standardwert | Beschreibung |
| ------------------- | -------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `truncation_length` | `1` | The number of directories the environment path should be truncated to. `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 blue"` | Stil für dieses Modul. |
| `format` | `"via [$symbol$environment]($style) "` | Das Format für das Modul. |
| `disabled` | `false` | Disables the `spack` module. |
### Variables
| Variable | Beispiel | Beschreibung |
| ----------- | ------------ | ------------------------------------- |
| environment | `astronauts` | The current spack environment |
| symbol | | Spiegelt den Wert der Option `symbol` |
| style\* | | Spiegelt den Wert der Option `style` |
*: This variable can only be used as a part of a style string
### Beispiel
```toml
# ~/.config/starship.toml
[spack]
format = "[$symbol$environment](dimmed blue) "
```
## Status ## Status
The `status` module displays the exit code of the previous command. If $success_symbol is empty (default), the module will be shown only if the exit code is not `0`. The status code will cast to a signed 32-bit integer. The `status` module displays the exit code of the previous command. If $success_symbol is empty (default), the module will be shown only if the exit code is not `0`. The status code will cast to a signed 32-bit integer.
::: tip ::: tip
This module is disabled by default. To enable it, set `disabled` to `false` in your configuration file. Dieses Modul ist standardmäßig deaktiviert. Setze in deiner Konfiguration `disabled` auf `false` um es zu aktivieren.
::: :::
@ -3035,7 +3120,7 @@ The `sudo` module displays if sudo credentials are currently cached. The module
::: tip ::: tip
This module is disabled by default. To enable it, set `disabled` to `false` in your configuration file. Dieses Modul ist standardmäßig deaktiviert. Setze in deiner Konfiguration `disabled` auf `false` um es zu aktivieren.
::: :::
@ -3129,7 +3214,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: By default the module will be shown if any of the following conditions are met:
- The current directory contains a `.terraform` folder - Das aktuelle Verzeichnis enthält eine `.terraform`-Datei
- Current directory contains a file with the `.tf`, `.tfplan` or `.tfstate` extensions - Current directory contains a file with the `.tf`, `.tfplan` or `.tfstate` extensions
### Optionen ### Optionen
@ -3143,7 +3228,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_files` | `[]` | Which filenames should trigger this module. |
| `detect_folders` | `[".terraform"]` | Which folders should trigger this module. | | `detect_folders` | `[".terraform"]` | Which folders should trigger this module. |
| `style` | `"bold 105"` | Stil für dieses Modul. | | `style` | `"bold 105"` | Stil für dieses Modul. |
| `disabled` | `false` | Disables the `terraform` module. | | `disabled` | `false` | Deaktiviert das `terraform` Modul. |
### Variables ### Variables
@ -3178,33 +3263,33 @@ format = "[🏎💨 $workspace]($style) "
## Uhrzeit ## Uhrzeit
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. 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.
::: tip ::: tip
This module is disabled by default. To enable it, set `disabled` to `false` in your configuration file. Dieses Modul ist standardmäßig deaktiviert. Setze in deiner Konfiguration `disabled` auf `false` um es zu aktivieren.
::: :::
### Optionen ### Optionen
| Option | Standardwert | Beschreibung | | Option | Standardwert | Beschreibung |
| ----------------- | ----------------------- | ---------------------------------------------------------------------------------------------------------------------------------- | | ----------------- | ----------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `format` | `"at [$time]($style) "` | The format string for the module. | | `format` | `"at [$time]($style) "` | The format string for the module. |
| `use_12hr` | `false` | Enables 12 hour formatting | | `use_12hr` | `false` | Aktiviert die Formatierung der Uhrzeit im 12-Stunden-Format. |
| `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. | | `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"` | The style for the module time | | `style` | `"bold yellow"` | Stil für dieses Modul. |
| `utc_time_offset` | `"local"` | Sets the UTC offset to use. Range from -24 &lt; x &lt; 24. Allows floats to accommodate 30/45 minute timezone offsets. | | `utc_time_offset` | `"local"` | Legt das UTC-Offset fest, das verwendet werden soll. Range from -24 &lt; x &lt; 24. Allows floats to accommodate 30/45 minute timezone offsets. |
| `disabled` | `true` | Disables the `time` module. | | `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 | | `time_range` | `"-"` | Sets the time range during which the module will be shown. Times must be specified in 24-hours format |
If `use_12hr` is `true`, then `time_format` defaults to `"%r"`. Otherwise, it defaults to `"%T"`. Manually setting `time_format` will override the `use_12hr` setting. 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.
### Variables ### Variables
| Variable | Beispiel | Beschreibung | | Variable | Beispiel | Beschreibung |
| --------- | ---------- | ------------------------------------ | | --------- | ---------- | ------------------------------------ |
| time | `13:08:10` | The current time. | | uhrzeit | `13:08:10` | The current time. |
| style\* | | Spiegelt den Wert der Option `style` | | style\* | | Spiegelt den Wert der Option `style` |
*: This variable can only be used as a part of a style string *: This variable can only be used as a part of a style string
@ -3222,14 +3307,14 @@ utc_time_offset = "-5"
time_range = "10:00:00-14:00:00" time_range = "10:00:00-14:00:00"
``` ```
## Username ## Benutzername
The `username` module shows active user's username. Das Modul wird nur dann angezeigt, wenn eine der folgenden Bedingungen zutrifft: Das Modul `username` zeigt den Benutzernamen des aktiven Benutzers. Das Modul wird nur dann angezeigt, wenn eine der folgenden Bedingungen zutrifft:
- The current user is root - The current user is root/admin
- The current user isn't the same as the one that is logged in - Der aktuelle Benutzer ist nicht derjenige, der derzeit angemeldet ist
- The user is currently connected as an SSH session - Der Benutzer ist über eine SSH-Sitzung verbunden
- The variable `show_always` is set to true - Die Variale `show_always` ist auf `true` gesetzt
::: tip ::: tip
@ -3239,13 +3324,13 @@ SSH connection is detected by checking environment variables `SSH_CONNECTION`, `
### Optionen ### Optionen
| Option | Standardwert | Beschreibung | | Option | Standardwert | Beschreibung |
| ------------- | ----------------------- | ------------------------------------- | | ------------- | ----------------------- | ------------------------------------------- |
| `style_root` | `"bold red"` | The style used when the user is root. | | `style_root` | `"bold red"` | The style used when the user is root/admin. |
| `style_user` | `"bold yellow"` | The style used for non-root users. | | `style_user` | `"bold yellow"` | Stil bei allen anderen Benutzern. |
| `format` | `"[$user]($style) in "` | Das Format für das Modul. | | `format` | `"[$user]($style) in "` | Das Format für das Modul. |
| `show_always` | `false` | Always shows the `username` module. | | `show_always` | `false` | `username`-Modul immer anzeigen. |
| `disabled` | `false` | Disables the `username` module. | | `disabled` | `false` | Deaktiviert das `username`-Modul. |
### Variables ### Variables
@ -3417,9 +3502,9 @@ The `custom` modules show the output of some arbitrary commands.
These modules will be shown if any of the following conditions are met: These modules will be shown if any of the following conditions are met:
- The current directory contains a file whose name is in `files` - The current directory contains a file whose name is in `detect_files`
- The current directory contains a directory whose name is in `directories` - The current directory contains a directory whose name is in `detect_folders`
- The current directory contains a file whose extension is in `extensions` - The current directory contains a file whose extension is in `detect_extensions`
- The `when` command returns 0 - The `when` command returns 0
- The current Operating System (std::env::consts::OS) matchs with `os` field if defined. - The current Operating System (std::env::consts::OS) matchs with `os` field if defined.
@ -3451,20 +3536,22 @@ Format strings can also contain shell specific prompt sequences, e.g. [Bash](htt
### Optionen ### Optionen
| Option | Standardwert | Beschreibung | | Option | Standardwert | Beschreibung |
| ------------- | ------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | | ------------------- | ------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `command` | `""` | The command whose output should be printed. The command will be passed on stdin to the shell. | | `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. | | `when` | `false` | Either a boolean value (`true` or `false`, without quotes) or a string shell command used as a condition to show the module. In case of a string, the module will be shown if the command returns a `0` status code. |
| `shell` | | [See below](#custom-command-shell) | | `shell` | | [See below](#custom-command-shell) |
| `description` | `"<custom module>"` | The description of the module that is shown when running `starship explain`. | | `beschreibung` | `"<custom module>"` | 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. | | `detect_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. | | `detect_folders` | `[]` | 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. | | `detect_extensions` | `[]` | The extensions that will be searched in the working directory for a match. |
| `symbol` | `""` | The symbol used before displaying the command output. | | `symbol` | `""` | The symbol used before displaying the command output. |
| `style` | `"bold green"` | Stil für dieses Modul. | | `style` | `"bold green"` | Stil für dieses Modul. |
| `format` | `"[$symbol($output )]($style)"` | Das Format für das Modul. | | `format` | `"[$symbol($output )]($style)"` | Das Format für das Modul. |
| `disabled` | `false` | Disables this `custom` 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). | | `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). |
| `use_stdin` | | An optional boolean value that overrides whether commands should be forwarded to the shell via the standard input or as an argument. If unset standard input is used by default, unless the shell does not support it (cmd, nushell). Setting this disables shell-specific argument handling. |
| `ignore_timeout` | `false` | Ignore global `command_timeout` setting and keep running external commands, no matter how long they take. |
### Variables ### Variables
@ -3487,7 +3574,7 @@ If unset, it will fallback to STARSHIP_SHELL and then to "sh" on Linux, and "cmd
The `command` will be passed in on stdin. The `command` will be passed in on stdin.
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. 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 -`. If `shell` is not given or only contains one element and Starship detects Cmd will be used, the following argument will automatically be added: `/C` and `stdin` will be set to `false`. If `shell` is not given or only contains one element and Starship detects Nushell will be used, the following arguments will automatically be added: `-c` and `stdin` will be set to `false`. This behavior can be avoided by explicitly passing arguments to the shell, e.g.
```toml ```toml
shell = ["pwsh", "-Command", "-"] shell = ["pwsh", "-Command", "-"]
@ -3512,12 +3599,18 @@ Automatic detection of shells and proper parameters addition are currently imple
[custom.foo] [custom.foo]
command = "echo foo" # shows output of command command = "echo foo" # shows output of command
files = ["foo"] # can specify filters but wildcards are not supported detect_files = ["foo"] # can specify filters but wildcards are not supported
when = """ test "$HOME" == "$PWD" """ when = """ test "$HOME" == "$PWD" """
format = " transcending [$output]($style)" format = " transcending [$output]($style)"
[custom.time] [custom.time]
command = "time /T" command = "time /T"
extensions = ["pst"] # filters *.pst files detect_extensions = ["pst"] # filters *.pst files
shell = ["pwsh.exe", "-NoProfile", "-Command", "-"] shell = ["pwsh.exe", "-NoProfile", "-Command", "-"]
[custom.time-as-arg]
command = "time /T"
detect_extensions = ["pst"] # filters *.pst files
shell = ["pwsh.exe", "-NoProfile", "-Command"]
use_stdin = false
``` ```

View File

@ -145,7 +145,7 @@
<img <img
src="https://raw.githubusercontent.com/starship/starship/master/media/demo.gif" src="https://raw.githubusercontent.com/starship/starship/master/media/demo.gif"
alt="Starship with iTerm2 and the Snazzy theme" alt="Starship mit iTerm2 und dem Snazzy Thema"
width="50%" width="50%"
align="right" align="right"
/> />
@ -160,7 +160,7 @@
- **Einfach:** schnell zu installieren  Betriebsbereit in nur wenigen Minuten. - **Einfach:** schnell zu installieren  Betriebsbereit in nur wenigen Minuten.
<p align="center"> <p align="center">
<a href="https://starship.rs/config/"><strong>Explore the Starship docs&nbsp;&nbsp;</strong></a> <a href="https://starship.rs/config/"><strong>Schau dir die Starship-Dokumentation an&nbsp;&nbsp;</strong></a>
</p> </p>
<a name="🚀-installation"></a> <a name="🚀-installation"></a>
@ -173,7 +173,7 @@
### Schritt 1. Installiere Starship ### Schritt 1. Installiere Starship
Select your operating system from the list below to view installation instructions: Wähle dein Betriebssystem aus der Liste für detaillierte Installationsanweisungen:
<details> <details>
<summary>Android</summary> <summary>Android</summary>
@ -264,7 +264,7 @@ Install Starship using any of the following package managers:
### Schritt 2. Richte deine Shell für die Nutzung von Starship ein ### Schritt 2. Richte deine Shell für die Nutzung von Starship ein
Configure your shell to initialize starship. Select yours from the list below: Konfigurieren deine Shell um Starship zu initialisieren. Wähle dafür deine Shell aus der Liste aus:
<details> <details>
<summary>Bash</summary> <summary>Bash</summary>
@ -278,7 +278,7 @@ eval "$(starship init bash)"
</details> </details>
<details> <details>
<summary>Cmd</summary> <summary>Cmd</summary>
You need to use [Clink](https://chrisant996.github.io/clink/clink.html) (v1.2.30+) with Cmd. Create a file at this path `%LocalAppData%\clink\starship.lua` with the following contents: You need to use [Clink](https://chrisant996.github.io/clink/clink.html) (v1.2.30+) with Cmd. Create a file at this path `%LocalAppData%\clink\starship.lua` with the following contents:
@ -297,7 +297,7 @@ Trage folgendes am Ende von `~/.config/fish/rc.elv` ein:
eval (starship init elvish) eval (starship init elvish)
``` ```
Note: Only Elvish v0.17+ is supported Note: Only Elvish v0.18+ is supported
</details> </details>
@ -390,9 +390,9 @@ eval "$(starship init zsh)"
### Schritt 3. Starship konfigurieren ### Schritt 3. Starship konfigurieren
Start a new shell instance, and you should see your beautiful new shell prompt. If you're happy with the defaults, enjoy! Starte eine neue Shell, um deinen neuen und schönen Prompt zu sehen. Wenn du mit den Defaults zufrieden bist, bist du bereits fertig!
If you're looking to further customize Starship: Falls du Starship weiter anpassen möchtest:
- **[Konfiguration](https://starship.rs/config/)** - Lerne, wie du Starship deinen Bedürfnissen nach anpassen kannst - **[Konfiguration](https://starship.rs/config/)** - Lerne, wie du Starship deinen Bedürfnissen nach anpassen kannst
@ -400,15 +400,15 @@ If you're looking to further customize Starship:
## 🤝 Mitwirken ## 🤝 Mitwirken
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). Wir laden Leute **aller Erfahrungsstufen** herzlich ein mitzumachen! Falls du dich mit dem Projekt vertaut machen willst, versuche ein [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/). Wenn du eine andere Sprache flüssig sprichts, würden wir uns sehr freuen wenn du helfen würdest die Dokumentation in anderen Sprachen auf dem aktuellsten Stand zu halten. Hier kannst du bei der Übersetzung helfen [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. 👋 Falls du an Starship mitwirken willst, wirf bitte einen Blick auf den [Contributing Guide](https://github.com/starship/starship/blob/master/CONTRIBUTING.md). Schau auch gerne auf unserem [Discord server](https://discord.gg/8Jzqu3T) vorbei. 👋
## 💭 Inspiriert durch ## 💭 Inspiriert durch
Please check out these previous works that helped inspire the creation of starship. 🙏 Checkt bitte diese älteren Projekte, die das Entstehen von Starhip inspiriert haben. 🙏
- **[denysdovhan/spaceship-prompt](https://github.com/denysdovhan/spaceship-prompt)** A ZSH prompt for astronauts. - **[denysdovhan/spaceship-prompt](https://github.com/denysdovhan/spaceship-prompt)** A ZSH prompt for astronauts.
@ -418,9 +418,9 @@ Please check out these previous works that helped inspire the creation of starsh
<p align="center"> <p align="center">
<br> <br>
<img width="100" src="https://raw.githubusercontent.com/starship/starship/master/media/icon.png" alt="Starship rocket icon"> <img width="100" src="https://raw.githubusercontent.com/starship/starship/master/media/icon.png" alt="Starship Raketen Icon">
</p> </p>
## 📝 Lizenz ## 📝 Lizenz
Copyright © 2019-present, [Starship Contributors](https://github.com/starship/starship/graphs/contributors).<br /> This project is [ISC](https://github.com/starship/starship/blob/master/LICENSE) licensed. Copyright © 2019-present, [Starship Contributors](https://github.com/starship/starship/graphs/contributors).<br /> Unter der [ISC](https://github.com/starship/starship/blob/master/LICENSE) Lizens.

View File

@ -1,4 +1,4 @@
# Advanced Installation # Erweiterte Installation
Um Starship zu installieren, musst du zwei Dinge tun: Um Starship zu installieren, musst du zwei Dinge tun:

View File

@ -120,7 +120,7 @@ description: '¡Starship es el prompt minimalista, ultrarápido e infinitamente
#### Elvish #### Elvish
::: warning Solo se admite Elvish v0.17 o superior. ::: ::: warning Solo se admite Elvish v0.18 o superior. :::
Añade el siguiente código al final de `~/.elvish/rc.elv`: Añade el siguiente código al final de `~/.elvish/rc.elv`:
@ -144,13 +144,13 @@ description: '¡Starship es el prompt minimalista, ultrarápido e infinitamente
#### Nushell #### Nushell
::: advertencia Esto cambiará en el futuro. Only Nushell v0.60+ is supported. ::: Run the following: ::: advertencia Esto cambiará en el futuro. Sólo se admite Nushell v0.60+. ::: Ejecuta lo siguiente:
```sh ```sh
mkdir ~/.cache/starship mkdir ~/.cache/starship
starship init nu | save ~/.cache/starship/init.nu starship init nu | save ~/.cache/starship/init.nu
``` ```
And add the following to the end of your Nushell configuration (find it by running `$nu.config-path`): Añade lo siguiente al final de tu configuración de Nushell (encuéntrala ejecutando `$nu.config-path`):
```sh ```sh
mkdir ~/.cache/starship mkdir ~/.cache/starship
@ -171,7 +171,7 @@ description: '¡Starship es el prompt minimalista, ultrarápido e infinitamente
#### Cmd #### Cmd
Necesitas usar [Clink](https://chrisant996.github.io/clink/clink.html) (v1.2.30+) con Cmd. Add the following to a file `starship.lua` and place this file in Clink scripts directory: Necesitas usar [Clink](https://chrisant996.github.io/clink/clink.html) (v1.2.30+) con Cmd. Añade lo siguiente a un archivo `starship.lua` y coloca este archivo en el directorio de scripts de Clink:
```lua ```lua
-- starship.lua -- starship.lua

View File

@ -131,7 +131,7 @@ Invoke-Expression (&starship init powershell)
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`. 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). Nota: El prompt derecho es una sola línea siguiendo la ubicación de entrada. Para alinear los 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, xonsh, cmd. `right_format` está actualmente soportado para los siguientes intérpretes de comandos: elvish, fish, zsh, xonsh, cmd.

File diff suppressed because it is too large Load Diff

View File

@ -1,4 +1,4 @@
# Frequently Asked Questions # Preguntas frecuentes
## ¿Cuál es la configuración usada en el GIF de demostración? ## ¿Cuál es la configuración usada en el GIF de demostración?

View File

@ -145,7 +145,7 @@
<img <img
src="https://raw.githubusercontent.com/starship/starship/master/media/demo.gif" src="https://raw.githubusercontent.com/starship/starship/master/media/demo.gif"
alt="Starship with iTerm2 and the Snazzy theme" alt="Starship con iTerm 2 y el tema Snazzy"
width="50%" width="50%"
align="right" align="right"
/> />
@ -160,7 +160,7 @@
- **Fácil:** rápido de instalar empieza a usarlo en minutos. - **Fácil:** rápido de instalar empieza a usarlo en minutos.
<p align="center"> <p align="center">
<a href="https://starship.rs/config/"><strong>Explore the Starship docs&nbsp;&nbsp;</strong></a> <a href="https://starship.rs/config/"><strong>Explora la documentación de Starship&nbsp;&nbsp;</strong></a>
</p> </p>
<a name="🚀-installation"></a> <a name="🚀-installation"></a>
@ -173,12 +173,12 @@
### Paso 1. Instalar Starship ### Paso 1. Instalar Starship
Select your operating system from the list below to view installation instructions: Seleccione su sistema operativo de la lista de abajo para ver las instrucciones de instalación:
<details> <details>
<summary>Android</summary> <summary>Android</summary>
Install Starship using any of the following package managers: Instalar Starship usando cualquiera de los siguientes gestores de paquetes:
| Repositorio | Instrucciones | | Repositorio | Instrucciones |
| --------------------------------------------------------------------------------- | ---------------------- | | --------------------------------------------------------------------------------- | ---------------------- |
@ -189,7 +189,7 @@ Install Starship using any of the following package managers:
<details> <details>
<summary>BSD</summary> <summary>BSD</summary>
Install Starship using any of the following package managers: Instalar Starship usando cualquiera de los siguientes gestores de paquetes:
| Distribución | Repositorio | Instrucciones | | Distribución | Repositorio | Instrucciones |
| ---------------- | -------------------------------------------------------- | --------------------------------- | | ---------------- | -------------------------------------------------------- | --------------------------------- |
@ -264,7 +264,7 @@ Instalar Starship usando cualquiera de los siguientes gestores de paquetes:
### Paso 2. Configura tu shell para usar Starship ### Paso 2. Configura tu shell para usar Starship
Configure your shell to initialize starship. Selecciona el tuyo de la lista de abajo: Configure su shell para inicializar starship. Selecciona el tuyo de la lista de abajo:
<details> <details>
<summary>Bash</summary> <summary>Bash</summary>
@ -280,7 +280,7 @@ eval "$(starship init bash)"
<details> <details>
<summary>Cmd</summary> <summary>Cmd</summary>
Necesitas usar [Clink](https://chrisant996.github.io/clink/clink.html) (v1.2.30+) con Cmd. Create a file at this path `%LocalAppData%\clink\starship.lua` with the following contents: Necesitas usar [Clink](https://chrisant996.github.io/clink/clink.html) (v1.2.30+) con Cmd. Crea un archivo en esta ruta `%LocalAppData%\clink\starship.lua` con el siguiente contenido:
```lua ```lua
load(io.popen('starship init cmd'):read("*a"))() load(io.popen('starship init cmd'):read("*a"))()
@ -297,7 +297,7 @@ Añade el siguiente código al final de `~/.elvish/rc.elv`:
eval (starship init elvish) eval (starship init elvish)
``` ```
Nota: Sólo se admite Elvish v0.17+ Nota: Solo se admite Elvish v0.18+
</details> </details>
@ -326,28 +326,28 @@ eval $(starship init ion)
<details> <details>
<summary>Nushell</summary> <summary>Nushell</summary>
Run the following: Ejecuta lo siguiente:
```sh ```sh
mkdir ~/.cache/starship mkdir ~/.cache/starship
starship init nu | save ~/.cache/starship/init.nu starship init nu | save ~/.cache/starship/init.nu
``` ```
And add the following to the end of your Nushell configuration (find it by running `$nu.config-path`): Añade lo siguiente al final de tu configuración de Nushell (encuéntrala ejecutando `$nu.config-path`):
```sh ```sh
starship init nu | save ~/.cache/starship/init.nu starship init nu | save ~/.cache/starship/init.nu
source ~/.cache/starship/init.nu source ~/.cache/starship/init.nu
``` ```
Note: Only Nushell v0.60+ is supported Nota: Solo se admite Nushell v0.60+
</details> </details>
<details> <details>
<summary>PowerShell</summary> <summary>PowerShell</summary>
Add the following to the end of your PowerShell configuration (find it by running `$PROFILE`): Añade lo siguiente al final de tu configuración de PowerShell (encuéntrala ejecutando `$PROFILE`):
```powershell ```powershell
Invoke-Expression (&starship init powershell) Invoke-Expression (&starship init powershell)
@ -390,9 +390,9 @@ eval "$(starship init zsh)"
### Paso 3. Configurar Starship ### Paso 3. Configurar Starship
Start a new shell instance, and you should see your beautiful new shell prompt. If you're happy with the defaults, enjoy! Inicia una nueva instancia de shell, y deberías ver tu nuevo y hermoso prompt para shell. Si estás contento con los valores por defecto, ¡disfruta!
If you're looking to further customize Starship: Si estás buscando personalizar Starship:
- **[Configuración](https://starship.rs/config/)** aprende a configurar Starship para ajustar el prompt a tu gusto - **[Configuración](https://starship.rs/config/)** aprende a configurar Starship para ajustar el prompt a tu gusto
@ -400,15 +400,15 @@ If you're looking to further customize Starship:
## 🤝 Contribuir ## 🤝 Contribuir
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). ¡Siempre estamos buscando colaboradores de **todos los niveles y habilidades**! Si estás interesado en empezar en el proyecto con algo sencillo, prueba con un problema etiquetado como [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/). Si hablas con fluidez en un idioma que no sea inglés, agradecemos mucho cualquier ayuda para mantener nuestros documentos traducidos y actualizados en otros idiomas. Si quieres ayudar, puedes contribuir con las traducciones en el [Crowdin de Starship](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. 👋 Si estás interesado en ayudar contribuyendo a starship, por favor échale un vistazo a [Guía de Colaboración](https://github.com/starship/starship/blob/master/CONTRIBUTING.md). También siéntete libre de pasarte por nuestro [servidor de Discord](https://discord.gg/8Jzqu3T) y saludarnos. 👋
## 💭 Inspirado por ## 💭 Inspirado por
Please check out these previous works that helped inspire the creation of starship. 🙏 Por favor, revisa estos proyectos que inspiraron la creación de Starship. 🙏
- **[denysdovhan/spaceship-prompt](https://github.com/denysdovhan/spaceship-prompt)** Un prompt de ZSH para astronautas. - **[denysdovhan/spaceship-prompt](https://github.com/denysdovhan/spaceship-prompt)** Un prompt de ZSH para astronautas.
@ -418,9 +418,9 @@ Please check out these previous works that helped inspire the creation of starsh
<p align="center"> <p align="center">
<br> <br>
<img width="100" src="https://raw.githubusercontent.com/starship/starship/master/media/icon.png" alt="Starship rocket icon"> <img width="100" src="https://raw.githubusercontent.com/starship/starship/master/media/icon.png" alt="Icono de Starship">
</p> </p>
## 📝 Licencia ## 📝 Licencia
Copyright © 2019-present, [Starship Contributors](https://github.com/starship/starship/graphs/contributors).<br /> This project is [ISC](https://github.com/starship/starship/blob/master/LICENSE) licensed. Copyright © 2019-actualidad, [Creadores de Starship](https://github.com/starship/starship/graphs/contributors).<br /> Este proyecto está bajo una licencia [ISC](https://github.com/starship/starship/blob/master/LICENSE).

View File

@ -1,4 +1,4 @@
# Advanced Installation # Instalación avanzada
Para instalar Starship, necesitas hacer dos cosas: Para instalar Starship, necesitas hacer dos cosas:
@ -63,7 +63,7 @@ Activa el módulo `programs.starship` en tu archivo `home.nix` y añade tus ajus
{ {
programs.starship = { programs.starship = {
enable = true; enable = true;
# Configuration written to ~/.config/starship.toml # Configuración escrita en ~/.config/starship.toml
settings = { settings = {
# add_newline = false; # add_newline = false;

View File

@ -2,40 +2,40 @@
Aqui tienes una colección de preajustes creados por la comunidad de Starship. ¡Si quieres compartir un preajuste, por favor, [envía un PR](https://github.com/starship/starship/edit/master/docs/presets/README.md) actualizando este archivo! 😊 Aqui tienes una colección de preajustes creados por la comunidad de Starship. ¡Si quieres compartir un preajuste, por favor, [envía un PR](https://github.com/starship/starship/edit/master/docs/presets/README.md) actualizando este archivo! 😊
To get details on how to use a preset, simply click on the image. Para obtener detalles sobre cómo utilizar un preajuste, simplemente haga clic en la imagen.
## [Símbolos de Nerd Font](./nerd-font.md) ## [Símbolos de Nerd Font](./nerd-font.md)
This preset changes the symbols for each module to use Nerd Font symbols. Este preajuste cambia los símbolos de cada módulo para usar símbolos Nerd Font.
[![Captura de pantalla del preajuste de los Símbolos de Nerd Font](/presets/img/nerd-font-symbols.png "Click to view Nerd Font Symbols preset")](./nerd-font) [![Captura de pantalla del preajuste de los Símbolos de Nerd Font](/presets/img/nerd-font-symbols.png "Haga clic para ver el preajuste de Símbolos de Nerd Font")](./nerd-font)
## [Segmentos entre Corchetes](./bracketed-segments.md) ## [Segmentos entre Corchetes](./bracketed-segments.md)
Este preajuste cambia el formato de todos los módulos incorporados para mostrar su segmento entre corchetes en lugar de usar la redacción por defecto de Starship ("via", "on", etc.). Este preajuste cambia el formato de todos los módulos incorporados para mostrar su segmento entre corchetes en lugar de usar la redacción por defecto de Starship ("via", "on", etc.).
[![Captura de pantalla del preajuste de los Segmentos entre Corchetes](/presets/img/bracketed-segments.png "Click to view Bracketed Segments preset")](./bracketed-segments) [![Captura de pantalla del preajuste de los Segmentos entre Corchetes](/presets/img/bracketed-segments.png "Haga clic para ver el preajuste de Segmentos entre Corchetes")](./bracketed-segments)
## [Símbolos de texto sin formato](./plain-text.md) ## [Símbolos de texto sin formato](./plain-text.md)
This preset changes the symbols for each module into plain text. Great if you don't have access to Unicode. Este preajuste cambia los símbolos a texto sin formato. Bueno si usted no tiene acceso a Unicode.
[![Captura de pantalla del ajuste de los Símbolos de Texto Plano](/presets/img/plain-text-symbols.png "Click to view Plain Text Symbols preset")](./plain-text) [![Captura de pantalla del ajuste de los Símbolos de Texto Plano](/presets/img/plain-text-symbols.png "Haga clic para ver el preajuste de Símbolos de Texto Sin Formato")](./plain-text)
## [No Runtime Versions](./no-runtimes.md) ## [Ocultar Versiones en Tiempo de Ejecución](./no-runtimes.md)
Este preajuste oculta la versión de los tiempos de ejecución del idioma. Si trabajas en contenedores o entornos virtualizados, ¡ésto es para ti! Este preajuste oculta la versión de los tiempos de ejecución del idioma. Si trabajas en contenedores o entornos virtualizados, ¡ésto es para ti!
[![Captura de pantalla del preajuste de Ocultar de versiones de tiempo de ejecución](/presets/img/no-runtime-versions.png "Click to view No Runtime Versions preset")](./no-runtimes) [![Captura de pantalla del preajuste de Ocultar de versiones de tiempo de ejecución](/presets/img/no-runtime-versions.png "Haga clic para ver el preajuste de Ocultar Versiones en Tiempo de Ejecución")](./no-runtimes)
## [Pure Prompt](./pure-preset.md) ## [Prompt de Pure](./pure-preset.md)
Esta preajuste emula la apariencia y el comportamiento de [Pure](https://github.com/sindresorhus/pure). Esta preajuste emula la apariencia y el comportamiento de [Pure](https://github.com/sindresorhus/pure).
[![Captura de pantalla del ajuste de Pure](/presets/img/pure-preset.png "Click to view Pure Prompt preset")](./pure-preset) [![Captura de pantalla del ajuste de Pure](/presets/img/pure-preset.png "Haga clic para ver el preajuste del Prompt de Pure")](./pure-preset)
## [Pastel Powerline](./pastel-powerline.md) ## [Pastel Powerline](./pastel-powerline.md)
This preset is inspired by [M365Princess](https://github.com/JanDeDobbeleer/oh-my-posh/blob/main/themes/M365Princess.omp.json). It also shows how path substitution works in starship. Este preajuste está inspirado en [M365Princess](https://github.com/JanDeDobbeleer/oh-my-posh/blob/main/themes/M365Princess.omp.json). También muestra cómo funciona la sustitución de rutas en Starship.
[![Screenshot of Pastel Powerline preset](/presets/img/pastel-powerline.png "Click to view Pure Prompt preset")](./pastel-powerline) [![Captura de pantalla del preajuste de Pastel Powerline](/presets/img/pastel-powerline.png "Haga clic para ver el preajuste del Prompt de Pure")](./pastel-powerline)

View File

@ -1,6 +1,6 @@
[Return to Presets](./README.md#bracketed-segments) [Volver a Preajustes](./README.md#bracketed-segments)
# Bracketed Segments Preset # Preajuste Segmentos entre Corchetes
Este preajuste cambia el formato de todos los módulos incorporados para mostrar su segmento entre corchetes en lugar de usar la redacción por defecto de Starship ("via", "on", etc.). Este preajuste cambia el formato de todos los módulos incorporados para mostrar su segmento entre corchetes en lugar de usar la redacción por defecto de Starship ("via", "on", etc.).
@ -8,6 +8,6 @@ Este preajuste cambia el formato de todos los módulos incorporados para mostrar
### Configuración ### Configuración
[Click to download TOML](/presets/toml/bracketed-segments.toml) [Clic para descargar TOML](/presets/toml/bracketed-segments.toml)
<<< @/.vuepress/public/presets/toml/bracketed-segments.toml <<< @/.vuepress/public/presets/toml/bracketed-segments.toml

View File

@ -1,8 +1,8 @@
[Return to Presets](./README.md#nerd-font-symbols) [Volver a Preajustes](./README.md#nerd-font-symbols)
# Nerd Font Symbols Preset # Preajuste de Símbolos de Nerd Font
This preset changes the symbols for each module to use Nerd Font symbols. Este preajuste cambia los símbolos de cada módulo para usar símbolos Nerd Font.
![Captura de pantalla del preajuste de los Símbolos de Nerd Font](/presets/img/nerd-font-symbols.png) ![Captura de pantalla del preajuste de los Símbolos de Nerd Font](/presets/img/nerd-font-symbols.png)
@ -12,6 +12,6 @@ This preset changes the symbols for each module to use Nerd Font symbols.
### Configuración ### Configuración
[Click to download TOML](/presets/toml/nerd-font-symbols.toml) [Clic para descargar TOML](/presets/toml/nerd-font-symbols.toml)
<<< @/.vuepress/public/presets/toml/nerd-font-symbols.toml <<< @/.vuepress/public/presets/toml/nerd-font-symbols.toml

View File

@ -1,6 +1,6 @@
[Return to Presets](./README.md#no-runtime-versions) [Volver a Preajustes](./README.md#no-runtime-versions)
# No Runtime Versions Preset # Preajuste Ocultar Versiones en Tiempo de Ejecución
Este preajuste oculta la versión de los tiempos de ejecución del idioma. Si trabajas en contenedores o entornos virtualizados, ¡ésto es para ti! Este preajuste oculta la versión de los tiempos de ejecución del idioma. Si trabajas en contenedores o entornos virtualizados, ¡ésto es para ti!
@ -8,6 +8,6 @@ Este preajuste oculta la versión de los tiempos de ejecución del idioma. Si tr
### Configuración ### Configuración
[Click to download TOML](/presets/toml/no-runtime-versions.toml) [Clic para descargar TOML](/presets/toml/no-runtime-versions.toml)
<<< @/.vuepress/public/presets/toml/no-runtime-versions.toml <<< @/.vuepress/public/presets/toml/no-runtime-versions.toml

View File

@ -1,17 +1,17 @@
[Return to Presets](./README.md#pastel-powerline) [Volver a Preajustes](./README.md#pastel-powerline)
# Pastel Powerline Preset # Preajuste Pastel Powerline
This preset is inspired by [M365Princess](https://github.com/JanDeDobbeleer/oh-my-posh/blob/main/themes/M365Princess.omp.json). It also shows how path substitution works in starship. Este preajuste está inspirado en [M365Princess](https://github.com/JanDeDobbeleer/oh-my-posh/blob/main/themes/M365Princess.omp.json). También muestra cómo funciona la sustitución de rutas en Starship.
![Screenshot of Pastel Powerline preset](/presets/img/pastel-powerline.png) ![Captura de pantalla del preajuste Pastel Powerline](/presets/img/pastel-powerline.png)
### Prerequisitos ### Prerequisitos
- A [Nerd Font](https://www.nerdfonts.com/) installed and enabled in your terminal (the example uses Caskaydia Cove Nerd Font) - Una [Nerd Font](https://www.nerdfonts.com/) instalada y habilitada en tu terminal (el ejemplo usa Fira Code Nerd Font)
### Configuración ### Configuración
[Click to download TOML](/presets/toml/pastel-powerline.toml) [Clic para descargar TOML](/presets/toml/pastel-powerline.toml)
<<< @/.vuepress/public/presets/toml/pastel-powerline.toml <<< @/.vuepress/public/presets/toml/pastel-powerline.toml

View File

@ -1,13 +1,13 @@
[Return to Presets](./README.md#plain-text-symbols) [Volver a Preajustes](./README.md#plain-text-symbols)
## Plain Text Symbols Preset ## Preajuste Símbolos de Texto sin Formato
This preset changes the symbols for each module into plain text. Great if you don't have access to Unicode. Este preajuste cambia los símbolos a texto sin formato. Bueno si usted no tiene acceso a Unicode.
![Captura de pantalla del ajuste de los Símbolos de Texto Plano](/presets/img/plain-text-symbols.png) ![Captura de pantalla del ajuste de los Símbolos de Texto Plano](/presets/img/plain-text-symbols.png)
### Configuración ### Configuración
[Click to download TOML](/presets/toml/plain-text-symbols.toml) [Clic para descargar TOML](/presets/toml/plain-text-symbols.toml)
<<< @/.vuepress/public/presets/toml/plain-text-symbols.toml <<< @/.vuepress/public/presets/toml/plain-text-symbols.toml

View File

@ -1,6 +1,6 @@
[Return to Presets](./README.md#pure) [Volver a Preajustes](./README.md#pure)
# Pure Preset # Preajuste Pure
Esta preajuste emula la apariencia y el comportamiento de [Pure](https://github.com/sindresorhus/pure). Esta preajuste emula la apariencia y el comportamiento de [Pure](https://github.com/sindresorhus/pure).
@ -8,6 +8,6 @@ Esta preajuste emula la apariencia y el comportamiento de [Pure](https://github.
### Configuración ### Configuración
[Click to download TOML](/presets/toml/pure-preset.toml) [Clic para descargar TOML](/presets/toml/pure-preset.toml)
<<< @/.vuepress/public/presets/toml/pure-preset.toml <<< @/.vuepress/public/presets/toml/pure-preset.toml

View File

@ -120,7 +120,7 @@ description: Starship est une invite minimaliste, ultra-rapide et hautement pers
#### Elvish #### Elvish
::: warning Seul elvish v0.17 ou supérieur est pris en charge. ::: ::: warning Seul elvish v0.18 ou supérieur est pris en charge. :::
Ajoutez ce qui suit à la fin de `~/.elvish/rc.elv`: Ajoutez ce qui suit à la fin de `~/.elvish/rc.elv`:
@ -144,13 +144,13 @@ description: Starship est une invite minimaliste, ultra-rapide et hautement pers
#### Nushell #### Nushell
::: warning Cela va changer dans le futur. Only Nushell v0.60+ is supported. ::: Run the following: ::: warning Cela va changer dans le futur. Seul Nushell v0.60+ est supporté. ::: Exécutez les commandes suivantes:
```sh ```sh
mkdir ~/.cache/starship mkdir ~/.cache/starship
starship init nu | save ~/.cache/starship/init.nu starship init nu | save ~/.cache/starship/init.nu
``` ```
And add the following to the end of your Nushell configuration (find it by running `$nu.config-path`): Ajoutez le code suivant à la fin de votre configuration Nushell (trouvez-la en exécutant `$nu.config path`):
```sh ```sh
mkdir ~/.cache/starship mkdir ~/.cache/starship
@ -171,7 +171,7 @@ description: Starship est une invite minimaliste, ultra-rapide et hautement pers
#### Cmd #### Cmd
Vous devez utiliser [Clink](https://chrisant996.github.io/clink/clink.html) (v1.2.30+) avec Cmd. Add the following to a file `starship.lua` and place this file in Clink scripts directory: Vous devez utiliser [Clink](https://chrisant996.github.io/clink/clink.html) (v1.2.30+) avec Cmd. Ajoutez le code ci-dessous dans un fichier `starship.lua` et placez-le dans le dossier des scripts Clink:
```lua ```lua
-- starship.lua -- starship.lua

View File

@ -10,9 +10,9 @@ Les configurations dans cette section sont sujettes à modification dans les fut
## Commandes pré-invite et pré-exécution personnalisées dans Cmd ## Commandes pré-invite et pré-exécution personnalisées dans Cmd
Clink provides extremely flexible APIs to run pre-prompt and pre-exec commands in Cmd shell. It is fairly simple to use with Starship. Make the following changes to your `starship.lua` file as per your requirements: Clink fournit des APIs extrêmement flexibles pour exécuter des commandes pre-invite et pre-exec dans Cmd. Il est assez simple à utiliser avec Starship. Effectuez les modifications suivantes dans votre fichier `starship.lua`, en fonction de vos besoins:
- To run a custom function right before the prompt is drawn, define a new function called `starship_preprompt_user_func`. This function receives the current prompt as a string that you can utilize. For example, to draw a rocket before the prompt, you would do - Pour exécuter une fonction juste avant que linvite soit dessinée, définissez une nouvelle fonction appelée `starship_preprompt_user_func`. Cette fonction reçoit linvite courante sous la forme dune chaine que vous pouvez utiliser. Par exemple, pour dessiner une fusée avant linvite, vous pouvez faire
```lua ```lua
function starship_preprompt_user_func(prompt) function starship_preprompt_user_func(prompt)
@ -22,7 +22,7 @@ end
load(io.popen('starship init cmd'):read("*a"))() load(io.popen('starship init cmd'):read("*a"))()
``` ```
- To run a custom function right before a command is executed, define a new function called `starship_precmd_user_func`. This function receives the current commandline as a string that you can utilize. For example, to print the command that's about to be executed, you would do - Pour exécuter une fonction personnalisée juste avant quune commande soit exécutée, définissez une nouvelle fonction appelée `starship_precmd_user_func`. Cette fonction reçoit la ligne de commande courante sous la forme dune chaine que vous pouvez utiliser. Par exemple, pour afficher la commande sur le point dêtre exécutée, vous pouvez faire
```lua ```lua
function starship_precmd_user_func(line) function starship_precmd_user_func(line)
@ -71,7 +71,7 @@ function Invoke-Starship-PreCommand {
## Modifier le titre des fenêtres ## Modifier le titre des fenêtres
Certaines commandes du shell changeront automatiquement le titre de la fenêtre (par exemple, pour refléter le dossier courant). Fish le fait même par défaut. Starship does not do this, but it's fairly straightforward to add this functionality to `bash`, `zsh`, `cmd` or `powershell`. Certaines commandes du shell changeront automatiquement le titre de la fenêtre (par exemple, pour refléter le dossier courant). Fish le fait même par défaut. Starship ne fait pas ça, mais cest assez facile dajouter cette fonctionnalité à `bash`, `zsh`, `cmd` ou `powershell`.
Tout d'abord, définissez une fonction de changement de titre de fenêtre (identique en bash et zsh) : Tout d'abord, définissez une fonction de changement de titre de fenêtre (identique en bash et zsh) :
@ -106,7 +106,7 @@ function set_win_title(){
starship_precmd_user_func="set_win_title" starship_precmd_user_func="set_win_title"
``` ```
For Cmd, you can change the window title using the `starship_preprompt_user_func` function. Pour Cmd, vous pouvez changer le titre de la fenêtre en utilisant la fonction `starship_preprompt_user_func`.
```lua ```lua
function starship_preprompt_user_func(prompt) function starship_preprompt_user_func(prompt)
@ -116,7 +116,7 @@ end
load(io.popen('starship init cmd'):read("*a"))() load(io.popen('starship init cmd'):read("*a"))()
``` ```
You can also set a similar output with PowerShell by creating a function named `Invoke-Starship-PreCommand`. Vous pouvez également faire la même chose avec PowerShell en créant une fonction nommée `Invoke-Starship-PreCommand`.
```powershell ```powershell
# edit $PROFILE # edit $PROFILE
@ -129,11 +129,11 @@ Invoke-Expression (&starship init powershell)
## Mettre linvite à droite ## Mettre linvite à droite
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`. Certains shells peuvent gérer une invite de commande à droite, sur la même ligne que lentrée utilisateur. Starship peut définir le contenu de cet invite à droite en utilisant loption `right_format`. Nimporte quel module qui peut être utilisé dans `format` est aussi géré dans `right_format`. La variable `$all` va seulement contenir les modules qui ne sont explicitement utilisés ni dans `format`, ni dans `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). Note: linvite à droite est une seule ligne, sur la même ligne que lentrée. 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, xonsh, cmd. `right_format` est actuellement géré pour les shells suivants: elvish, fish, zsh, xonsh, cmd.
### Exemple ### Exemple
@ -155,13 +155,13 @@ Génère linvite suivante:
## Invite de continuation ## Invite de continuation
Some shells support a continuation prompt along with the normal prompt. This prompt is rendered instead of the normal prompt when the user has entered an incomplete statement (such as a single left parenthesis or quote). Certains shells gèrent une invite de continuation en plus de linvite normale. Cette invite est affichée à la place de linvite normale quand lutilisateur a entré une expression incomplète (par exemple, une parenthèse gauche ou une apostrophe seule).
Starship can set the continuation prompt using the `continuation_prompt` option. The default prompt is `"[∙](bright-black) "`. Starship peut définir linvite de continuation en utilisant loption `continuation_prompt`. Linvite par défaut est `"[∙](bright-black) "`.
Note: `continuation_prompt` should be set to a literal string without any variables. Note: la valeur de `continuation_prompt` doit être une chaine littérale, sans variable.
Note: Continuation prompts are only available in the following shells: Note: les invites de confirmation sont uniquement disponibles pour les shells suivants:
- `bash` - `bash`
- `zsh` - `zsh`
@ -172,7 +172,7 @@ Note: Continuation prompts are only available in the following shells:
```toml ```toml
# ~/.config/starship.toml # ~/.config/starship.toml
# A continuation prompt that displays two filled in arrows # Un invite de continuation qui affiche deux flèches pleines
continuation_prompt = "▶▶" continuation_prompt = "▶▶"
``` ```

File diff suppressed because it is too large Load Diff

View File

@ -297,7 +297,7 @@ Ajoutez ce qui suit à la fin de `~/.elvish/rc.elv`:
eval (starship init elvish) eval (starship init elvish)
``` ```
Note: Seul Elvish v0.17+ est supporté Note: Seul Elvish v0.18+ est supporté
</details> </details>
@ -326,28 +326,28 @@ eval $(starship init ion)
<details> <details>
<summary>Nushell</summary> <summary>Nushell</summary>
Run the following: Exécutez les commandes suivantes:
```sh ```sh
mkdir ~/.cache/starship mkdir ~/.cache/starship
starship init nu | save ~/.cache/starship/init.nu starship init nu | save ~/.cache/starship/init.nu
``` ```
And add the following to the end of your Nushell configuration (find it by running `$nu.config-path`): Ajoutez le code suivant à la fin de votre configuration Nushell (trouvez-la en exécutant `$nu.config path`):
```sh ```sh
starship init nu | save ~/.cache/starship/init.nu starship init nu | save ~/.cache/starship/init.nu
source ~/.cache/starship/init.nu source ~/.cache/starship/init.nu
``` ```
Note: Only Nushell v0.60+ is supported Note: Seul Nushell v0.60+ est supporté
</details> </details>
<details> <details>
<summary>PowerShell</summary> <summary>PowerShell</summary>
Add the following to the end of your PowerShell configuration (find it by running `$PROFILE`): Ajoutez ce qui suit à la fin de votre configuration PowerShell (trouvez-la en exécutant `$PROFILE`):
```powershell ```powershell
Invoke-Expression (&starship init powershell) Invoke-Expression (&starship init powershell)
@ -390,9 +390,9 @@ eval "$(starship init zsh)"
### Étape 3. Configurer Starship ### Étape 3. Configurer Starship
Start a new shell instance, and you should see your beautiful new shell prompt. If you're happy with the defaults, enjoy! Démarrez une nouvelle instance de votre shell, et vous devriez voir votre magnifique nouveau prompt. Si vous appréciez les paramètres par défaut, profitez!
If you're looking to further customize Starship: Si vous souhaitez personnaliser Starship:
- **[Configuration](https://starship.rs/config/)** apprenez à configurer Starship pour ajuster votre prompt à vos préférences - **[Configuration](https://starship.rs/config/)** apprenez à configurer Starship pour ajuster votre prompt à vos préférences
@ -400,15 +400,15 @@ If you're looking to further customize Starship:
## 🤝 Contribuer ## 🤝 Contribuer
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). Nous sommes toujours à la recherche de contributeurs de **tous les niveaux de compétence**! Si vous cherchez à faciliter votre entrée dans le projet, essayez un [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/). Si vous parlez couramment une langue autre que l'anglais, nous apprécions grandement toute aide pour que nos documents soient traduits et mis à jour dans d'autres langues. Si vous souhaitez nous aider, les traductions peuvent êtres suggérées sur le [Crowdin de Starship](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. 👋 Si vous êtes intéressé à aider à contribuer à Starship, veuillez jeter un coup d'oeil à notre [Guide de contribution](https://github.com/starship/starship/blob/master/CONTRIBUTING.md). Aussi, n'hésitez pas à vous rendre sur notre [serveur Discord](https://discord.gg/8Jzqu3T) pour dire bonjour. 👋
## 💭Inspiré par ## 💭Inspiré par
Please check out these previous works that helped inspire the creation of starship. 🙏 Jetez un œil aux précédents projets qui ont inspiré la création de starship. 🙏
- **[denysdovhan/spaceship-prompt](https://github.com/denysdovhan/spaceship-prompt)** Un prompt ZSH pour les astronautes. - **[denysdovhan/spaceship-prompt](https://github.com/denysdovhan/spaceship-prompt)** Un prompt ZSH pour les astronautes.
@ -418,9 +418,9 @@ Please check out these previous works that helped inspire the creation of starsh
<p align="center"> <p align="center">
<br> <br>
<img width="100" src="https://raw.githubusercontent.com/starship/starship/master/media/icon.png" alt="Starship rocket icon"> <img width="100" src="https://raw.githubusercontent.com/starship/starship/master/media/icon.png" alt="Icône de fusée de Starship">
</p> </p>
## 📝 License ## 📝 License
Copyright © 2019-present, [Starship Contributors](https://github.com/starship/starship/graphs/contributors).<br /> This project is [ISC](https://github.com/starship/starship/blob/master/LICENSE) licensed. Copyright © 2019-présent, [Contributeurs Starship](https://github.com/starship/starship/graphs/contributors).<br /> Ce projet est sous licence [ISC](https://github.com/starship/starship/blob/master/LICENSE).

View File

@ -120,7 +120,7 @@ description: Starship merupakan sebuah prompt yang minimal, super cepat, dan san
#### Elvish #### Elvish
::: warning Hanya elvish v0.17 atau versi yang lebih baru yang mendapat dukungan pengembangan. ::: ::: warning Hanya elvish v0.18 atau versi yang lebih baru yang mendapat dukungan pengembangan. :::
Tambahkan skrip berikut pada baris akhir `~/.elvish/rc.elv`: Tambahkan skrip berikut pada baris akhir `~/.elvish/rc.elv`:

View File

@ -131,7 +131,7 @@ Invoke-Expression (&starship init powershell)
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`. 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). 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, xonsh, cmd. `right_format` is currently supported for the following shells: elvish, fish, zsh, xonsh, cmd.

File diff suppressed because it is too large Load Diff

View File

@ -160,7 +160,7 @@
- **Mudah:** pemasangan singkat  mulai menggunakannya dalam hitungan menit. - **Mudah:** pemasangan singkat  mulai menggunakannya dalam hitungan menit.
<p align="center"> <p align="center">
<a href="https://starship.rs/config/"><strong>Explore the Starship docs&nbsp;&nbsp;</strong></a> <a href="https://starship.rs/config/"><strong>Jelajahi dokumentasi Starship&nbsp;&nbsp;</strong></a>
</p> </p>
<a name="🚀-installation"></a> <a name="🚀-installation"></a>
@ -297,7 +297,7 @@ Tambahkan skrip berikut pada baris akhir `~/.elvish/rc.elv`:
eval (starship init elvish) eval (starship init elvish)
``` ```
Note: Only Elvish v0.17+ is supported Note: Only Elvish v0.18+ is supported
</details> </details>
@ -392,7 +392,7 @@ eval "$(starship init zsh)"
Start a new shell instance, and you should see your beautiful new shell prompt. If you're happy with the defaults, enjoy! Start a new shell instance, and you should see your beautiful new shell prompt. If you're happy with the defaults, enjoy!
If you're looking to further customize Starship: Jika kamu ingin mengkustomisasi Starship lebih jauh:
- **[Configuration](https://starship.rs/config/)** learn how to configure Starship to tweak your prompt to your liking - **[Configuration](https://starship.rs/config/)** learn how to configure Starship to tweak your prompt to your liking
@ -404,7 +404,7 @@ We are always looking for contributors of **all skill levels**! If you're lookin
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/). 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/).
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. 👋 Jika kamu tertarik untuk membantu berkontribusi ke starship, silakan lihat [Pedoman Berkontribusi](https://github.com/starship/starship/blob/master/CONTRIBUTING.md) kami. Also, feel free to drop into our [Discord server](https://discord.gg/8Jzqu3T) and say hi. 👋
## 💭 Terinspirasi Oleh ## 💭 Terinspirasi Oleh
@ -418,7 +418,7 @@ Please check out these previous works that helped inspire the creation of starsh
<p align="center"> <p align="center">
<br> <br>
<img width="100" src="https://raw.githubusercontent.com/starship/starship/master/media/icon.png" alt="Starship rocket icon"> <img width="100" src="https://raw.githubusercontent.com/starship/starship/master/media/icon.png" alt="Ikon roket Starship">
</p> </p>
## 📝 Lisensi ## 📝 Lisensi

View File

@ -120,7 +120,7 @@ description: Starship è il prompt minimalista, super veloce ed estremamente per
#### Elvish #### Elvish
::: warning È supportato solo elvish v0.17 o superiore. ::: ::: warning È supportato solo elvish v0.18 o superiore. :::
Aggiungi quanto segue alla fine di `~/.elvish/rc.elv`: Aggiungi quanto segue alla fine di `~/.elvish/rc.elv`:

View File

@ -131,7 +131,7 @@ Invoke-Expression (&starship init powershell)
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`. 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). 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, xonsh, cmd. `right_format` is currently supported for the following shells: elvish, fish, zsh, xonsh, cmd.

View File

@ -9,6 +9,9 @@ mkdir -p ~/.config && touch ~/.config/starship.toml
Tutta la configurazione per starship è fatta in questo file [TOML](https://github.com/toml-lang/toml): Tutta la configurazione per starship è fatta in questo file [TOML](https://github.com/toml-lang/toml):
```toml ```toml
# Get editor completions based on the config schema
"$schema" = 'https://starship.rs/config-schema.json'
# Inserts a blank line between shell prompts # Inserts a blank line between shell prompts
add_newline = true add_newline = true
@ -199,6 +202,7 @@ $hg_branch\
$docker_context\ $docker_context\
$package\ $package\
$buf\ $buf\
$c\
$cmake\ $cmake\
$cobol\ $cobol\
$container\ $container\
@ -235,6 +239,7 @@ $vagrant\
$zig\ $zig\
$nix_shell\ $nix_shell\
$conda\ $conda\
$spack\
$memory_usage\ $memory_usage\
$aws\ $aws\
$gcloud\ $gcloud\
@ -263,9 +268,9 @@ format = "$all$directory$character"
## AWS ## AWS
The `aws` module shows the current AWS region and profile when credentials, a `credential_process` or a `sso_start_url` have been setup. 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. The `aws` module shows the current AWS region and profile when credentials, a `credential_process` or a `sso_start_url` have been setup. Alternatively, you can force this module to show the region and profile even when the credentials have not been setup with the `force_display` option. 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.
The module will display a profile only if its credentials are present in `~/.aws/credentials` or a `credential_process` is defined in `~/.aws/config`. Alternatively, having any of the `AWS_ACCESS_KEY_ID`, `AWS_SECRET_ACCESS_KEY`, or `AWS_SESSION_TOKEN` env vars defined will also suffice. The module will display a profile only if its credentials are present in `~/.aws/credentials` or a `credential_process` is defined in `~/.aws/config`. Alternatively, having any of the `AWS_ACCESS_KEY_ID`, `AWS_SECRET_ACCESS_KEY`, or `AWS_SESSION_TOKEN` env vars defined will also suffice. If the option `force_display` is set to `true`, all available information will be displayed even if the conditions above are not respected.
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. 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.
@ -275,15 +280,16 @@ When using [AWSume](https://awsu.me) the profile is read from the `AWSUME_PROFIL
### Opzioni ### Opzioni
| Opzione | Default | Descrizione | | Opzione | Default | Descrizione |
| ------------------- | -------------------------------------------------------------------- | ----------------------------------------------------------------- | | ------------------- | -------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------- |
| `format` | `'on [$symbol($profile )(\($region\) )(\[$duration\])]($style)'` | The format for the module. | | `format` | `'on [$symbol($profile )(\($region\) )(\[$duration\])]($style)'` | The format for the module. |
| `symbol` | `"☁️ "` | The symbol used before displaying the current AWS profile. | | `symbol` | `"☁️ "` | The symbol used before displaying the current AWS profile. |
| `region_aliases` | | Table of region aliases to display in addition to the AWS name. | | `region_aliases` | | Table of region aliases to display in addition to the AWS name. |
| `profile_aliases` | | Table of profile aliases to display in addition to the AWS name. | | `profile_aliases` | | Table of profile aliases to display in addition to the AWS name. |
| `style` | `"bold yellow"` | Lo stile per il modulo. | | `style` | `"bold yellow"` | Lo stile per il modulo. |
| `expiration_symbol` | `X` | The symbol displayed when the temporary credentials have expired. | | `expiration_symbol` | `X` | The symbol displayed when the temporary credentials have expired. |
| `disabled` | `false` | Disables the `AWS` module. | | `disabled` | `false` | Disables the `AWS` module. |
| `force_display` | `false` | If `true` displays info even if `credentials`, `credential_process` or `sso_start_url` have not been setup. |
### Variables ### Variables
@ -472,6 +478,52 @@ The `buf` module shows the currently installed version of [Buf](https://buf.buil
symbol = "🦬 " symbol = "🦬 "
``` ```
## C
The `c` module shows some information about your C compiler. By default the module will be shown if the current directory contains a `.c` or `.h` file.
### Opzioni
| Opzione | Default | Descrizione |
| ------------------- | --------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------- |
| `format` | `"via [$symbol($version(-$name) )]($style)"` | The format string for the module. |
| `version_format` | `"v${raw}"` | Il formato della versione. Le variabili disponibili sono `raw`, `major`, `minore`, & `patch` |
| `symbol` | `"C "` | The symbol used before displaying the compiler details |
| `detect_extensions` | `["c", "h"]` | Quali estensioni dovrebbero attivare questo modulo. |
| `detect_files` | `[]` | Quali nomi di file dovrebbero attivare questo modulo. |
| `detect_folders` | `[]` | Quali cartelle dovrebbero attivare questo modulo. |
| `commands` | [ [ "cc", "--version" ], [ "gcc", "--version" ], [ "clang", "--version" ] ] | How to detect what the compiler is |
| `style` | `"bold 149"` | Lo stile per il modulo. |
| `disabled` | `false` | Disables the `c` module. |
### Variables
| Variable | Esempio | Descrizione |
| -------- | ------- | ------------------------------------ |
| name | clang | The name of the compiler |
| version | 13.0.0 | The version of the compiler |
| symbol | | Mirrors the value of option `symbol` |
| style | | Mirrors the value of option `style` |
NB that `version` is not in the default format.
### Commands
The `commands` option accepts a list of commands to determine the compiler version and name.
Each command is represented as a list of the executable name, followed by its arguments, usually something like `["mycc", "--version"]`. Starship will try executing each command until it gets a result on STDOUT.
If a C compiler is not supported by this module, you can request it by [raising an issue on GitHub](https://github.com/starship/starship/).
### Esempio
```toml
# ~/.config/starship.toml
[c]
format = "via [$name $version]($style)"
```
## Character ## Character
The `character` module shows a character (usually an arrow) beside where the text is entered in your terminal. The `character` module shows a character (usually an arrow) beside where the text is entered in your terminal.
@ -550,9 +602,9 @@ The `cmake` module shows the currently installed version of [CMake](https://cmak
| `format` | `"via [$symbol($version )]($style)"` | The format for the module. | | `format` | `"via [$symbol($version )]($style)"` | The format for the module. |
| `version_format` | `"v${raw}"` | Il formato della versione. Le variabili disponibili sono `raw`, `major`, `minore`, & `patch` | | `version_format` | `"v${raw}"` | Il formato della versione. Le variabili disponibili sono `raw`, `major`, `minore`, & `patch` |
| `symbol` | `"△ "` | The symbol used before the version of cmake. | | `symbol` | `"△ "` | The symbol used before the version of cmake. |
| `detect_extensions` | `[]` | Which extensions should trigger this module | | `detect_extensions` | `[]` | Quali estensioni dovrebbero attivare questo modulo |
| `detect_files` | `["CMakeLists.txt", "CMakeCache.txt"]` | Which filenames should trigger this module | | `detect_files` | `["CMakeLists.txt", "CMakeCache.txt"]` | Quali nomi di file dovrebbero attivare questo modulo |
| `detect_folders` | `[]` | Which folders should trigger this module | | `detect_folders` | `[]` | Quali cartelle dovrebbero attivare questo modulo |
| `style` | `"bold blue"` | Lo stile per il modulo. | | `style` | `"bold blue"` | Lo stile per il modulo. |
| `disabled` | `false` | Disables the `cmake` module. | | `disabled` | `false` | Disables the `cmake` module. |
@ -962,7 +1014,7 @@ You'll also need the .NET Core SDK installed in order to use it correctly.
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. 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 (<https://docs.microsoft.com/en-us/dotnet/standard/frameworks#supported-target-framework-versions>) when there is a csproj file in the current directory. The module will also show the Target Framework Moniker (<https://docs.microsoft.com/en-us/dotnet/standard/frameworks#supported-target-frameworks>) when there is a `.csproj` file in the current directory.
### Opzioni ### Opzioni
@ -2360,8 +2412,8 @@ The `package` module is shown when the current directory is the repository for a
| `symbol` | `"📦 "` | The symbol used before displaying the version the package. | | `symbol` | `"📦 "` | The symbol used before displaying the version the package. |
| `version_format` | `"v${raw}"` | Il formato della versione. Le variabili disponibili sono `raw`, `major`, `minore`, & `patch` | | `version_format` | `"v${raw}"` | Il formato della versione. Le variabili disponibili sono `raw`, `major`, `minore`, & `patch` |
| `style` | `"bold 208"` | Lo stile per il modulo. | | `style` | `"bold 208"` | Lo stile per il modulo. |
| `display_private` | `false` | Enable displaying version for packages marked as private. | | `display_private` | `false` | Abilita la visualizzazione della versione per i pacchetti contrassegnati come privati. |
| `disabled` | `false` | Disables the `package` module. | | `disabled` | `false` | Disabilita il modulo `package`. |
### Variables ### Variables
@ -2587,9 +2639,9 @@ By default the module will be shown if any of the following conditions are met:
| `pyenv_version_name` | `false` | Use pyenv to get Python version | | `pyenv_version_name` | `false` | Use pyenv to get Python version |
| `pyenv_prefix` | `pyenv` | Prefix before pyenv version display, only used if pyenv is used | | `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. | | `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_extensions` | `["py"]` | Quali estensioni dovrebbero attivare questo modulo |
| `detect_files` | `[".python-version", "Pipfile", "__init__.py", "pyproject.toml", "requirements.txt", "setup.py", "tox.ini"]` | Which filenames should trigger this module | | `detect_files` | `[".python-version", "Pipfile", "__init__.py", "pyproject.toml", "requirements.txt", "setup.py", "tox.ini"]` | Quali nomi di file dovrebbero attivare questo modulo |
| `detect_folders` | `[]` | Which folders should trigger this module | | `detect_folders` | `[]` | Quali cartelle dovrebbero attivare questo modulo |
| `disabled` | `false` | Disables the `python` module. | | `disabled` | `false` | Disables the `python` module. |
::: tip ::: tip
@ -2667,9 +2719,9 @@ The `rlang` module shows the currently installed version of [R](https://www.r-pr
| `version_format` | `"v${raw}"` | Il formato della versione. Le variabili disponibili sono `raw`, `major`, `minore`, & `patch` | | `version_format` | `"v${raw}"` | Il formato della versione. Le variabili disponibili sono `raw`, `major`, `minore`, & `patch` |
| `symbol` | `"📐"` | A format string representing the symbol of R. | | `symbol` | `"📐"` | A format string representing the symbol of R. |
| `style` | `"blu grassetto"` | Lo stile per il modulo. | | `style` | `"blu grassetto"` | Lo stile per il modulo. |
| `detect_extensions` | `["R", "Rd", "Rmd", "Rproj", "Rsx"]` | Which extensions should trigger this module | | `detect_extensions` | `["R", "Rd", "Rmd", "Rproj", "Rsx"]` | Quali estensioni dovrebbero attivare questo modulo |
| `detect_files` | `[".Rprofile"]` | Which filenames should trigger this module | | `detect_files` | `[".Rprofile"]` | Quali nomi di file dovrebbero attivare questo modulo |
| `detect_folders` | `[".Rproj.user"]` | Which folders should trigger this module | | `detect_folders` | `[".Rproj.user"]` | Quali cartelle dovrebbero attivare questo modulo |
| `disabled` | `false` | Disables the `r` module. | | `disabled` | `false` | Disables the `r` module. |
### Variables ### Variables
@ -2969,6 +3021,39 @@ The `singularity` module shows the current [Singularity](https://sylabs.io/singu
format = '[📦 \[$env\]]($style) ' format = '[📦 \[$env\]]($style) '
``` ```
## Spack
The `spack` module shows the current [Spack](https://spack.readthedocs.io/en/latest/) environment, if `$SPACK_ENV` is set.
### Opzioni
| Opzione | Default | Descrizione |
| ------------------- | -------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------- |
| `truncation_length` | `1` | The number of directories the environment path should be truncated to. `0` means no truncation. Also see the [`directory`](#directory) module. |
| `symbol` | `"🅢 "` | The symbol used before the environment name. |
| `style` | `"bold blue"` | Lo stile per il modulo. |
| `format` | `"via [$symbol$environment]($style) "` | The format for the module. |
| `disabled` | `false` | Disables the `spack` module. |
### Variables
| Variable | Esempio | Descrizione |
| ----------- | ------------ | ------------------------------------ |
| environment | `astronauts` | The current spack environment |
| 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
### Esempio
```toml
# ~/.config/starship.toml
[spack]
format = "[$symbol$environment](dimmed blue) "
```
## Status ## Status
The `status` module displays the exit code of the previous command. If $success_symbol is empty (default), the module will be shown only if the exit code is not `0`. The status code will cast to a signed 32-bit integer. The `status` module displays the exit code of the previous command. If $success_symbol is empty (default), the module will be shown only if the exit code is not `0`. The status code will cast to a signed 32-bit integer.
@ -3204,7 +3289,7 @@ If `use_12hr` is `true`, then `time_format` defaults to `"%r"`. Otherwise, it de
| Variable | Esempio | Descrizione | | Variable | Esempio | Descrizione |
| --------- | ---------- | ----------------------------------- | | --------- | ---------- | ----------------------------------- |
| time | `13:08:10` | The current time. | | ora | `13:08:10` | The current time. |
| style\* | | Mirrors the value of option `style` | | style\* | | Mirrors the value of option `style` |
*: This variable can only be used as a part of a style string *: This variable can only be used as a part of a style string
@ -3226,7 +3311,7 @@ time_range = "10:00:00-14:00:00"
The `username` module shows active user's username. The module will be shown if any of the following conditions are met: 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 is root/admin
- The current user isn't the same as the one that is logged in - The current user isn't the same as the one that is logged in
- The user is currently connected as an SSH session - The user is currently connected as an SSH session
- The variable `show_always` is set to true - The variable `show_always` is set to true
@ -3239,13 +3324,13 @@ SSH connection is detected by checking environment variables `SSH_CONNECTION`, `
### Opzioni ### Opzioni
| Opzione | Default | Descrizione | | Opzione | Default | Descrizione |
| ------------- | ----------------------- | ------------------------------------- | | ------------- | ----------------------- | ------------------------------------------- |
| `style_root` | `"bold red"` | The style used when the user is root. | | `style_root` | `"bold red"` | The style used when the user is root/admin. |
| `style_user` | `"bold yellow"` | The style used for non-root users. | | `style_user` | `"bold yellow"` | The style used for non-root users. |
| `format` | `"[$user]($style) in "` | The format for the module. | | `format` | `"[$user]($style) in "` | The format for the module. |
| `show_always` | `false` | Always shows the `username` module. | | `show_always` | `false` | Always shows the `username` module. |
| `disabled` | `false` | Disables the `username` module. | | `disabled` | `false` | Disables the `username` module. |
### Variables ### Variables
@ -3318,12 +3403,12 @@ The `vlang` module shows you your currently installed version of [V](https://vla
| ------------------- | -------------------------------------------- | -------------------------------------------------------------------------------------------- | | ------------------- | -------------------------------------------- | -------------------------------------------------------------------------------------------- |
| `format` | `"via [$symbol($version )]($style)"` | The format for the module. | | `format` | `"via [$symbol($version )]($style)"` | The format for the module. |
| `version_format` | `"v${raw}"` | Il formato della versione. Le variabili disponibili sono `raw`, `major`, `minore`, & `patch` | | `version_format` | `"v${raw}"` | Il formato della versione. Le variabili disponibili sono `raw`, `major`, `minore`, & `patch` |
| `symbol` | `"V "` | A format string representing the symbol of V | | `symbol` | `"V "` | Una stringa di formato che rappresenta il simbolo di V |
| `detect_extensions` | `["v"]` | Quali estensioni dovrebbero attivare questo modulo. | | `detect_extensions` | `["v"]` | Quali estensioni dovrebbero attivare questo modulo. |
| `detect_files` | `["v.mod", "vpkg.json", ".vpkg-lock.json" ]` | Quali nomi di file dovrebbero attivare questo modulo. | | `detect_files` | `["v.mod", "vpkg.json", ".vpkg-lock.json" ]` | Quali nomi di file dovrebbero attivare questo modulo. |
| `detect_folders` | `[]` | Quali cartelle dovrebbero attivare questo modulo. | | `detect_folders` | `[]` | Quali cartelle dovrebbero attivare questo modulo. |
| `style` | `"blu grassetto"` | Lo stile per il modulo. | | `style` | `"blu grassetto"` | Lo stile per il modulo. |
| `disabled` | `false` | Disables the `vlang` module. | | `disabled` | `false` | Disabilita il modulo `vlang`. |
### Variables ### Variables
@ -3417,9 +3502,9 @@ The `custom` modules show the output of some arbitrary commands.
These modules will be shown if any of the following conditions are met: These modules will be shown if any of the following conditions are met:
- The current directory contains a file whose name is in `files` - The current directory contains a file whose name is in `detect_files`
- The current directory contains a directory whose name is in `directories` - The current directory contains a directory whose name is in `detect_folders`
- The current directory contains a file whose extension is in `extensions` - The current directory contains a file whose extension is in `detect_extensions`
- The `when` command returns 0 - The `when` command returns 0
- The current Operating System (std::env::consts::OS) matchs with `os` field if defined. - The current Operating System (std::env::consts::OS) matchs with `os` field if defined.
@ -3451,20 +3536,22 @@ Format strings can also contain shell specific prompt sequences, e.g. [Bash](htt
### Opzioni ### Opzioni
| Opzione | Default | Descrizione | | Opzione | Default | Descrizione |
| ------------- | ------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | | ------------------- | ------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `command` | `""` | The command whose output should be printed. The command will be passed on stdin to the shell. | | `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. | | `when` | `false` | Either a boolean value (`true` or `false`, without quotes) or a string shell command used as a condition to show the module. In case of a string, the module will be shown if the command returns a `0` status code. |
| `shell` | | [See below](#custom-command-shell) | | `shell` | | [See below](#custom-command-shell) |
| `description` | `"<custom module>"` | The description of the module that is shown when running `starship explain`. | | `descrizione` | `"<custom module>"` | 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. | | `detect_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. | | `detect_folders` | `[]` | 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. | | `detect_extensions` | `[]` | The extensions that will be searched in the working directory for a match. |
| `symbol` | `""` | The symbol used before displaying the command output. | | `symbol` | `""` | The symbol used before displaying the command output. |
| `style` | `"bold green"` | Lo stile per il modulo. | | `style` | `"bold green"` | Lo stile per il modulo. |
| `format` | `"[$symbol($output )]($style)"` | The format for the module. | | `format` | `"[$symbol($output )]($style)"` | The format for the module. |
| `disabled` | `false` | Disables this `custom` 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). | | `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). |
| `use_stdin` | | An optional boolean value that overrides whether commands should be forwarded to the shell via the standard input or as an argument. If unset standard input is used by default, unless the shell does not support it (cmd, nushell). Setting this disables shell-specific argument handling. |
| `ignore_timeout` | `false` | Ignore global `command_timeout` setting and keep running external commands, no matter how long they take. |
### Variables ### Variables
@ -3487,7 +3574,7 @@ If unset, it will fallback to STARSHIP_SHELL and then to "sh" on Linux, and "cmd
The `command` will be passed in on stdin. The `command` will be passed in on stdin.
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. 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 -`. If `shell` is not given or only contains one element and Starship detects Cmd will be used, the following argument will automatically be added: `/C` and `stdin` will be set to `false`. If `shell` is not given or only contains one element and Starship detects Nushell will be used, the following arguments will automatically be added: `-c` and `stdin` will be set to `false`. This behavior can be avoided by explicitly passing arguments to the shell, e.g.
```toml ```toml
shell = ["pwsh", "-Command", "-"] shell = ["pwsh", "-Command", "-"]
@ -3512,12 +3599,18 @@ Automatic detection of shells and proper parameters addition are currently imple
[custom.foo] [custom.foo]
command = "echo foo" # shows output of command command = "echo foo" # shows output of command
files = ["foo"] # can specify filters but wildcards are not supported detect_files = ["foo"] # can specify filters but wildcards are not supported
when = """ test "$HOME" == "$PWD" """ when = """ test "$HOME" == "$PWD" """
format = " transcending [$output]($style)" format = " transcending [$output]($style)"
[custom.time] [custom.time]
command = "time /T" command = "time /T"
extensions = ["pst"] # filters *.pst files detect_extensions = ["pst"] # filters *.pst files
shell = ["pwsh.exe", "-NoProfile", "-Command", "-"] shell = ["pwsh.exe", "-NoProfile", "-Command", "-"]
[custom.time-as-arg]
command = "time /T"
detect_extensions = ["pst"] # filters *.pst files
shell = ["pwsh.exe", "-NoProfile", "-Command"]
use_stdin = false
``` ```

View File

@ -145,7 +145,7 @@
<img <img
src="https://raw.githubusercontent.com/starship/starship/master/media/demo.gif" src="https://raw.githubusercontent.com/starship/starship/master/media/demo.gif"
alt="Starship with iTerm2 and the Snazzy theme" alt="Starship con iTerm2 e il tema Snazzy"
width="50%" width="50%"
align="right" align="right"
/> />
@ -160,7 +160,7 @@
- **Facile:** veloce da installare - inizia ad usarlo in pochi minuti. - **Facile:** veloce da installare - inizia ad usarlo in pochi minuti.
<p align="center"> <p align="center">
<a href="https://starship.rs/config/"><strong>Explore the Starship docs&nbsp;&nbsp;</strong></a> <a href="https://starship.rs/config/"><strong>Esplora la documentazione di Starship&nbsp;&nbsp;</strong></a>
</p> </p>
<a name="🚀-installation"></a> <a name="🚀-installation"></a>
@ -173,7 +173,7 @@
### Fase 1. Installa Starship ### Fase 1. Installa Starship
Select your operating system from the list below to view installation instructions: Selezionare il sistema operativo dall'elenco qui sotto per visualizzare le istruzioni per l'installazione:
<details> <details>
<summary>Android</summary> <summary>Android</summary>
@ -264,7 +264,7 @@ Install Starship using any of the following package managers:
### Fase 2. Imposta la tua shell a utilizzare Starship ### Fase 2. Imposta la tua shell a utilizzare Starship
Configure your shell to initialize starship. Select yours from the list below: Configura la shell a inizializzare Starship. Seleziona la tua dalla lista qui sotto:
<details> <details>
<summary>Bash</summary> <summary>Bash</summary>
@ -297,7 +297,7 @@ Aggiungi quanto segue alla fine di `~/.elvish/rc.elv`:
eval (starship init elvish) eval (starship init elvish)
``` ```
Note: Only Elvish v0.17+ is supported Note: Only Elvish v0.18+ is supported
</details> </details>
@ -390,9 +390,9 @@ eval "$(starship init zsh)"
### Fase 3. Configura Starship ### Fase 3. Configura Starship
Start a new shell instance, and you should see your beautiful new shell prompt. If you're happy with the defaults, enjoy! Inizia una nuova istanza del shell, e dovresti vedere il tuo bellissimo nuovo shell prompt. Se sei soddisfatto dei valori predefiniti, ottimo!
If you're looking to further customize Starship: Se stai cercando di personalizzare ulteriormente Starship:
- **[Configurazione](https://starship.rs/config/)** impara come configurare Starship per modificare il tuo prompt a tuo piacimento - **[Configurazione](https://starship.rs/config/)** impara come configurare Starship per modificare il tuo prompt a tuo piacimento
@ -400,15 +400,15 @@ If you're looking to further customize Starship:
## 🤝 Contribuire ## 🤝 Contribuire
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). Siamo sempre alla ricerca di collaboratori di **tutti i livelli**! Se stai cercando di entrare facilmente nel progetto, prova un [buon primo problema](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/). Se parli correntemente una lingua diversa dall'inglese, apprezziamo molto qualsiasi aiuto per mantenere i nostri documenti tradotti e aggiornati in altre lingue. Se desideri collaborare, le traduzioni possono essere fornite su [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. 👋 Se sei interessato ad aiutare a contribuire a Starship, dai un'occhiata alla nostra [Guida al Contributo](https://github.com/starship/starship/blob/master/CONTRIBUTING.md). Inoltre, sentiti libero di entrare nel nostro [server Discord](https://discord.gg/8Jzqu3T) e dire ciao. 👋
## 💭 Ispirato Da ## 💭 Ispirato Da
Please check out these previous works that helped inspire the creation of starship. 🙏 Ti invito di controllare questi lavori precedenti che hanno contribuito a ispirare la creazione di Starship. 🙏
- **[denysdovhan/spaceship-prompt](https://github.com/denysdovhan/spaceship-prompt)** Un prompt ZSH per astronauti. - **[denysdovhan/spaceship-prompt](https://github.com/denysdovhan/spaceship-prompt)** Un prompt ZSH per astronauti.
@ -423,4 +423,4 @@ Please check out these previous works that helped inspire the creation of starsh
## 📝 Licenza ## 📝 Licenza
Copyright © 2019-present, [Starship Contributors](https://github.com/starship/starship/graphs/contributors).<br /> This project is [ISC](https://github.com/starship/starship/blob/master/LICENSE) licensed. Copyright © 2019-presente, [Starship Contributors](https://github.com/starship/starship/graphs/contributors).<br /> Questo progetto è sotto licenza [ISC](https://github.com/starship/starship/blob/master/LICENSE).

View File

@ -1,4 +1,4 @@
# Advanced Installation # Installazione Avanzata
Per installare starship, è necessario fare due cose: Per installare starship, è necessario fare due cose:

View File

@ -18,7 +18,7 @@ features:
footer: ISC Licensed | Copyright © 2019-present Starship Contributors footer: ISC Licensed | Copyright © 2019-present Starship Contributors
#Used for the description meta tag, for SEO #Used for the description meta tag, for SEO
metaTitle: "Starship: Cross-Shell Prompt" metaTitle: "Starship: Cross-Shell Prompt"
description: Starship はミニマルで、非常に高速で、カスタマイズ性の高い、あらゆるシェルのためのプロンプトです! ミニマルかつ洗練された形で、あなたに必要な情報を表示します。 Quick installation available for Bash, Fish, ZSH, Ion, Tcsh, Elvish, Nu, Xonsh, Cmd, and PowerShell. description: Starship はミニマルで、非常に高速で、カスタマイズ性の高い、あらゆるシェルのためのプロンプトです! ミニマルかつ洗練された形で、あなたに必要な情報を表示します。 Bash, Fish, ZSH, Ion, Tcsh, Elvish, Nu, Xonsh, Cmd, PowerShellで簡単に利用できます。
--- ---
<div class="center"> <div class="center">
@ -120,7 +120,7 @@ description: Starship はミニマルで、非常に高速で、カスタマイ
#### Elvish #### Elvish
::: warning elvish v0.17以上のみサポートされています。 ::: ::: warning elvish v0.18以上のみサポートされています。 :::
`~/.elvish/rc.elv` の最後に以下を追記してください。 `~/.elvish/rc.elv` の最後に以下を追記してください。
@ -144,13 +144,13 @@ description: Starship はミニマルで、非常に高速で、カスタマイ
#### Nushell #### Nushell
::: warning This will change in the future. Only Nushell v0.60+ is supported. ::: Run the following: ::: 警告 これは将来的に変更されます。 Only Nushell v0.60+ is supported. 以下を実行します:
```sh ```sh
mkdir ~/.cache/starship mkdir ~/.cache/starship
starship init nu | save ~/.cache/starship/init.nu starship init nu | save ~/.cache/starship/init.nu
``` ```
And add the following to the end of your Nushell configuration (find it by running `$nu.config-path`): そして、Nushellの設定ファイルの最後に以下を追加してください `$nu.config-path` を実行してください)。
```sh ```sh
mkdir ~/.cache/starship mkdir ~/.cache/starship
@ -171,7 +171,7 @@ description: Starship はミニマルで、非常に高速で、カスタマイ
#### Cmd #### Cmd
You need to use [Clink](https://chrisant996.github.io/clink/clink.html) (v1.2.30+) with Cmd. Add the following to a file `starship.lua` and place this file in Clink scripts directory: [Clink](https://chrisant996.github.io/clink/clink.html) (v1.2.30+) コマンドを使用する必要があります。 以下をファイル `starship.lua` に追加し、Clinkスクリプトディレクトリに配置します:
```lua ```lua
-- starship.lua -- starship.lua

View File

@ -131,7 +131,7 @@ Invoke-Expression (&starship init powershell)
シェルによっては、入力と同じ行にレンダリングされる右プロンプトをサポートしています。 Starship では `right_format` オプションを使って右プロンプトの内容を設定できます。 `format`で使用できるモジュールはすべて`right_format`でも使用できます。 変数`$all`には、`format`や`right_format`で明示的に使用されていないモジュールのみが格納されます。 シェルによっては、入力と同じ行にレンダリングされる右プロンプトをサポートしています。 Starship では `right_format` オプションを使って右プロンプトの内容を設定できます。 `format`で使用できるモジュールはすべて`right_format`でも使用できます。 変数`$all`には、`format`や`right_format`で明示的に使用されていないモジュールのみが格納されます。
注意: 右プロンプトは入力の場所に続く単一の行です。 複数行のプロンプトで入力行の上を右寄せにするには、[fillモジュール](/config/#fill)を参照してください。 注意: 右プロンプトは入力の場所に続く単一の行です。 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, xonsh, cmd. `right_format` is currently supported for the following shells: elvish, fish, zsh, xonsh, cmd.

File diff suppressed because it is too large Load Diff

View File

@ -12,7 +12,7 @@
## デモのGIFのようにコマンド補完はどうしたら使用できますか ## デモのGIFのようにコマンド補完はどうしたら使用できますか
補完サポート、または自動補完は選択したシェルによって提供されます。 デモ中では、デフォルトの[Fish Shell](https://fishshell.com/)によって補完されています。 Z Shell (zsh) を利用しているのであれば、[zsh-autosuggestions](https://github.com/zsh-users/zsh-autosuggestions)を参してください。 補完サポート、または自動補完は選択したシェルによって提供されます。 デモ中では、デフォルトの[Fish Shell](https://fishshell.com/)によって補完されています。 Z Shell (zsh) を利用しているのであれば、[zsh-autosuggestions](https://github.com/zsh-users/zsh-autosuggestions)を参してください。
## トップレベルの`format`と`<module>.disabled`は同じように動作しますか? ## トップレベルの`format`と`<module>.disabled`は同じように動作しますか?

View File

@ -160,7 +160,7 @@
- **簡単:** 迅速なインストールが可能であり、数分で使用開始可能です。 - **簡単:** 迅速なインストールが可能であり、数分で使用開始可能です。
<p align="center"> <p align="center">
<a href="https://starship.rs/config/"><strong>Explore the Starship docs&nbsp;&nbsp;</strong></a> <a href="https://starship.rs/config/"><strong>Starshipのドキュメントを見る&nbsp;&nbsp;</strong></a>
</p> </p>
<a name="🚀-installation"></a> <a name="🚀-installation"></a>
@ -173,12 +173,12 @@
### Step 1. Install Starship ### Step 1. Install Starship
Select your operating system from the list below to view installation instructions: 以下のリストからお使いのOSを選択し、インストール方法をご確認ください。
<details> <details>
<summary>Android</summary> <summary>Android</summary>
Install Starship using any of the following package managers: 以下のいずれかのパッケージマネージャーを使用して、Starshipをインストールします。
| Repository | Instructions | | Repository | Instructions |
| --------------------------------------------------------------------------------- | ---------------------- | | --------------------------------------------------------------------------------- | ---------------------- |
@ -189,7 +189,7 @@ Install Starship using any of the following package managers:
<details> <details>
<summary>BSD</summary> <summary>BSD</summary>
Install Starship using any of the following package managers: 以下のいずれかのパッケージマネージャーを使用して、Starshipをインストールします。
| Distribution | Repository | Instructions | | Distribution | Repository | Instructions |
| ------------ | -------------------------------------------------------- | --------------------------------- | | ------------ | -------------------------------------------------------- | --------------------------------- |
@ -202,13 +202,13 @@ Install Starship using any of the following package managers:
<details> <details>
<summary>Linux</summary> <summary>Linux</summary>
Install the latest version for your system: お使いのシステムに合わせた最新版をインストールしてください。
```sh ```sh
curl -sS https://starship.rs/install.sh | sh curl -sS https://starship.rs/install.sh | sh
``` ```
Alternatively, install Starship using any of the following package managers: または、以下のパッケージマネージャを使用して、Starshipをインストールします。
| Distribution | Repository | Instructions | | Distribution | Repository | Instructions |
| ------------------ | ----------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------ | | ------------------ | ----------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------ |
@ -231,13 +231,13 @@ Alternatively, install Starship using any of the following package managers:
<details> <details>
<summary>macOS</summary> <summary>macOS</summary>
Install the latest version for your system: お使いのシステムに合わせた最新版をインストールしてください。
```sh ```sh
curl -sS https://starship.rs/install.sh | sh curl -sS https://starship.rs/install.sh | sh
``` ```
Alternatively, install Starship using any of the following package managers: または、以下のパッケージマネージャを使用して、Starshipをインストールします。
| Repository | Instructions | | Repository | Instructions |
| -------------------------------------------------------- | --------------------------------------- | | -------------------------------------------------------- | --------------------------------------- |
@ -251,7 +251,7 @@ Alternatively, install Starship using any of the following package managers:
<details> <details>
<summary>Windows</summary> <summary>Windows</summary>
Install Starship using any of the following package managers: 以下のいずれかのパッケージマネージャーを使用して、Starshipをインストールします。
| Repository | Instructions | | Repository | Instructions |
| -------------------------------------------------------------------------------- | --------------------------------------- | | -------------------------------------------------------------------------------- | --------------------------------------- |
@ -264,7 +264,7 @@ Install Starship using any of the following package managers:
### Step 2. Setup your shell to use Starship ### Step 2. Setup your shell to use Starship
Configure your shell to initialize starship. Select yours from the list below: Starshipを初期化するためのシェルの設定。 以下のリストからお使いのシェルを選択してください。
<details> <details>
<summary>Bash</summary> <summary>Bash</summary>
@ -280,7 +280,7 @@ eval "$(starship init bash)"
<details> <details>
<summary>Cmd</summary> <summary>Cmd</summary>
You need to use [Clink](https://chrisant996.github.io/clink/clink.html) (v1.2.30+) with Cmd. Create a file at this path `%LocalAppData%\clink\starship.lua` with the following contents: [Clink](https://chrisant996.github.io/clink/clink.html) (v1.2.30+) コマンドを使用する必要があります。 このパス`%LocalAppData%\clink\starship.lua` に以下の内容を含むファイルを作成する。
```lua ```lua
load(io.popen('starship init cmd'):read("*a"))() load(io.popen('starship init cmd'):read("*a"))()
@ -297,7 +297,7 @@ load(io.popen('starship init cmd'):read("*a"))()
eval (starship init elvish) eval (starship init elvish)
``` ```
Note: Only Elvish v0.17+ is supported Note: Only Elvish v0.18+ is supported
</details> </details>
@ -333,7 +333,7 @@ mkdir ~/.cache/starship
starship init nu | save ~/.cache/starship/init.nu starship init nu | save ~/.cache/starship/init.nu
``` ```
And add the following to the end of your Nushell configuration (find it by running `$nu.config-path`): そして、Nushellの設定ファイルの最後に以下を追加してください `$nu.config-path` を実行してください)。
```sh ```sh
starship init nu | save ~/.cache/starship/init.nu starship init nu | save ~/.cache/starship/init.nu
@ -390,9 +390,9 @@ eval "$(starship init zsh)"
### Step 3. Configure Starship ### Step 3. Configure Starship
Start a new shell instance, and you should see your beautiful new shell prompt. If you're happy with the defaults, enjoy! 新しいシェルインスタンスを起動すると、美しくて新しいシェルプロンプトが表示されるはずです。 デフォルトで問題なければ、お楽しみください!
If you're looking to further customize Starship: Starshipのさらなるカスタマイズを目指すなら以下を参考にしてみてください。
- **[Configuration](https://starship.rs/config/)** learn how to configure Starship to tweak your prompt to your liking - **[Configuration](https://starship.rs/config/)** learn how to configure Starship to tweak your prompt to your liking
@ -400,15 +400,15 @@ If you're looking to further customize Starship:
## 🤝 貢献 ## 🤝 貢献
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). 私たちは常に**すべてのスキルレベル**の貢献者を探しています! もし簡単にプロジェクトへ参加する方法をお探しなら、 [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/). あなたが英語以外の言語に堪能な場合、ドキュメントの翻訳と更新に協力していただけると嬉しいです。 協力してくれる場合、翻訳は [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. 👋 もしあなたが Starship への貢献に興味がある場合は、我々の[貢献ガイド](https://github.com/starship/starship/blob/master/CONTRIBUTING.md)をご覧ください。 また、気軽に我々の[Discord サーバー](https://discord.gg/8Jzqu3T)へ顔を出してください。 👋
## 💭影響を受けたプロダクト ## 💭影響を受けたプロダクト
Please check out these previous works that helped inspire the creation of starship. 🙏 よければStarship の作成に影響を与えた、これまでのプロジェクトをチェックしてください 🙏
- **[denysdovhan/spaceship-prompt](https://github.com/denysdovhan/spaceship-prompt)** A ZSH prompt for astronauts. - **[denysdovhan/spaceship-prompt](https://github.com/denysdovhan/spaceship-prompt)** A ZSH prompt for astronauts.
@ -423,4 +423,4 @@ Please check out these previous works that helped inspire the creation of starsh
## 📝 ライセンス ## 📝 ライセンス
Copyright © 2019-present, [Starship Contributors](https://github.com/starship/starship/graphs/contributors).<br /> This project is [ISC](https://github.com/starship/starship/blob/master/LICENSE) licensed. Copyright © 2019-present, [Starship Contributors](https://github.com/starship/starship/graphs/contributors).<br /> このプロジェクトは [ISC](https://github.com/starship/starship/blob/master/LICENSE) でライセンスされています。

View File

@ -1,4 +1,4 @@
# Advanced Installation # 高度なインストール
Starship をインストールするには、以下の2つのことを行う必要があります。 Starship をインストールするには、以下の2つのことを行う必要があります。

View File

@ -1,4 +1,4 @@
# 準備するもの # プリセット
以下は、Starship用にコミュニティに提供された構成プリセットのコレクションです。 共有するプリセットがある場合は、このファイルを更新して[PR](https://github.com/starship/starship/edit/master/docs/presets/README.md)を送信してください! 😊 以下は、Starship用にコミュニティに提供された構成プリセットのコレクションです。 共有するプリセットがある場合は、このファイルを更新して[PR](https://github.com/starship/starship/edit/master/docs/presets/README.md)を送信してください! 😊

View File

@ -120,7 +120,7 @@ description: Starship is the minimal, blazing fast, and extremely customizable p
#### Elvish #### Elvish
::: warning elvish v0.17 이상만 지원. ::: ::: warning elvish v0.18 이상만 지원. :::
`~/.elvish/rc.elv` 의 끝부분에 아래 라인을 추가: `~/.elvish/rc.elv` 의 끝부분에 아래 라인을 추가:
@ -171,7 +171,7 @@ description: Starship is the minimal, blazing fast, and extremely customizable p
#### Cmd #### Cmd
Cmd를 이용하려면 [Clink](https://chrisant996.github.io/clink/clink.html) (v1.2.30+) 를 사용해야 합니다. Add the following to a file `starship.lua` and place this file in Clink scripts directory: Cmd를 이용하려면 [Clink](https://chrisant996.github.io/clink/clink.html) (v1.2.30+) 를 사용해야 합니다. `starship.lua` 파일에 아래의 라인을 추가하고 파일을 Clink scripts 폴더에 저장합니다.
```lua ```lua
-- starship.lua -- starship.lua

View File

@ -131,7 +131,7 @@ Invoke-Expression (&starship init powershell)
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`. 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). 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, xonsh, cmd. `right_format` is currently supported for the following shells: elvish, fish, zsh, xonsh, cmd.

View File

@ -9,6 +9,9 @@ mkdir -p ~/.config && touch ~/.config/starship.toml
All configuration for starship is done in this [TOML](https://github.com/toml-lang/toml) file: All configuration for starship is done in this [TOML](https://github.com/toml-lang/toml) file:
```toml ```toml
# Get editor completions based on the config schema
"$schema" = 'https://starship.rs/config-schema.json'
# Inserts a blank line between shell prompts # Inserts a blank line between shell prompts
add_newline = true add_newline = true
@ -199,6 +202,7 @@ $hg_branch\
$docker_context\ $docker_context\
$package\ $package\
$buf\ $buf\
$c\
$cmake\ $cmake\
$cobol\ $cobol\
$container\ $container\
@ -235,6 +239,7 @@ $vagrant\
$zig\ $zig\
$nix_shell\ $nix_shell\
$conda\ $conda\
$spack\
$memory_usage\ $memory_usage\
$aws\ $aws\
$gcloud\ $gcloud\
@ -263,9 +268,9 @@ format = "$all$directory$character"
## AWS ## AWS
The `aws` module shows the current AWS region and profile when credentials, a `credential_process` or a `sso_start_url` have been setup. 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. The `aws` module shows the current AWS region and profile when credentials, a `credential_process` or a `sso_start_url` have been setup. Alternatively, you can force this module to show the region and profile even when the credentials have not been setup with the `force_display` option. 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.
The module will display a profile only if its credentials are present in `~/.aws/credentials` or a `credential_process` is defined in `~/.aws/config`. Alternatively, having any of the `AWS_ACCESS_KEY_ID`, `AWS_SECRET_ACCESS_KEY`, or `AWS_SESSION_TOKEN` env vars defined will also suffice. The module will display a profile only if its credentials are present in `~/.aws/credentials` or a `credential_process` is defined in `~/.aws/config`. Alternatively, having any of the `AWS_ACCESS_KEY_ID`, `AWS_SECRET_ACCESS_KEY`, or `AWS_SESSION_TOKEN` env vars defined will also suffice. If the option `force_display` is set to `true`, all available information will be displayed even if the conditions above are not respected.
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. 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.
@ -275,15 +280,16 @@ When using [AWSume](https://awsu.me) the profile is read from the `AWSUME_PROFIL
### Options ### Options
| Option | Default | Description | | Option | Default | Description |
| ------------------- | -------------------------------------------------------------------- | ----------------------------------------------------------------- | | ------------------- | -------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------- |
| `format` | `'on [$symbol($profile )(\($region\) )(\[$duration\])]($style)'` | The format for the module. | | `format` | `'on [$symbol($profile )(\($region\) )(\[$duration\])]($style)'` | The format for the module. |
| `symbol` | `"☁️ "` | The symbol used before displaying the current AWS profile. | | `symbol` | `"☁️ "` | The symbol used before displaying the current AWS profile. |
| `region_aliases` | | Table of region aliases to display in addition to the AWS name. | | `region_aliases` | | Table of region aliases to display in addition to the AWS name. |
| `profile_aliases` | | Table of profile aliases to display in addition to the AWS name. | | `profile_aliases` | | Table of profile aliases to display in addition to the AWS name. |
| `style` | `"bold yellow"` | The style for the module. | | `style` | `"bold yellow"` | The style for the module. |
| `expiration_symbol` | `X` | The symbol displayed when the temporary credentials have expired. | | `expiration_symbol` | `X` | The symbol displayed when the temporary credentials have expired. |
| `disabled` | `false` | Disables the `AWS` module. | | `disabled` | `false` | Disables the `AWS` module. |
| `force_display` | `false` | If `true` displays info even if `credentials`, `credential_process` or `sso_start_url` have not been setup. |
### Variables ### Variables
@ -472,6 +478,52 @@ The `buf` module shows the currently installed version of [Buf](https://buf.buil
symbol = "🦬 " symbol = "🦬 "
``` ```
## C
The `c` module shows some information about your C compiler. By default the module will be shown if the current directory contains a `.c` or `.h` file.
### Options
| Option | Default | Description |
| ------------------- | --------------------------------------------------------------------------- | ------------------------------------------------------------------------- |
| `format` | `"via [$symbol($version(-$name) )]($style)"` | The format string for the module. |
| `version_format` | `"v${raw}"` | The version format. Available vars are `raw`, `major`, `minor`, & `patch` |
| `symbol` | `"C "` | The symbol used before displaying the compiler details |
| `detect_extensions` | `["c", "h"]` | Which extensions should trigger this module. |
| `detect_files` | `[]` | Which filenames should trigger this module. |
| `detect_folders` | `[]` | Which folders should trigger this module. |
| `commands` | [ [ "cc", "--version" ], [ "gcc", "--version" ], [ "clang", "--version" ] ] | How to detect what the compiler is |
| `style` | `"bold 149"` | The style for the module. |
| `disabled` | `false` | Disables the `c` module. |
### Variables
| Variable | Example | Description |
| -------- | ------- | ------------------------------------ |
| name | clang | The name of the compiler |
| version | 13.0.0 | The version of the compiler |
| symbol | | Mirrors the value of option `symbol` |
| style | | Mirrors the value of option `style` |
NB that `version` is not in the default format.
### Commands
The `commands` option accepts a list of commands to determine the compiler version and name.
Each command is represented as a list of the executable name, followed by its arguments, usually something like `["mycc", "--version"]`. Starship will try executing each command until it gets a result on STDOUT.
If a C compiler is not supported by this module, you can request it by [raising an issue on GitHub](https://github.com/starship/starship/).
### Example
```toml
# ~/.config/starship.toml
[c]
format = "via [$name $version]($style)"
```
## Character ## Character
The `character` module shows a character (usually an arrow) beside where the text is entered in your terminal. The `character` module shows a character (usually an arrow) beside where the text is entered in your terminal.
@ -962,7 +1014,7 @@ You'll also need the .NET Core SDK installed in order to use it correctly.
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. 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 (<https://docs.microsoft.com/en-us/dotnet/standard/frameworks#supported-target-framework-versions>) when there is a csproj file in the current directory. The module will also show the Target Framework Moniker (<https://docs.microsoft.com/en-us/dotnet/standard/frameworks#supported-target-frameworks>) when there is a `.csproj` file in the current directory.
### Options ### Options
@ -2969,6 +3021,39 @@ The `singularity` module shows the current [Singularity](https://sylabs.io/singu
format = '[📦 \[$env\]]($style) ' format = '[📦 \[$env\]]($style) '
``` ```
## Spack
The `spack` module shows the current [Spack](https://spack.readthedocs.io/en/latest/) environment, if `$SPACK_ENV` is set.
### Options
| Option | Default | Description |
| ------------------- | -------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------- |
| `truncation_length` | `1` | The number of directories the environment path should be truncated to. `0` means no truncation. Also see the [`directory`](#directory) module. |
| `symbol` | `"🅢 "` | The symbol used before the environment name. |
| `style` | `"bold blue"` | The style for the module. |
| `format` | `"via [$symbol$environment]($style) "` | The format for the module. |
| `disabled` | `false` | Disables the `spack` module. |
### Variables
| Variable | Example | Description |
| ----------- | ------------ | ------------------------------------ |
| environment | `astronauts` | The current spack environment |
| 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
### Example
```toml
# ~/.config/starship.toml
[spack]
format = "[$symbol$environment](dimmed blue) "
```
## Status ## Status
The `status` module displays the exit code of the previous command. If $success_symbol is empty (default), the module will be shown only if the exit code is not `0`. The status code will cast to a signed 32-bit integer. The `status` module displays the exit code of the previous command. If $success_symbol is empty (default), the module will be shown only if the exit code is not `0`. The status code will cast to a signed 32-bit integer.
@ -3226,7 +3311,7 @@ time_range = "10:00:00-14:00:00"
The `username` module shows active user's username. The module will be shown if any of the following conditions are met: 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 is root/admin
- The current user isn't the same as the one that is logged in - The current user isn't the same as the one that is logged in
- The user is currently connected as an SSH session - The user is currently connected as an SSH session
- The variable `show_always` is set to true - The variable `show_always` is set to true
@ -3239,13 +3324,13 @@ SSH connection is detected by checking environment variables `SSH_CONNECTION`, `
### Options ### Options
| Option | Default | Description | | Option | Default | Description |
| ------------- | ----------------------- | ------------------------------------- | | ------------- | ----------------------- | ------------------------------------------- |
| `style_root` | `"bold red"` | The style used when the user is root. | | `style_root` | `"bold red"` | The style used when the user is root/admin. |
| `style_user` | `"bold yellow"` | The style used for non-root users. | | `style_user` | `"bold yellow"` | The style used for non-root users. |
| `format` | `"[$user]($style) in "` | The format for the module. | | `format` | `"[$user]($style) in "` | The format for the module. |
| `show_always` | `false` | Always shows the `username` module. | | `show_always` | `false` | Always shows the `username` module. |
| `disabled` | `false` | Disables the `username` module. | | `disabled` | `false` | Disables the `username` module. |
### Variables ### Variables
@ -3417,9 +3502,9 @@ The `custom` modules show the output of some arbitrary commands.
These modules will be shown if any of the following conditions are met: These modules will be shown if any of the following conditions are met:
- The current directory contains a file whose name is in `files` - The current directory contains a file whose name is in `detect_files`
- The current directory contains a directory whose name is in `directories` - The current directory contains a directory whose name is in `detect_folders`
- The current directory contains a file whose extension is in `extensions` - The current directory contains a file whose extension is in `detect_extensions`
- The `when` command returns 0 - The `when` command returns 0
- The current Operating System (std::env::consts::OS) matchs with `os` field if defined. - The current Operating System (std::env::consts::OS) matchs with `os` field if defined.
@ -3451,20 +3536,22 @@ Format strings can also contain shell specific prompt sequences, e.g. [Bash](htt
### Options ### Options
| Option | Default | Description | | Option | Default | Description |
| ------------- | ------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | | ------------------- | ------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `command` | `""` | The command whose output should be printed. The command will be passed on stdin to the shell. | | `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. | | `when` | `false` | Either a boolean value (`true` or `false`, without quotes) or a string shell command used as a condition to show the module. In case of a string, the module will be shown if the command returns a `0` status code. |
| `shell` | | [See below](#custom-command-shell) | | `shell` | | [See below](#custom-command-shell) |
| `description` | `"<custom module>"` | The description of the module that is shown when running `starship explain`. | | `description` | `"<custom module>"` | The description of the module that is shown when running `starship explain`. |
| `files` | `[]` | The files that will be searched in the working directory for a match. | | `detect_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. | | `detect_folders` | `[]` | 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. | | `detect_extensions` | `[]` | The extensions that will be searched in the working directory for a match. |
| `symbol` | `""` | The symbol used before displaying the command output. | | `symbol` | `""` | The symbol used before displaying the command output. |
| `style` | `"bold green"` | The style for the module. | | `style` | `"bold green"` | The style for the module. |
| `format` | `"[$symbol($output )]($style)"` | The format for the module. | | `format` | `"[$symbol($output )]($style)"` | The format for the module. |
| `disabled` | `false` | Disables this `custom` 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). | | `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). |
| `use_stdin` | | An optional boolean value that overrides whether commands should be forwarded to the shell via the standard input or as an argument. If unset standard input is used by default, unless the shell does not support it (cmd, nushell). Setting this disables shell-specific argument handling. |
| `ignore_timeout` | `false` | Ignore global `command_timeout` setting and keep running external commands, no matter how long they take. |
### Variables ### Variables
@ -3487,7 +3574,7 @@ If unset, it will fallback to STARSHIP_SHELL and then to "sh" on Linux, and "cmd
The `command` will be passed in on stdin. The `command` will be passed in on stdin.
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. 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 -`. If `shell` is not given or only contains one element and Starship detects Cmd will be used, the following argument will automatically be added: `/C` and `stdin` will be set to `false`. If `shell` is not given or only contains one element and Starship detects Nushell will be used, the following arguments will automatically be added: `-c` and `stdin` will be set to `false`. This behavior can be avoided by explicitly passing arguments to the shell, e.g.
```toml ```toml
shell = ["pwsh", "-Command", "-"] shell = ["pwsh", "-Command", "-"]
@ -3512,12 +3599,18 @@ Automatic detection of shells and proper parameters addition are currently imple
[custom.foo] [custom.foo]
command = "echo foo" # shows output of command command = "echo foo" # shows output of command
files = ["foo"] # can specify filters but wildcards are not supported detect_files = ["foo"] # can specify filters but wildcards are not supported
when = """ test "$HOME" == "$PWD" """ when = """ test "$HOME" == "$PWD" """
format = " transcending [$output]($style)" format = " transcending [$output]($style)"
[custom.time] [custom.time]
command = "time /T" command = "time /T"
extensions = ["pst"] # filters *.pst files detect_extensions = ["pst"] # filters *.pst files
shell = ["pwsh.exe", "-NoProfile", "-Command", "-"] shell = ["pwsh.exe", "-NoProfile", "-Command", "-"]
[custom.time-as-arg]
command = "time /T"
detect_extensions = ["pst"] # filters *.pst files
shell = ["pwsh.exe", "-NoProfile", "-Command"]
use_stdin = false
``` ```

View File

@ -160,7 +160,7 @@
- **Easy:** 빠른 설치 - 몇 분 안에 사용할 수 있습니다. - **Easy:** 빠른 설치 - 몇 분 안에 사용할 수 있습니다.
<p align="center"> <p align="center">
<a href="https://starship.rs/config/"><strong>Explore the Starship docs&nbsp;&nbsp;</strong></a> <a href="https://starship.rs/config/"><strong>Starship 문서 보기&nbsp;&nbsp;</strong></a>
</p> </p>
<a name="🚀-installation"></a> <a name="🚀-installation"></a>
@ -173,12 +173,12 @@
### 1단계. Starship 설치하기 ### 1단계. Starship 설치하기
Select your operating system from the list below to view installation instructions: 아래의 목록 중 해당하는 운영체제를 골라 설치 지침을 확인하세요:
<details> <details>
<summary>Android</summary> <summary>Android</summary>
Install Starship using any of the following package managers: 다음 패키지 관리자 중 하나를 사용해 Starship 을 설치하세요:
| Repository | Instructions | | Repository | Instructions |
| --------------------------------------------------------------------------------- | ---------------------- | | --------------------------------------------------------------------------------- | ---------------------- |
@ -189,7 +189,7 @@ Install Starship using any of the following package managers:
<details> <details>
<summary>BSD</summary> <summary>BSD</summary>
Install Starship using any of the following package managers: 다음 패키지 관리자 중 하나를 사용해 Starship 을 설치하세요:
| Distribution | Repository | Instructions | | Distribution | Repository | Instructions |
| ------------ | -------------------------------------------------------- | --------------------------------- | | ------------ | -------------------------------------------------------- | --------------------------------- |
@ -251,7 +251,7 @@ Alternatively, install Starship using any of the following package managers:
<details> <details>
<summary>Windows</summary> <summary>Windows</summary>
Install Starship using any of the following package managers: 다음 패키지 관리자 중 하나를 사용해 Starship 을 설치하세요:
| Repository | Instructions | | Repository | Instructions |
| -------------------------------------------------------------------------------- | --------------------------------------- | | -------------------------------------------------------------------------------- | --------------------------------------- |
@ -264,7 +264,7 @@ Install Starship using any of the following package managers:
### 2단계. 쉘에 Starship 적용하기 ### 2단계. 쉘에 Starship 적용하기
Configure your shell to initialize starship. Select yours from the list below: 쉘에 Starship 초기 설정을 합니다. 아래의 리스트 중에 해당하는 것을 고르세요:
<details> <details>
<summary>Bash</summary> <summary>Bash</summary>
@ -297,7 +297,7 @@ load(io.popen('starship init cmd'):read("*a"))()
eval (starship init elvish) eval (starship init elvish)
``` ```
Note: Only Elvish v0.17+ is supported Note: Only Elvish v0.18+ is supported
</details> </details>
@ -347,7 +347,7 @@ Note: Only Nushell v0.60+ is supported
<details> <details>
<summary>파워셀</summary> <summary>파워셀</summary>
Add the following to the end of your PowerShell configuration (find it by running `$PROFILE`): 다음 내용을 PowerShell 설정파일 (찾으려면 `$PROFILE` 실행) 마지막 부분에 추가하세요:
```powershell ```powershell
Invoke-Expression (&starship init powershell) Invoke-Expression (&starship init powershell)
@ -390,9 +390,9 @@ eval "$(starship init zsh)"
### 3단계. Starship 설정하기 ### 3단계. Starship 설정하기
Start a new shell instance, and you should see your beautiful new shell prompt. If you're happy with the defaults, enjoy! 새로운 쉘 인스턴스를 시작하면 아름다운 새 쉘 프롬프트를 볼 수 있습니다. 기본 설정에 만족한다면, 즐기세요!
If you're looking to further customize Starship: Starship을 추가로 커스터마이징 하고싶다면:
- **[Configuration](https://starship.rs/config/)** 원하는대로 프롬프트를 수정할 수 있도록 Starship 설정을 배울 수 있습니다. - **[Configuration](https://starship.rs/config/)** 원하는대로 프롬프트를 수정할 수 있도록 Starship 설정을 배울 수 있습니다.
@ -400,15 +400,15 @@ If you're looking to further customize Starship:
## 🤝 기여하기 ## 🤝 기여하기
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). 우리는 언제나 **기술 수준에 관계없이** 기여자를 찾고 있습니다! 프로젝트에 참여하고자 한다면, [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/). 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. 번역에 도움을 주고자 한다면, [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. 👋 Starship 에 기여하는데 관심이 있다면, [Contributing Guide](https://github.com/starship/starship/blob/master/CONTRIBUTING.md) 를 한 번 살펴봐 주세요 그리고 부담갖지 말고 [Discord 서버](https://discord.gg/8Jzqu3T) 에 들러 인사 한 마디 남겨보세요 👋
## 💭 Inspired By ## 💭 Inspired By
Please check out these previous works that helped inspire the creation of starship. 🙏 Starship 을 만드는 데에 영감이 되었던 이전 작업들도 살펴보세요. 🙏
- **[denysdovhan/spaceship-prompt](https://github.com/denysdovhan/spaceship-prompt)** A ZSH prompt for astronauts. - **[denysdovhan/spaceship-prompt](https://github.com/denysdovhan/spaceship-prompt)** A ZSH prompt for astronauts.
@ -418,7 +418,7 @@ Please check out these previous works that helped inspire the creation of starsh
<p align="center"> <p align="center">
<br> <br>
<img width="100" src="https://raw.githubusercontent.com/starship/starship/master/media/icon.png" alt="Starship rocket icon"> <img width="100" src="https://raw.githubusercontent.com/starship/starship/master/media/icon.png" alt="Starship 로켓 아이콘">
</p> </p>
## 📝라이선스 ## 📝라이선스

View File

@ -120,7 +120,7 @@ description: Starship is the minimal, blazing fast, and extremely customizable p
#### Elvish #### Elvish
::: warning Only elvish v0.17 or higher is supported. ::: ::: warning Only elvish v0.18 or higher is supported. :::
Add the following to the end of `~/.elvish/rc.elv`: Add the following to the end of `~/.elvish/rc.elv`:

View File

@ -131,7 +131,7 @@ Invoke-Expression (&starship init powershell)
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`. 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). 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, xonsh, cmd. `right_format` is currently supported for the following shells: elvish, fish, zsh, xonsh, cmd.

View File

@ -9,6 +9,9 @@ mkdir -p ~/.config && touch ~/.config/starship.toml
All configuration for starship is done in this [TOML](https://github.com/toml-lang/toml) file: All configuration for starship is done in this [TOML](https://github.com/toml-lang/toml) file:
```toml ```toml
# Get editor completions based on the config schema
"$schema" = 'https://starship.rs/config-schema.json'
# Inserts a blank line between shell prompts # Inserts a blank line between shell prompts
add_newline = true add_newline = true
@ -199,6 +202,7 @@ $hg_branch\
$docker_context\ $docker_context\
$package\ $package\
$buf\ $buf\
$c\
$cmake\ $cmake\
$cobol\ $cobol\
$container\ $container\
@ -235,6 +239,7 @@ $vagrant\
$zig\ $zig\
$nix_shell\ $nix_shell\
$conda\ $conda\
$spack\
$memory_usage\ $memory_usage\
$aws\ $aws\
$gcloud\ $gcloud\
@ -263,9 +268,9 @@ format = "$all$directory$character"
## AWS ## AWS
The `aws` module shows the current AWS region and profile when credentials, a `credential_process` or a `sso_start_url` have been setup. 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. The `aws` module shows the current AWS region and profile when credentials, a `credential_process` or a `sso_start_url` have been setup. Alternatively, you can force this module to show the region and profile even when the credentials have not been setup with the `force_display` option. 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.
The module will display a profile only if its credentials are present in `~/.aws/credentials` or a `credential_process` is defined in `~/.aws/config`. Alternatively, having any of the `AWS_ACCESS_KEY_ID`, `AWS_SECRET_ACCESS_KEY`, or `AWS_SESSION_TOKEN` env vars defined will also suffice. The module will display a profile only if its credentials are present in `~/.aws/credentials` or a `credential_process` is defined in `~/.aws/config`. Alternatively, having any of the `AWS_ACCESS_KEY_ID`, `AWS_SECRET_ACCESS_KEY`, or `AWS_SESSION_TOKEN` env vars defined will also suffice. If the option `force_display` is set to `true`, all available information will be displayed even if the conditions above are not respected.
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. 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.
@ -275,15 +280,16 @@ When using [AWSume](https://awsu.me) the profile is read from the `AWSUME_PROFIL
### Options ### Options
| Option | Default | Description | | Option | Default | Description |
| ------------------- | -------------------------------------------------------------------- | ----------------------------------------------------------------- | | ------------------- | -------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------- |
| `format` | `'on [$symbol($profile )(\($region\) )(\[$duration\])]($style)'` | The format for the module. | | `format` | `'on [$symbol($profile )(\($region\) )(\[$duration\])]($style)'` | The format for the module. |
| `symbol` | `"☁️ "` | The symbol used before displaying the current AWS profile. | | `symbol` | `"☁️ "` | The symbol used before displaying the current AWS profile. |
| `region_aliases` | | Table of region aliases to display in addition to the AWS name. | | `region_aliases` | | Table of region aliases to display in addition to the AWS name. |
| `profile_aliases` | | Table of profile aliases to display in addition to the AWS name. | | `profile_aliases` | | Table of profile aliases to display in addition to the AWS name. |
| `style` | `"bold yellow"` | The style for the module. | | `style` | `"bold yellow"` | The style for the module. |
| `expiration_symbol` | `X` | The symbol displayed when the temporary credentials have expired. | | `expiration_symbol` | `X` | The symbol displayed when the temporary credentials have expired. |
| `disabled` | `false` | Disables the `AWS` module. | | `disabled` | `false` | Disables the `AWS` module. |
| `force_display` | `false` | If `true` displays info even if `credentials`, `credential_process` or `sso_start_url` have not been setup. |
### Variables ### Variables
@ -472,6 +478,52 @@ The `buf` module shows the currently installed version of [Buf](https://buf.buil
symbol = "🦬 " symbol = "🦬 "
``` ```
## C
The `c` module shows some information about your C compiler. By default the module will be shown if the current directory contains a `.c` or `.h` file.
### Options
| Option | Default | Description |
| ------------------- | --------------------------------------------------------------------------- | ------------------------------------------------------------------------- |
| `format` | `"via [$symbol($version(-$name) )]($style)"` | The format string for the module. |
| `version_format` | `"v${raw}"` | The version format. Available vars are `raw`, `major`, `minor`, & `patch` |
| `symbol` | `"C "` | The symbol used before displaying the compiler details |
| `detect_extensions` | `["c", "h"]` | Which extensions should trigger this module. |
| `detect_files` | `[]` | Which filenames should trigger this module. |
| `detect_folders` | `[]` | Which folders should trigger this module. |
| `commands` | [ [ "cc", "--version" ], [ "gcc", "--version" ], [ "clang", "--version" ] ] | How to detect what the compiler is |
| `style` | `"bold 149"` | The style for the module. |
| `disabled` | `false` | Disables the `c` module. |
### Variables
| Variable | Example | Description |
| -------- | ------- | ------------------------------------ |
| name | clang | The name of the compiler |
| version | 13.0.0 | The version of the compiler |
| symbol | | Mirrors the value of option `symbol` |
| style | | Mirrors the value of option `style` |
NB that `version` is not in the default format.
### Commands
The `commands` option accepts a list of commands to determine the compiler version and name.
Each command is represented as a list of the executable name, followed by its arguments, usually something like `["mycc", "--version"]`. Starship will try executing each command until it gets a result on STDOUT.
If a C compiler is not supported by this module, you can request it by [raising an issue on GitHub](https://github.com/starship/starship/).
### Example
```toml
# ~/.config/starship.toml
[c]
format = "via [$name $version]($style)"
```
## Character ## Character
The `character` module shows a character (usually an arrow) beside where the text is entered in your terminal. The `character` module shows a character (usually an arrow) beside where the text is entered in your terminal.
@ -962,7 +1014,7 @@ You'll also need the .NET Core SDK installed in order to use it correctly.
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. 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 (<https://docs.microsoft.com/en-us/dotnet/standard/frameworks#supported-target-framework-versions>) when there is a csproj file in the current directory. The module will also show the Target Framework Moniker (<https://docs.microsoft.com/en-us/dotnet/standard/frameworks#supported-target-frameworks>) when there is a `.csproj` file in the current directory.
### Options ### Options
@ -2969,6 +3021,39 @@ The `singularity` module shows the current [Singularity](https://sylabs.io/singu
format = '[📦 \[$env\]]($style) ' format = '[📦 \[$env\]]($style) '
``` ```
## Spack
The `spack` module shows the current [Spack](https://spack.readthedocs.io/en/latest/) environment, if `$SPACK_ENV` is set.
### Options
| Option | Default | Description |
| ------------------- | -------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------- |
| `truncation_length` | `1` | The number of directories the environment path should be truncated to. `0` means no truncation. Also see the [`directory`](#directory) module. |
| `symbol` | `"🅢 "` | The symbol used before the environment name. |
| `style` | `"bold blue"` | The style for the module. |
| `format` | `"via [$symbol$environment]($style) "` | The format for the module. |
| `disabled` | `false` | Disables the `spack` module. |
### Variables
| Variable | Example | Description |
| ----------- | ------------ | ------------------------------------ |
| environment | `astronauts` | The current spack environment |
| 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
### Example
```toml
# ~/.config/starship.toml
[spack]
format = "[$symbol$environment](dimmed blue) "
```
## Status ## Status
The `status` module displays the exit code of the previous command. If $success_symbol is empty (default), the module will be shown only if the exit code is not `0`. The status code will cast to a signed 32-bit integer. The `status` module displays the exit code of the previous command. If $success_symbol is empty (default), the module will be shown only if the exit code is not `0`. The status code will cast to a signed 32-bit integer.
@ -3226,7 +3311,7 @@ time_range = "10:00:00-14:00:00"
The `username` module shows active user's username. The module will be shown if any of the following conditions are met: 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 is root/admin
- The current user isn't the same as the one that is logged in - The current user isn't the same as the one that is logged in
- The user is currently connected as an SSH session - The user is currently connected as an SSH session
- The variable `show_always` is set to true - The variable `show_always` is set to true
@ -3239,13 +3324,13 @@ SSH connection is detected by checking environment variables `SSH_CONNECTION`, `
### Options ### Options
| Option | Default | Description | | Option | Default | Description |
| ------------- | ----------------------- | ------------------------------------- | | ------------- | ----------------------- | ------------------------------------------- |
| `style_root` | `"bold red"` | The style used when the user is root. | | `style_root` | `"bold red"` | The style used when the user is root/admin. |
| `style_user` | `"bold yellow"` | The style used for non-root users. | | `style_user` | `"bold yellow"` | The style used for non-root users. |
| `format` | `"[$user]($style) in "` | The format for the module. | | `format` | `"[$user]($style) in "` | The format for the module. |
| `show_always` | `false` | Always shows the `username` module. | | `show_always` | `false` | Always shows the `username` module. |
| `disabled` | `false` | Disables the `username` module. | | `disabled` | `false` | Disables the `username` module. |
### Variables ### Variables
@ -3417,9 +3502,9 @@ The `custom` modules show the output of some arbitrary commands.
These modules will be shown if any of the following conditions are met: These modules will be shown if any of the following conditions are met:
- The current directory contains a file whose name is in `files` - The current directory contains a file whose name is in `detect_files`
- The current directory contains a directory whose name is in `directories` - The current directory contains a directory whose name is in `detect_folders`
- The current directory contains a file whose extension is in `extensions` - The current directory contains a file whose extension is in `detect_extensions`
- The `when` command returns 0 - The `when` command returns 0
- The current Operating System (std::env::consts::OS) matchs with `os` field if defined. - The current Operating System (std::env::consts::OS) matchs with `os` field if defined.
@ -3451,20 +3536,22 @@ Format strings can also contain shell specific prompt sequences, e.g. [Bash](htt
### Options ### Options
| Option | Default | Description | | Option | Default | Description |
| ------------- | ------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | | ------------------- | ------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `command` | `""` | The command whose output should be printed. The command will be passed on stdin to the shell. | | `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. | | `when` | `false` | Either a boolean value (`true` or `false`, without quotes) or a string shell command used as a condition to show the module. In case of a string, the module will be shown if the command returns a `0` status code. |
| `shell` | | [See below](#custom-command-shell) | | `shell` | | [See below](#custom-command-shell) |
| `description` | `"<custom module>"` | The description of the module that is shown when running `starship explain`. | | `description` | `"<custom module>"` | The description of the module that is shown when running `starship explain`. |
| `files` | `[]` | The files that will be searched in the working directory for a match. | | `detect_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. | | `detect_folders` | `[]` | 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. | | `detect_extensions` | `[]` | The extensions that will be searched in the working directory for a match. |
| `symbol` | `""` | The symbol used before displaying the command output. | | `symbol` | `""` | The symbol used before displaying the command output. |
| `style` | `"bold green"` | The style for the module. | | `style` | `"bold green"` | The style for the module. |
| `format` | `"[$symbol($output )]($style)"` | The format for the module. | | `format` | `"[$symbol($output )]($style)"` | The format for the module. |
| `disabled` | `false` | Disables this `custom` 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). | | `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). |
| `use_stdin` | | An optional boolean value that overrides whether commands should be forwarded to the shell via the standard input or as an argument. If unset standard input is used by default, unless the shell does not support it (cmd, nushell). Setting this disables shell-specific argument handling. |
| `ignore_timeout` | `false` | Ignore global `command_timeout` setting and keep running external commands, no matter how long they take. |
### Variables ### Variables
@ -3487,7 +3574,7 @@ If unset, it will fallback to STARSHIP_SHELL and then to "sh" on Linux, and "cmd
The `command` will be passed in on stdin. The `command` will be passed in on stdin.
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. 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 -`. If `shell` is not given or only contains one element and Starship detects Cmd will be used, the following argument will automatically be added: `/C` and `stdin` will be set to `false`. If `shell` is not given or only contains one element and Starship detects Nushell will be used, the following arguments will automatically be added: `-c` and `stdin` will be set to `false`. This behavior can be avoided by explicitly passing arguments to the shell, e.g.
```toml ```toml
shell = ["pwsh", "-Command", "-"] shell = ["pwsh", "-Command", "-"]
@ -3512,12 +3599,18 @@ Automatic detection of shells and proper parameters addition are currently imple
[custom.foo] [custom.foo]
command = "echo foo" # shows output of command command = "echo foo" # shows output of command
files = ["foo"] # can specify filters but wildcards are not supported detect_files = ["foo"] # can specify filters but wildcards are not supported
when = """ test "$HOME" == "$PWD" """ when = """ test "$HOME" == "$PWD" """
format = " transcending [$output]($style)" format = " transcending [$output]($style)"
[custom.time] [custom.time]
command = "time /T" command = "time /T"
extensions = ["pst"] # filters *.pst files detect_extensions = ["pst"] # filters *.pst files
shell = ["pwsh.exe", "-NoProfile", "-Command", "-"] shell = ["pwsh.exe", "-NoProfile", "-Command", "-"]
[custom.time-as-arg]
command = "time /T"
detect_extensions = ["pst"] # filters *.pst files
shell = ["pwsh.exe", "-NoProfile", "-Command"]
use_stdin = false
``` ```

View File

@ -143,7 +143,7 @@
<img <img
src="https://raw.githubusercontent.com/starship/starship/master/media/demo.gif" src="https://raw.githubusercontent.com/starship/starship/master/media/demo.gif"
alt="Starship with iTerm2 and the Snazzy theme" alt="Starship met iTerm2 en het thema Snazzy"
width="50%" width="50%"
align="right" align="right"
/> />
@ -158,7 +158,7 @@
- **Makkelijk:** snel te installeren - begin in een handomdraai met het te gebruiken. - **Makkelijk:** snel te installeren - begin in een handomdraai met het te gebruiken.
<p align="center"> <p align="center">
<a href="https://starship.rs/config/"><strong>Explore the Starship docs&nbsp;&nbsp;</strong></a> <a href="https://starship.rs/config/"><strong>Verken de Starship-documentatie&nbsp;&nbsp;</strong></a>
</p> </p>
<a name="🚀-installation"></a> <a name="🚀-installation"></a>
@ -295,7 +295,7 @@ Add the following to the end of `~/.elvish/rc.elv`:
eval (starship init elvish) eval (starship init elvish)
``` ```
Note: Only Elvish v0.17+ is supported Note: Only Elvish v0.18+ is supported
</details> </details>

View File

@ -120,7 +120,7 @@ description: Starship is the minimal, blazing fast, and extremely customizable p
#### Elvish #### Elvish
::: warning Only elvish v0.17 or higher is supported. ::: ::: warning Only elvish v0.18 or higher is supported. :::
Dodaj na koniec pliku `~/.elvish/rc.elv`: Dodaj na koniec pliku `~/.elvish/rc.elv`:

View File

@ -131,7 +131,7 @@ Invoke-Expression (&starship init powershell)
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`. 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). 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, xonsh, cmd. `right_format` is currently supported for the following shells: elvish, fish, zsh, xonsh, cmd.

View File

@ -9,6 +9,9 @@ mkdir -p ~/.config && touch ~/.config/starship.toml
Cała konfiguracja starship jest wykonywana w tym pliku [TOML](https://github.com/toml-lang/toml): Cała konfiguracja starship jest wykonywana w tym pliku [TOML](https://github.com/toml-lang/toml):
```toml ```toml
# Get editor completions based on the config schema
"$schema" = 'https://starship.rs/config-schema.json'
# Inserts a blank line between shell prompts # Inserts a blank line between shell prompts
add_newline = true add_newline = true
@ -199,6 +202,7 @@ $hg_branch\
$docker_context\ $docker_context\
$package\ $package\
$buf\ $buf\
$c\
$cmake\ $cmake\
$cobol\ $cobol\
$container\ $container\
@ -235,6 +239,7 @@ $vagrant\
$zig\ $zig\
$nix_shell\ $nix_shell\
$conda\ $conda\
$spack\
$memory_usage\ $memory_usage\
$aws\ $aws\
$gcloud\ $gcloud\
@ -263,9 +268,9 @@ format = "$all$directory$character"
## AWS ## AWS
The `aws` module shows the current AWS region and profile when credentials, a `credential_process` or a `sso_start_url` have been setup. 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. The `aws` module shows the current AWS region and profile when credentials, a `credential_process` or a `sso_start_url` have been setup. Alternatively, you can force this module to show the region and profile even when the credentials have not been setup with the `force_display` option. 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.
The module will display a profile only if its credentials are present in `~/.aws/credentials` or a `credential_process` is defined in `~/.aws/config`. Alternatively, having any of the `AWS_ACCESS_KEY_ID`, `AWS_SECRET_ACCESS_KEY`, or `AWS_SESSION_TOKEN` env vars defined will also suffice. The module will display a profile only if its credentials are present in `~/.aws/credentials` or a `credential_process` is defined in `~/.aws/config`. Alternatively, having any of the `AWS_ACCESS_KEY_ID`, `AWS_SECRET_ACCESS_KEY`, or `AWS_SESSION_TOKEN` env vars defined will also suffice. If the option `force_display` is set to `true`, all available information will be displayed even if the conditions above are not respected.
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. 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.
@ -275,15 +280,16 @@ When using [AWSume](https://awsu.me) the profile is read from the `AWSUME_PROFIL
### Options ### Options
| Option | Default | Description | | Option | Default | Description |
| ------------------- | -------------------------------------------------------------------- | ----------------------------------------------------------------- | | ------------------- | -------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------- |
| `format` | `'on [$symbol($profile )(\($region\) )(\[$duration\])]($style)'` | The format for the module. | | `format` | `'on [$symbol($profile )(\($region\) )(\[$duration\])]($style)'` | The format for the module. |
| `symbol` | `"☁️ "` | The symbol used before displaying the current AWS profile. | | `symbol` | `"☁️ "` | The symbol used before displaying the current AWS profile. |
| `region_aliases` | | Table of region aliases to display in addition to the AWS name. | | `region_aliases` | | Table of region aliases to display in addition to the AWS name. |
| `profile_aliases` | | Table of profile aliases to display in addition to the AWS name. | | `profile_aliases` | | Table of profile aliases to display in addition to the AWS name. |
| `style` | `"bold yellow"` | The style for the module. | | `style` | `"bold yellow"` | The style for the module. |
| `expiration_symbol` | `X` | The symbol displayed when the temporary credentials have expired. | | `expiration_symbol` | `X` | The symbol displayed when the temporary credentials have expired. |
| `disabled` | `false` | Disables the `AWS` module. | | `disabled` | `false` | Disables the `AWS` module. |
| `force_display` | `false` | If `true` displays info even if `credentials`, `credential_process` or `sso_start_url` have not been setup. |
### Variables ### Variables
@ -472,6 +478,52 @@ The `buf` module shows the currently installed version of [Buf](https://buf.buil
symbol = "🦬 " symbol = "🦬 "
``` ```
## C
The `c` module shows some information about your C compiler. By default the module will be shown if the current directory contains a `.c` or `.h` file.
### Options
| Option | Default | Description |
| ------------------- | --------------------------------------------------------------------------- | ------------------------------------------------------------------------- |
| `format` | `"via [$symbol($version(-$name) )]($style)"` | The format string for the module. |
| `version_format` | `"v${raw}"` | The version format. Available vars are `raw`, `major`, `minor`, & `patch` |
| `symbol` | `"C "` | The symbol used before displaying the compiler details |
| `detect_extensions` | `["c", "h"]` | Which extensions should trigger this module. |
| `detect_files` | `[]` | Which filenames should trigger this module. |
| `detect_folders` | `[]` | Which folders should trigger this module. |
| `commands` | [ [ "cc", "--version" ], [ "gcc", "--version" ], [ "clang", "--version" ] ] | How to detect what the compiler is |
| `style` | `"bold 149"` | The style for the module. |
| `disabled` | `false` | Disables the `c` module. |
### Variables
| Zmienne | Example | Description |
| ------- | ------- | ------------------------------------ |
| name | clang | The name of the compiler |
| version | 13.0.0 | The version of the compiler |
| symbol | | Mirrors the value of option `symbol` |
| style | | Mirrors the value of option `style` |
NB that `version` is not in the default format.
### Commands
The `commands` option accepts a list of commands to determine the compiler version and name.
Each command is represented as a list of the executable name, followed by its arguments, usually something like `["mycc", "--version"]`. Starship will try executing each command until it gets a result on STDOUT.
If a C compiler is not supported by this module, you can request it by [raising an issue on GitHub](https://github.com/starship/starship/).
### Example
```toml
# ~/.config/starship.toml
[c]
format = "via [$name $version]($style)"
```
## Character ## Character
The `character` module shows a character (usually an arrow) beside where the text is entered in your terminal. The `character` module shows a character (usually an arrow) beside where the text is entered in your terminal.
@ -962,7 +1014,7 @@ You'll also need the .NET Core SDK installed in order to use it correctly.
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. 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 (<https://docs.microsoft.com/en-us/dotnet/standard/frameworks#supported-target-framework-versions>) when there is a csproj file in the current directory. The module will also show the Target Framework Moniker (<https://docs.microsoft.com/en-us/dotnet/standard/frameworks#supported-target-frameworks>) when there is a `.csproj` file in the current directory.
### Options ### Options
@ -1106,7 +1158,7 @@ default = "unknown user"
| Option | Default | Description | | Option | Default | Description |
| ---------- | ------------------------------ | ---------------------------------------------------------------------------- | | ---------- | ------------------------------ | ---------------------------------------------------------------------------- |
| `symbol` | `""` | The symbol used before displaying the variable value. | | `symbol` | `""` | The symbol used before displaying the variable value. |
| `variable` | | The environment variable to be displayed. | | `zmienne` | | The environment variable to be displayed. |
| `default` | | The default value to be displayed when the selected variable is not defined. | | `default` | | The default value to be displayed when the selected variable is not defined. |
| `format` | `"with [$env_value]($style) "` | The format for the module. | | `format` | `"with [$env_value]($style) "` | The format for the module. |
| `disabled` | `false` | Disables the `env_var` module. | | `disabled` | `false` | Disables the `env_var` module. |
@ -2969,6 +3021,39 @@ The `singularity` module shows the current [Singularity](https://sylabs.io/singu
format = '[📦 \[$env\]]($style) ' format = '[📦 \[$env\]]($style) '
``` ```
## Spack
The `spack` module shows the current [Spack](https://spack.readthedocs.io/en/latest/) environment, if `$SPACK_ENV` is set.
### Options
| Option | Default | Description |
| ------------------- | -------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------- |
| `truncation_length` | `1` | The number of directories the environment path should be truncated to. `0` means no truncation. Also see the [`directory`](#directory) module. |
| `symbol` | `"🅢 "` | The symbol used before the environment name. |
| `style` | `"bold blue"` | The style for the module. |
| `format` | `"via [$symbol$environment]($style) "` | The format for the module. |
| `disabled` | `false` | Disables the `spack` module. |
### Variables
| Zmienne | Example | Description |
| ----------- | ------------ | ------------------------------------ |
| environment | `astronauts` | The current spack environment |
| 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
### Example
```toml
# ~/.config/starship.toml
[spack]
format = "[$symbol$environment](dimmed blue) "
```
## Status ## Status
The `status` module displays the exit code of the previous command. If $success_symbol is empty (default), the module will be shown only if the exit code is not `0`. The status code will cast to a signed 32-bit integer. The `status` module displays the exit code of the previous command. If $success_symbol is empty (default), the module will be shown only if the exit code is not `0`. The status code will cast to a signed 32-bit integer.
@ -3226,7 +3311,7 @@ time_range = "10:00:00-14:00:00"
The `username` module shows active user's username. The module will be shown if any of the following conditions are met: 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 is root/admin
- The current user isn't the same as the one that is logged in - The current user isn't the same as the one that is logged in
- The user is currently connected as an SSH session - The user is currently connected as an SSH session
- The variable `show_always` is set to true - The variable `show_always` is set to true
@ -3239,13 +3324,13 @@ SSH connection is detected by checking environment variables `SSH_CONNECTION`, `
### Options ### Options
| Option | Default | Description | | Option | Default | Description |
| ------------- | ----------------------- | ------------------------------------- | | ------------- | ----------------------- | ------------------------------------------- |
| `style_root` | `"bold red"` | The style used when the user is root. | | `style_root` | `"bold red"` | The style used when the user is root/admin. |
| `style_user` | `"bold yellow"` | The style used for non-root users. | | `style_user` | `"bold yellow"` | The style used for non-root users. |
| `format` | `"[$user]($style) in "` | The format for the module. | | `format` | `"[$user]($style) in "` | The format for the module. |
| `show_always` | `false` | Always shows the `username` module. | | `show_always` | `false` | Always shows the `username` module. |
| `disabled` | `false` | Disables the `username` module. | | `disabled` | `false` | Disables the `username` module. |
### Variables ### Variables
@ -3417,9 +3502,9 @@ The `custom` modules show the output of some arbitrary commands.
These modules will be shown if any of the following conditions are met: These modules will be shown if any of the following conditions are met:
- The current directory contains a file whose name is in `files` - The current directory contains a file whose name is in `detect_files`
- The current directory contains a directory whose name is in `directories` - The current directory contains a directory whose name is in `detect_folders`
- The current directory contains a file whose extension is in `extensions` - The current directory contains a file whose extension is in `detect_extensions`
- The `when` command returns 0 - The `when` command returns 0
- The current Operating System (std::env::consts::OS) matchs with `os` field if defined. - The current Operating System (std::env::consts::OS) matchs with `os` field if defined.
@ -3451,20 +3536,22 @@ Format strings can also contain shell specific prompt sequences, e.g. [Bash](htt
### Options ### Options
| Option | Default | Description | | Option | Default | Description |
| ------------- | ------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | | ------------------- | ------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `command` | `""` | The command whose output should be printed. The command will be passed on stdin to the shell. | | `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. | | `when` | `false` | Either a boolean value (`true` or `false`, without quotes) or a string shell command used as a condition to show the module. In case of a string, the module will be shown if the command returns a `0` status code. |
| `shell` | | [See below](#custom-command-shell) | | `shell` | | [See below](#custom-command-shell) |
| `description` | `"<custom module>"` | The description of the module that is shown when running `starship explain`. | | `description` | `"<custom module>"` | The description of the module that is shown when running `starship explain`. |
| `files` | `[]` | The files that will be searched in the working directory for a match. | | `detect_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. | | `detect_folders` | `[]` | 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. | | `detect_extensions` | `[]` | The extensions that will be searched in the working directory for a match. |
| `symbol` | `""` | The symbol used before displaying the command output. | | `symbol` | `""` | The symbol used before displaying the command output. |
| `style` | `"bold green"` | The style for the module. | | `style` | `"bold green"` | The style for the module. |
| `format` | `"[$symbol($output )]($style)"` | The format for the module. | | `format` | `"[$symbol($output )]($style)"` | The format for the module. |
| `disabled` | `false` | Disables this `custom` 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). | | `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). |
| `use_stdin` | | An optional boolean value that overrides whether commands should be forwarded to the shell via the standard input or as an argument. If unset standard input is used by default, unless the shell does not support it (cmd, nushell). Setting this disables shell-specific argument handling. |
| `ignore_timeout` | `false` | Ignore global `command_timeout` setting and keep running external commands, no matter how long they take. |
### Variables ### Variables
@ -3487,7 +3574,7 @@ If unset, it will fallback to STARSHIP_SHELL and then to "sh" on Linux, and "cmd
The `command` will be passed in on stdin. The `command` will be passed in on stdin.
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. 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 -`. If `shell` is not given or only contains one element and Starship detects Cmd will be used, the following argument will automatically be added: `/C` and `stdin` will be set to `false`. If `shell` is not given or only contains one element and Starship detects Nushell will be used, the following arguments will automatically be added: `-c` and `stdin` will be set to `false`. This behavior can be avoided by explicitly passing arguments to the shell, e.g.
```toml ```toml
shell = ["pwsh", "-Command", "-"] shell = ["pwsh", "-Command", "-"]
@ -3512,12 +3599,18 @@ Automatic detection of shells and proper parameters addition are currently imple
[custom.foo] [custom.foo]
command = "echo foo" # shows output of command command = "echo foo" # shows output of command
files = ["foo"] # can specify filters but wildcards are not supported detect_files = ["foo"] # can specify filters but wildcards are not supported
when = """ test "$HOME" == "$PWD" """ when = """ test "$HOME" == "$PWD" """
format = " transcending [$output]($style)" format = " transcending [$output]($style)"
[custom.time] [custom.time]
command = "time /T" command = "time /T"
extensions = ["pst"] # filters *.pst files detect_extensions = ["pst"] # filters *.pst files
shell = ["pwsh.exe", "-NoProfile", "-Command", "-"] shell = ["pwsh.exe", "-NoProfile", "-Command", "-"]
[custom.time-as-arg]
command = "time /T"
detect_extensions = ["pst"] # filters *.pst files
shell = ["pwsh.exe", "-NoProfile", "-Command"]
use_stdin = false
``` ```

View File

@ -145,7 +145,7 @@
<img <img
src="https://raw.githubusercontent.com/starship/starship/master/media/demo.gif" src="https://raw.githubusercontent.com/starship/starship/master/media/demo.gif"
alt="Starship with iTerm2 and the Snazzy theme" alt="Starship na iTerm2 z motywem Snazzy"
width="50%" width="50%"
align="right" align="right"
/> />
@ -160,7 +160,7 @@
- **Łatwy w obsłudze:** szybka instalacja - zacznij korzystać w kilka minut. - **Łatwy w obsłudze:** szybka instalacja - zacznij korzystać w kilka minut.
<p align="center"> <p align="center">
<a href="https://starship.rs/config/"><strong>Explore the Starship docs&nbsp;&nbsp;</strong></a> <a href="https://starship.rs/config/"><strong>Przeglądaj dokumentację Starship&nbsp;&nbsp;</strong></a>
</p> </p>
<a name="🚀-installation"></a> <a name="🚀-installation"></a>
@ -297,7 +297,7 @@ Dodaj na koniec pliku `~/.elvish/rc.elv`:
eval (starship init elvish) eval (starship init elvish)
``` ```
Note: Only Elvish v0.17+ is supported Note: Only Elvish v0.18+ is supported
</details> </details>
@ -400,15 +400,15 @@ If you're looking to further customize Starship:
## 🤝Wspomóż nas ## 🤝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ć. 👋
## 💭Inspiracje ## 💭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)** A ZSH prompt for astronauts.

View File

@ -1,4 +1,4 @@
# Advanced Installation # Zaawansowana Instalacja
Aby zainstalować starship, musisz zrobić dwie rzeczy: Aby zainstalować starship, musisz zrobić dwie rzeczy:

View File

@ -120,7 +120,7 @@ description: O Starship é o prompt minimalista, extremamente rápido e extremam
#### Elvish #### Elvish
::: warning Apenas a versão v0.17 ou superior do elvish é suportada. ::: ::: warning Somente a versão v0.18 ou superior do elvish é suportada. :::
Adicione o comando a seguir ao final do arquivo `~/.elvish/rc.elv`: Adicione o comando a seguir ao final do arquivo `~/.elvish/rc.elv`:
@ -144,7 +144,7 @@ description: O Starship é o prompt minimalista, extremamente rápido e extremam
#### Nushell #### Nushell
::: Atenção Isto vai mudar no futuro. Only Nushell v0.60+ is supported. ::: Run the following: ::: Atenção Isto vai mudar no futuro. Somente Nushell v0.60+ é suportado. ::: Execute os seguintes comandos:
```sh ```sh
mkdir ~/.cache/starship mkdir ~/.cache/starship
starship init nu | save ~/.cache/starship/init.nu starship init nu | save ~/.cache/starship/init.nu
@ -171,7 +171,7 @@ description: O Starship é o prompt minimalista, extremamente rápido e extremam
#### Cmd #### Cmd
Você precisa do [Clink](https://chrisant996.github.io/clink/clink.html) (v1.2.30+) com Cmd. Add the following to a file `starship.lua` and place this file in Clink scripts directory: Você precisa do [Clink](https://chrisant996.github.io/clink/clink.html) (v1.2.30+) com Cmd. Adicione o seguinte num arquivo `starship.lua` e coloque este arquivo no diretório scripts do Clink:
```lua ```lua
-- starship.lua -- starship.lua

View File

@ -131,7 +131,7 @@ Invoke-Expression (&starship init powershell)
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`. 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`.
Nota: O prompt direito é uma linha única seguindo o local de entrada. Para alinhar à direita os módulos acima a linha de entrada em um prompt de várias linhas, consulte o [módulo fill](/config/#fill). Nota: O prompt direito é uma linha única seguindo o local de entrada. To right align modules above the input line in a multi-line prompt, see the [`fill` module](/config/#fill).
`right_format` é atualmente compatível com os seguintes shells: elvish, fish, zsh, xonsh, cmd. `right_format` é atualmente compatível com os seguintes shells: elvish, fish, zsh, xonsh, cmd.

File diff suppressed because it is too large Load Diff

View File

@ -1,4 +1,4 @@
# Frequently Asked Questions # Perguntas Frequentes
## Qual é a configuração usada no GIF de demonstração? ## Qual é a configuração usada no GIF de demonstração?

View File

@ -145,7 +145,7 @@
<img <img
src="https://raw.githubusercontent.com/starship/starship/master/media/demo.gif" src="https://raw.githubusercontent.com/starship/starship/master/media/demo.gif"
alt="Starship with iTerm2 and the Snazzy theme" alt="Starship com iTerm2 e o tema Snazzy"
width="50%" width="50%"
align="right" align="right"
/> />
@ -160,7 +160,7 @@
- **Fácil:**Instalação rápida comece a usar em minutos. - **Fácil:**Instalação rápida comece a usar em minutos.
<p align="center"> <p align="center">
<a href="https://starship.rs/config/"><strong>Explore the Starship docs&nbsp;&nbsp;</strong></a> <a href="https://starship.rs/config/"><strong>Consulte a documentação&nbsp;&nbsp;</strong></a>
</p> </p>
<a name="🚀-installation"></a> <a name="🚀-installation"></a>
@ -173,12 +173,12 @@
### 1º passo. Instalar o Starship ### 1º passo. Instalar o Starship
Select your operating system from the list below to view installation instructions: Selecione seu sistema operacional na lista abaixo para ver as instruções de instalação:
<details> <details>
<summary>Android</summary> <summary>Android</summary>
Install Starship using any of the following package managers: Instale o Starship usando qualquer um dos seguintes gerenciadores de pacotes:
| Repositório | Instruções | | Repositório | Instruções |
| --------------------------------------------------------------------------------- | ---------------------- | | --------------------------------------------------------------------------------- | ---------------------- |
@ -189,7 +189,7 @@ Install Starship using any of the following package managers:
<details> <details>
<summary>BSD</summary> <summary>BSD</summary>
Install Starship using any of the following package managers: Instale o Starship usando qualquer um dos seguintes gerenciadores de pacotes:
| Distribuição | Repositório | Instruções | | Distribuição | Repositório | Instruções |
| -------------- | -------------------------------------------------------- | --------------------------------- | | -------------- | -------------------------------------------------------- | --------------------------------- |
@ -202,13 +202,13 @@ Install Starship using any of the following package managers:
<details> <details>
<summary>Linux</summary> <summary>Linux</summary>
Install the latest version for your system: Instale a versão mais recente no seu sistema:
```sh ```sh
curl -sS https://starship.rs/install.sh | sh curl -sS https://starship.rs/install.sh | sh
``` ```
Alternatively, install Starship using any of the following package managers: Ou instale o Starship usando qualquer um dos seguintes gerenciadores de pacotes:
| Distribuição | Repositório | Instruções | | Distribuição | Repositório | Instruções |
| ------------------ | ----------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------ | | ------------------ | ----------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------ |
@ -231,13 +231,13 @@ Alternatively, install Starship using any of the following package managers:
<details> <details>
<summary>macOS</summary> <summary>macOS</summary>
Install the latest version for your system: Instale a versão mais recente no seu sistema:
```sh ```sh
curl -sS https://starship.rs/install.sh | sh curl -sS https://starship.rs/install.sh | sh
``` ```
Alternatively, install Starship using any of the following package managers: Ou instale o Starship usando qualquer um dos seguintes gerenciadores de pacotes:
| Repositório | Instruções | | Repositório | Instruções |
| -------------------------------------------------------- | --------------------------------------- | | -------------------------------------------------------- | --------------------------------------- |
@ -251,7 +251,7 @@ Alternatively, install Starship using any of the following package managers:
<details> <details>
<summary>Windows</summary> <summary>Windows</summary>
Install Starship using any of the following package managers: Instale o Starship usando qualquer um dos seguintes gerenciadores de pacotes:
| Repositório | Instruções | | Repositório | Instruções |
| -------------------------------------------------------------------------------- | --------------------------------------- | | -------------------------------------------------------------------------------- | --------------------------------------- |
@ -264,7 +264,7 @@ Install Starship using any of the following package managers:
### 2º passo. Configure seu shell para usar o Starship ### 2º passo. Configure seu shell para usar o Starship
Configure your shell to initialize starship. Select yours from the list below: Configure seu shell para inicializar o starship. Selecione o seu na lista abaixo:
<details> <details>
<summary>Bash</summary> <summary>Bash</summary>
@ -280,7 +280,7 @@ eval "$(starship init bash)"
<details> <details>
<summary>Cmd</summary> <summary>Cmd</summary>
Você precisa do [Clink](https://chrisant996.github.io/clink/clink.html) (v1.2.30+) com Cmd. Create a file at this path `%LocalAppData%\clink\starship.lua` with the following contents: Você precisa do [Clink](https://chrisant996.github.io/clink/clink.html) (v1.2.30+) com Cmd. Crie um arquivo neste caminho `%LocalAppData%\clink\starship.lua` com o seguinte conteúdo:
```lua ```lua
load(io.popen('starship init cmd'):read("*a"))() load(io.popen('starship init cmd'):read("*a"))()
@ -297,7 +297,7 @@ Adicione o comando a seguir ao final do arquivo `~/.elvish/rc.elv`:
eval (starship init elvish) eval (starship init elvish)
``` ```
Note: Only Elvish v0.17+ is supported Nota: Somente Elvish v0.18+ é suportado
</details> </details>
@ -347,7 +347,7 @@ Note: Only Nushell v0.60+ is supported
<details> <details>
<summary>PowerShell</summary> <summary>PowerShell</summary>
Add the following to the end of your PowerShell configuration (find it by running `$PROFILE`): Adicione o seguinte no final da sua configuração PowerShell (encontre executando `$PROFILE`):
```powershell ```powershell
Invoke-Expression (&starship init powershell) Invoke-Expression (&starship init powershell)
@ -390,9 +390,9 @@ eval "$(starship init zsh)"
### 3º passo. Configurar o Starship ### 3º passo. Configurar o Starship
Start a new shell instance, and you should see your beautiful new shell prompt. If you're happy with the defaults, enjoy! Inicie uma nova instância de shell e você deverá ver seu belo novo prompt de shell. Se você estiver feliz com as configurações padrões, aproveite!
If you're looking to further customize Starship: Se você estiver procurando personalizar ainda mais a Starship:
- **[Configuração](https://starship.rs/config/)** saiba como configurar o Starship para ajustar seu prompt ao seu gosto - **[Configuração](https://starship.rs/config/)** saiba como configurar o Starship para ajustar seu prompt ao seu gosto
@ -400,15 +400,15 @@ If you're looking to further customize Starship:
## 🤝 Contribuindo ## 🤝 Contribuindo
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). Nós estamos sempre procurando contribuidores de **todos os níveis de conhecimento**! Se você está buscando um caminho mais fácil para começar no projeto, veja essas [boas issues para começar](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/). Se você é fluente em uma linguá não inglesa, nos ficaríamos gratos por qualquer ajuda em manter nossas documentações traduzidas e atualizadas em outras linguás. Se você deseja ajudar nas traduções, você pode contribuir no [Crowdin do Starship](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. 👋 Se você está interessado em ajudar contribuindo com o projeto, dê uma olhada no nosso [Guia de Contribuição](https://github.com/starship/starship/blob/master/CONTRIBUTING.md). Além disso, sinta-se à vontade para entrar no nosso [servidor no Discord](https://discord.gg/8Jzqu3T) e dizer oi. 👋
## 💭 Inspirado por ## 💭 Inspirado por
Please check out these previous works that helped inspire the creation of starship. 🙏 Por favor, confira estes projetos anteriores que ajudaram a inspirar a criação do startship. 🙏
- **[denysdovhan/spaceship-prompt](https://github.com/denysdovhan/spaceship-prompt)** Um prompt ZSH para astronautas. - **[denysdovhan/spaceship-prompt](https://github.com/denysdovhan/spaceship-prompt)** Um prompt ZSH para astronautas.
@ -418,9 +418,9 @@ Please check out these previous works that helped inspire the creation of starsh
<p align="center"> <p align="center">
<br> <br>
<img width="100" src="https://raw.githubusercontent.com/starship/starship/master/media/icon.png" alt="Starship rocket icon"> <img width="100" src="https://raw.githubusercontent.com/starship/starship/master/media/icon.png" alt="Ícone de foguete do Starship">
</p> </p>
## 📝 Licença ## 📝 Licença
Copyright © 2019-present, [Starship Contributors](https://github.com/starship/starship/graphs/contributors).<br /> This project is [ISC](https://github.com/starship/starship/blob/master/LICENSE) licensed. Todos os direitos reservados © 2019-Presente, [Contribuidores Starship](https://github.com/starship/starship/graphs/contributors).<br /> Este projeto está licenciado pelo [ISC](https://github.com/starship/starship/blob/master/LICENSE).

View File

@ -1,4 +1,4 @@
# Advanced Installation # Instalação Avançada
Para instalar o starship, você precisa de duas coisas: Para instalar o starship, você precisa de duas coisas:

View File

@ -1,4 +1,4 @@
# Migrando para V0.45.0 # Migrando para v0.45.0
Starship v0.45.0 é o lançamento com grandes mudanças, em preparação para a grande versão v1.0.0. Nos fizemos algumas grandes mudanças em como é feita as configurações do prompt. para aceitar uma customização maior. Starship v0.45.0 é o lançamento com grandes mudanças, em preparação para a grande versão v1.0.0. Nos fizemos algumas grandes mudanças em como é feita as configurações do prompt. para aceitar uma customização maior.

View File

@ -1,41 +1,41 @@
# Configurações # Personalizações
Aqui tem uma coleção de predefinições de configuração criadas pela comunidade de Starship. Se você tem uma configuração para compartilhar, por favor, [envie uma PR](https://github.com/starship/starship/edit/master/docs/presets/README.md) atualizando este arquivo! 😊 Aqui tem uma coleção de personalizações desenvolvidas pela comunidade para usar com Starship. Se você tem uma personalização para compartilhar, por favor, [envie uma PR](https://github.com/starship/starship/edit/master/docs/presets/README.md) atualizando este arquivo! 😊
To get details on how to use a preset, simply click on the image. Para mais detalhes sobre como usar uma personalização, clique na imagem.
## [Símbolos Nerd Font](./nerd-font.md) ## [Símbolos Nerd Font](./nerd-font.md)
This preset changes the symbols for each module to use Nerd Font symbols. Essa personalização altera os símbolos para cada módulo usar Nerd Font.
[![Captura de tela da predefinição Nerd Font Symbols](/presets/img/nerd-font-symbols.png "Click to view Nerd Font Symbols preset")](./nerd-font) [![Captura de tela da personalização com símbolos usando Nerd Font](/presets/img/nerd-font-symbols.png "Clique para ver as personalizações para Nerd Font")](./nerd-font)
## [Seguimentos entre colchetes](./bracketed-segments.md) ## [Seguimentos entre colchetes](./bracketed-segments.md)
Está configuração altera o formato de todos os módulos integrados para que usem colchetes ao mostrar o seguimento ao invés de usar texto padrão do Starship ("via", "on", etc.). Está personalização altera o formato de todos os módulos integrados para que usem colchetes ao mostrar o seguimento ao invés de usar texto convencional do Starship ("via", "on", etc.).
[![Captura de tela de segmentos predefinidos](/presets/img/bracketed-segments.png "Click to view Bracketed Segments preset")](./bracketed-segments) [![Captura de tela de segmentos predefinidos](/presets/img/bracketed-segments.png "Clique para ver as personalizações de seguimentos entre colchetes")](./bracketed-segments)
## [Símbolos de texto simples](./plain-text.md) ## [Símbolos de texto simples](./plain-text.md)
This preset changes the symbols for each module into plain text. Great if you don't have access to Unicode. Essa personalização converte os símbolos para cada módulo em texto simples. Importante para quando não tiver suporte para caracteres Unicode.
[![Captura de tela da predefinição de símbolos de texto simples](/presets/img/plain-text-symbols.png "Click to view Plain Text Symbols preset")](./plain-text) [![Captura de tela de personalização de símbolos de texto simples](/presets/img/plain-text-symbols.png "Clique para ver as personalizações para símbolos de texto simples")](./plain-text)
## [No Runtime Versions](./no-runtimes.md) ## [Runtime Ausente](./no-runtimes.md)
Está predefinição oculta a versão do runtime da linguagem. Se você trabalha com containers ou ambientes virtualizados, este é para você! Está predefinição oculta a versão do runtime da linguagem. Se você trabalha com containers ou ambientes virtualizados, este é para você!
[![Captura de tela de ajustes de ocultar versão de runtime](/presets/img/no-runtime-versions.png "Click to view No Runtime Versions preset")](./no-runtimes) [![Captura de tela de uma personalização ocultando a versão do runtime](/presets/img/no-runtime-versions.png "Clique para ver as personalizações para remover a versão do runtime")](./no-runtimes)
## [Pure Prompt](./pure-preset.md) ## [Prompt do Terminal com Pure](./pure-preset.md)
Essa configuração simula a aparência e o comportamento do [Pure](https://github.com/sindresorhus/pure). Essa personalização simula a aparência e o comportamento do [Pure](https://github.com/sindresorhus/pure).
[![Captura de tela da configuração emulando Pure](/presets/img/pure-preset.png "Click to view Pure Prompt preset")](./pure-preset) [![Captura de tela da personalização do prompt do terminal usando Pure](/presets/img/pure-preset.png "Clique para ver as personalização para usar no prompt do terminal com Pure")](./pure-preset)
## [Pastel Powerline](./pastel-powerline.md) ## [Pastel Powerline](./pastel-powerline.md)
This preset is inspired by [M365Princess](https://github.com/JanDeDobbeleer/oh-my-posh/blob/main/themes/M365Princess.omp.json). It also shows how path substitution works in starship. Esta personalização é inspirada em [M365Princess](https://github.com/JanDeDobbeleer/oh-my-posh/blob/main/themes/M365Princess.omp.json). Mostra também como a substituição de segmentos do caminho completo do diretório funciona no starship.
[![Screenshot of Pastel Powerline preset](/presets/img/pastel-powerline.png "Click to view Pure Prompt preset")](./pastel-powerline) [![Capture de tela das personalizações com Pastel Powerline](/presets/img/pastel-powerline.png "Clique para ver as personalização para usar no prompt do terminal com Pure")](./pastel-powerline)

View File

@ -1,13 +1,13 @@
[Return to Presets](./README.md#bracketed-segments) [Retornar para Personalizações](./README.md#bracketed-segments)
# Bracketed Segments Preset # Predefinições entre colchetes
Está configuração altera o formato de todos os módulos integrados para que usem colchetes ao mostrar o seguimento ao invés de usar texto padrão do Starship ("via", "on", etc.). Esta configuração altera o formato de todos os módulos internos para mostrar seus respectivos segmentos entre colchetes em vez de usar o texto convencional do Starship ("via", "on", etc.).
![Captura de tela de segmentos predefinidos](/presets/img/bracketed-segments.png) ![Captura de tela de segmentos predefinidos](/presets/img/bracketed-segments.png)
### Configuração ### Configuração
[Click to download TOML](/presets/toml/bracketed-segments.toml) [Clique para baixar o TOML](/presets/toml/bracketed-segments.toml)
<<< @/.vuepress/public/presets/toml/bracketed-segments.toml <<< @/.vuepress/public/presets/toml/bracketed-segments.toml

View File

@ -1,8 +1,8 @@
[Return to Presets](./README.md#nerd-font-symbols) [Retornar para Personalizações](./README.md#nerd-font-symbols)
# Nerd Font Symbols Preset # Símbolos Nerd Font
This preset changes the symbols for each module to use Nerd Font symbols. Essa predefinição altera os símbolos para cada módulo usar símbolos com Nerd Font.
![Captura de tela da predefinição Nerd Font Symbols](/presets/img/nerd-font-symbols.png) ![Captura de tela da predefinição Nerd Font Symbols](/presets/img/nerd-font-symbols.png)
@ -12,6 +12,6 @@ This preset changes the symbols for each module to use Nerd Font symbols.
### Configuração ### Configuração
[Click to download TOML](/presets/toml/nerd-font-symbols.toml) [Clique para baixar o TOML](/presets/toml/nerd-font-symbols.toml)
<<< @/.vuepress/public/presets/toml/nerd-font-symbols.toml <<< @/.vuepress/public/presets/toml/nerd-font-symbols.toml

View File

@ -1,13 +1,13 @@
[Return to Presets](./README.md#no-runtime-versions) [Retornar para Predefinições](./README.md#no-runtime-versions)
# No Runtime Versions Preset # Remover versão do runtime
Está predefinição oculta a versão do runtime da linguagem. Se você trabalha com containers ou ambientes virtualizados, este é para você! Está personalização oculta a versão do runtime da linguagem. Se você trabalha com containers ou ambientes virtualizados, este é para você!
![Captura de tela de ajustes de ocultar versão de runtime](/presets/img/no-runtime-versions.png) ![Captura de tela de ajustes de ocultar versão de runtime](/presets/img/no-runtime-versions.png)
### Configuração ### Configuração
[Click to download TOML](/presets/toml/no-runtime-versions.toml) [Clique para baixar o TOML](/presets/toml/no-runtime-versions.toml)
<<< @/.vuepress/public/presets/toml/no-runtime-versions.toml <<< @/.vuepress/public/presets/toml/no-runtime-versions.toml

View File

@ -1,17 +1,17 @@
[Return to Presets](./README.md#pastel-powerline) [Retornar para Predefinições](./README.md#pastel-powerline)
# Pastel Powerline Preset # Pastel Powerline
This preset is inspired by [M365Princess](https://github.com/JanDeDobbeleer/oh-my-posh/blob/main/themes/M365Princess.omp.json). It also shows how path substitution works in starship. Esta personalização é inspirada em [M365Princess](https://github.com/JanDeDobbeleer/oh-my-posh/blob/main/themes/M365Princess.omp.json). Mostra também como a substituição de segmentos do caminho completo do diretório funciona no starship.
![Screenshot of Pastel Powerline preset](/presets/img/pastel-powerline.png) ![Screenshot do preset Pastel Powerline](/presets/img/pastel-powerline.png)
### Pré-requisitos ### Pré-requisitos
- A [Nerd Font](https://www.nerdfonts.com/) installed and enabled in your terminal (the example uses Caskaydia Cove Nerd Font) - Uma [Nerd Font](https://www.nerdfonts.com/) instalada e funcionando no seu terminal (o exemplo utiliza Fira Code Nerd Font)
### Configuração ### Configuração
[Click to download TOML](/presets/toml/pastel-powerline.toml) [Clique para baixar o TOML](/presets/toml/pastel-powerline.toml)
<<< @/.vuepress/public/presets/toml/pastel-powerline.toml <<< @/.vuepress/public/presets/toml/pastel-powerline.toml

View File

@ -1,13 +1,13 @@
[Return to Presets](./README.md#plain-text-symbols) [Retornar para Personalizações](./README.md#plain-text-symbols)
## Plain Text Symbols Preset ## Personalização de símbolos de texto simples
This preset changes the symbols for each module into plain text. Great if you don't have access to Unicode. Essa personalização converte os símbolos para cada módulo em texto simples. Importante para quando não tiver suporte para caracteres Unicode.
![Captura de tela da predefinição de símbolos de texto simples](/presets/img/plain-text-symbols.png) ![Captura de tela da predefinição de símbolos de texto simples](/presets/img/plain-text-symbols.png)
### Configuração ### Configuração
[Click to download TOML](/presets/toml/plain-text-symbols.toml) [Clique para baixar o TOML](/presets/toml/plain-text-symbols.toml)
<<< @/.vuepress/public/presets/toml/plain-text-symbols.toml <<< @/.vuepress/public/presets/toml/plain-text-symbols.toml

View File

@ -1,13 +1,13 @@
[Return to Presets](./README.md#pure) [Retornar para Personalizações](./README.md#pure)
# Pure Preset # Personalização do prompt do terminal com Pure
Essa configuração simula a aparência e o comportamento do [Pure](https://github.com/sindresorhus/pure). Essa personalização simula o comportamento e aparência do [Pure](https://github.com/sindresorhus/pure).
![Captura de tela da configuração emulando Pure](/presets/img/pure-preset.png) ![Captura de tela da configuração emulando Pure](/presets/img/pure-preset.png)
### Configuração ### Configuração
[Click to download TOML](/presets/toml/pure-preset.toml) [Clique para baixar o TOML](/presets/toml/pure-preset.toml)
<<< @/.vuepress/public/presets/toml/pure-preset.toml <<< @/.vuepress/public/presets/toml/pure-preset.toml

View File

@ -120,7 +120,7 @@ description: Starship is the minimal, blazing fast, and extremely customizable p
#### Elvish #### Elvish
::: warning Only elvish v0.17 or higher is supported. ::: ::: warning Only elvish v0.18 or higher is supported. :::
Add the following to the end of `~/.elvish/rc.elv`: Add the following to the end of `~/.elvish/rc.elv`:

View File

@ -131,7 +131,7 @@ Invoke-Expression (&starship init powershell)
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`. 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). 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, xonsh, cmd. `right_format` is currently supported for the following shells: elvish, fish, zsh, xonsh, cmd.

View File

@ -9,6 +9,9 @@ mkdir -p ~/.config && touch ~/.config/starship.toml
All configuration for starship is done in this [TOML](https://github.com/toml-lang/toml) file: All configuration for starship is done in this [TOML](https://github.com/toml-lang/toml) file:
```toml ```toml
# Get editor completions based on the config schema
"$schema" = 'https://starship.rs/config-schema.json'
# Inserts a blank line between shell prompts # Inserts a blank line between shell prompts
add_newline = true add_newline = true
@ -199,6 +202,7 @@ $hg_branch\
$docker_context\ $docker_context\
$package\ $package\
$buf\ $buf\
$c\
$cmake\ $cmake\
$cobol\ $cobol\
$container\ $container\
@ -235,6 +239,7 @@ $vagrant\
$zig\ $zig\
$nix_shell\ $nix_shell\
$conda\ $conda\
$spack\
$memory_usage\ $memory_usage\
$aws\ $aws\
$gcloud\ $gcloud\
@ -263,9 +268,9 @@ format = "$all$directory$character"
## AWS ## AWS
The `aws` module shows the current AWS region and profile when credentials, a `credential_process` or a `sso_start_url` have been setup. 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. The `aws` module shows the current AWS region and profile when credentials, a `credential_process` or a `sso_start_url` have been setup. Alternatively, you can force this module to show the region and profile even when the credentials have not been setup with the `force_display` option. 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.
The module will display a profile only if its credentials are present in `~/.aws/credentials` or a `credential_process` is defined in `~/.aws/config`. Alternatively, having any of the `AWS_ACCESS_KEY_ID`, `AWS_SECRET_ACCESS_KEY`, or `AWS_SESSION_TOKEN` env vars defined will also suffice. The module will display a profile only if its credentials are present in `~/.aws/credentials` or a `credential_process` is defined in `~/.aws/config`. Alternatively, having any of the `AWS_ACCESS_KEY_ID`, `AWS_SECRET_ACCESS_KEY`, or `AWS_SESSION_TOKEN` env vars defined will also suffice. If the option `force_display` is set to `true`, all available information will be displayed even if the conditions above are not respected.
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. 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.
@ -275,15 +280,16 @@ When using [AWSume](https://awsu.me) the profile is read from the `AWSUME_PROFIL
### Options ### Options
| Option | Default | Description | | Option | Default | Description |
| ------------------- | -------------------------------------------------------------------- | ----------------------------------------------------------------- | | ------------------- | -------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------- |
| `format` | `'on [$symbol($profile )(\($region\) )(\[$duration\])]($style)'` | The format for the module. | | `format` | `'on [$symbol($profile )(\($region\) )(\[$duration\])]($style)'` | The format for the module. |
| `symbol` | `"☁️ "` | The symbol used before displaying the current AWS profile. | | `symbol` | `"☁️ "` | The symbol used before displaying the current AWS profile. |
| `region_aliases` | | Table of region aliases to display in addition to the AWS name. | | `region_aliases` | | Table of region aliases to display in addition to the AWS name. |
| `profile_aliases` | | Table of profile aliases to display in addition to the AWS name. | | `profile_aliases` | | Table of profile aliases to display in addition to the AWS name. |
| `style` | `"bold yellow"` | The style for the module. | | `style` | `"bold yellow"` | The style for the module. |
| `expiration_symbol` | `X` | The symbol displayed when the temporary credentials have expired. | | `expiration_symbol` | `X` | The symbol displayed when the temporary credentials have expired. |
| `disabled` | `false` | Disables the `AWS` module. | | `disabled` | `false` | Disables the `AWS` module. |
| `force_display` | `false` | If `true` displays info even if `credentials`, `credential_process` or `sso_start_url` have not been setup. |
### Variables ### Variables
@ -472,6 +478,52 @@ The `buf` module shows the currently installed version of [Buf](https://buf.buil
symbol = "🦬 " symbol = "🦬 "
``` ```
## C
The `c` module shows some information about your C compiler. By default the module will be shown if the current directory contains a `.c` or `.h` file.
### Options
| Option | Default | Description |
| ------------------- | --------------------------------------------------------------------------- | ------------------------------------------------------------------------- |
| `format` | `"via [$symbol($version(-$name) )]($style)"` | The format string for the module. |
| `version_format` | `"v${raw}"` | The version format. Available vars are `raw`, `major`, `minor`, & `patch` |
| `symbol` | `"C "` | The symbol used before displaying the compiler details |
| `detect_extensions` | `["c", "h"]` | Which extensions should trigger this module. |
| `detect_files` | `[]` | Which filenames should trigger this module. |
| `detect_folders` | `[]` | Which folders should trigger this module. |
| `commands` | [ [ "cc", "--version" ], [ "gcc", "--version" ], [ "clang", "--version" ] ] | How to detect what the compiler is |
| `style` | `"bold 149"` | The style for the module. |
| `disabled` | `false` | Disables the `c` module. |
### Variables
| Variable | Example | Description |
| -------- | ------- | ------------------------------------ |
| name | clang | The name of the compiler |
| version | 13.0.0 | The version of the compiler |
| symbol | | Mirrors the value of option `symbol` |
| style | | Mirrors the value of option `style` |
NB that `version` is not in the default format.
### Commands
The `commands` option accepts a list of commands to determine the compiler version and name.
Each command is represented as a list of the executable name, followed by its arguments, usually something like `["mycc", "--version"]`. Starship will try executing each command until it gets a result on STDOUT.
If a C compiler is not supported by this module, you can request it by [raising an issue on GitHub](https://github.com/starship/starship/).
### Example
```toml
# ~/.config/starship.toml
[c]
format = "via [$name $version]($style)"
```
## Character ## Character
The `character` module shows a character (usually an arrow) beside where the text is entered in your terminal. The `character` module shows a character (usually an arrow) beside where the text is entered in your terminal.
@ -962,7 +1014,7 @@ You'll also need the .NET Core SDK installed in order to use it correctly.
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. 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 (<https://docs.microsoft.com/en-us/dotnet/standard/frameworks#supported-target-framework-versions>) when there is a csproj file in the current directory. The module will also show the Target Framework Moniker (<https://docs.microsoft.com/en-us/dotnet/standard/frameworks#supported-target-frameworks>) when there is a `.csproj` file in the current directory.
### Options ### Options
@ -2969,6 +3021,39 @@ The `singularity` module shows the current [Singularity](https://sylabs.io/singu
format = '[📦 \[$env\]]($style) ' format = '[📦 \[$env\]]($style) '
``` ```
## Spack
The `spack` module shows the current [Spack](https://spack.readthedocs.io/en/latest/) environment, if `$SPACK_ENV` is set.
### Options
| Option | Default | Description |
| ------------------- | -------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------- |
| `truncation_length` | `1` | The number of directories the environment path should be truncated to. `0` means no truncation. Also see the [`directory`](#directory) module. |
| `symbol` | `"🅢 "` | The symbol used before the environment name. |
| `style` | `"bold blue"` | The style for the module. |
| `format` | `"via [$symbol$environment]($style) "` | The format for the module. |
| `disabled` | `false` | Disables the `spack` module. |
### Variables
| Variable | Example | Description |
| ----------- | ------------ | ------------------------------------ |
| environment | `astronauts` | The current spack environment |
| 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
### Example
```toml
# ~/.config/starship.toml
[spack]
format = "[$symbol$environment](dimmed blue) "
```
## Status ## Status
The `status` module displays the exit code of the previous command. If $success_symbol is empty (default), the module will be shown only if the exit code is not `0`. The status code will cast to a signed 32-bit integer. The `status` module displays the exit code of the previous command. If $success_symbol is empty (default), the module will be shown only if the exit code is not `0`. The status code will cast to a signed 32-bit integer.
@ -3226,7 +3311,7 @@ time_range = "10:00:00-14:00:00"
The `username` module shows active user's username. The module will be shown if any of the following conditions are met: 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 is root/admin
- The current user isn't the same as the one that is logged in - The current user isn't the same as the one that is logged in
- The user is currently connected as an SSH session - The user is currently connected as an SSH session
- The variable `show_always` is set to true - The variable `show_always` is set to true
@ -3239,13 +3324,13 @@ SSH connection is detected by checking environment variables `SSH_CONNECTION`, `
### Options ### Options
| Option | Default | Description | | Option | Default | Description |
| ------------- | ----------------------- | ------------------------------------- | | ------------- | ----------------------- | ------------------------------------------- |
| `style_root` | `"bold red"` | The style used when the user is root. | | `style_root` | `"bold red"` | The style used when the user is root/admin. |
| `style_user` | `"bold yellow"` | The style used for non-root users. | | `style_user` | `"bold yellow"` | The style used for non-root users. |
| `format` | `"[$user]($style) in "` | The format for the module. | | `format` | `"[$user]($style) in "` | The format for the module. |
| `show_always` | `false` | Always shows the `username` module. | | `show_always` | `false` | Always shows the `username` module. |
| `disabled` | `false` | Disables the `username` module. | | `disabled` | `false` | Disables the `username` module. |
### Variables ### Variables
@ -3417,9 +3502,9 @@ The `custom` modules show the output of some arbitrary commands.
These modules will be shown if any of the following conditions are met: These modules will be shown if any of the following conditions are met:
- The current directory contains a file whose name is in `files` - The current directory contains a file whose name is in `detect_files`
- The current directory contains a directory whose name is in `directories` - The current directory contains a directory whose name is in `detect_folders`
- The current directory contains a file whose extension is in `extensions` - The current directory contains a file whose extension is in `detect_extensions`
- The `when` command returns 0 - The `when` command returns 0
- The current Operating System (std::env::consts::OS) matchs with `os` field if defined. - The current Operating System (std::env::consts::OS) matchs with `os` field if defined.
@ -3451,20 +3536,22 @@ Format strings can also contain shell specific prompt sequences, e.g. [Bash](htt
### Options ### Options
| Option | Default | Description | | Option | Default | Description |
| ------------- | ------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | | ------------------- | ------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `command` | `""` | The command whose output should be printed. The command will be passed on stdin to the shell. | | `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. | | `when` | `false` | Either a boolean value (`true` or `false`, without quotes) or a string shell command used as a condition to show the module. In case of a string, the module will be shown if the command returns a `0` status code. |
| `shell` | | [See below](#custom-command-shell) | | `shell` | | [See below](#custom-command-shell) |
| `description` | `"<custom module>"` | The description of the module that is shown when running `starship explain`. | | `description` | `"<custom module>"` | The description of the module that is shown when running `starship explain`. |
| `files` | `[]` | The files that will be searched in the working directory for a match. | | `detect_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. | | `detect_folders` | `[]` | 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. | | `detect_extensions` | `[]` | The extensions that will be searched in the working directory for a match. |
| `symbol` | `""` | The symbol used before displaying the command output. | | `symbol` | `""` | The symbol used before displaying the command output. |
| `style` | `"bold green"` | The style for the module. | | `style` | `"bold green"` | The style for the module. |
| `format` | `"[$symbol($output )]($style)"` | The format for the module. | | `format` | `"[$symbol($output )]($style)"` | The format for the module. |
| `disabled` | `false` | Disables this `custom` 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). | | `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). |
| `use_stdin` | | An optional boolean value that overrides whether commands should be forwarded to the shell via the standard input or as an argument. If unset standard input is used by default, unless the shell does not support it (cmd, nushell). Setting this disables shell-specific argument handling. |
| `ignore_timeout` | `false` | Ignore global `command_timeout` setting and keep running external commands, no matter how long they take. |
### Variables ### Variables
@ -3487,7 +3574,7 @@ If unset, it will fallback to STARSHIP_SHELL and then to "sh" on Linux, and "cmd
The `command` will be passed in on stdin. The `command` will be passed in on stdin.
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. 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 -`. If `shell` is not given or only contains one element and Starship detects Cmd will be used, the following argument will automatically be added: `/C` and `stdin` will be set to `false`. If `shell` is not given or only contains one element and Starship detects Nushell will be used, the following arguments will automatically be added: `-c` and `stdin` will be set to `false`. This behavior can be avoided by explicitly passing arguments to the shell, e.g.
```toml ```toml
shell = ["pwsh", "-Command", "-"] shell = ["pwsh", "-Command", "-"]
@ -3512,12 +3599,18 @@ Automatic detection of shells and proper parameters addition are currently imple
[custom.foo] [custom.foo]
command = "echo foo" # shows output of command command = "echo foo" # shows output of command
files = ["foo"] # can specify filters but wildcards are not supported detect_files = ["foo"] # can specify filters but wildcards are not supported
when = """ test "$HOME" == "$PWD" """ when = """ test "$HOME" == "$PWD" """
format = " transcending [$output]($style)" format = " transcending [$output]($style)"
[custom.time] [custom.time]
command = "time /T" command = "time /T"
extensions = ["pst"] # filters *.pst files detect_extensions = ["pst"] # filters *.pst files
shell = ["pwsh.exe", "-NoProfile", "-Command", "-"] shell = ["pwsh.exe", "-NoProfile", "-Command", "-"]
[custom.time-as-arg]
command = "time /T"
detect_extensions = ["pst"] # filters *.pst files
shell = ["pwsh.exe", "-NoProfile", "-Command"]
use_stdin = false
``` ```

View File

@ -297,7 +297,7 @@ Add the following to the end of `~/.elvish/rc.elv`:
eval (starship init elvish) eval (starship init elvish)
``` ```
Note: Only Elvish v0.17+ is supported Note: Only Elvish v0.18+ is supported
</details> </details>

View File

@ -120,7 +120,7 @@ description: Starship - минимальная, быстрая и бесконе
#### Elvish #### Elvish
::: warning Поддерживается только elvish v0.17 или выше. ::: ::: warning Поддерживается только elvish v0.18 или выше. :::
Добавьте следующую строку в конец `~/.elvish/rc.elv`: Добавьте следующую строку в конец `~/.elvish/rc.elv`:

View File

@ -131,7 +131,7 @@ Invoke-Expression (&starship init powershell)
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`. 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). 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, xonsh, cmd. `right_format` is currently supported for the following shells: elvish, fish, zsh, xonsh, cmd.

File diff suppressed because it is too large Load Diff

View File

@ -145,7 +145,7 @@
<img <img
src="https://raw.githubusercontent.com/starship/starship/master/media/demo.gif" src="https://raw.githubusercontent.com/starship/starship/master/media/demo.gif"
alt="Starship with iTerm2 and the Snazzy theme" alt="Starship в iTerm2 с темой Snazzy"
width="50%" width="50%"
align="right" align="right"
/> />
@ -160,7 +160,7 @@
- **Легкая:** быстрая установка - начните использовать ее в считанные минуты. - **Легкая:** быстрая установка - начните использовать ее в считанные минуты.
<p align="center"> <p align="center">
<a href="https://starship.rs/config/"><strong>Explore the Starship docs&nbsp;&nbsp;</strong></a> <a href="https://starship.rs/config/"><strong>Изучите документацию Starship&nbsp;&nbsp;</strong></a>
</p> </p>
<a name="🚀-installation"></a> <a name="🚀-installation"></a>
@ -297,7 +297,7 @@ load(io.popen('starship init cmd'):read("*a"))()
eval (starship init elvish) eval (starship init elvish)
``` ```
Note: Only Elvish v0.17+ is supported Note: Only Elvish v0.18+ is supported
</details> </details>
@ -400,15 +400,15 @@ If you're looking to further customize Starship:
## 🤝 Помощь ## 🤝 Помощь
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). Мы всегда ищем помощников **всех уровней навыков**! Если вы хотите облегчить свой путь к проекту, попробуйте [хорошие первые задачи](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/). Если Вы свободно владеете иностранным языком отличным от английского, мы высоко оценим любую помощь в переводе нашей документации на другие языки и поддержании ее в актуальном состоянии. Если вы хотите помочь, переводы могут быть сделаны на платформе [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. 👋 Если вы хотите помочь в создании Starship, пожалуйста, ознакомьтесь с нашим [Руководством по содействию](https://github.com/starship/starship/blob/master/CONTRIBUTING.md). Кроме того, заходите на наш [Discord сервер](https://discord.gg/8Jzqu3T) и поздоровайтесь. 👋
## 💭 Вдохновение ## 💭 Вдохновение
Please check out these previous works that helped inspire the creation of starship. 🙏 Пожалуйста, ознакомьтесь с этими предыдущими работами, которые помогли вдохновить создание Starship. 🙏
- **[denysdovhan/spaceship-prompt](https://github.com/denysdovhan/spaceship-prompt)** A ZSH prompt for astronauts. - **[denysdovhan/spaceship-prompt](https://github.com/denysdovhan/spaceship-prompt)** A ZSH prompt for astronauts.
@ -418,9 +418,9 @@ Please check out these previous works that helped inspire the creation of starsh
<p align="center"> <p align="center">
<br> <br>
<img width="100" src="https://raw.githubusercontent.com/starship/starship/master/media/icon.png" alt="Starship rocket icon"> <img width="100" src="https://raw.githubusercontent.com/starship/starship/master/media/icon.png" alt="Иконка ракеты Starship">
</p> </p>
## 📝 Лицензия ## 📝 Лицензия
Copyright © 2019-present, [Starship Contributors](https://github.com/starship/starship/graphs/contributors).<br /> This project is [ISC](https://github.com/starship/starship/blob/master/LICENSE) licensed. Авторское право © 2019-настоящее, [Starship Contributors](https://github.com/starship/starship/graphs/contributors).<br /> Этот проект [ISC](https://github.com/starship/starship/blob/master/LICENSE) лицензирован.

View File

@ -120,7 +120,7 @@ description: Starship is the minimal, blazing fast, and extremely customizable p
#### Elvish #### Elvish
::: warning Only elvish v0.17 or higher is supported. ::: ::: warning Only elvish v0.18 or higher is supported. :::
Add the following to the end of `~/.elvish/rc.elv`: Add the following to the end of `~/.elvish/rc.elv`:

View File

@ -130,7 +130,7 @@ Invoke-Expression (&starship init powershell)
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`. 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). 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, xonsh, cmd. `right_format` is currently supported for the following shells: elvish, fish, zsh, xonsh, cmd.

View File

@ -9,6 +9,9 @@ mkdir -p ~/.config && touch ~/.config/starship.toml
All configuration for starship is done in this [TOML](https://github.com/toml-lang/toml) file: All configuration for starship is done in this [TOML](https://github.com/toml-lang/toml) file:
```toml ```toml
# Get editor completions based on the config schema
"$schema" = 'https://starship.rs/config-schema.json'
# Inserts a blank line between shell prompts # Inserts a blank line between shell prompts
add_newline = true add_newline = true
@ -199,6 +202,7 @@ $hg_branch\
$docker_context\ $docker_context\
$package\ $package\
$buf\ $buf\
$c\
$cmake\ $cmake\
$cobol\ $cobol\
$container\ $container\
@ -235,6 +239,7 @@ $vagrant\
$zig\ $zig\
$nix_shell\ $nix_shell\
$conda\ $conda\
$spack\
$memory_usage\ $memory_usage\
$aws\ $aws\
$gcloud\ $gcloud\
@ -263,9 +268,9 @@ format = "$all$directory$character"
## AWS ## AWS
The `aws` module shows the current AWS region and profile when credentials, a `credential_process` or a `sso_start_url` have been setup. 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. The `aws` module shows the current AWS region and profile when credentials, a `credential_process` or a `sso_start_url` have been setup. Alternatively, you can force this module to show the region and profile even when the credentials have not been setup with the `force_display` option. 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.
The module will display a profile only if its credentials are present in `~/.aws/credentials` or a `credential_process` is defined in `~/.aws/config`. Alternatively, having any of the `AWS_ACCESS_KEY_ID`, `AWS_SECRET_ACCESS_KEY`, or `AWS_SESSION_TOKEN` env vars defined will also suffice. The module will display a profile only if its credentials are present in `~/.aws/credentials` or a `credential_process` is defined in `~/.aws/config`. Alternatively, having any of the `AWS_ACCESS_KEY_ID`, `AWS_SECRET_ACCESS_KEY`, or `AWS_SESSION_TOKEN` env vars defined will also suffice. If the option `force_display` is set to `true`, all available information will be displayed even if the conditions above are not respected.
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. 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.
@ -275,15 +280,16 @@ When using [AWSume](https://awsu.me) the profile is read from the `AWSUME_PROFIL
### Options ### Options
| Option | Default | Description | | Option | Default | Description |
| ------------------- | -------------------------------------------------------------------- | ----------------------------------------------------------------- | | ------------------- | -------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------- |
| `format` | `'on [$symbol($profile )(\($region\) )(\[$duration\])]($style)'` | The format for the module. | | `format` | `'on [$symbol($profile )(\($region\) )(\[$duration\])]($style)'` | The format for the module. |
| `symbol` | `"☁️ "` | The symbol used before displaying the current AWS profile. | | `symbol` | `"☁️ "` | The symbol used before displaying the current AWS profile. |
| `region_aliases` | | Table of region aliases to display in addition to the AWS name. | | `region_aliases` | | Table of region aliases to display in addition to the AWS name. |
| `profile_aliases` | | Table of profile aliases to display in addition to the AWS name. | | `profile_aliases` | | Table of profile aliases to display in addition to the AWS name. |
| `style` | `"bold yellow"` | The style for the module. | | `style` | `"bold yellow"` | The style for the module. |
| `expiration_symbol` | `X` | The symbol displayed when the temporary credentials have expired. | | `expiration_symbol` | `X` | The symbol displayed when the temporary credentials have expired. |
| `disabled` | `false` | Disables the `AWS` module. | | `disabled` | `false` | Disables the `AWS` module. |
| `force_display` | `false` | If `true` displays info even if `credentials`, `credential_process` or `sso_start_url` have not been setup. |
### Variables ### Variables
@ -472,6 +478,52 @@ The `buf` module shows the currently installed version of [Buf](https://buf.buil
symbol = "🦬 " symbol = "🦬 "
``` ```
## C
The `c` module shows some information about your C compiler. By default the module will be shown if the current directory contains a `.c` or `.h` file.
### Options
| Option | Default | Description |
| ------------------- | --------------------------------------------------------------------------- | ------------------------------------------------------------------------- |
| `format` | `"via [$symbol($version(-$name) )]($style)"` | The format string for the module. |
| `version_format` | `"v${raw}"` | The version format. Available vars are `raw`, `major`, `minor`, & `patch` |
| `symbol` | `"C "` | The symbol used before displaying the compiler details |
| `detect_extensions` | `["c", "h"]` | Which extensions should trigger this module. |
| `detect_files` | `[]` | Which filenames should trigger this module. |
| `detect_folders` | `[]` | Which folders should trigger this module. |
| `commands` | [ [ "cc", "--version" ], [ "gcc", "--version" ], [ "clang", "--version" ] ] | How to detect what the compiler is |
| `style` | `"bold 149"` | The style for the module. |
| `disabled` | `false` | Disables the `c` module. |
### Variables
| Variable | Example | Description |
| -------- | ------- | ------------------------------------ |
| name | clang | The name of the compiler |
| version | 13.0.0 | The version of the compiler |
| symbol | | Mirrors the value of option `symbol` |
| style | | Mirrors the value of option `style` |
NB that `version` is not in the default format.
### Commands
The `commands` option accepts a list of commands to determine the compiler version and name.
Each command is represented as a list of the executable name, followed by its arguments, usually something like `["mycc", "--version"]`. Starship will try executing each command until it gets a result on STDOUT.
If a C compiler is not supported by this module, you can request it by [raising an issue on GitHub](https://github.com/starship/starship/).
### Example
```toml
# ~/.config/starship.toml
[c]
format = "via [$name $version]($style)"
```
## Character ## Character
The `character` module shows a character (usually an arrow) beside where the text is entered in your terminal. The `character` module shows a character (usually an arrow) beside where the text is entered in your terminal.
@ -962,7 +1014,7 @@ You'll also need the .NET Core SDK installed in order to use it correctly.
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. 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 (<https://docs.microsoft.com/en-us/dotnet/standard/frameworks#supported-target-framework-versions>) when there is a csproj file in the current directory. The module will also show the Target Framework Moniker (<https://docs.microsoft.com/en-us/dotnet/standard/frameworks#supported-target-frameworks>) when there is a `.csproj` file in the current directory.
### Options ### Options
@ -2969,6 +3021,39 @@ The `singularity` module shows the current [Singularity](https://sylabs.io/singu
format = '[📦 \[$env\]]($style) ' format = '[📦 \[$env\]]($style) '
``` ```
## Spack
The `spack` module shows the current [Spack](https://spack.readthedocs.io/en/latest/) environment, if `$SPACK_ENV` is set.
### Options
| Option | Default | Description |
| ------------------- | -------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------- |
| `truncation_length` | `1` | The number of directories the environment path should be truncated to. `0` means no truncation. Also see the [`directory`](#directory) module. |
| `symbol` | `"🅢 "` | The symbol used before the environment name. |
| `style` | `"bold blue"` | The style for the module. |
| `format` | `"via [$symbol$environment]($style) "` | The format for the module. |
| `disabled` | `false` | Disables the `spack` module. |
### Variables
| Variable | Example | Description |
| ----------- | ------------ | ------------------------------------ |
| environment | `astronauts` | The current spack environment |
| 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
### Example
```toml
# ~/.config/starship.toml
[spack]
format = "[$symbol$environment](dimmed blue) "
```
## Status ## Status
The `status` module displays the exit code of the previous command. If $success_symbol is empty (default), the module will be shown only if the exit code is not `0`. The status code will cast to a signed 32-bit integer. The `status` module displays the exit code of the previous command. If $success_symbol is empty (default), the module will be shown only if the exit code is not `0`. The status code will cast to a signed 32-bit integer.
@ -3226,7 +3311,7 @@ time_range = "10:00:00-14:00:00"
The `username` module shows active user's username. The module will be shown if any of the following conditions are met: 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 is root/admin
- The current user isn't the same as the one that is logged in - The current user isn't the same as the one that is logged in
- The user is currently connected as an SSH session - The user is currently connected as an SSH session
- The variable `show_always` is set to true - The variable `show_always` is set to true
@ -3239,13 +3324,13 @@ SSH connection is detected by checking environment variables `SSH_CONNECTION`, `
### Options ### Options
| Option | Default | Description | | Option | Default | Description |
| ------------- | ----------------------- | ------------------------------------- | | ------------- | ----------------------- | ------------------------------------------- |
| `style_root` | `"bold red"` | The style used when the user is root. | | `style_root` | `"bold red"` | The style used when the user is root/admin. |
| `style_user` | `"bold yellow"` | The style used for non-root users. | | `style_user` | `"bold yellow"` | The style used for non-root users. |
| `format` | `"[$user]($style) in "` | The format for the module. | | `format` | `"[$user]($style) in "` | The format for the module. |
| `show_always` | `false` | Always shows the `username` module. | | `show_always` | `false` | Always shows the `username` module. |
| `disabled` | `false` | Disables the `username` module. | | `disabled` | `false` | Disables the `username` module. |
### Variables ### Variables
@ -3417,9 +3502,9 @@ The `custom` modules show the output of some arbitrary commands.
These modules will be shown if any of the following conditions are met: These modules will be shown if any of the following conditions are met:
- The current directory contains a file whose name is in `files` - The current directory contains a file whose name is in `detect_files`
- The current directory contains a directory whose name is in `directories` - The current directory contains a directory whose name is in `detect_folders`
- The current directory contains a file whose extension is in `extensions` - The current directory contains a file whose extension is in `detect_extensions`
- The `when` command returns 0 - The `when` command returns 0
- The current Operating System (std::env::consts::OS) matchs with `os` field if defined. - The current Operating System (std::env::consts::OS) matchs with `os` field if defined.
@ -3451,20 +3536,22 @@ Format strings can also contain shell specific prompt sequences, e.g. [Bash](htt
### Options ### Options
| Option | Default | Description | | Option | Default | Description |
| ------------- | ------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | | ------------------- | ------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `command` | `""` | The command whose output should be printed. The command will be passed on stdin to the shell. | | `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. | | `when` | `false` | Either a boolean value (`true` or `false`, without quotes) or a string shell command used as a condition to show the module. In case of a string, the module will be shown if the command returns a `0` status code. |
| `shell` | | [See below](#custom-command-shell) | | `shell` | | [See below](#custom-command-shell) |
| `description` | `"<custom module>"` | The description of the module that is shown when running `starship explain`. | | `description` | `"<custom module>"` | The description of the module that is shown when running `starship explain`. |
| `files` | `[]` | The files that will be searched in the working directory for a match. | | `detect_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. | | `detect_folders` | `[]` | 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. | | `detect_extensions` | `[]` | The extensions that will be searched in the working directory for a match. |
| `symbol` | `""` | The symbol used before displaying the command output. | | `symbol` | `""` | The symbol used before displaying the command output. |
| `style` | `"bold green"` | The style for the module. | | `style` | `"bold green"` | The style for the module. |
| `format` | `"[$symbol($output )]($style)"` | The format for the module. | | `format` | `"[$symbol($output )]($style)"` | The format for the module. |
| `disabled` | `false` | Disables this `custom` 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). | | `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). |
| `use_stdin` | | An optional boolean value that overrides whether commands should be forwarded to the shell via the standard input or as an argument. If unset standard input is used by default, unless the shell does not support it (cmd, nushell). Setting this disables shell-specific argument handling. |
| `ignore_timeout` | `false` | Ignore global `command_timeout` setting and keep running external commands, no matter how long they take. |
### Variables ### Variables
@ -3487,7 +3574,7 @@ If unset, it will fallback to STARSHIP_SHELL and then to "sh" on Linux, and "cmd
The `command` will be passed in on stdin. The `command` will be passed in on stdin.
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. 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 -`. If `shell` is not given or only contains one element and Starship detects Cmd will be used, the following argument will automatically be added: `/C` and `stdin` will be set to `false`. If `shell` is not given or only contains one element and Starship detects Nushell will be used, the following arguments will automatically be added: `-c` and `stdin` will be set to `false`. This behavior can be avoided by explicitly passing arguments to the shell, e.g.
```toml ```toml
shell = ["pwsh", "-Command", "-"] shell = ["pwsh", "-Command", "-"]
@ -3512,12 +3599,18 @@ Automatic detection of shells and proper parameters addition are currently imple
[custom.foo] [custom.foo]
command = "echo foo" # shows output of command command = "echo foo" # shows output of command
files = ["foo"] # can specify filters but wildcards are not supported detect_files = ["foo"] # can specify filters but wildcards are not supported
when = """ test "$HOME" == "$PWD" """ when = """ test "$HOME" == "$PWD" """
format = " transcending [$output]($style)" format = " transcending [$output]($style)"
[custom.time] [custom.time]
command = "time /T" command = "time /T"
extensions = ["pst"] # filters *.pst files detect_extensions = ["pst"] # filters *.pst files
shell = ["pwsh.exe", "-NoProfile", "-Command", "-"] shell = ["pwsh.exe", "-NoProfile", "-Command", "-"]
[custom.time-as-arg]
command = "time /T"
detect_extensions = ["pst"] # filters *.pst files
shell = ["pwsh.exe", "-NoProfile", "-Command"]
use_stdin = false
``` ```

View File

@ -297,7 +297,7 @@ Add the following to the end of `~/.elvish/rc.elv`:
eval (starship init elvish) eval (starship init elvish)
``` ```
Note: Only Elvish v0.17+ is supported Note: Only Elvish v0.18+ is supported
</details> </details>

View File

@ -1,4 +1,4 @@
# Advanced Installation # Gelişmiş Kurulum
Starship'i kurmak için, 2 şeye ihtiyacınız var: Starship'i kurmak için, 2 şeye ihtiyacınız var:

View File

@ -120,7 +120,7 @@ description: Starship là prompt nhỏ, cực nhanh, và khả năng tuỳ biế
#### Elvish #### Elvish
::: warning Chỉ elvish v0.17 hoặc cao hơn được hỗ trợ. ::: ::: warning Chỉ elvish v0.18 hoặc cao hơn được hỗ trợ. :::
Thêm đoạn sau vào cuối tệp tin `~/.elvish/rc.elv`: Thêm đoạn sau vào cuối tệp tin `~/.elvish/rc.elv`:

View File

@ -131,7 +131,7 @@ Invoke-Expression (&starship init powershell)
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`. 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). 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, xonsh, cmd. `right_format` is currently supported for the following shells: elvish, fish, zsh, xonsh, cmd.

File diff suppressed because it is too large Load Diff

View File

@ -145,7 +145,7 @@
<img <img
src="https://raw.githubusercontent.com/starship/starship/master/media/demo.gif" src="https://raw.githubusercontent.com/starship/starship/master/media/demo.gif"
alt="Starship with iTerm2 and the Snazzy theme" alt="Starship với iTerm2 and chủ đề Snazzy"
width="50%" width="50%"
align="right" align="right"
/> />
@ -160,7 +160,7 @@
- **Dễ dàng:** cài đặt nhanh chóng  bắt đầu sử dụng nó trong vài phút. - **Dễ dàng:** cài đặt nhanh chóng  bắt đầu sử dụng nó trong vài phút.
<p align="center"> <p align="center">
<a href="https://starship.rs/config/"><strong>Explore the Starship docs&nbsp;&nbsp;</strong></a> <a href="https://starship.rs/config/"><strong>Khám phá tài liệu của Starship&nbsp;&nbsp;</strong></a>
</p> </p>
<a name="🚀-installation"></a> <a name="🚀-installation"></a>
@ -297,7 +297,7 @@ Thêm đoạn sau vào cuối tệp tin `~/.elvish/rc.elv`:
eval (starship init elvish) eval (starship init elvish)
``` ```
Note: Only Elvish v0.17+ is supported Note: Only Elvish v0.18+ is supported
</details> </details>
@ -400,15 +400,15 @@ If you're looking to further customize Starship:
## 🤝 Đóng góp ## 🤝 Đóng góp
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). Chúng tôi luôn luôn tìm kiếm những cộng tác viên ở **tất cả các các mức độ về kĩ năng**! Nếu bạn đang tìm kiếm cách dễ dàng để tham gia vào dự án, thử một [good issue đầu tiên](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/). Nếu bạn thành thạo một ngôn ngữ không phải Tiếng Anh, chúng tôi đánh giá cao mọi sự giúp đỡ của bạn trong việc dịch tài liệu của chúng tôi và cập nhật các ngôn ngữ khác. Nếu bạn muốn giúp đỡ, những bản dịch có thể được đóng góp trên [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. 👋 Nếu bạn thích thú trong việc giúp đỡ đóng góp cho starship, xin hãy xem [Hướng dẫn đóng góp](https://github.com/starship/starship/blob/master/CONTRIBUTING.md) của chúng tôi. Ngoài ra, vui lòng truy cập vào [máy chủ Discord](https://discord.gg/8Jzqu3T) và nói xin chào. 👋
## Cảm hứng ## Cảm hứng
Please check out these previous works that helped inspire the creation of starship. 🙏 Xin hãy xem qua những công việc này trước đây, những thứ đã giúp truyền cảm hứng để tạo ra starship. 🙏
- **[denysdovhan/spaceship-prompt](https://github.com/denysdovhan/spaceship-prompt)** A ZSH prompt for astronauts. - **[denysdovhan/spaceship-prompt](https://github.com/denysdovhan/spaceship-prompt)** A ZSH prompt for astronauts.
@ -423,4 +423,4 @@ Please check out these previous works that helped inspire the creation of starsh
## 📝 Giấy phép ## 📝 Giấy phép
Copyright © 2019-present, [Starship Contributors](https://github.com/starship/starship/graphs/contributors).<br /> This project is [ISC](https://github.com/starship/starship/blob/master/LICENSE) licensed. Bản quyền © 2019-nay, [Starship Contributors](https://github.com/starship/starship/graphs/contributors).<br /> Dự án này được [ISC](https://github.com/starship/starship/blob/master/LICENSE) cấp phép.

View File

@ -1,4 +1,4 @@
# Advanced Installation # Cài đặt nâng cao
Để cài đặt starship, bạn cần làm 2 thứ: Để cài đặt starship, bạn cần làm 2 thứ:

View File

@ -120,7 +120,7 @@ description: Starship is the minimal, blazing fast, and extremely customizable p
#### Elvish #### Elvish
::: warning Only elvish v0.17 or higher is supported. ::: ::: warning 警告 只支持 elvish v0.18 及以上。 :::
`~/.config/fish/rc.elv` 的最后,添加以下内容: `~/.config/fish/rc.elv` 的最后,添加以下内容:
@ -144,7 +144,7 @@ description: Starship is the minimal, blazing fast, and extremely customizable p
#### Nushell #### Nushell
::: warning This will change in the future. Only Nushell v0.60+ is supported. ::: Run the following: ::: warning 警告 将来可能会改变。 Only Nushell v0.60+ is supported. ::: Run the following:
```sh ```sh
mkdir ~/.cache/starship mkdir ~/.cache/starship
starship init nu | save ~/.cache/starship/init.nu starship init nu | save ~/.cache/starship/init.nu
@ -171,7 +171,7 @@ description: Starship is the minimal, blazing fast, and extremely customizable p
#### Cmd #### Cmd
您需要使用 [Clink](https://chrisant996.github.io/clink/clink.html) (v1.2.30+) 与 Cmd. Add the following to a file `starship.lua` and place this file in Clink scripts directory: 您需要使用 [Clink](https://chrisant996.github.io/clink/clink.html) (v1.2.30+) 与 Cmd. 将以下文件添加到文件 `starship.lua` 中,并将此文件放置在 Clink脚本目录中
```lua ```lua
-- starship.lua -- starship.lua

View File

@ -131,7 +131,7 @@ Invoke-Expression (&starship init powershell)
一些 Shell 支持右侧提示, 它与输入区渲染在同一行。 Starship 可以设置右侧提示的内容,使用 `right_format` 选项。 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`. 一些 Shell 支持右侧提示, 它与输入区渲染在同一行。 Starship 可以设置右侧提示的内容,使用 `right_format` 选项。 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). 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, xonsh, cmd. `right_format` is currently supported for the following shells: elvish, fish, zsh, xonsh, cmd.

File diff suppressed because it is too large Load Diff

View File

@ -145,7 +145,7 @@
<img <img
src="https://raw.githubusercontent.com/starship/starship/master/media/demo.gif" src="https://raw.githubusercontent.com/starship/starship/master/media/demo.gif"
alt="Starship with iTerm2 and the Snazzy theme" alt="使用 iTerm 和 Snazz 主题的 Starship"
width="50%" width="50%"
align="right" align="right"
/> />
@ -160,7 +160,7 @@
- **易用:** 安装快速 —— 几分钟就可上手。 - **易用:** 安装快速 —— 几分钟就可上手。
<p align="center"> <p align="center">
<a href="https://starship.rs/config/"><strong>Explore the Starship docs&nbsp;&nbsp;</strong></a> <a href="https://starship.rs/config/"><strong>探索 Starship 文档</strong></a>
</p> </p>
<a name="🚀-installation"></a> <a name="🚀-installation"></a>
@ -173,12 +173,12 @@
### 步骤 1. 安装 Starship ### 步骤 1. 安装 Starship
Select your operating system from the list below to view installation instructions: 从下面的列表中选择您的操作系统以查看安装指令:
<details> <details>
<summary>Android</summary> <summary>Android</summary>
Install Starship using any of the following package managers: 使用下列软件包管理器安装Starship
| 软件包来源 | 指令 | | 软件包来源 | 指令 |
| --------------------------------------------------------------------------------- | ---------------------- | | --------------------------------------------------------------------------------- | ---------------------- |
@ -189,7 +189,7 @@ Install Starship using any of the following package managers:
<details> <details>
<summary>BSD</summary> <summary>BSD</summary>
Install Starship using any of the following package managers: 使用下列软件包管理器安装Starship
| 发行版 | 软件包来源 | 指令 | | 发行版 | 软件包来源 | 指令 |
| ----------- | -------------------------------------------------------- | --------------------------------- | | ----------- | -------------------------------------------------------- | --------------------------------- |
@ -202,13 +202,13 @@ Install Starship using any of the following package managers:
<details> <details>
<summary>Linux</summary> <summary>Linux</summary>
Install the latest version for your system: 安装最新版本:
```sh ```sh
curl -sS https://starship.rs/install.sh | sh curl -sS https://starship.rs/install.sh | sh
``` ```
Alternatively, install Starship using any of the following package managers: 或者使用以下任一软件包管理器安装Starship
| 发行版 | 软件包来源 | 指令 | | 发行版 | 软件包来源 | 指令 |
| ------------------ | ----------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------ | | ------------------ | ----------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------ |
@ -231,13 +231,13 @@ Alternatively, install Starship using any of the following package managers:
<details> <details>
<summary>macOS</summary> <summary>macOS</summary>
Install the latest version for your system: 安装最新版本:
```sh ```sh
curl -sS https://starship.rs/install.sh | sh curl -sS https://starship.rs/install.sh | sh
``` ```
Alternatively, install Starship using any of the following package managers: 或者使用以下任一软件包管理器安装Starship
| 软件包来源 | 指令 | | 软件包来源 | 指令 |
| -------------------------------------------------------- | --------------------------------------- | | -------------------------------------------------------- | --------------------------------------- |
@ -251,7 +251,7 @@ Alternatively, install Starship using any of the following package managers:
<details> <details>
<summary>Windows</summary> <summary>Windows</summary>
Install Starship using any of the following package managers: 使用下列软件包管理器安装Starship
| 软件包来源 | 指令 | | 软件包来源 | 指令 |
| -------------------------------------------------------------------------------- | --------------------------------------- | | -------------------------------------------------------------------------------- | --------------------------------------- |
@ -264,7 +264,7 @@ Install Starship using any of the following package managers:
### 步骤 2. 设置你的终端以使用 Starship ### 步骤 2. 设置你的终端以使用 Starship
Configure your shell to initialize starship. Select yours from the list below: 配置你的终端来初始化 starship。 请从下面列表选择你的终端:
<details> <details>
<summary>Bash</summary> <summary>Bash</summary>
@ -280,7 +280,7 @@ eval "$(starship init bash)"
<details> <details>
<summary>Cmd</summary> <summary>Cmd</summary>
您需要使用 [Clink](https://chrisant996.github.io/clink/clink.html) (v1.2.30+) 与 Cmd. Create a file at this path `%LocalAppData%\clink\starship.lua` with the following contents: 您需要使用 [Clink](https://chrisant996.github.io/clink/clink.html) (v1.2.30+) 与 Cmd. 在路径 `%LocalAppData%\clink\starship.lua` 下创建文件,输入以下内容
```lua ```lua
load(io.popen('starship init cmd'):read("*a"))() load(io.popen('starship init cmd'):read("*a"))()
@ -297,7 +297,7 @@ load(io.popen('starship init cmd'):read("*a"))()
eval (starship init elvish) eval (starship init elvish)
``` ```
Note: Only Elvish v0.17+ is supported 注意:仅支持 v0.18 及以上版本的 Elvish
</details> </details>
@ -347,7 +347,7 @@ Note: Only Nushell v0.60+ is supported
<details> <details>
<summary>PowerShell</summary> <summary>PowerShell</summary>
Add the following to the end of your PowerShell configuration (find it by running `$PROFILE`): 将以下内容添加到您 PowerShell 配置文件的末尾(通过运行 `$PROFILE` 来获取配置文件的路径)
```powershell ```powershell
Invoke-Expression (&starship init powershell) Invoke-Expression (&starship init powershell)
@ -390,9 +390,9 @@ eval "$(starship init zsh)"
### 步骤 3. 配置 Starship ### 步骤 3. 配置 Starship
Start a new shell instance, and you should see your beautiful new shell prompt. If you're happy with the defaults, enjoy! 打开一个新的 Shell 实例,你应该就能看到漂亮的 Shell 新提示符了。 如果你对默认配置感到满意,就可以开始享用了!
If you're looking to further customize Starship: 如果你想进一步配置 Starship查阅下列内容
- **[配置](https://starship.rs/config/)**:学习如何配置 Starship 来调节提示符到你喜欢的样子。 - **[配置](https://starship.rs/config/)**:学习如何配置 Starship 来调节提示符到你喜欢的样子。
@ -400,15 +400,15 @@ If you're looking to further customize Starship:
## 🤝 贡献 ## 🤝 贡献
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). 我们一直在寻找贡献者!**不论你的技能如何**你都可以参与贡献 。 如果您希望快速为项目作出贡献,请尝试解决 [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/). 如果你能流利地使用非英语语种,我们非常感谢你帮助翻译我们的文件并将其更新到其他语言。 如果您想要帮助,可以在 [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. 👋 如果您有兴趣贡献于 Starship请查看我们的[贡献指南](https://github.com/starship/starship/blob/master/CONTRIBUTING.md)。 另外,你可以自由加入我们的 [Discord 服务器](https://discord.gg/8Jzqu3T) 。 👋
## 💭该项目受以下项目启发 ## 💭该项目受以下项目启发
Please check out these previous works that helped inspire the creation of starship. 🙏 请参考这些曾经为 Starship 提供启发的工程。 🙏
- **[denysdovhan/spaceship-prompt](https://github.com/denysdovhan/spaceship-prompt)** A ZSH prompt for astronauts. - **[denysdovhan/spaceship-prompt](https://github.com/denysdovhan/spaceship-prompt)** A ZSH prompt for astronauts.
@ -418,7 +418,7 @@ Please check out these previous works that helped inspire the creation of starsh
<p align="center"> <p align="center">
<br> <br>
<img width="100" src="https://raw.githubusercontent.com/starship/starship/master/media/icon.png" alt="Starship rocket icon"> <img width="100" src="https://raw.githubusercontent.com/starship/starship/master/media/icon.png" alt="Starship 图标">
</p> </p>
## 📝 License ## 📝 License

View File

@ -1,4 +1,4 @@
# Advanced Installation # 高级安装
安装Starship有以下两个步骤 安装Starship有以下两个步骤

View File

@ -120,7 +120,7 @@ description: Starship 是適合任何 shell 的最小、極速、高度客製化
#### Elvish #### Elvish
::: warning 只有 elvish v0.17 或以上版本才有支援 ::: ::: warning 只有 elvish v0.18 或以上版本才有支援 :::
將以下內容放到 `~/.elvish/rc.elv` 的結尾: 將以下內容放到 `~/.elvish/rc.elv` 的結尾:

View File

@ -131,7 +131,7 @@ Invoke-Expression (&starship init powershell)
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`. 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). 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, xonsh, cmd. `right_format` is currently supported for the following shells: elvish, fish, zsh, xonsh, cmd.

View File

@ -9,6 +9,9 @@ mkdir -p ~/.config && touch ~/.config/starship.toml
所有關於 Starship 的設定都在這個 [TOML](https://github.com/toml-lang/toml) 檔案內: 所有關於 Starship 的設定都在這個 [TOML](https://github.com/toml-lang/toml) 檔案內:
```toml ```toml
# Get editor completions based on the config schema
"$schema" = 'https://starship.rs/config-schema.json'
# Inserts a blank line between shell prompts # Inserts a blank line between shell prompts
add_newline = true add_newline = true
@ -199,6 +202,7 @@ $hg_branch\
$docker_context\ $docker_context\
$package\ $package\
$buf\ $buf\
$c\
$cmake\ $cmake\
$cobol\ $cobol\
$container\ $container\
@ -235,6 +239,7 @@ $vagrant\
$zig\ $zig\
$nix_shell\ $nix_shell\
$conda\ $conda\
$spack\
$memory_usage\ $memory_usage\
$aws\ $aws\
$gcloud\ $gcloud\
@ -263,9 +268,9 @@ format = "$all$directory$character"
## AWS ## AWS
The `aws` module shows the current AWS region and profile when credentials, a `credential_process` or a `sso_start_url` have been setup. 這是根據 `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 when credentials, a `credential_process` or a `sso_start_url` have been setup. Alternatively, you can force this module to show the region and profile even when the credentials have not been setup with the `force_display` option. 這是根據 `AWS_REGION`、`AWS_DEFAULT_REGION` 與 `AWS_PROFILE` 環境變數及 `~/.aws/config` 檔案。 This module also shows an expiration timer when using temporary credentials.
The module will display a profile only if its credentials are present in `~/.aws/credentials` or a `credential_process` is defined in `~/.aws/config`. Alternatively, having any of the `AWS_ACCESS_KEY_ID`, `AWS_SECRET_ACCESS_KEY`, or `AWS_SESSION_TOKEN` env vars defined will also suffice. The module will display a profile only if its credentials are present in `~/.aws/credentials` or a `credential_process` is defined in `~/.aws/config`. Alternatively, having any of the `AWS_ACCESS_KEY_ID`, `AWS_SECRET_ACCESS_KEY`, or `AWS_SESSION_TOKEN` env vars defined will also suffice. If the option `force_display` is set to `true`, all available information will be displayed even if the conditions above are not respected.
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. 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.
@ -275,15 +280,16 @@ When using [AWSume](https://awsu.me) the profile is read from the `AWSUME_PROFIL
### 選項 ### 選項
| Option | 預設 | 說明 | | Option | 預設 | 說明 |
| ------------------- | -------------------------------------------------------------------- | ----------------------------------------------------------------- | | ------------------- | -------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------- |
| `format` | `'on [$symbol($profile )(\($region\) )(\[$duration\])]($style)'` | The format for the module. | | `format` | `'on [$symbol($profile )(\($region\) )(\[$duration\])]($style)'` | The format for the module. |
| `symbol` | `"☁️ "` | 顯示在目前 AWS 配置之前的符號。 | | `symbol` | `"☁️ "` | 顯示在目前 AWS 配置之前的符號。 |
| `region_aliases` | | 除了AWS名稱外顯示區域別名表 | | `region_aliases` | | 除了AWS名稱外顯示區域別名表 |
| `profile_aliases` | | Table of profile aliases to display in addition to the AWS name. | | `profile_aliases` | | Table of profile aliases to display in addition to the AWS name. |
| `style` | `"bold yellow"` | 這個模組的風格。 | | `style` | `"bold yellow"` | 這個模組的風格。 |
| `expiration_symbol` | `X` | The symbol displayed when the temporary credentials have expired. | | `expiration_symbol` | `X` | The symbol displayed when the temporary credentials have expired. |
| `disabled` | `false` | Disables the `AWS` module. | | `disabled` | `false` | 停用 `AWS` 模組。 |
| `force_display` | `false` | If `true` displays info even if `credentials`, `credential_process` or `sso_start_url` have not been setup. |
### Variables ### Variables
@ -472,11 +478,57 @@ The `buf` module shows the currently installed version of [Buf](https://buf.buil
symbol = "🦬 " symbol = "🦬 "
``` ```
## C
The `c` module shows some information about your C compiler. By default the module will be shown if the current directory contains a `.c` or `.h` file.
### 選項
| Option | 預設 | 說明 |
| ------------------- | --------------------------------------------------------------------------- | ------------------------------------------------------------------------- |
| `format` | `"via [$symbol($version(-$name) )]($style)"` | The format string for the module. |
| `version_format` | `"v${raw}"` | The version format. Available vars are `raw`, `major`, `minor`, & `patch` |
| `symbol` | `"C "` | The symbol used before displaying the compiler details |
| `detect_extensions` | `["c", "h"]` | Which extensions should trigger this module. |
| `detect_files` | `[]` | Which filenames should trigger this module. |
| `detect_folders` | `[]` | Which folders should trigger this module. |
| `commands` | [ [ "cc", "--version" ], [ "gcc", "--version" ], [ "clang", "--version" ] ] | How to detect what the compiler is |
| `style` | `"bold 149"` | 這個模組的風格。 |
| `disabled` | `false` | Disables the `c` module. |
### Variables
| 變數 | 範例 | 說明 |
| ------- | ------ | ------------------------------------ |
| name | clang | The name of the compiler |
| version | 13.0.0 | The version of the compiler |
| symbol | | Mirrors the value of option `symbol` |
| style | | Mirrors the value of option `style` |
NB that `version` is not in the default format.
### Commands
The `commands` option accepts a list of commands to determine the compiler version and name.
Each command is represented as a list of the executable name, followed by its arguments, usually something like `["mycc", "--version"]`. Starship will try executing each command until it gets a result on STDOUT.
If a C compiler is not supported by this module, you can request it by [raising an issue on GitHub](https://github.com/starship/starship/).
### 範例
```toml
# ~/.config/starship.toml
[c]
format = "via [$name $version]($style)"
```
## 字元 ## 字元
The `character` module shows a character (usually an arrow) beside where the text is entered in your terminal. `character` 模組在你的文字輸入處旁顯示一個字元 (通常是箭頭)。
The character will tell you whether the last command was successful or not. It can do this in two ways: 這個字元會告訴你最後的指令是成功還是失敗。 It can do this in two ways:
- changing color (`red`/`green`) - changing color (`red`/`green`)
- changing shape (``/`✖`) - changing shape (``/`✖`)
@ -497,7 +549,7 @@ By default it only changes color. If you also want to change its shape take a lo
| `success_symbol` | `"[](bold green)"` | The format string used before the text input if the previous command succeeded. | | `success_symbol` | `"[](bold green)"` | The format string used before the text input if the previous command succeeded. |
| `error_symbol` | `"[](bold red)"` | The format string used before the text input if the previous command failed. | | `error_symbol` | `"[](bold red)"` | The format string used before the text input if the previous command failed. |
| `vicmd_symbol` | `"[](bold green)"` | The format string used before the text input if the shell is in vim normal mode. | | `vicmd_symbol` | `"[](bold green)"` | The format string used before the text input if the shell is in vim normal mode. |
| `disabled` | `false` | Disables the `character` module. | | `disabled` | `false` | 停用 `character` 模組。 |
### Variables ### Variables
@ -598,25 +650,25 @@ The `cobol` module shows the currently installed version of COBOL. By default, t
## 指令持續時間 ## 指令持續時間
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. `cmd_duration` 模組顯示最後一個指令執行所花費的時間。 這個模組只會在指令花費超過兩秒或是有設定 `min_time` 時,超過設定值時出現。
::: warning Do not hook the DEBUG trap in Bash ::: warning 不要在 Bash 中設置 DEBUG trap
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` 中使用 Starship不要在執行 `eval $(starship init $0)` 之後設置 `DEBUG` trap不然這個模組**會**壞掉。
::: :::
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. 想使用類似 preexec 功能的 Bash 使用者可以 [rcaloras 的 bash_preexec 框架](https://github.com/rcaloras/bash-preexec)。 只要在 `eval $(starship init $0)` 之前簡單地定義 `preexec_functions``precmd_functions` 兩個陣列,然後就可以照常進行。
### 選項 ### 選項
| Option | 預設 | 說明 | | Option | 預設 | 說明 |
| ---------------------- | ----------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------- | | ---------------------- | ----------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `min_time` | `2_000` | Shortest duration to show time for (in milliseconds). | | `min_time` | `2_000` | Shortest duration to show time for (in milliseconds). |
| `show_milliseconds` | `false` | Show milliseconds in addition to seconds for the duration. | | `show_milliseconds` | `false` | 顯示時間除了以秒為單位外,亦以毫秒顯示 |
| `format` | `"took [$duration]($style) "` | The format for the module. | | `format` | `"took [$duration]($style) "` | The format for the module. |
| `style` | `"bold yellow"` | 這個模組的風格。 | | `style` | `"bold yellow"` | 這個模組的風格。 |
| `disabled` | `false` | Disables the `cmd_duration` module. | | `disabled` | `false` | 停用 `cmd_duration` 模組。 |
| `show_notifications` | `false` | Show desktop notifications when command completes. | | `show_notifications` | `false` | Show desktop notifications when command completes. |
| `min_time_to_notify` | `45_000` | Shortest duration for notification (in milliseconds). | | `min_time_to_notify` | `45_000` | Shortest duration for notification (in milliseconds). |
| `notification_timeout` | | Duration to show notification for (in milliseconds). If unset, notification timeout will be determined by daemon. Not all notification daemons honor this option. | | `notification_timeout` | | Duration to show notification for (in milliseconds). If unset, notification timeout will be determined by daemon. Not all notification daemons honor this option. |
@ -652,14 +704,14 @@ This does not suppress conda's own prompt modifier, you may want to run `conda c
### 選項 ### 選項
| Option | 預設 | 說明 | | 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. | | `truncation_length` | `1` | 如果環境變數由所`conda create -p [path]`產生時,環境變數的資料夾需要截斷的數目。 `0` 表示不截斷 也請參考 [`directory`](#directory)模組 |
| `symbol` | `"🅒 "` | The symbol used before the environment name. | | `symbol` | `"🅒 "` | 環境名稱前使用的符號。 |
| `style` | `"bold green"` | 這個模組的風格。 | | `style` | `"bold green"` | 這個模組的風格。 |
| `format` | `"via [$symbol$environment]($style) "` | The format for the module. | | `format` | `"via [$symbol$environment]($style) "` | The format for the module. |
| `ignore_base` | `true` | Ignores `base` environment when activated. | | `ignore_base` | `true` | Ignores `base` environment when activated. |
| `disabled` | `false` | Disables the `conda` module. | | `disabled` | `false` | 停用 `conda` 模組。 |
### Variables ### Variables
@ -716,8 +768,8 @@ format = "[$symbol \\[$name\\]]($style) "
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/). By default the module will be shown if any of the following conditions are met:
- The current directory contains a `shard.yml` file - 現在資料夾中含有一個 `shard.yml` 檔案
- The current directory contains a `.cr` file - 現在資料夾中含有一個`.cr`檔案
### 選項 ### 選項
@ -757,7 +809,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 file with `.dart` extension
- The current directory contains a `.dart_tool` directory - The current directory contains a `.dart_tool` directory
- The current directory contains a `pubspec.yaml`, `pubspec.yml` or `pubspec.lock` file - 現在資料夾中包含一個 `pubspec.yaml`、`pubspec.yml` 或 `pubspec.lock` 檔案
### 選項 ### 選項
@ -829,21 +881,21 @@ format = "via [🦕 $version](green bold) "
## 資料夾 ## 資料夾
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. `directory` 模組顯示到現在資料夾的路徑,並裁減到前三層資料夾。 你的資料夾也會被裁減到你所在的 git 儲存庫的根目錄。
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. 如果正在使用 fish 風格的 pwd 選項,將不會隱藏被裁減的資料夾,而是會根據你在選項中設定的數字看到每一層資料夾的縮寫。
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`. 例如,給定一個右列的路徑 `~/Dev/Nix/nixpkgs/pkgs` 其中 `nixpkgs` 是儲存庫的根目錄,而且該選項被設定為 `1`。 你會看到 `~/D/N/nixpkgs/pkgs`,而在這個設定之前則是 `nixpkgs/pkgs`
### 選項 ### 選項
| Option | 預設 | 說明 | | Option | 預設 | 說明 |
| ------------------- | ----------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------- | | ------------------- | ----------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------- |
| `truncation_length` | `3` | The number of parent folders that the current directory should be truncated to. | | `truncation_length` | `3` | 到達現在資料夾的路徑中,要被裁減掉的資料夾數目。 |
| `truncate_to_repo` | `true` | Whether or not to truncate to the root of the git repo that you're currently in. | | `truncate_to_repo` | `true` | 是否要裁減到你現在所在的 git 儲存庫的根目錄。 |
| `format` | `"[$path]($style)[$read_only]($read_only_style) "` | The format for the module. | | `format` | `"[$path]($style)[$read_only]($read_only_style) "` | The format for the module. |
| `style` | `"bold cyan"` | 這個模組的風格。 | | `style` | `"bold cyan"` | 這個模組的風格。 |
| `disabled` | `false` | Disables the `directory` module. | | `disabled` | `false` | 停用 `directory` 模組。 |
| `read_only` | `"🔒"` | The symbol indicating current directory is read only. | | `read_only` | `"🔒"` | The symbol indicating current directory is read only. |
| `read_only_style` | `"red"` | The style for the read only symbol. | | `read_only_style` | `"red"` | The style for the read only symbol. |
| `truncation_symbol` | `""` | The symbol to prefix to truncated paths. eg: "…/" | | `truncation_symbol` | `""` | The symbol to prefix to truncated paths. eg: "…/" |
@ -853,12 +905,12 @@ For example, given `~/Dev/Nix/nixpkgs/pkgs` where `nixpkgs` is the repo root, an
| `use_os_path_sep` | `true` | Use the OS specific path separator instead of always using `/` (e.g. `\` on Windows) | | `use_os_path_sep` | `true` | Use the OS specific path separator instead of always using `/` (e.g. `\` on Windows) |
<details> <details>
<summary>This module has a few advanced configuration options that control how the directory is displayed.</summary> <summary>這個模組有些進階設定選項可以控制顯示資料夾。</summary>
| Advanced Option | 預設 | 說明 | | Advanced Option | 預設 | 說明 |
| --------------------------- | ------ | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------- | | --------------------------- | ------ | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `substitutions` | | A table of substitutions to be made to the path. | | `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. | | `fish_style_pwd_dir_length` | `0` | 當使用 fish shell 的 pwd 路徑邏輯時使用的字元數量。 |
| `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. | | `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. `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.
@ -945,7 +997,7 @@ format = "via [🐋 $context](blue bold)"
## Dotnet ## Dotnet
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. The `dotnet` module shows the relevant version of the [.NET Core SDK](https://dotnet.microsoft.com/) for the current directory. 如果這個資料夾已經選定一個 SDK則顯示這個 SDK 的版本。 如果沒有的話,則顯示最新安裝的 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: 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:
@ -960,9 +1012,9 @@ 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. You'll also need the .NET Core SDK installed in order to use it correctly.
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. 這個模組內部是使用它自己的機制來偵測版本。 一般來說這個模組有 `dotnet --version` 的兩倍快,但是它可能會在你的 .NET 專案有不尋常的資料夾結構時顯示不正確的版本。 如果精確度比速度更重要的話,你可以藉由設定模組中的 `heuristic = false` 選項來停用這個功能。
The module will also show the Target Framework Moniker (<https://docs.microsoft.com/en-us/dotnet/standard/frameworks#supported-target-framework-versions>) when there is a csproj file in the current directory. The module will also show the Target Framework Moniker (<https://docs.microsoft.com/en-us/dotnet/standard/frameworks#supported-target-frameworks>) when there is a `.csproj` file in the current directory.
### 選項 ### 選項
@ -970,13 +1022,13 @@ The module will also show the Target Framework Moniker (<https://docs.microsoft.
| ------------------- | ------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------- | | ------------------- | ------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------- |
| `format` | `"via [$symbol($version )(🎯 $tfm )]($style)"` | The format for the module. | | `format` | `"via [$symbol($version )(🎯 $tfm )]($style)"` | The format for the module. |
| `version_format` | `"v${raw}"` | The version format. Available vars are `raw`, `major`, `minor`, & `patch` | | `version_format` | `"v${raw}"` | The version format. Available vars are `raw`, `major`, `minor`, & `patch` |
| `symbol` | `".NET "` | The symbol used before displaying the version of dotnet. | | `symbol` | `".NET "` | 在顯示 dotnet 版本之前用的符號。 |
| `heuristic` | `true` | Use faster version detection to keep starship snappy. | | `heuristic` | `true` | 使用更快速的版本偵測法來保持 starship 的速度。 |
| `detect_extensions` | `["csproj", "fsproj", "xproj"]` | Which extensions should trigger this module. | | `detect_extensions` | `["csproj", "fsproj", "xproj"]` | Which extensions should trigger this module. |
| `detect_files` | `["global.json", "project.json", "Directory.Build.props", "Directory.Build.targets", "Packages.props"]` | Which filenames should trigger this module. | | `detect_files` | `["global.json", "project.json", "Directory.Build.props", "Directory.Build.targets", "Packages.props"]` | Which filenames should trigger this module. |
| `detect_folders` | `[]` | Which folders should trigger this modules. | | `detect_folders` | `[]` | Which folders should trigger this modules. |
| `style` | `"bold blue"` | 這個模組的風格。 | | `style` | `"bold blue"` | 這個模組的風格。 |
| `disabled` | `false` | Disables the `dotnet` module. | | `disabled` | `false` | 停用 `dotnet` 模組。 |
### Variables ### Variables
@ -1004,7 +1056,7 @@ heuristic = false
The `elixir` module shows the currently installed version of [Elixir](https://elixir-lang.org/) and [Erlang/OTP](https://erlang.org/doc/). By default the module will be shown if any of the following conditions are met: The `elixir` module shows the currently installed version of [Elixir](https://elixir-lang.org/) and [Erlang/OTP](https://erlang.org/doc/). By default the module will be shown if any of the following conditions are met:
- The current directory contains a `mix.exs` file. - 現在資料夾中含有一個 `mix.exs` 檔案.
### 選項 ### 選項
@ -1043,8 +1095,8 @@ symbol = "🔮 "
The `elm` module shows the currently installed version of [Elm](https://elm-lang.org/). By default the module will be shown if any of the following conditions are met: The `elm` module shows the currently installed version of [Elm](https://elm-lang.org/). By default the module will be shown if any of the following conditions are met:
- The current directory contains a `elm.json` file - 現在資料夾中含有一個 `elm.json` 檔案
- The current directory contains a `elm-package.json` file - 現在資料夾中包含一個 `elm-package.json` 檔案
- The current directory contains a `.elm-version` file - The current directory contains a `.elm-version` file
- The current directory contains a `elm-stuff` folder - The current directory contains a `elm-stuff` folder
- The current directory contains `*.elm` files - The current directory contains `*.elm` files
@ -1083,10 +1135,10 @@ format = "via [ $version](cyan bold) "
## 環境變數 ## 環境變數
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: The `env_var` module displays the current value of a selected environment variables. 這個模組只在下列條件其中之一達到時顯示:
- The `variable` configuration option matches an existing environment variable - `variable` 設定選項符合一個存在的環境變數。
- The `variable` configuration option is not defined, but the `default` configuration option is - 沒有設定 `variable` 選項,但是有設定 `default` 選項。
::: 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. ::: 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.
@ -1103,13 +1155,13 @@ default = "unknown user"
### 選項 ### 選項
| Option | 預設 | 說明 | | Option | 預設 | 說明 |
| ---------- | ------------------------------ | ---------------------------------------------------------------------------- | | ---------- | ------------------------------ | -------------------------- |
| `symbol` | `""` | The symbol used before displaying the variable value. | | `symbol` | `""` | 顯示在變數數值之前的符號。 |
| `variable` | | The environment variable to be displayed. | | `variable` | | 要顯示的環境變數。 |
| `default` | | The default value to be displayed when the selected variable is not defined. | | `default` | | 在選擇的變數值沒有定義時,顯示的預設值。 |
| `format` | `"with [$env_value]($style) "` | The format for the module. | | `format` | `"with [$env_value]($style) "` | The format for the module. |
| `disabled` | `false` | Disables the `env_var` module. | | `disabled` | `false` | 停用 `env_var` 模組。 |
### Variables ### Variables
@ -1147,8 +1199,8 @@ default = "unknown user"
The `erlang` module shows the currently installed version of [Erlang/OTP](https://erlang.org/doc/). By default the module will be shown if any of the following conditions are met: The `erlang` module shows the currently installed version of [Erlang/OTP](https://erlang.org/doc/). By default the module will be shown if any of the following conditions are met:
- The current directory contains a `rebar.config` file. - 現在資料夾中含有一個 `rebar.config` 檔案.
- The current directory contains a `erlang.mk` file. - 現在資料夾中含有一個 `erlang.mk` 檔案.
### 選項 ### 選項
@ -1284,23 +1336,23 @@ format = 'on [$symbol$account(@$domain)(\($project\))]($style) '
very-long-project-name = "vlpn" very-long-project-name = "vlpn"
``` ```
## Git Branch ## Git 分支
The `git_branch` module shows the active branch of the repo in your current directory. `git_branch` 模組顯示現在的資料夾中使用中的儲存庫的分支。
### 選項 ### 選項
| Option | 預設 | 說明 | | Option | 預設 | 說明 |
| -------------------- | -------------------------------- | ---------------------------------------------------------------------------------------- | | -------------------- | -------------------------------- | ------------------------------------------------------------------------------------ |
| `always_show_remote` | `false` | Shows the remote tracking branch name, even if it is equal to the local branch name. | | `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) "` | The format for the module. Use `"$branch"` to refer to the current branch name. | | `format` | `"on [$symbol$branch]($style) "` | The format for the module. Use `"$branch"` to refer to the current branch name. |
| `symbol` | `" "` | A format string representing the symbol of git branch. | | `symbol` | `" "` | A format string representing the symbol of git branch. |
| `style` | `"bold purple"` | 這個模組的風格。 | | `style` | `"bold purple"` | 這個模組的風格。 |
| `truncation_length` | `2^63 - 1` | Truncates a git branch to `N` graphemes. | | `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. | | `truncation_symbol` | `"…"` | 用來指示分支名稱被縮減的符號。 You can use `""` for no symbol. |
| `only_attached` | `false` | Only show the branch name when not in a detached `HEAD` state. | | `only_attached` | `false` | Only show the branch name when not in a detached `HEAD` state. |
| `ignore_branches` | `[]` | A list of names to avoid displaying. Useful for "master" or "main". | | `ignore_branches` | `[]` | A list of names to avoid displaying. Useful for "master" or "main". |
| `disabled` | `false` | Disables the `git_branch` module. | | `disabled` | `false` | 停用 `git_branch` 模組。 |
### Variables ### Variables
@ -1363,7 +1415,7 @@ tag_symbol = "🔖 "
## Git State ## Git State
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. `git_state` 模組會顯示在 git 儲存庫中的資料夾內以及會在有作業正在進行時顯示像是_REBASING_、_BISECTING_ 等等。 如果有進展的資訊 (像是 REBASING 3/10),也會一併顯示出來。
### 選項 ### 選項
@ -1378,7 +1430,7 @@ The `git_state` module will show in directories which are part of a git reposito
| `am_or_rebase` | `"AM/REBASE"` | A format string displayed when an ambiguous `apply-mailbox` or `rebase` 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"` | 這個模組的風格。 | | `style` | `"bold yellow"` | 這個模組的風格。 |
| `format` | `'\([$state( $progress_current/$progress_total)]($style)\) '` | The format for the module. | | `format` | `'\([$state( $progress_current/$progress_total)]($style)\) '` | The format for the module. |
| `disabled` | `false` | Disables the `git_state` module. | | `disabled` | `false` | 停用 `git_state` 模組。 |
### Variables ### Variables
@ -1407,7 +1459,7 @@ The `git_metrics` module will show the number of added and deleted lines in the
::: tip ::: tip
This module is disabled by default. To enable it, set `disabled` to `false` in your configuration file. 這個模組預設是停用的。 想要啟用它的話,請在設定檔中將 `disabled` 設定為 `false`
::: :::
@ -1444,7 +1496,7 @@ format = '[+$added]($added_style)/[-$deleted]($deleted_style) '
## Git Status ## Git Status
The `git_status` module shows symbols representing the state of the repo in your current directory. `git_status` 模組顯示用來表示現在資料夾之中儲存庫狀態的符號。
::: tip ::: tip
@ -1457,7 +1509,7 @@ The Git Status module is very slow in Windows directories (for example under `/m
| Option | 預設 | 說明 | | Option | 預設 | 說明 |
| ------------------- | ----------------------------------------------- | ----------------------------------------------------------------------------------------------------------- | | ------------------- | ----------------------------------------------- | ----------------------------------------------------------------------------------------------------------- |
| `format` | `'([\[$all_status$ahead_behind\]]($style) )'` | The default format for `git_status` | | `format` | `'([\[$all_status$ahead_behind\]]($style) )'` | The default format for `git_status` |
| `conflicted` | `"="` | This branch has merge conflicts. | | `conflicted` | `"="` | 這個分支有合併衝突。 |
| `ahead` | `"⇡"` | The format of `ahead` | | `ahead` | `"⇡"` | The format of `ahead` |
| `behind` | `"⇣"` | The format of `behind` | | `behind` | `"⇣"` | The format of `behind` |
| `diverged` | `"⇕"` | The format of `diverged` | | `diverged` | `"⇕"` | The format of `diverged` |
@ -1470,7 +1522,7 @@ The Git Status module is very slow in Windows directories (for example under `/m
| `deleted` | `"✘"` | The format of `deleted` | | `deleted` | `"✘"` | The format of `deleted` |
| `style` | `"bold red"` | 這個模組的風格。 | | `style` | `"bold red"` | 這個模組的風格。 |
| `ignore_submodules` | `false` | Ignore changes to submodules. | | `ignore_submodules` | `false` | Ignore changes to submodules. |
| `disabled` | `false` | Disables the `git_status` module. | | `disabled` | `false` | 停用 `git_status` 模組。 |
| `windows_starship` | | Use this (Linux) path to a Windows Starship executable to render `git_status` when on Windows paths in WSL. | | `windows_starship` | | Use this (Linux) path to a Windows Starship executable to render `git_status` when on Windows paths in WSL. |
### Variables ### Variables
@ -1548,14 +1600,14 @@ windows_starship = '/mnt/c/Users/username/scoop/apps/starship/current/starship.e
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 `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 - 現在資料夾中含有一個 `go.mod` 檔案
- The current directory contains a `go.sum` file - 現在資料夾中含有一個 `go.sum` 檔案
- The current directory contains a `glide.yaml` file - 現在資料夾中含有一個 `glide.yaml` 檔案
- The current directory contains a `Gopkg.yml` file - 現在資料夾中含有一個 `Gopkg.yml` 檔案
- The current directory contains a `Gopkg.lock` file - 現在資料夾中含有一個 `Gopkg.lock` 檔案
- The current directory contains a `.go-version` file - The current directory contains a `.go-version` file
- The current directory contains a `Godeps` directory - 現在資料夾中含有一個 `Godeps` 資料夾
- The current directory contains a file with the `.go` extension - 現在資料夾中含有一個檔案具有 `.go` 副檔名
### 選項 ### 選項
@ -1568,7 +1620,7 @@ The `golang` module shows the currently installed version of [Go](https://golang
| `detect_files` | `["go.mod", "go.sum", "glide.yaml", "Gopkg.yml", "Gopkg.lock", ".go-version"]` | Which filenames should trigger this module. | | `detect_files` | `["go.mod", "go.sum", "glide.yaml", "Gopkg.yml", "Gopkg.lock", ".go-version"]` | Which filenames should trigger this module. |
| `detect_folders` | `["Godeps"]` | Which folders should trigger this module. | | `detect_folders` | `["Godeps"]` | Which folders should trigger this module. |
| `style` | `"bold cyan"` | 這個模組的風格。 | | `style` | `"bold cyan"` | 這個模組的風格。 |
| `disabled` | `false` | Disables the `golang` module. | | `disabled` | `false` | 停用 `golang` 模組。 |
### Variables ### Variables
@ -1595,7 +1647,7 @@ The `haskell` module finds the current selected GHC version and/or the selected
By default the module will be shown if any of the following conditions are met: By default the module will be shown if any of the following conditions are met:
- The current directory contains a `stack.yaml` file - 現在資料夾中含有一個 `stack.yaml` 檔案
- The current directory contains any `.hs`, `.cabal`, or `.hs-boot` file - The current directory contains any `.hs`, `.cabal`, or `.hs-boot` file
### 選項 ### 選項
@ -1626,7 +1678,7 @@ By default the module will be shown if any of the following conditions are met:
The `helm` module shows the currently installed version of [Helm](https://helm.sh/). By default the module will be shown if any of the following conditions are met: The `helm` module shows the currently installed version of [Helm](https://helm.sh/). By default the module will be shown if any of the following conditions are met:
- The current directory contains a `helmfile.yaml` file - 現在資料夾中含有一個 `helmfile.yaml` 檔案
- The current directory contains a `Chart.yaml` file - The current directory contains a `Chart.yaml` file
### 選項 ### 選項
@ -1663,23 +1715,23 @@ format = "via [⎈ $version](bold white) "
## 主機名稱 ## 主機名稱
The `hostname` module shows the system hostname. `hostname` 模組顯示系統的主機名稱。
### 選項 ### 選項
| Option | 預設 | 說明 | | Option | 預設 | 說明 |
| ---------- | --------------------------- | ------------------------------------------------------------------------------------------------------------------------------------ | | ---------- | --------------------------- | ---------------------------------------------------------- |
| `ssh_only` | `true` | Only show hostname when connected to an SSH session. | | `ssh_only` | `true` | 只在連接到一個 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 | | `trim_at` | `"."` | 擷取出主機名稱的斷點,以第一個符合的為準。 `"."` 會讓它停在第一個點的符號。 `""` 會停用任何的截斷功能。 |
| `format` | `"[$hostname]($style) in "` | The format for the module. | | `format` | `"[$hostname]($style) in "` | The format for the module. |
| `style` | `"bold dimmed green"` | 這個模組的風格。 | | `style` | `"bold dimmed green"` | 這個模組的風格。 |
| `disabled` | `false` | Disables the `hostname` module. | | `disabled` | `false` | 停用 `hostname` 模組。 |
### Variables ### Variables
| 變數 | 範例 | 說明 | | 變數 | 範例 | 說明 |
| --------- | ---------- | ----------------------------------- | | --------- | ---------- | ----------------------------------- |
| hostname | `computer` | The hostname of the computer | | 主機名稱 | `computer` | The hostname of the computer |
| style\* | | Mirrors the value of option `style` | | style\* | | Mirrors the value of option `style` |
*: This variable can only be used as a part of a style string *: This variable can only be used as a part of a style string
@ -1714,7 +1766,7 @@ The `java` module shows the currently installed version of [Java](https://www.or
| `detect_folders` | `[]` | Which folders should trigger this modules. | | `detect_folders` | `[]` | Which folders should trigger this modules. |
| `symbol` | `"☕ "` | A format string representing the symbol of Java | | `symbol` | `"☕ "` | A format string representing the symbol of Java |
| `style` | `"red dimmed"` | 這個模組的風格。 | | `style` | `"red dimmed"` | 這個模組的風格。 |
| `disabled` | `false` | Disables the `java` module. | | `disabled` | `false` | 停用 `java` 模組。 |
### Variables ### Variables
@ -1735,9 +1787,9 @@ The `java` module shows the currently installed version of [Java](https://www.or
symbol = "🌟 " symbol = "🌟 "
``` ```
## Jobs ## 工作
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. `jobs` 模組顯示現在正在執行中的工作。 這個模組只會在有背景工作正在執行時顯示。 The module will show the number of jobs running if there are at least 2 jobs, or more than the `number_threshold` config value, if it exists. The module will show a symbol if there is at least 1 job, or more than the `symbol_threshold` config value, if it exists. You can set both values to 0 in order to _always_ show the symbol and number of jobs, even if there are 0 jobs running.
The default functionality is: The default functionality is:
@ -1761,13 +1813,13 @@ The `threshold` option is deprecated, but if you want to use it, the module will
| Option | 預設 | 說明 | | Option | 預設 | 說明 |
| ------------------ | ----------------------------- | ------------------------------------------------------------------------ | | ------------------ | ----------------------------- | ------------------------------------------------------------------------ |
| `threshold`* | `1` | Show number of jobs if exceeded. | | `threshold`* | `1` | 在超過指定值時顯示工作數量。 |
| `symbol_threshold` | `1` | Show `symbol` if the job count is at least `symbol_threshold`. | | `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`. | | `number_threshold` | `2` | Show the number of jobs if the job count is at least `number_threshold`. |
| `format` | `"[$symbol$number]($style) "` | The format for the module. | | `format` | `"[$symbol$number]($style) "` | The format for the module. |
| `symbol` | `"✦"` | The string used to represent the `symbol` variable. | | `symbol` | `"✦"` | The string used to represent the `symbol` variable. |
| `style` | `"bold blue"` | 這個模組的風格。 | | `style` | `"bold blue"` | 這個模組的風格。 |
| `disabled` | `false` | Disables the `jobs` module. | | `disabled` | `false` | 停用 `jobs` 模組。 |
*: This option is deprecated, please use the `number_threshold` and `symbol_threshold` options instead. *: This option is deprecated, please use the `number_threshold` and `symbol_threshold` options instead.
@ -1885,7 +1937,7 @@ Displays the current [Kubernetes context](https://kubernetes.io/docs/concepts/co
::: tip ::: tip
This module is disabled by default. To enable it, set `disabled` to `false` in your configuration file. 這個模組預設是停用的。 想要啟用它的話,請在設定檔中將 `disabled` 設定為 `false`
::: :::
@ -1947,15 +1999,15 @@ Long and automatically generated cluster names can be identified and shortened u
"gke_.*_(?P<var_cluster>[\\w-]+)" = "gke-$var_cluster" "gke_.*_(?P<var_cluster>[\\w-]+)" = "gke-$var_cluster"
``` ```
## Line Break ## 換行
The `line_break` module separates the prompt into two lines. `line_break` 模組將提示字元分成兩行。
### 選項 ### 選項
| Option | 預設 | 說明 | | Option | 預設 | 說明 |
| ---------- | ------- | ------------------------------------------------------------------ | | ---------- | ------- | ----------------------------- |
| `disabled` | `false` | Disables the `line_break` module, making the prompt a single line. | | `disabled` | `false` | 停用 `line_break` 模組,讓提示字元變成一行。 |
### 範例 ### 範例
@ -2040,27 +2092,27 @@ The `lua` module shows the currently installed version of [Lua](http://www.lua.o
format = "via [🌕 $version](bold blue) " format = "via [🌕 $version](bold blue) "
``` ```
## Memory Usage ## 記憶體使用量
The `memory_usage` module shows current system memory and swap usage. `memory_usage` 模組顯示現在系統記憶體與 swap 的使用量。
By default the swap usage is displayed if the total system swap is non-zero. 預設 swap 使用量會在系統總 swap 使用量不為 0 時顯示出來。
::: tip ::: tip
This module is disabled by default. To enable it, set `disabled` to `false` in your configuration file. 這個模組預設是停用的。 想要啟用它的話,請在設定檔中將 `disabled` 設定為 `false`
::: :::
### 選項 ### 選項
| Option | 預設 | 說明 | | Option | 預設 | 說明 |
| ----------- | ----------------------------------------------- | -------------------------------------------------------- | | ----------- | ----------------------------------------------- | -------------------------- |
| `threshold` | `75` | Hide the memory usage unless it exceeds this percentage. | | `threshold` | `75` | 將記憶體使用量隱藏,除非使用量超過指定值。 |
| `format` | `"via $symbol [${ram}( \| ${swap})]($style) "` | The format for the module. | | `format` | `"via $symbol [${ram}( \| ${swap})]($style) "` | The format for the module. |
| `symbol` | `"🐏"` | The symbol used before displaying the memory usage. | | `symbol` | `"🐏"` | 顯示在記憶體使用量之前的符號。 |
| `style` | `"bold dimmed white"` | 這個模組的風格。 | | `style` | `"bold dimmed white"` | 這個模組的風格。 |
| `disabled` | `true` | Disables the `memory_usage` module. | | `disabled` | `true` | 停用 `memory_usage` 模組。 |
### Variables ### Variables
@ -2099,7 +2151,7 @@ The `hg_branch` module shows the active branch of the repo in your current direc
| `style` | `"bold purple"` | 這個模組的風格。 | | `style` | `"bold purple"` | 這個模組的風格。 |
| `format` | `"on [$symbol$branch]($style) "` | The format for the module. | | `format` | `"on [$symbol$branch]($style) "` | The format for the module. |
| `truncation_length` | `2^63 - 1` | Truncates the hg branch name to `N` graphemes | | `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. | | `truncation_symbol` | `"…"` | 用來指示分支名稱被縮減的符號。 |
| `disabled` | `true` | Disables the `hg_branch` module. | | `disabled` | `true` | Disables the `hg_branch` module. |
### Variables ### Variables
@ -2127,7 +2179,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: 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:
- The current directory contains a `nim.cfg` file - 現在資料夾中含有一個 `nim.cfg` 檔案
- The current directory contains a file with the `.nim` extension - 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 `.nims` extension
- The current directory contains a file with the `.nimble` extension - The current directory contains a file with the `.nimble` extension
@ -2167,7 +2219,7 @@ 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. The module will be shown when inside a nix-shell environment. The `nix_shell` module shows the [nix-shell](https://nixos.org/guides/nix-pills/developing-with-nix-shell.html) environment. 這個模組會在 nix-shell 環境中顯示。
### 選項 ### 選項
@ -2178,7 +2230,7 @@ The `nix_shell` module shows the [nix-shell](https://nixos.org/guides/nix-pills/
| `style` | `"bold blue"` | 這個模組的風格。 | | `style` | `"bold blue"` | 這個模組的風格。 |
| `impure_msg` | `"impure"` | A format string shown when the shell is impure. | | `impure_msg` | `"impure"` | A format string shown when the shell is impure. |
| `pure_msg` | `"pure"` | A format string shown when the shell is pure. | | `pure_msg` | `"pure"` | A format string shown when the shell is pure. |
| `disabled` | `false` | Disables the `nix_shell` module. | | `disabled` | `false` | 停用 `nix_shell` 模組。 |
### Variables ### Variables
@ -2207,10 +2259,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: 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:
- The current directory contains a `package.json` file - 現在資料夾中包含一個 `package.json` 檔案
- The current directory contains a `.node-version` file - The current directory contains a `.node-version` file
- The current directory contains a `.nvmrc` file - The current directory contains a `.nvmrc` file
- The current directory contains a `node_modules` directory - 現在資料夾中包含一個 `node_modules` 資料夾
- The current directory contains a file with the `.js`, `.mjs` or `.cjs` extension - The current directory contains a file with the `.js`, `.mjs` or `.cjs` extension
- The current directory contains a file with the `.ts`, `.mts` or `.cts` extension - The current directory contains a file with the `.ts`, `.mts` or `.cts` extension
@ -2225,7 +2277,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_files` | `["package.json", ".node-version"]` | Which filenames should trigger this module. |
| `detect_folders` | `["node_modules"]` | Which folders should trigger this module. | | `detect_folders` | `["node_modules"]` | Which folders should trigger this module. |
| `style` | `"bold green"` | 這個模組的風格。 | | `style` | `"bold green"` | 這個模組的風格。 |
| `disabled` | `false` | Disables the `nodejs` module. | | `disabled` | `false` | 停用 `nodejs` 模組。 |
| `not_capable_style` | `bold red` | The style for the module when an engines property in package.json does not match the Node.js version. | | `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 ### Variables
@ -2329,9 +2381,9 @@ style = "bold yellow"
symbol = "☁️ " symbol = "☁️ "
``` ```
## 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`, `helm`, `shards` and `dart` packages. The `package` 模組在現在資料夾是一個套件的儲藏庫時出現,並顯示他的現在版本。 The module currently supports `npm`, `nimble`, `cargo`, `poetry`, `composer`, `gradle`, `julia`, `mix`, `helm`, `shards` and `dart` packages.
- [**npm**](https://docs.npmjs.com/cli/commands/npm) The `npm` package version is extracted from the `package.json` present in the current directory - [**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 - [**Cargo**](https://doc.rust-lang.org/cargo/) The `cargo` package version is extracted from the `Cargo.toml` present in the current directory
@ -2357,11 +2409,11 @@ The `package` module is shown when the current directory is the repository for a
| Option | 預設 | 說明 | | Option | 預設 | 說明 |
| ----------------- | --------------------------------- | ------------------------------------------------------------------------- | | ----------------- | --------------------------------- | ------------------------------------------------------------------------- |
| `format` | `"is [$symbol$version]($style) "` | The format for the module. | | `format` | `"is [$symbol$version]($style) "` | The format for the module. |
| `symbol` | `"📦 "` | The symbol used before displaying the version the package. | | `symbol` | `"📦 "` | 顯示在套件的版本之前的符號。 |
| `version_format` | `"v${raw}"` | The version format. Available vars are `raw`, `major`, `minor`, & `patch` | | `version_format` | `"v${raw}"` | The version format. Available vars are `raw`, `major`, `minor`, & `patch` |
| `style` | `"bold 208"` | 這個模組的風格。 | | `style` | `"bold 208"` | 這個模組的風格。 |
| `display_private` | `false` | Enable displaying version for packages marked as private. | | `display_private` | `false` | Enable displaying version for packages marked as private. |
| `disabled` | `false` | Disables the `package` module. | | `disabled` | `false` | 停用 `package` 模組。 |
### Variables ### Variables
@ -2426,7 +2478,7 @@ format = "via [🦪 $version]($style) "
The `php` module shows the currently installed version of [PHP](https://www.php.net/). By default the module will be shown if any of the following conditions are met: The `php` module shows the currently installed version of [PHP](https://www.php.net/). By default the module will be shown if any of the following conditions are met:
- The current directory contains a `composer.json` file - 現在資料夾中含有一個 `composer.json` 檔案
- The current directory contains a `.php-version` file - The current directory contains a `.php-version` file
- The current directory contains a `.php` extension - The current directory contains a `.php` extension
@ -2493,7 +2545,7 @@ By default the module will be shown if any of the following conditions are met:
| --------- | ---------- | ------------------------------------ | | --------- | ---------- | ------------------------------------ |
| version | `v0.12.24` | The version of `pulumi` | | version | `v0.12.24` | The version of `pulumi` |
| stack | `dev` | The current Pulumi stack | | stack | `dev` | The current Pulumi stack |
| username | `alice` | The current Pulumi username | | 使用者名稱 | `alice` | The current Pulumi username |
| symbol | | Mirrors the value of option `symbol` | | symbol | | Mirrors the value of option `symbol` |
| style\* | | Mirrors the value of option `style` | | style\* | | Mirrors the value of option `style` |
@ -2523,7 +2575,7 @@ format = "[$symbol$stack]($style) "
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. By default the module will be shown if any of the following conditions are met:
- The current directory contains a `spago.dhall` file - 現在資料夾中含有一個 `spago.dhall` 檔案
- The current directory contains a file with the `.purs` extension - The current directory contains a file with the `.purs` extension
### 選項 ### 選項
@ -2566,14 +2618,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: By default the module will be shown if any of the following conditions are met:
- The current directory contains a `.python-version` file - 目前資料夾中有一個 `.python-version` 檔案
- The current directory contains a `Pipfile` file - 目前資料夾中有一個 `Pipfile` 檔案
- The current directory contains a `__init__.py` file - The current directory contains a `__init__.py` file
- The current directory contains a `pyproject.toml` file - 目前資料夾中有一個 `pyproject.toml` 檔案
- The current directory contains a `requirements.txt` file - 目前資料夾中有一個 `requirements.txt` 檔案
- The current directory contains a `setup.py` file - 現在資料夾中含有一個 `setup.py` 檔案
- The current directory contains a `tox.ini` file - 目前資料夾中有一個 `tox.ini` 檔案
- The current directory contains a file with the `.py` extension. - 目前資料夾中有一個 `.py` 副檔名的檔案.
- A virtual environment is currently activated - A virtual environment is currently activated
### 選項 ### 選項
@ -2584,13 +2636,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` | | `version_format` | `"v${raw}"` | The version format. Available vars are `raw`, `major`, `minor`, & `patch` |
| `symbol` | `"🐍 "` | A format string representing the symbol of Python | | `symbol` | `"🐍 "` | A format string representing the symbol of Python |
| `style` | `"yellow bold"` | 這個模組的風格。 | | `style` | `"yellow bold"` | 這個模組的風格。 |
| `pyenv_version_name` | `false` | Use pyenv to get Python version | | `pyenv_version_name` | `false` | 使用 pyenv 取得 Python 的版本。 |
| `pyenv_prefix` | `pyenv` | Prefix before pyenv version display, only used if pyenv is used | | `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. | | `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_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_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 | | `detect_folders` | `[]` | Which folders should trigger this module |
| `disabled` | `false` | Disables the `python` module. | | `disabled` | `false` | 停用 `python` 模組。 |
::: tip ::: tip
@ -2731,9 +2783,9 @@ symbol = "🔴 "
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 current directory contains a `Gemfile` file - 目前資料夾中有一個 `Gemfile` 檔案
- The current directory contains a `.ruby-version` file - The current directory contains a `.ruby-version` file
- The current directory contains a `.rb` file - 目前資料夾中有一個 `.rb` 檔案
- The environment variables `RUBY_VERSION` or `RBENV_VERSION` are set - The environment variables `RUBY_VERSION` or `RBENV_VERSION` are set
Starship gets the current Ruby version by running `ruby -v`. Starship gets the current Ruby version by running `ruby -v`.
@ -2750,7 +2802,7 @@ Starship gets the current Ruby version by running `ruby -v`.
| `detect_folders` | `[]` | Which folders should trigger this module. | | `detect_folders` | `[]` | Which folders should trigger this module. |
| `detect_variables` | `["RUBY_VERSION", "RBENV_VERSION"]` | Which environment variables should trigger this module. | | `detect_variables` | `["RUBY_VERSION", "RBENV_VERSION"]` | Which environment variables should trigger this module. |
| `style` | `"bold red"` | 這個模組的風格。 | | `style` | `"bold red"` | 這個模組的風格。 |
| `disabled` | `false` | Disables the `ruby` module. | | `disabled` | `false` | 停用 `ruby` 模組。 |
### Variables ### Variables
@ -2775,8 +2827,8 @@ symbol = "🔺 "
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 current directory contains a `Cargo.toml` file - 目前資料夾中有一個 `Cargo.toml` 檔案
- The current directory contains a file with the `.rs` extension - 現在資料夾中包含一個檔案具有 `.rs` 副檔名
### 選項 ### 選項
@ -2789,7 +2841,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_files` | `["Cargo.toml"]` | Which filenames should trigger this module. |
| `detect_folders` | `[]` | Which folders should trigger this module. | | `detect_folders` | `[]` | Which folders should trigger this module. |
| `style` | `"bold red"` | 這個模組的風格。 | | `style` | `"bold red"` | 這個模組的風格。 |
| `disabled` | `false` | Disables the `rust` module. | | `disabled` | `false` | 停用 `rust` 模組。 |
### Variables ### Variables
@ -2856,7 +2908,7 @@ The `shell` module shows an indicator for currently used shell.
::: tip ::: tip
This module is disabled by default. To enable it, set `disabled` to `false` in your configuration file. 這個模組預設是停用的。 想要啟用它的話,請在設定檔中將 `disabled` 設定為 `false`
::: :::
@ -2969,13 +3021,46 @@ The `singularity` module shows the current [Singularity](https://sylabs.io/singu
format = '[📦 \[$env\]]($style) ' format = '[📦 \[$env\]]($style) '
``` ```
## Spack
The `spack` module shows the current [Spack](https://spack.readthedocs.io/en/latest/) environment, if `$SPACK_ENV` is set.
### 選項
| Option | 預設 | 說明 |
| ------------------- | -------------------------------------- | ----------------------------------------------------------------------------------------------------------------- |
| `truncation_length` | `1` | The number of directories the environment path should be truncated to. `0` 表示不截斷 也請參考 [`directory`](#directory)模組 |
| `symbol` | `"🅢 "` | 環境名稱前使用的符號。 |
| `style` | `"bold blue"` | 這個模組的風格。 |
| `format` | `"via [$symbol$environment]($style) "` | The format for the module. |
| `disabled` | `false` | Disables the `spack` module. |
### Variables
| 變數 | 範例 | 說明 |
| ----------- | ------------ | ------------------------------------ |
| environment | `astronauts` | The current spack environment |
| symbol | | Mirrors the value of option `symbol` |
| style\* | | Mirrors the value of option `style` |
*: This variable can only be used as a part of a style string
### 範例
```toml
# ~/.config/starship.toml
[spack]
format = "[$symbol$environment](dimmed blue) "
```
## Status ## Status
The `status` module displays the exit code of the previous command. If $success_symbol is empty (default), the module will be shown only if the exit code is not `0`. The status code will cast to a signed 32-bit integer. The `status` module displays the exit code of the previous command. If $success_symbol is empty (default), the module will be shown only if the exit code is not `0`. The status code will cast to a signed 32-bit integer.
::: tip ::: tip
This module is disabled by default. To enable it, set `disabled` to `false` in your configuration file. 這個模組預設是停用的。 想要啟用它的話,請在設定檔中將 `disabled` 設定為 `false`
::: :::
@ -3035,7 +3120,7 @@ The `sudo` module displays if sudo credentials are currently cached. The module
::: tip ::: tip
This module is disabled by default. To enable it, set `disabled` to `false` in your configuration file. 這個模組預設是停用的。 想要啟用它的話,請在設定檔中將 `disabled` 設定為 `false`
::: :::
@ -3178,33 +3263,33 @@ 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. `time` 模組顯示目前的**當地**時間. `format` 設定值被 [`chrono`](https://crates.io/crates/chrono) crate 用來控制時間如何顯示。 請看 [chrono 的 strftime 文件](https://docs.rs/chrono/0.4.7/chrono/format/strftime/index.html)來了解有那些選項可以使用。
::: tip ::: tip
This module is disabled by default. To enable it, set `disabled` to `false` in your configuration file. 這個模組預設是停用的。 想要啟用它的話,請在設定檔中將 `disabled` 設定為 `false`
::: :::
### 選項 ### 選項
| Option | 預設 | 說明 | | Option | 預設 | 說明 |
| ----------------- | ----------------------- | ---------------------------------------------------------------------------------------------------------------------------------- | | ----------------- | ----------------------- | ----------------------------------------------------------------------------------------------------- |
| `format` | `"at [$time]($style) "` | The format string for the module. | | `format` | `"at [$time]($style) "` | The format string for the module. |
| `use_12hr` | `false` | Enables 12 hour formatting | | `use_12hr` | `false` | 啟用 12 小時格式。 |
| `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. | | `time_format` | 請看下列 | 用來顯示時間的 [chrono 格式字串](https://docs.rs/chrono/0.4.7/chrono/format/strftime/index.html)。 |
| `style` | `"bold yellow"` | The style for the module time | | `style` | `"bold yellow"` | 這個模組的時間的風格。 |
| `utc_time_offset` | `"local"` | Sets the UTC offset to use. Range from -24 &lt; x &lt; 24. Allows floats to accommodate 30/45 minute timezone offsets. | | `utc_time_offset` | `"local"` | 設定相對於 UTC 的時差。 Range from -24 &lt; x &lt; 24. 允許使用浮點數來表示 30/45 分鐘時差的時區。 |
| `disabled` | `true` | Disables the `time` module. | | `disabled` | `true` | 停用 `time` 模組。 |
| `time_range` | `"-"` | Sets the time range during which the module will be shown. Times must be specified in 24-hours format | | `time_range` | `"-"` | Sets the time range during which the module will be shown. Times must be specified in 24-hours format |
If `use_12hr` is `true`, then `time_format` defaults to `"%r"`. Otherwise, it defaults to `"%T"`. Manually setting `time_format` will override the `use_12hr` setting. If `use_12hr` is `true`, then `time_format` defaults to `"%r"`. 不然的話,它會被預設為 `"%T"` Manually setting `time_format` will override the `use_12hr` setting.
### Variables ### Variables
| 變數 | 範例 | 說明 | | 變數 | 範例 | 說明 |
| --------- | ---------- | ----------------------------------- | | --------- | ---------- | ----------------------------------- |
| time | `13:08:10` | The current time. | | 時間 | `13:08:10` | The current time. |
| style\* | | Mirrors the value of option `style` | | style\* | | Mirrors the value of option `style` |
*: This variable can only be used as a part of a style string *: This variable can only be used as a part of a style string
@ -3222,14 +3307,14 @@ utc_time_offset = "-5"
time_range = "10:00:00-14:00:00" time_range = "10:00:00-14:00:00"
``` ```
## Username ## 使用者名稱
The `username` module shows active user's username. 這個模組在下列其中一個條件達成時顯示: `username` 模組顯示現在使用中的使用者名稱。 這個模組在下列其中一個條件達成時顯示:
- The current user is root - The current user is root/admin
- The current user isn't the same as the one that is logged in - 目前使用者並非登入時的使用者
- The user is currently connected as an SSH session - 使用者透過 SSH session 進行連線
- The variable `show_always` is set to true - 變數 `show_always` 被設為 true
::: tip ::: tip
@ -3239,13 +3324,13 @@ SSH connection is detected by checking environment variables `SSH_CONNECTION`, `
### 選項 ### 選項
| Option | 預設 | 說明 | | Option | 預設 | 說明 |
| ------------- | ----------------------- | ------------------------------------- | | ------------- | ----------------------- | ------------------------------------------- |
| `style_root` | `"bold red"` | The style used when the user is root. | | `style_root` | `"bold red"` | The style used when the user is root/admin. |
| `style_user` | `"bold yellow"` | The style used for non-root users. | | `style_user` | `"bold yellow"` | 非 root 使用者時使用的風格。 |
| `format` | `"[$user]($style) in "` | The format for the module. | | `format` | `"[$user]($style) in "` | The format for the module. |
| `show_always` | `false` | Always shows the `username` module. | | `show_always` | `false` | 總是顯示 `username` 模組。 |
| `disabled` | `false` | Disables the `username` module. | | `disabled` | `false` | 停用 `username` 模組。 |
### Variables ### Variables
@ -3417,9 +3502,9 @@ The `custom` modules show the output of some arbitrary commands.
These modules will be shown if any of the following conditions are met: These modules will be shown if any of the following conditions are met:
- The current directory contains a file whose name is in `files` - The current directory contains a file whose name is in `detect_files`
- The current directory contains a directory whose name is in `directories` - The current directory contains a directory whose name is in `detect_folders`
- The current directory contains a file whose extension is in `extensions` - The current directory contains a file whose extension is in `detect_extensions`
- The `when` command returns 0 - The `when` command returns 0
- The current Operating System (std::env::consts::OS) matchs with `os` field if defined. - The current Operating System (std::env::consts::OS) matchs with `os` field if defined.
@ -3451,20 +3536,22 @@ Format strings can also contain shell specific prompt sequences, e.g. [Bash](htt
### 選項 ### 選項
| Option | 預設 | 說明 | | Option | 預設 | 說明 |
| ------------- | ------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | | ------------------- | ------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `command` | `""` | The command whose output should be printed. The command will be passed on stdin to the shell. | | `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. | | `when` | `false` | Either a boolean value (`true` or `false`, without quotes) or a string shell command used as a condition to show the module. In case of a string, the module will be shown if the command returns a `0` status code. |
| `shell` | | [See below](#custom-command-shell) | | `shell` | | [See below](#custom-command-shell) |
| `description` | `"<custom module>"` | The description of the module that is shown when running `starship explain`. | | `說明` | `"<custom module>"` | 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. | | `detect_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. | | `detect_folders` | `[]` | 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. | | `detect_extensions` | `[]` | The extensions that will be searched in the working directory for a match. |
| `symbol` | `""` | The symbol used before displaying the command output. | | `symbol` | `""` | The symbol used before displaying the command output. |
| `style` | `"bold green"` | 這個模組的風格。 | | `style` | `"bold green"` | 這個模組的風格。 |
| `format` | `"[$symbol($output )]($style)"` | The format for the module. | | `format` | `"[$symbol($output )]($style)"` | The format for the module. |
| `disabled` | `false` | Disables this `custom` 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). | | `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). |
| `use_stdin` | | An optional boolean value that overrides whether commands should be forwarded to the shell via the standard input or as an argument. If unset standard input is used by default, unless the shell does not support it (cmd, nushell). Setting this disables shell-specific argument handling. |
| `ignore_timeout` | `false` | Ignore global `command_timeout` setting and keep running external commands, no matter how long they take. |
### Variables ### Variables
@ -3487,7 +3574,7 @@ If unset, it will fallback to STARSHIP_SHELL and then to "sh" on Linux, and "cmd
The `command` will be passed in on stdin. The `command` will be passed in on stdin.
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. 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 -`. If `shell` is not given or only contains one element and Starship detects Cmd will be used, the following argument will automatically be added: `/C` and `stdin` will be set to `false`. If `shell` is not given or only contains one element and Starship detects Nushell will be used, the following arguments will automatically be added: `-c` and `stdin` will be set to `false`. This behavior can be avoided by explicitly passing arguments to the shell, e.g.
```toml ```toml
shell = ["pwsh", "-Command", "-"] shell = ["pwsh", "-Command", "-"]
@ -3512,12 +3599,18 @@ Automatic detection of shells and proper parameters addition are currently imple
[custom.foo] [custom.foo]
command = "echo foo" # shows output of command command = "echo foo" # shows output of command
files = ["foo"] # can specify filters but wildcards are not supported detect_files = ["foo"] # can specify filters but wildcards are not supported
when = """ test "$HOME" == "$PWD" """ when = """ test "$HOME" == "$PWD" """
format = " transcending [$output]($style)" format = " transcending [$output]($style)"
[custom.time] [custom.time]
command = "time /T" command = "time /T"
extensions = ["pst"] # filters *.pst files detect_extensions = ["pst"] # filters *.pst files
shell = ["pwsh.exe", "-NoProfile", "-Command", "-"] shell = ["pwsh.exe", "-NoProfile", "-Command", "-"]
[custom.time-as-arg]
command = "time /T"
detect_extensions = ["pst"] # filters *.pst files
shell = ["pwsh.exe", "-NoProfile", "-Command"]
use_stdin = false
``` ```

Some files were not shown because too many files have changed in this diff Show More