mirror of
https://github.com/fish-shell/fish-shell.git
synced 2026-05-28 01:11:15 -03:00
Use new set_color features for __fish_cancel_commandline
We still apparently need to rely on tput for 'el'.
This commit is contained in:
@@ -9,8 +9,8 @@ function __fish_cancel_commandline
|
||||
#
|
||||
# Set reverse fg/bg color mode, output ^C, restore normal mode, clear to EOL (to erase any
|
||||
# autosuggestion).
|
||||
if command -v tput >/dev/null
|
||||
echo -ns (tput smso; or tput so) "^C" (tput rmso; or tput se) (tput el; or tput ce)
|
||||
if command -sq tput
|
||||
echo -ns (set_color -r) "^C" (set_color normal) (tput el; or tput ce)
|
||||
else
|
||||
echo -n "^C"
|
||||
end
|
||||
|
||||
Reference in New Issue
Block a user