0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 5 years have passed since last update.

fish shellで直前のコマンドの引数を参照する

Last updated at Posted at 2019-03-04

つまり

bash
mkdir hoge
cd !$  # cd hoge 

みたいなことをなるべく簡単にfishでやりたい

結論

cdまで打ってから

Alt + ↑ or Alt + ↓を叩けばいい

Alt↑ recalls individual arguments, starting from the last argument in the last line executed. A single press replaces "!$", later presses replace "!!:4" and the like.

ちなみに

!$はひどいインターフェースだってfishのFAQに書いてあった

0
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?