docs(i18n): Update translations (#908)

This commit is contained in:
Matan Kushner
2020-02-07 16:47:30 -05:00
committed by GitHub
parent 54acc2cdc3
commit 3271b586f4
14 changed files with 504 additions and 107 deletions
+64 -10
View File
@@ -8,7 +8,7 @@ Starship 目前正在开发中。 很多新的配置选项将会在之后的版
您需要创建配置文件 `~/.config/starship.toml` 以供 Starship 使用。
```shell
```sh
$ mkdir -p ~/.config && touch ~/.config/starship.toml
```
@@ -28,7 +28,7 @@ disabled = true
```
你可以设置环境变量 `STARSHIP_CONFIG` 来修改 starship 查找配置文件 `starship.toml` 时查找的位置:
```shell
```sh
export STARSHIP_CONFIG=~/.starship
```
@@ -100,6 +100,7 @@ prompt_order = [
"hg_branch",
"package",
"dotnet",
"elm",
"golang",
"haskell",
"java",
@@ -114,6 +115,7 @@ prompt_order = [
"memory_usage",
"aws",
"env_var",
"crystal",
"cmd_duration",
"line_break",
"jobs",
@@ -376,6 +378,33 @@ style = "green"
heuristic = false
```
## Elm
The `elm` module shows the currently installed version of Elm. 此组件只有满足以下条件之一时才会被显示:
- 当前目录包含 `elm.json` 文件
- 当前目录包含 `elm-package.json` 文件
- The current directory contains a `elm-stuff` folder
- The current directory contains a `*.elm` files
### 配置项
| 字段 | 默认值 | 描述 |
| ---------- | ------------- | ----------------------------------------------------- |
| `symbol` | `"🌳 "` | The symbol used before displaying the version of Elm. |
| `style` | `"bold cyan"` | 此组件的样式。 |
| `disabled` | `false` | Disables the `elm` module. |
### 示例
```toml
# ~/.config/starship.toml
[elm]
symbol = " "
```
## Environment Variable
`env_var` 组件显示选定的环境变量的当前值。 此组件只有满足以下条件之一时才会被显示:
@@ -597,7 +626,7 @@ symbol = "🏎💨 "
# ~/.config/starship.toml
[haskell]
symbol = "λx.x "
symbol = " "
```
## Mercurial Branch
@@ -752,7 +781,7 @@ pure_msg = "pure shell"
## Java
`java` 组件显示当前安装的 Java 版本。 此组件将在符合以下条件之一时显示:
`java` 组件显示当前安装的 Java 版本。 此组件只有满足以下条件之一时才会被显示:
- 当前目录包含 `pom.xml``build.gradle.kts``build.sbt` 文件
- 当前目录包含一个扩展名为 `.java``.class``.gradle``.jar` 的文件
@@ -812,6 +841,31 @@ separator = "/"
style = "bold dimmed green"
```
## Crystal
The `crystal` module shows the currently installed version of Crystal. 此组件只有满足以下条件之一时才会被显示:
- 当前目录包含 `shard.yml` 文件
- The current directory contains a `.cr` file
### 配置项
| 字段 | 默认值 | 描述 |
| ---------- | ------------ | --------------------------------------------------------- |
| `symbol` | `"🔮 "` | The symbol used before displaying the version of crystal. |
| `style` | `"bold red"` | 此组件的样式。 |
| `disabled` | `false` | Disables the `crystal` module. |
### 示例
```toml
# ~/.config/starship.toml
[crystal]
symbol = "✨ "
style = "bold blue"
```
## NodeJS
`nodejs` 组件显示当前安装的 NodeJS 版本。 此组件将在符合以下任意条件之一时显示:
@@ -867,7 +921,7 @@ symbol = "🎁 "
## PHP
`php` 组件显示当前安装的 PHP 版本。 此组件将在符合以下任意条件之一时显示:
`php` 组件显示当前安装的 PHP 版本。 此组件只有满足以下条件之一时才会被显示:
- 当前目录包含一个 `composer.json` 文件
- 当前目录包含一个 `.php` 文件
@@ -897,7 +951,7 @@ symbol = "🔹 "
否则,它将显示来自 `python --version` 的版本号,并显示当前的 Python 虚拟环境,如果激活了的话。
此组件将在符合以下任意条件之一时显示:
此组件只有满足以下条件之一时才会被显示:
- 当前目录包含 `.python-version` 文件
- 当前目录包含 `requirements.txt` 文件
@@ -930,7 +984,7 @@ pyenv_prefix = "foo "
## Ruby
`ruby` 组件显示当前安装的 Ruby 版本。 此组件将在符合以下任意条件之一时显示:
`ruby` 组件显示当前安装的 Ruby 版本。 此组件只有满足以下条件之一时才会被显示:
- 当前目录包含 `Gemfile` 文件
- 当前目录包含 `.rb` 文件
@@ -954,7 +1008,7 @@ symbol = "🔺 "
## Rust
`rust` 组件显示当前安装的 Rust 版本。 此组件将在符合以下任意条件时显示:
`rust` 组件显示当前安装的 Rust 版本。 此组件只有满足以下条件之一时才会被显示:
- 当前目录包含 `Cargo.toml` 文件
- 当前目录包含一个使用 `.rs` 扩展名的文件
@@ -978,7 +1032,7 @@ symbol = "⚙️ "
## Terraform
`terraform` 组件显示当前选定的 terraform 工作区和版本。 默认情况下不会显示 terraform 版本,因为当使用大量插件时,当前版本 terraform 查询版本号很慢。 此组件将在符合以下任意条件时显示:
`terraform` 组件显示当前选定的 terraform 工作区和版本。 默认情况下不会显示 terraform 版本,因为当使用大量插件时,当前版本 terraform 查询版本号很慢。 此组件只有满足以下条件之一时才会被显示:
- 当前目录包含 `.terraform` 目录
- 当前目录包含一个使用 `.tf` 扩展名的文件
@@ -1036,7 +1090,7 @@ utc_time_offset = -5
## Username
`username` 组件显示当前活跃的用户名。 此组件将在符合以下任意条件时显示:
`username` 组件显示当前活跃的用户名。 此组件只有满足以下条件之一时才会被显示:
- 当前用户是 root
- 当前用户与登录用户不相同