TIL

I know some of these, but most are new to me:

  • ESC-A ESC-a executes the current line, but retains it in the buffer (accept-and-hold)
  • ESC-B ESC-b to move backward one word (backward-word)
  • ESC-C ESC-c to capitalize the current word (capitalize-word)
  • ESC-D ESC-d to kill/erase the current word (kill-word)
  • ESC-E ESC-e unused
  • ESC-F ESC-f to move forward one word (forward-word)
  • ESC-G ESC-g recalls the top line off the buffer stack (get-line)
  • ESC-H ESC-h runs man on the current command (run-help)
  • ESC-I ESC-i unused
  • ESC-J ESC-j unused
  • ESC-K ESC-k unused
  • ESC-L ESC-l to lowercase the current word (down-case-word)
  • ESC-M ESC-m unused
  • ESC-N ESC-n (history-seach-forward)
  • ESC-O ESC-o unused
  • ESC-P ESC-p (history-seach-backward)
  • ESC-Q ESC-q(and^q) clears and pushes the current buffer into the buffer stack (push-line`)
    after executing a command, the old buffer will be loaded in the editing buffer
  • ESC-R ESC-r unused
  • ESC-S ESC-s ESC-$ fixes spelling in the current word (spell-word)
  • ESC-T ESC-t swap the cursor word with the one before it (transpose-words)
  • ESC-U ESC-u to uppercase the current word (up-case-word)
  • ESC-V ESC-v unused
  • ESC-W ESC-w copy the area from cursor to the mark to the kill buffer (copy-region-as-kill)
  • ESC-x prompts you to write a zle command to execute (execute-named-cmd)
  • ESC-y removes the yanked text, and yank the new top (yank-pop)
  • ESC-Z ESC-z reruns the last function ran via execute-named-cmd (execute-last-named-cmd)
  • ESC-' to quote the current line (quote-line)
    puts a ' at the beginning and end of the current command, and escape all current ' characters within the command
  • ESC-" escape everything from the cursor to the mark (quote-region)
    similar to above, but instead of quoting the whole command, it goes from the cursor to the current mark (set via set-mark-command, ^@)
  • ESC-? runs which on the current command (which-command)

Source:

  • [1] `man zshall`
zsh