iTerm2
Last updated
Last updated
Here's a step-by-step guide to help you set up a nice iTerm2 configuration on your Mac. This setup will focus on aesthetics, productivity, and usability. Weβll cover installing iTerm2, customizing its appearance, adding features, and using some popular tools to enhance your terminal experience.
Download iTerm2:
Visit the and download the latest stable release.
Install iTerm2:
Open the downloaded file and drag the iTerm2 app to your Applications folder.
Launch iTerm2:
Open iTerm2 from your Applications folder.
Set iTerm2 as Default Terminal:
Go to iTerm2
> Make iTerm2 Default Term
in the menu bar.
Check for Updates:
Go to iTerm2
> Check for Updates
to ensure you have the latest version.
Install Powerline Fonts:
Open a new terminal window in iTerm2 and run the following command to clone the Powerline fonts repository:
Navigate to the cloned directory and run the installation script:
After installation, you can remove the cloned repository:
Choose a Color Scheme:
iTerm2 supports custom color schemes. You can download schemes from .
To import a color scheme, go to iTerm2
> Preferences
> Profiles
> Colors
tab, and click Color Presets
> Import
. Select the downloaded .itermcolors
file.
Set a Font:
Go to iTerm2
> Preferences
> Profiles
> Text
.
Choose a Powerline-compatible font like "MesloLGS NF" from the dropdown.
Transparency and Blur:
Go to iTerm2
> Preferences
> Profiles
> Window
.
Adjust the transparency slider and enable blur for a nice effect.
Install Oh My Zsh:
Install Zsh if you havenβt already by running:
Then install Oh My Zsh using the following command:
Choose a Zsh Theme:
Oh My Zsh comes with many themes. You can set a theme by editing the ~/.zshrc
file:
Find the line ZSH_THEME="robbyrussell"
and change it to your desired theme, e.g., agnoster
for a Powerline-like theme:
Install Zsh Plugins:
zsh-syntax-highlighting: Highlights command syntax.
Add the following to your .zshrc
:
zsh-autosuggestions: Suggests commands as you type.
Add the following to your .zshrc
:
Configure Plugins in Zsh:
Edit your .zshrc
file to include plugins:
Reload Zsh Configuration:
After making changes, reload your terminal configuration:
Install Tmux:
Install Tmux via Homebrew:
Configure Tmux:
Create a configuration file:
Add some basic configurations:
Use Tmux:
Start a new Tmux session:
Detach from the session with Ctrl-a d
.
Reattach with:
Hotkeys:
Go to iTerm2
> Preferences
> Keys
to configure key mappings for easier navigation.
Window Management:
Use Cmd-d
to split panes vertically and Cmd-Shift-d
to split horizontally.
Profile Switching:
Create multiple profiles for different tasks, accessible from iTerm2
> Preferences
> Profiles
.
Automation and Scripting:
Explore iTerm2βs scripting capabilities to automate tasks using Python or AppleScript.