Skip to content

Commit

Permalink
remove redundant if
Browse files Browse the repository at this point in the history
  • Loading branch information
IlanCosman committed Jan 5, 2024
1 parent ceb2fc8 commit f798c2a
Showing 1 changed file with 7 additions and 9 deletions.
16 changes: 7 additions & 9 deletions functions/fish_prompt.fish
Original file line number Diff line number Diff line change
Expand Up @@ -151,15 +151,13 @@ end"

if test "$tide_prompt_transient_enabled" = true
function _tide_enter_transient
# If the commandline will be executed, or is empty
if commandline --is-valid || test -z "$(commandline)"
# Pager open usually means selecting, not running
# Can be untrue, but it's better than the alternative
if not commandline --paging-mode
set -g _tide_transient
set -g _tide_repaint
commandline -f repaint
end
# If the commandline will be executed or is empty, and the pager is not open
# Pager open usually means selecting, not running
# Can be untrue, but it's better than the alternative
if commandline --is-valid || test -z "$(commandline)" && not commandline --paging-mode
set -g _tide_transient
set -g _tide_repaint
commandline -f repaint
end
commandline -f execute
end
Expand Down

0 comments on commit f798c2a

Please sign in to comment.