465 lines
7.4 KiB
Markdown
465 lines
7.4 KiB
Markdown
# Prasetel (Presets)
|
|
|
|
Berikut ini adalah koleksi konfigurasi prasetel dari kumpulan komunita Starship. Jika kamu punya konfigurasi prasetel untuk dibagikan, silakan [kirim PR](https://github.com/starship/starship/edit/master/docs/presets/README.md) untuk memperbarui file ini! 😊
|
|
|
|
## Simbol Nerd Font
|
|
|
|
Konfigurasi prasetel berikut tidak mengubah apapun selain simbol yang digunakan untuk masing-masing modulnya. Kalau kamu enggak suka dengan emoji, hal ini mungkin bisa menarik perhatianmu!
|
|
|
|
![Tangkapan Layar dari preset simbol Nerd Font](/presets/nerd-font-symbols.png)
|
|
|
|
### Prasyarat
|
|
|
|
- Nerd Font yang terpasang dan telah diaktifkan di dalam terminal (contoh berikut menggunakan Nerd Font Fira Code)
|
|
|
|
### Konfigurasi
|
|
|
|
```toml
|
|
[aws]
|
|
symbol = " "
|
|
|
|
[conda]
|
|
symbol = " "
|
|
|
|
[dart]
|
|
symbol = " "
|
|
|
|
[directory]
|
|
read_only = " "
|
|
|
|
[docker_context]
|
|
symbol = " "
|
|
|
|
[elixir]
|
|
symbol = " "
|
|
|
|
[elm]
|
|
symbol = " "
|
|
|
|
[git_branch]
|
|
symbol = " "
|
|
|
|
[golang]
|
|
symbol = " "
|
|
|
|
[hg_branch]
|
|
symbol = " "
|
|
|
|
[java]
|
|
symbol = " "
|
|
|
|
[julia]
|
|
symbol = " "
|
|
|
|
[memory_usage]
|
|
symbol = " "
|
|
|
|
[nim]
|
|
symbol = " "
|
|
|
|
[nix_shell]
|
|
symbol = " "
|
|
|
|
[package]
|
|
symbol = " "
|
|
|
|
[perl]
|
|
symbol = " "
|
|
|
|
[php]
|
|
symbol = " "
|
|
|
|
[python]
|
|
symbol = " "
|
|
|
|
[ruby]
|
|
symbol = " "
|
|
|
|
[rust]
|
|
symbol = " "
|
|
|
|
[scala]
|
|
symbol = " "
|
|
|
|
[shlvl]
|
|
symbol = " "
|
|
|
|
[swift]
|
|
symbol = "ﯣ "
|
|
```
|
|
|
|
## Segmen Berkurung
|
|
|
|
Konfigurasi prasetel berikut mengubah format dari seluruh modul bawaan untuk menampilkan segmennya di dalam tanda kurung daripada menggunakan susunan kata bawaan Starship ("via", "on", dll.).
|
|
|
|
Sebelum:
|
|
|
|
![Tangkapan Layar dari konfigurasi bawaan Starship](/presets/bracketed-segments-before.png)
|
|
|
|
Sesudah:
|
|
|
|
![Tangkapan Layar dari Segmen Berkurung](/presets/bracketed-segments-after.png)
|
|
|
|
### Konfigurasi
|
|
|
|
```toml
|
|
[aws]
|
|
format = '\[[$symbol($profile)(\($region\))(\[$duration\])]($style)\]'
|
|
|
|
[cmake]
|
|
format = '\[[$symbol($version)]($style)\]'
|
|
|
|
[cmd_duration]
|
|
format = '\[[⏱ $duration ]($style)\]'
|
|
|
|
[cobol]
|
|
format = '\[[$symbol($version)]($style)\]'
|
|
|
|
[conda]
|
|
format = '\[[$symbol$environment]($style)\]'
|
|
|
|
[crystal]
|
|
format = '\[[$symbol($version)]($style)\]'
|
|
|
|
[dart]
|
|
format = '\[[$symbol($version)]($style)\]'
|
|
|
|
[deno]
|
|
format = '\[[$symbol($version)]($style)\]'
|
|
|
|
[docker_context]
|
|
format = '\[[$symbol$context]($style)\]'
|
|
|
|
[dotnet]
|
|
format = '\[[$symbol($version)(🎯 $tfm)]($style)\]'
|
|
|
|
[elixir]
|
|
format = '\[[$symbol($version \(OTP $otp_version\))]($style)\]'
|
|
|
|
[elm]
|
|
format = '\[[$symbol($version)]($style)\]'
|
|
|
|
[erlang]
|
|
format = '\[[$symbol($version)]($style)\]'
|
|
|
|
[gcloud]
|
|
format = '\[[$symbol$account(@$domain)(\($region\))]($style)\]'
|
|
|
|
[git_branch]
|
|
format = '\[[$symbol$branch]($style)\]'
|
|
|
|
[git_status]
|
|
format = '([\[$all_status$ahead_behind\]]($style))'
|
|
|
|
[golang]
|
|
format = '\[[$symbol($version)]($style)\]'
|
|
|
|
[helm]
|
|
format = '\[[$symbol($version)]($style)\]'
|
|
|
|
[hg_branch]
|
|
format = '\[[$symbol$branch]($style)\]'
|
|
|
|
[java]
|
|
format = '\[[$symbol($version)]($style)\]'
|
|
|
|
[julia]
|
|
format = '\[[$symbol($version)]($style)\]'
|
|
|
|
[kotlin]
|
|
format = '\[[$symbol($version)]($style)\]'
|
|
|
|
[kubernetes]
|
|
format = '\[[$symbol$context( \($namespace\))]($style)\]'
|
|
|
|
[lua]
|
|
format = '\[[$symbol($version)]($style)\]'
|
|
|
|
[memory_usage]
|
|
format = '\[$symbol[$ram( | $swap)]($style)\]'
|
|
|
|
[nim]
|
|
format = '\[[$symbol($version)]($style)\]'
|
|
|
|
[nix_shell]
|
|
format = '\[[$symbol$state( \($name\))]($style)\]'
|
|
|
|
[nodejs]
|
|
format = '\[[$symbol($version)]($style)\]'
|
|
|
|
[ocaml]
|
|
format = '\[[$symbol($version)(\($switch_indicator$switch_name\))]($style)\]'
|
|
|
|
[openstack]
|
|
format = '\[[$symbol$cloud(\($project\))]($style)\]'
|
|
|
|
[package]
|
|
format = '\[[$symbol$version]($style)\]'
|
|
|
|
[perl]
|
|
format = '\[[$symbol($version)]($style)\]'
|
|
|
|
[php]
|
|
format = '\[[$symbol($version)]($style)\]'
|
|
|
|
[purescript]
|
|
format = '\[[$symbol($version)]($style)\]'
|
|
|
|
[python]
|
|
format = '\[[${symbol}${pyenv_prefix}(${version})(\($virtualenv\))]($style)\]'
|
|
|
|
[red]
|
|
format = '\[[$symbol($version)]($style)\]'
|
|
|
|
[ruby]
|
|
format = '\[[$symbol($version)]($style)\]'
|
|
|
|
[rust]
|
|
format = '\[[$symbol($version)]($style)\]'
|
|
|
|
[scala]
|
|
format = '\[[$symbol($version)]($style)\]'
|
|
|
|
[swift]
|
|
format = '\[[$symbol($version)]($style)\]'
|
|
|
|
[terraform]
|
|
format = '\[[$symbol$workspace]($style)\]'
|
|
|
|
[time]
|
|
format = '\[[$time]($style)\]'
|
|
|
|
[username]
|
|
format = '\[[$user]($style)\]'
|
|
|
|
[vagrant]
|
|
format = '\[[$symbol($version)]($style)\]'
|
|
|
|
[vlang]
|
|
format = '\[[$symbol($version)]($style)\]'
|
|
|
|
[zig]
|
|
format = '\[[$symbol($version)]($style)\]'
|
|
```
|
|
|
|
## Simbol Teks Sederhana
|
|
|
|
Konfigurasi prasetel berikut mengubah simbol menjadi teks sederhana. Jika terminal atau font kamu tidak mampu me-render Nerd Font atau emoji, mungkin kamu bisa mencoba konfigurasi prasetel berikut!
|
|
|
|
Sebelum (aturan bawaan dengan menggunakan font Fixedys):
|
|
|
|
![Tangkapan Layar dari konfigurasi bawaan Starship dengan Font Fixedsys](/presets/plain-text-symbols-before.png)
|
|
|
|
Sesudah (Simbol Teks Sederhana):
|
|
|
|
![Tangkapan Layar dari preset Simbol Teks Sederhana](/presets/plain-text-symbols-after.png)
|
|
|
|
### Konfigurasi
|
|
|
|
```toml
|
|
[character]
|
|
success_symbol = "[>](bold green)"
|
|
error_symbol = "[x](bold red)"
|
|
vicmd_symbol = "[<](bold green)"
|
|
|
|
[git_commit]
|
|
tag_symbol = " tag "
|
|
|
|
[git_status]
|
|
ahead = ">"
|
|
behind = "<"
|
|
diverged = "<>"
|
|
renamed = "r"
|
|
deleted = "x"
|
|
|
|
[aws]
|
|
symbol = "aws "
|
|
|
|
[cobol]
|
|
symbol = "cobol "
|
|
|
|
[conda]
|
|
symbol = "conda "
|
|
|
|
[crystal]
|
|
symbol = "cr "
|
|
|
|
[cmake]
|
|
symbol = "cmake "
|
|
|
|
[dart]
|
|
symbol = "dart "
|
|
|
|
[deno]
|
|
symbol = "deno "
|
|
|
|
[dotnet]
|
|
symbol = ".NET "
|
|
|
|
[directory]
|
|
read_only = " ro"
|
|
|
|
[docker_context]
|
|
symbol = "docker "
|
|
|
|
[elixir]
|
|
symbol = "exs "
|
|
|
|
[elm]
|
|
symbol = "elm "
|
|
|
|
[git_branch]
|
|
symbol = "git "
|
|
|
|
[golang]
|
|
symbol = "go "
|
|
|
|
[hg_branch]
|
|
symbol = "hg "
|
|
|
|
[java]
|
|
symbol = "java "
|
|
|
|
[julia]
|
|
symbol = "jl "
|
|
|
|
[kotlin]
|
|
symbol = "kt "
|
|
|
|
[nodejs]
|
|
symbol = "nodejs "
|
|
|
|
[memory_usage]
|
|
symbol = "memory "
|
|
|
|
[nim]
|
|
symbol = "nim "
|
|
|
|
[nix_shell]
|
|
symbol = "nix "
|
|
|
|
[ocaml]
|
|
symbol = "ml "
|
|
|
|
[package]
|
|
symbol = "pkg "
|
|
|
|
[perl]
|
|
symbol = "pl "
|
|
|
|
[php]
|
|
symbol = "php "
|
|
|
|
[purescript]
|
|
symbol = "purs "
|
|
|
|
[python]
|
|
symbol = "py "
|
|
|
|
[ruby]
|
|
symbol = "rb "
|
|
|
|
[rust]
|
|
symbol = "rs "
|
|
|
|
[scala]
|
|
symbol = "scala "
|
|
|
|
[swift]
|
|
symbol = "swift "
|
|
```
|
|
|
|
## Penyembunyian Versi Runtime
|
|
|
|
Konfigurasi prasetel berikut menyembunyikan versi language runtimes. Jika kamu bekerja di dalam kontainer atau environments virtual, preset berikut cocok untukmu!
|
|
|
|
![Tangkapan Layar dari preset Penyembunyian Versi Runtime](/presets/hide-runtime-versions.png)
|
|
|
|
### Konfigurasi
|
|
|
|
```toml
|
|
[cmake]
|
|
format = "via [$symbol]($style)"
|
|
|
|
[cobol]
|
|
format = "via [$symbol]($style)"
|
|
|
|
[crystal]
|
|
format = "via [$symbol]($style)"
|
|
|
|
[dart]
|
|
format = "via [$symbol]($style)"
|
|
|
|
[deno]
|
|
format = "via [$symbol]($style)"
|
|
|
|
[dotnet]
|
|
format = "[$symbol(🎯 $tfm )]($style)"
|
|
|
|
[elixir]
|
|
format = 'via [$symbol]($style)'
|
|
|
|
[elm]
|
|
format = 'via [$symbol]($style)'
|
|
|
|
[erlang]
|
|
format = 'via [$symbol]($style)'
|
|
|
|
[golang]
|
|
format = 'via [$symbol]($style)'
|
|
|
|
[helm]
|
|
format = 'via [$symbol]($style)'
|
|
|
|
[julia]
|
|
format = 'via [$symbol]($style)'
|
|
|
|
[kotlin]
|
|
format = 'via [$symbol]($style)'
|
|
|
|
[lua]
|
|
format = 'via [$symbol]($style)'
|
|
|
|
[nim]
|
|
format = 'via [$symbol]($style)'
|
|
|
|
[nodejs]
|
|
format = 'via [$symbol]($style)'
|
|
|
|
[ocaml]
|
|
format = 'via [$symbol(\($switch_indicator$switch_name\) )]($style)'
|
|
|
|
[perl]
|
|
format = 'via [$symbol]($style)'
|
|
|
|
[php]
|
|
format = 'via [$symbol]($style)'
|
|
|
|
[purescript]
|
|
format = 'via [$symbol]($style)'
|
|
|
|
[red]
|
|
format = 'via [$symbol]($style)'
|
|
|
|
[rlang]
|
|
format = 'via [$symbol]($style)'
|
|
|
|
[ruby]
|
|
format = 'via [$symbol]($style)'
|
|
|
|
[rust]
|
|
format = 'via [$symbol]($style)'
|
|
|
|
[swift]
|
|
format = 'via [$symbol]($style)'
|
|
|
|
[vagrant]
|
|
format = 'via [$symbol]($style)'
|
|
|
|
[vlang]
|
|
format = 'via [$symbol]($style)'
|
|
|
|
[zig]
|
|
format = 'via [$symbol]($style)'
|
|
```
|