iterm2インストールからfish導入まで
mac新調したのでターミナル環境を一から構築してみた備忘録です。
- iterm2インストール
- hot key設定
- Controlダブルタップで起動するように設定
Mojave
だとこのままでは有効にならない- システム環境設定->セキュリティとプライバシー->プライバシー->アクセシビリティからiterm2を許可する
- fishインストール
brew install fish
- fish有効化
sudo vi /etc/shells
chsh -s /usr/local/bin/fish
- prompt変更
- fish_configで設定画面表示
- promptタブで
minimalist
を選択してSet Promot
ボタン押す
- パッケージマネージャ(fisher)インストール
curl https://git.io/fisher --create-dirs -sLo ~/.config/fish/functions/fisher.fish
- プラグイン追加
- bobthefish
$ fisher add oh-my-fish/theme-bobthefish
- フォント導入
git clone https://github.com/powerline/fonts.git
cd fonts
->./install.sh
- Preferences->Profiles->Hotkey Window->Text->Font で
Roboto Mono for Powerline
を選択 - cloneしたリポジトリは不要なので削除
- Draculaテーマインストール
git clone https://github.com/dracula/iterm.git
cd iterm
open ./iterm/Dracula.itermcolors
- Preferences->Profiles->Colors->Color Presets からDraculaを選択
- cloneしたリポジトリは不要なので削除
- peco
brew install peco
fisher add oh-my-fish/plugin-peco
- 上記コマンドでエラーが出る場合は
fisher omf/plugin-peco
を試す
- 上記コマンドでエラーが出る場合は
- vi ~/.config/fish/config.fish
- bobthefish
function fish_user_key_bindings bind \cr 'peco_select_history (commandline -b)' end
* control + r でコマンド履歴検索できる