/usr/bin/bash: Difference between revisions

Line 1,849: Line 1,849:


=== Event Designators ===
=== Event Designators ===
An event designator is a reference to a command line entry in the history list.  Unless the  reference is absolute, events are relative to the current position in the history list.
イベント・デジグネーターは、ヒストリーリスト内のコマンドラインエントリーの参照である。 参照が絶対的でない限り、イベントはヒストリーリストの現在の位置からの相対的なものである。
;!       
;!       
:Start a history substitution, except when followed by a blank, newline, carriage return, = or ( (when the extglob shell option is enabled using the shopt builtin).
:空白、改行、キャリッジリターン、=、または ( shopt 組み込み関数で extglob シェルオプションが有効になっている場合) が続く場合を除き、履歴置換を開始する。
;!n
;!n
:Refer to command line n.
:コマンドラインnを参照のこと。
;!-n
;!-n
:Refer to the current command minus n.
:現在のコマンドマイナスnを参照。
;!!
;!!
:Refer to the previous command.  This is a synonym for `!-1'.
:前のコマンドを参照のこと。 これは `!-1' と同意語である。
;!string
;!string
:Refer to the most recent command preceding the current position in the history list starting with string.
:文字列で始まる履歴リストで、現在の位置より前にある最新のコマンドを参照する。
;!?string<nowiki>[?]</nowiki>
;!?string<nowiki>[?]</nowiki>
:Refer  to  the most recent command preceding the current position in the history list containing string. The trailing ? may be omitted if string is followed immediately by a newline.  If string is missing, the string from the most recent search is used; it is an error if there is no previous search string.
:stringを含む履歴リストで、現在の位置より前にある最新のコマンドを参照する。 stringの直後に改行が続く場合、末尾の ? は省略できる。 stringがない場合、最新の検索文字列が使われる。以前の検索文字列がない場合はエラーとなる。
;^string1^string2^
;^string1^string2^
:Quick substitution.  Repeat the previous command, replacing string1 with string2.  Equivalent to ``!!:s^string1^string2^'' (see Modifiers below).
:素早く置換する。 文字列1を文字列2に置き換えて、前のコマンドを繰り返す。 (以下の[[#Modifiers|Modifiers ]]を参照のこと)。
;!#
;!#
:The entire command line typed so far.
:これまでに入力されたコマンドライン全体。


=== Word Designators ===
=== Word Designators ===