This article was originally published on iTerm2, Prezto, and Solarized for Mac High Performance Development

As a developer, I pursue extreme efficiency, so I will pursue efficiency in many details. For example, when typing commands in the command line window, if I can make good use of the shortcut keys, I can type more commands in a short time. IDEA shortcuts, if used well, can produce more code in the same amount of time. This article mainly summarizes my use of iTerm2, extending the Zsh configuration framework Prezto and the installation and configuration of the eye protection theme Solarized.

iTerm2

ITerm2 is a very useful terminal, and one of the first things I installed when I got a new Mac was iTerm2. Here I’ve summarized some of the commonly used iTerm2 shortcuts, the ones that are most frequently used in everyday work and that improve efficiency the most, listed below.

shortcuts The effect
Fn please Jump to the beginning of a line
Fn ➝ Jump to the end of each line
Control u Delete current row
Option please Jumps to the first letter of the current word, delimited by a space
Option ➝ Skip to the end of the current word, delimited by a space
Control w Deletes the cursor position to the first letter of the current word
Cmd d Splits the current Tab window vertically into two child Windows
Cmd Shift d Splits the current Tab window horizontally into two child Windows
Cmd [ In the current Tab page window, move to the previous child window
Cmd ] In the current Tab page window, move to a later child window
Cmd t Create a new Tab page window
Cmd please Move to the previous Tab page window
Cmd ➝ Move to the next Tab page window
Cmd q Exit the iTerm2 program
Cmd Shift ; Search for commands executed in history
Cmd Shift h Search for pasted content in history
Cmd option i Multiple input Windows input commands at the same time, very suitable for operating multiple machines at the same time
Cmd option e Search the contents of multiple Windows

Prezto

Prezto is a Zsh configuration framework designed to simplify the configuration of Zsh. You can use Prezto in two articles: Prezto website and Customizing Your Prezto Prompt.

Zpreztorc files are used to enable the history completion, syntax highlighting, git, and other functions of the plugins. When selecting a theme, you can use prompt -l to list all the themes. Preview the theme’s style according to prompt -p themename. I’m using its classic theme sorin, other themes have not been tried, you can install and configure as you like.

Solarized theme

As a developer, you will need to choose a theme that is better for your eyes because you spend a lot of time in front of various editors every day. Solarized theme is one of the most popular themes, and it is also very good for your eyes. Solarized themes are divided into light and dark themes. I mainly use Typora, iTerm2, IDEA and Visual Studio Code. Here I summarize the methods of setting Solarized themes with these four editors.

Typora set

  1. Typora — > Preferences — > Appearance — > Get Theme, look for the “Solarized” theme on the Web page that opens, and download the theme locally.

  2. Typora — > Preferences — > Appearance — > Open the themes folder, unzip the themes downloaded in the previous step, and copy the relevant files into Typora’s themes folder, as shown below

  3. In the Typora window, select theme — >Solarized Dark or Solarized. The theme format is as follows:

ITerm2 set

The current version of iTerm2 is very simple and comes with a Solarized theme. From iTerm2 — >Preferences — >Profiles, open the configuration window and select the Colors Tab. There is a drop-down box in the lower right corner to select, as shown below:

The IDEA of setting up

  1. You can download and import the Solarized Theme plug-in from the IDEA plug-in market
  2. Searching for theme in preferences, you can see that theme Settings can be set in Appearance

The resources

  1. Ericbanisadr.com/tutorials/s…
  2. medium.com/@adrian.j.c…

This issue focuses on topics such as backend technology, JVM troubleshooting and optimization, Java interview questions, personal growth and self-management, providing readers with front-line developer work and growth experience, looking forward to your harvest here.