3 ms·
Do you know where I can find a list of hotkeys along the lines of C-a? I personally created my own hotkey (shift left arrow) but learning standard ones would pr
by xenophanes 16y ago
Do you know where I can find a list of hotkeys along the lines of C-a? I personally created my own hotkey (shift left arrow) but learning standard ones would probably be good.
- jrockway 16y agoIf you use bash, read the "Command Line Editing" section of "info readline".
- telemachos 16y agoYou can also tweak the behavior of readline (for Bash and other applications) and custom make your own key combinations by editing your ~/.inputrc file. A random example from mine: # Insert double quotes & set cursor between them "\C-x\"": "\"\"\eb" # # Insert single quotes & set cursor between them "\C-x'": "''\eb" See also the Bash manual: http://www.gnu.org/software/bash/manual/bashref.html#Command-Line-Editing http://www.gnu.org/software/bash/manual/bashref.html#Command...
- pyre 16y agoMost shells default to emacs keybindings: C-a beginning of line C-k kill text from cursor to end of line C-e end of line M-b move cursor backwards by a word M-f move cursor forwards by a word C-w delete backwards by a word C-h backspace (great when real backspace doesn't work) C-r reverse search through command history (C-w works in Vim(insert mode) and Emacs, but kills me when I try to type it in a browser window to delete a word... Good-bye window and/or tab) In zsh I actually have M-w bound to the normal backspace-by-a-word and C-w bound to the vim version which will do things like count '/' as a word separator so that I can easily backspace through sections of a path rather than be required to delete the whole thing (or nothing).
- xenophanes 16y agoHmm, FYI most of those work in the safari reply box. I think Apple put them for all Cocoa text fields not just terminal :-)
- uxp 16y ago> I think Apple put them for all Cocoa text fields not just terminal :-) It is the NSTextField that accepts those commands. The prefix NS stands for NeXTSTEP, so the functionality existed long before Cocoa.
- pyre 16y agoYea, but you have to hit Ctrl+Option or Cmd+Option (can't remember which off the top of my head) for Meta though, instead of just Option (which is what most people bind to Meta in Terminal.app or iTerm.app).
- BrandonM 16y ago> (C-w works in Vim(insert mode) and Emacs, but kills me when I try to type it in a browser window to delete a word... Good-bye window and/or tab) Control-Shift-T usually solves that problem for me in Firefox.