LinuxCommandLibrary

starship

Customize terminal prompt

TLDR

Print the starship integration code for the specified shell

$ starship init [bash|elvish|fish|ion|powershell|tcsh|zsh|nu|xonsh|cmd]
copy

Explain each part of the current prompt and show the time taken to render them
$ starship explain
copy

Print the computed starship configuration (use --default to print default configuration instead)
$ starship print-config
copy

List supported modules
$ starship module --list
copy

Edit the starship configuration in the default editor
$ starship configure
copy

Create a bug report GitHub issue pre-populated with information about the system and starship configuration
$ starship bug-report
copy

Print the completion script for the specified shell
$ starship completions [bash|elvish|fish|powershell|zsh]
copy

Display help for a subcommand
$ starship [subcommand] --help
copy

SYNOPSIS

No direct command execution. Configure via config file (starship.toml) and shell configuration.

PARAMETERS

N/A
    Starship is configured via a `starship.toml` configuration file. Parameters are set within this file to customize prompt behavior. Consult the starship documentation for specific config parameters for each module.

DESCRIPTION

Starship is a minimal, blazing-fast, and infinitely customizable prompt for any shell!

It's designed to provide you with all the information you need in a glance, adapting dynamically to the context of your current directory. Starship supports major shells like Bash, Zsh, Fish, Nu, and more.

Its highly customizable nature allows users to tailor the prompt to their specific needs and preferences through a simple configuration file.

Modules for various languages, frameworks, and tools can be enabled or disabled, controlling exactly what information is displayed in the prompt, creating a personalized experience.

Starship aims to enhance productivity by delivering crucial information about the working environment directly in the terminal prompt.

CAVEATS

Starship relies on external tools and environments for its module functionality. Performance may vary depending on system resources and configured modules.

Proper configuration of your shell is required to load and display the Starship prompt.

Complex configurations can increase prompt rendering time, although Starship is designed to be very fast.

CONFIGURATION

The main configuration file is usually located at `$HOME/.config/starship.toml` or `$XDG_CONFIG_HOME/starship.toml`. You can edit this file to customize the prompt.

MODULES

Starship uses modules to display information. These include modules for git status, programming language versions, package managers, and more. Enable/Disable modules within the config file.

ENVIRONMENT VARIABLES

Starship respects environment variables such as `$HOME`, `$PWD`, and shell-specific variables like `$VIRTUAL_ENV` or `$CONDA_DEFAULT_ENV`.

These are often used within modules to provide context-aware information.

HISTORY

Starship was created to address the limitations of other prompt customization tools, aiming for speed, simplicity, and extensibility. It gained popularity due to its ease of use and cross-shell compatibility. The project is actively maintained and has a vibrant community contributing modules and improvements.

SEE ALSO

bash(1), zsh(1), fish(1), nu(1)

Copied to clipboard