terminal:tools:starship
Table of Contents
starship
Cross-shell prompt. Replaces the bash PS1 with a fast, informative, customisable prompt. Written in Rust.
# initialise in ~/.bashrc: eval "$(starship init bash)"
What It Shows
By default (context-aware — only shown when relevant):
- Current directory
- Git branch and status (staged/unstaged/ahead/behind)
- Language version (Python, Node, Rust, Go — detected from project files)
- Command duration (for commands over ~2 seconds)
- Exit code of last command (on failure)
Configuration
Config: ~/.config/starship.toml
[character] success_symbol = "[➜](bold green)" error_symbol = "[➜](bold red)" [git_branch] symbol = " " [directory] truncation_length = 3
Full preset gallery: starship.rs/presets
Install
curl -sS https://starship.rs/install.sh | sh # then add to ~/.bashrc: eval "$(starship init bash)"
See Also
terminal/tools/starship.txt · Last modified: by 127.0.0.1
