My shell prompt used to be a small festival. Two lines, a git status segment that recomputed the world on every keystroke, the time, the battery, a little icon for the language runtime, the exit code of the last command rendered as a sad face. It looked great in a screenshot and told me almost nothing I acted on.
The question I finally asked: which of these have I ever actually changed my behaviour because of? Not "which is nice to know", which is everything. Which one made me stop and do something different. The list was short.
The exit code, yes, but only when it's non-zero, and only the number. A red dot and the actual code so I know whether it was a 1 or a 137 (the latter meaning something got OOM-killed, which is a very different afternoon). The git branch, because I have absolutely committed to the wrong one. And, crucially, whether I'm on a remote host, because I have absolutely run the right command on the wrong machine.
So I rebuilt it in starship and threw out the rest. The config is mostly subtraction. I disabled the battery module, the time, the per-language version segments. I kept the directory, a compact git branch and dirty indicator, the exit status (shown only on failure), and a hostname segment that only appears when SSH_CONNECTION is set. That last one is the single best change: my prompt is plain at home and grows a hostname the instant I'm somewhere I could do damage. The visual difference is enough that I notice before my fingers do something regrettable.
[hostname]
ssh_only = true
format = "[$hostname](bold red) "
[status]
disabled = false
format = "[$int]($style) "
[cmd_duration]
min_time = 2000
format = "[$duration](dimmed) "
The cmd_duration one snuck back in and earned its place: it only shows up when a command took more than two seconds, which is exactly when I want to know, and silent otherwise. The signal appears precisely when it's useful and stays out of the way the rest of the time. That's the whole principle, really.
A prompt is a heads-up display. The job of a heads-up display is not to show you everything, it's to show you the few things that change what you do next, and to disappear when they're nominal. Mine is quieter now and I read it more, because there's less to read. Turns out the most useful prompt segment is the one that's blank most of the time.