📄 rluser.texinfo
字号:
before point with a space.By default, this command is unbound.@end ftable@node Commands For Killing@subsection Killing And Yanking@ftable @code@item kill-line (C-k)Kill the text from point to the end of the line.@item backward-kill-line (C-x Rubout)Kill backward to the beginning of the line.@item unix-line-discard (C-u)Kill backward from the cursor to the beginning of the current line.@item kill-whole-line ()Kill all characters on the current line, no matter where point is.By default, this is unbound.@item kill-word (M-d)Kill from point to the end of the current word, or if betweenwords, to the end of the next word.Word boundaries are the same as @code{forward-word}.@item backward-kill-word (M-@key{DEL})Kill the word behind point.Word boundaries are the same as @code{backward-word}.@item unix-word-rubout (C-w)Kill the word behind point, using white space as a word boundary.The killed text is saved on the kill-ring.@item delete-horizontal-space ()Delete all spaces and tabs around point. By default, this is unbound.@item kill-region ()Kill the text in the current region.By default, this command is unbound.@item copy-region-as-kill ()Copy the text in the region to the kill buffer, so it can be yankedright away. By default, this command is unbound.@item copy-backward-word ()Copy the word before point to the kill buffer.The word boundaries are the same as @code{backward-word}.By default, this command is unbound.@item copy-forward-word ()Copy the word following point to the kill buffer.The word boundaries are the same as @code{forward-word}.By default, this command is unbound.@item yank (C-y)Yank the top of the kill ring into the buffer at point.@item yank-pop (M-y)Rotate the kill-ring, and yank the new top. You can only do this ifthe prior command is @code{yank} or @code{yank-pop}.@end ftable@node Numeric Arguments@subsection Specifying Numeric Arguments@ftable @code@item digit-argument (@kbd{M-0}, @kbd{M-1}, @dots{} @kbd{M--})Add this digit to the argument already accumulating, or start a newargument. @kbd{M--} starts a negative argument.@item universal-argument ()This is another way to specify an argument.If this command is followed by one or more digits, optionally with aleading minus sign, those digits define the argument.If the command is followed by digits, executing @code{universal-argument}again ends the numeric argument, but is otherwise ignored.As a special case, if this command is immediately followed by acharacter that is neither a digit or minus sign, the argument countfor the next command is multiplied by four.The argument count is initially one, so executing this function thefirst time makes the argument count four, a second time makes theargument count sixteen, and so on.By default, this is not bound to a key.@end ftable@node Commands For Completion@subsection Letting Readline Type For You@ftable @code@item complete (@key{TAB})Attempt to perform completion on the text before point.The actual completion performed is application-specific.@ifset BashFeaturesBash attempts completion treating the text as a variable (if thetext begins with @samp{$}), username (if the text begins with@samp{~}), hostname (if the text begins with @samp{@@}), orcommand (including aliases and functions) in turn. If none of these produces a match, filename completion is attempted.@end ifset@ifclear BashFeaturesThe default is filename completion.@end ifclear@item possible-completions (M-?)List the possible completions of the text before point.@item insert-completions (M-*)Insert all completions of the text before point that would havebeen generated by @code{possible-completions}.@item menu-complete ()Similar to @code{complete}, but replaces the word to be completedwith a single match from the list of possible completions.Repeated execution of @code{menu-complete} steps through the listof possible completions, inserting each match in turn.At the end of the list of completions, the bell is rung(subject to the setting of @code{bell-style})and the original text is restored.An argument of @var{n} moves @var{n} positions forward in the listof matches; a negative argument may be used to move backwardthrough the list.This command is intended to be bound to @key{TAB}, but is unboundby default.@item delete-char-or-list ()Deletes the character under the cursor if not at the beginning orend of the line (like @code{delete-char}).If at the end of the line, behaves identically to@code{possible-completions}.This command is unbound by default.@ifset BashFeatures@item complete-filename (M-/)Attempt filename completion on the text before point.@item possible-filename-completions (C-x /)List the possible completions of the text before point,treating it as a filename.@item complete-username (M-~)Attempt completion on the text before point, treatingit as a username.@item possible-username-completions (C-x ~)List the possible completions of the text before point,treating it as a username.@item complete-variable (M-$)Attempt completion on the text before point, treatingit as a shell variable.@item possible-variable-completions (C-x $)List the possible completions of the text before point,treating it as a shell variable.@item complete-hostname (M-@@)Attempt completion on the text before point, treatingit as a hostname.@item possible-hostname-completions (C-x @@)List the possible completions of the text before point,treating it as a hostname.@item complete-command (M-!)Attempt completion on the text before point, treatingit as a command name. Command completion attempts tomatch the text against aliases, reserved words, shellfunctions, shell builtins, and finally executable filenames,in that order.@item possible-command-completions (C-x !)List the possible completions of the text before point,treating it as a command name.@item dynamic-complete-history (M-@key{TAB})Attempt completion on the text before point, comparingthe text against lines from the history list for possiblecompletion matches.@item complete-into-braces (M-@{)Perform filename completion and insert the list of possible completionsenclosed within braces so the list is available to the shell(@pxref{Brace Expansion}).@end ifset@end ftable@node Keyboard Macros@subsection Keyboard Macros@ftable @code@item start-kbd-macro (C-x ()Begin saving the characters typed into the current keyboard macro.@item end-kbd-macro (C-x ))Stop saving the characters typed into the current keyboard macroand save the definition.@item call-last-kbd-macro (C-x e)Re-execute the last keyboard macro defined, by making the charactersin the macro appear as if typed at the keyboard.@end ftable@node Miscellaneous Commands@subsection Some Miscellaneous Commands@ftable @code@item re-read-init-file (C-x C-r)Read in the contents of the @var{inputrc} file, and incorporateany bindings or variable assignments found there.@item abort (C-g)Abort the current editing command andring the terminal's bell (subject to the setting of@code{bell-style}).@item do-uppercase-version (M-a, M-b, M-@var{x}, @dots{})If the metafied character @var{x} is lowercase, run the commandthat is bound to the corresponding uppercase character.@item prefix-meta (@key{ESC})Metafy the next character typed. This is for keyboardswithout a meta key. Typing @samp{@key{ESC} f} is equivalent to typing@kbd{M-f}.@item undo (C-_ or C-x C-u)Incremental undo, separately remembered for each line.@item revert-line (M-r)Undo all changes made to this line. This is like executing the @code{undo}command enough times to get back to the beginning.@ifset BashFeatures@item tilde-expand (M-&)@end ifset@ifclear BashFeatures@item tilde-expand (M-~)@end ifclearPerform tilde expansion on the current word.@item set-mark (C-@@)Set the mark to the point. If anumeric argument is supplied, the mark is set to that position.@item exchange-point-and-mark (C-x C-x)Swap the point with the mark. The current cursor position is set tothe saved position, and the old cursor position is saved as the mark.@item character-search (C-])A character is read and point is moved to the next occurrence of thatcharacter. A negative count searches for previous occurrences.@item character-search-backward (M-C-])A character is read and point is moved to the previous occurrenceof that character. A negative count searches for subsequentoccurrences.@item insert-comment (M-#)Without a numeric argument, the value of the @code{comment-begin}variable is inserted at the beginning of the current line.If a numeric argument is supplied, this command acts as a toggle: ifthe characters at the beginning of the line do not match the valueof @code{comment-begin}, the value is inserted, otherwisethe characters in @code{comment-begin} are deleted from the beginning ofthe line.In either case, the line is accepted as if a newline had been typed.@ifset BashFeaturesThe default value of @code{comment-begin} causes this commandto make the current line a shell comment.If a numeric argument causes the comment character to be removed, the linewill be executed by the shell.@end ifset@item dump-functions ()Print all of the functions and their key bindings to theReadline output stream. If a numeric argument is supplied,the output is formatted in such a way that it can be made partof an @var{inputrc} file. This command is unbound by default.@item dump-variables ()Print all of the settable variables and their values to theReadline output stream. If a numeric argument is supplied,the output is formatted in such a way that it can be made partof an @var{inputrc} file. This command is unbound by default.@item dump-macros ()Print all of the Readline key sequences bound to macros and thestrings they output. If a numeric argument is supplied,the output is formatted in such a way that it can be made partof an @var{inputrc} file. This command is unbound by default.@ifset BashFeatures@item glob-complete-word (M-g)The word before point is treated as a pattern for pathname expansion,with an asterisk implicitly appended. This pattern is used togenerate a list of matching file names for possible completions.@item glob-expand-word (C-x *)The word before point is treated as a pattern for pathname expansion,and the list of matching file names is inserted, replacing the word.If a numeric argument is supplied, a @samp{*} is appended beforepathname expansion.@item glob-list-expansions (C-x g)The list of expansions that would have been generated by@code{glob-expand-word} is displayed, and the line is redrawn.If a numeric argument is supplied, a @samp{*} is appended beforepathname expansion.@item display-shell-version (C-x C-v)Display version information about the current instance of Bash.@item shell-expand-line (M-C-e)Expand the line as the shell does.This performs alias and history expansion as well as all of the shellword expansions (@pxref{Shell Expansions}).@item history-expand-line (M-^)Perform history expansion on the current line.@item magic-space ()Perform history expansion on the current line and insert a space(@pxref{History Interaction}).@item alias-expand-line ()Perform alias expansion on the current line (@pxref{Aliases}).@item history-and-alias-expand-line ()Perform history and alias expansion on the current line.@item insert-last-argument (M-. or M-_)A synonym for @code{yank-last-arg}.@item operate-and-get-next (C-o)Accept the current line for execution and fetch the next linerelative to the current line from the history for editing. Anyargument is ignored.@item edit-and-execute-command (C-xC-e)Invoke an editor on the current command line, and execute the result as shellcommands.Bash attempts to invoke@code{$FCEDIT}, @code{$EDITOR}, and @code{emacs}as the editor, in that order.@end ifset@ifclear BashFeatures@item emacs-editing-mode (C-e)When in @code{vi} command mode, this causes a switch to @code{emacs}editing mode.@item vi-editing-mode (M-C-j)When in @code{emacs} editing mode, this causes a switch to @code{vi}editing mode.
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -