keybindings.bash 507 B

12345678910111213141516
  1. # Use vi-bindings in readline for command editing
  2. set -o vi
  3. # Stop readline from auto-binding some control characters (e.g. ctrl-w) so that
  4. # they can be reassigned as desired.
  5. bind 'set bind-tty-special-chars off'
  6. # Set Ctrl-w to delete by word boundaries instead of to the previous space.
  7. bind '\C-w:backward-kill-word'
  8. # Set Ctrl-l to clear the screen.
  9. bind '\C-l:clear-screen'
  10. # Search history for the current input string.
  11. bind '"\e[A":history-search-backward'
  12. bind '"\e[B":history-search-forward'