mirror of
https://github.com/fish-shell/fish-shell
synced 2024-12-25 04:13:08 +00:00
Fix last status report (it's always 0)
It seems something is overwriting the status before it is saved to a variable. Fixed by setting the last_status variable at the very beginning.
This commit is contained in:
parent
e26f7aacc4
commit
2d42baac35
1 changed files with 2 additions and 2 deletions
|
@ -4,6 +4,8 @@
|
|||
|
||||
|
||||
function fish_prompt --description 'Write out the prompt'
|
||||
set -l last_status $status
|
||||
|
||||
if not set -q __fish_git_prompt_show_informative_status
|
||||
set -g __fish_git_prompt_show_informative_status 1
|
||||
end
|
||||
|
@ -59,8 +61,6 @@ function fish_prompt --description 'Write out the prompt'
|
|||
set -g __fish_git_prompt_color_cleanstate green --bold
|
||||
end
|
||||
|
||||
set -l last_status $status
|
||||
|
||||
if not set -q __fish_prompt_normal
|
||||
set -g __fish_prompt_normal (set_color normal)
|
||||
end
|
||||
|
|
Loading…
Reference in a new issue