2019-09-11 00:31:08 +00:00
|
|
|
function fish_prompt
|
|
|
|
switch "$fish_key_bindings"
|
|
|
|
case fish_hybrid_key_bindings fish_vi_key_bindings
|
|
|
|
set keymap "$fish_bind_mode"
|
|
|
|
case '*'
|
|
|
|
set keymap insert
|
|
|
|
end
|
|
|
|
set -l exit_code $status
|
|
|
|
# Account for changes in variable name between v2.7 and v3.0
|
|
|
|
set -l CMD_DURATION "$CMD_DURATION$cmd_duration"
|
2019-09-24 19:03:10 +00:00
|
|
|
set -l starship_duration_ns {$CMD_DURATION}000000
|
|
|
|
::STARSHIP:: prompt --status=$exit_code --keymap=$keymap --cmd-duration=$starship_duration_ns --jobs=(count (jobs -p))
|
2019-09-11 00:31:08 +00:00
|
|
|
end
|
|
|
|
function fish_mode_prompt; end
|
|
|
|
export STARSHIP_SHELL="fish"
|