端末でこのようなコマンドを実行すると、
$ tyop --count 3 --exact haveibeenpwned
このコマンドは、次のエラーコードを返します。
command not found: tyop
、
コマンドライン引数を--count 3 --exact haveibeenpwned
別のコマンド名(たとえばtypo
代わりにtyop
)に保ちながら最後のコマンドを再実行するにはどうすればよいですか?
$ typo --count 3 --exact haveibeenpwned
!!
可能であれば、またはなどのショートカットキーまたはシェル機能を探しています!^
。
ベストアンサー1
typo !*
~からman bash
:
Word Designators
Word designators are used to select desired words from the event. A :
separates the event specification from the word designator. It may be
omitted if the word designator begins with a ^, $, *, -, or %. Words
are numbered from the beginning of the line, with the first word being
denoted by 0 (zero). Words are inserted into the current line
separated by single spaces.
* All of the words but the zeroth. This is a synonym for `1-$'.
It is not an error to use * if there is just one word in the
event; the empty string is returned in that case.