When it appears
It renders when Starship detects the matching context and its configured conditions are met.
Preview
Rendered from the starting configuration in a representative simulated environment.
starship — preview
took 9s
Starting configuration
[cmd_duration]
format = "took [$duration]($style) "
style = "yellow bold"Open in the builderThe configuration is compressed into the URL fragment and stays in your browser.
Key options
- min_timenumber
- Shortest duration to show time for (in milliseconds).
- formatstring
- The format for the module.
- stylestring
- The style for the module.
- show_millisecondsboolean
- Show milliseconds in addition to seconds for the duration.
- disabledboolean
- Disables the cmd_duration module.
- show_notificationsboolean
- Show desktop notifications when command completes.
- min_time_to_notifynumber
- Shortest duration for notification (in milliseconds).
- notification_timeoutnumber
- Duration to show notification for (in milliseconds). If unset, notification timeout will be determined by daemon. Not all notification daemons honor this option.
Format variables
- $duration
- The time it took to execute the command
- $style
- Mirrors the value of option style
Common adjustments
- Edit format to reorder its variables or make surrounding text conditional.
- Adjust its style options to fit the palette used by the rest of the prompt.