Shopt : Change bar on input.

This commit is contained in:
Dmitry Voronin 2024-03-27 01:54:59 +03:00
parent c606452ede
commit c3cebe75b4
2 changed files with 23 additions and 2 deletions

View file

@ -2,6 +2,27 @@ shopt -s dotglob
shopt -s globstar
shopt -s autocd
shopt -s extglob
set -o vi
#################### VIM ####################
# FOR MORE INFORMATION CHECK:
# https://wiki.archlinux.org/index.php/Readline
# TURN ON VIM (E.G. FOR READLINE)
bind 'set editing-mode vi'
# SHOW THE VIM MODE IN THE PROMPT (COMMAND OR INSERT)
bind 'set show-mode-in-prompt on'
# SET THE MODE STRING AND CURSOR TO INDICATE THE VIM MODE
# FOR THE NUMBER AFTER `\e[`:
# 0: blinking block
# 1: blinking block (default)
# 2: steady block
# 3: blinking underline
# 4: steady underline
# 5: blinking bar (xterm)
# 6: steady bar (xterm)
bind 'set vi-ins-mode-string \1\e[6 q\2'
bind 'set vi-cmd-mode-string \1\e[2 q\2'
exec {BASH_XTRACEFD}>/dev/null

View file

@ -20,5 +20,5 @@ function ww() {
watch -n 0 "${@}"
}
# autocomplete.
# Autocomplete.
complete -F _autocomplete_nested w ww