LoginSignup
0
1

Iterm2でコマンドを実行させるカスタムウィンドを保存する

Last updated at Posted at 2024-02-12

iTerm2でカスタムウィンドを保存する方法について記載。

カスタムウィンドウを保存(Tabも同様)

1.iTerm2を開いて好きなレイアウトにウィンドウを配置する

2.Window > Save Window Arrangement
で適当な名前で保存

カスタムウィンドウを呼び出し

1.Window > Restore Window Arrangement
から呼び出したいカスタムウィンドウを選択

各Tabごとにコマンドを実行させる

1.Iterm2 > settings > profile からPereferencesを開く

2.Pereferencesのprofileから左下「+」を選択して新しいprofileを作成する

3.作成したprofileを選択し、Nameを指定し、
Commandのsend text at start:の箇所に実行したいコマンドを入力する。

4.コマンド入力画面上で右クリック、New TabからTabに設定したいコマンドのPereferenceを選択する

5.上記を繰り返して、好きなTab、コマンドを設定したらWindow > Save Window Arrangementで全体を保存する。
これで、Window設定を開くだけで複数のTab上で指定したコマンドを実行することができる

各Windowごとにコマンドを実行させる

1.上記「各Tabごとにコマンドを実行させる」と同じ方法でprofileを作成

2.コマンド入力画面上で右クリック、New Windowから設定したいコマンドのPereferenceを選択する

3.別Windowで開くので、同じWindow内でsplit表示にしたい場合は、
右クリック Move Session to Split Paneで移動先をまとめたいWindowを選択する

※splitする際にprofile設定できればスマートに設定できそうだけど現状はできないっぽい。

以上

0
1
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
1