mirror of
https://github.com/fish-shell/fish-shell
synced 2024-12-27 05:13:10 +00:00
Remove vi mode indicator from classic_git prompt
It is duplicative of the fish_mode_prompt function Fixes #2228
This commit is contained in:
parent
34faf7638e
commit
2b87705a46
1 changed files with 1 additions and 23 deletions
|
@ -69,27 +69,5 @@ function fish_prompt --description 'Write out the prompt'
|
|||
set prompt_status ' ' (set_color $fish_color_status) "[$last_status]" "$normal"
|
||||
end
|
||||
|
||||
set -l mode_str
|
||||
switch "$fish_key_bindings"
|
||||
case '*_vi_*' '*_vi'
|
||||
# possibly fish_vi_key_bindings, or custom key bindings
|
||||
# that includes the name "vi"
|
||||
set mode_str (
|
||||
echo -n " "
|
||||
switch $fish_bind_mode
|
||||
case default
|
||||
set_color --bold --background red white
|
||||
echo -n "[N]"
|
||||
case insert
|
||||
set_color --bold green
|
||||
echo -n "[I]"
|
||||
case visual
|
||||
set_color --bold magenta
|
||||
echo -n "[V]"
|
||||
end
|
||||
set_color normal
|
||||
)
|
||||
end
|
||||
|
||||
echo -n -s (set_color $fish_color_user) "$USER" $normal @ (set_color $fish_color_host) "$__fish_prompt_hostname" $normal ' ' (set_color $color_cwd) (prompt_pwd) $normal (__fish_git_prompt) $normal $prompt_status "$mode_str" "> "
|
||||
echo -n -s (set_color $fish_color_user) "$USER" $normal @ (set_color $fish_color_host) "$__fish_prompt_hostname" $normal ' ' (set_color $color_cwd) (prompt_pwd) $normal (__fish_git_prompt) $normal $prompt_status "> "
|
||||
end
|
||||
|
|
Loading…
Reference in a new issue